app-misc/pax-utils: arm64 stable (bug #725010)
[gentoo.git] / sys-fs / lxcfs / lxcfs-4.0.3.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=7
5
6 inherit autotools systemd
7
8 DESCRIPTION="FUSE filesystem for LXC"
9 HOMEPAGE="https://linuxcontainers.org/lxcfs/introduction/ https://github.com/lxc/lxcfs/"
10 SRC_URI="https://github.com/lxc/lxcfs/archive/${P}.tar.gz"
11
12 LICENSE="Apache-2.0"
13 SLOT="0"
14 KEYWORDS="~amd64"
15
16 # Omit all dbus.  Upstream appears to require it because systemd, but
17 # lxcfs makes no direct use of dbus.
18 # acct-group/lxd needed for the fowners below.
19 RDEPEND="dev-libs/glib:2
20         sys-fs/fuse:0"
21 DEPEND="${RDEPEND}"
22 BDEPEND="sys-apps/help2man"
23
24 RESTRICT="test"
25
26 S="${WORKDIR}/${PN}-${P}"
27
28 src_prepare() {
29         default
30         eautoreconf
31 }
32
33 src_configure() {
34         # Without the localstatedir the filesystem isn't mounted correctly
35         econf --localstatedir=/var
36 }
37
38 src_test() {
39         emake tests
40         tests/main.sh || die "Tests failed"
41 }
42
43 src_install() {
44         default
45
46         # Getting weird file collisions, 
47         # keepdir /var/lib/lxcfs
48         # fowners -R root:lxd /var/lib/lxcfs
49
50         newconfd "${FILESDIR}"/lxcfs-4.0.0.confd lxcfs
51         newinitd "${FILESDIR}"/lxcfs-4.0.0.initd lxcfs
52         systemd_dounit config/init/systemd/lxcfs.service
53 }