dev-python/pytest: arm64 stable (bug #723996)
[gentoo.git] / sys-fs / bcache-tools / bcache-tools-1.0.8.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=5
5
6 inherit toolchain-funcs udev
7
8 DESCRIPTION="Tools for bcachefs"
9 HOMEPAGE="https://bcache.evilpiepirate.org/"
10 SRC_URI="https://github.com/g2p/bcache-tools/archive/v${PV}.tar.gz -> ${P}.tgz"
11
12 SLOT="0"
13 LICENSE="GPL-2"
14 KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
15 IUSE=""
16
17 RDEPEND=">=sys-apps/util-linux-2.24"
18 DEPEND="${RDEPEND}"
19
20 src_prepare() {
21         tc-export CC
22         sed \
23                 -e '/^CFLAGS/s:-O2::' \
24                 -e '/^CFLAGS/s:-g:-std=gnu89:' \
25                 -i Makefile || die
26 }
27
28 src_install() {
29         into /
30         dosbin make-bcache bcache-super-show
31
32         exeinto $(get_udevdir)
33         doexe bcache-register probe-bcache
34
35         udev_dorules 69-bcache.rules
36
37         insinto /etc/initramfs-tools/hooks/bcache
38         doins initramfs/hook
39
40         # that is what dracut does
41         insinto /usr/lib/dracut/modules.d/90bcache
42         doins dracut/module-setup.sh
43
44         doman *.8
45
46         dodoc README
47 }
48
49 pkg_postinst() {
50         udev_reload
51 }