app-emulation/xen: don't install EFI bits with USE=-efi
authorDoug Goldstein <cardoe@gentoo.org>
Sun, 6 Dec 2015 05:28:08 +0000 (23:28 -0600)
committerDoug Goldstein <cardoe@gentoo.org>
Sun, 6 Dec 2015 05:35:14 +0000 (23:35 -0600)
Don't install the EFI bits if the user didn't want them.

Signed-off-by: Doug Goldstein <cardoe@gentoo.org>
app-emulation/xen/xen-4.6.0-r2.ebuild

index 717b3e1e0d4af3baab53b27eeb2c4c531364915a..b67f6392c1855eb7eb0b9ce4fe81f622cf07b40b 100644 (file)
@@ -6,7 +6,7 @@ EAPI=5
 
 PYTHON_COMPAT=( python2_7 )
 
-inherit eutils mount-boot flag-o-matic python-any-r1 toolchain-funcs versionator
+inherit eutils multilib mount-boot flag-o-matic python-any-r1 toolchain-funcs versionator
 
 MY_PV=${PV/_/-}
 MY_P=${PN}-${PV/_/-}
@@ -170,6 +170,9 @@ src_install() {
        fi
 
        emake LDFLAGS="$(raw-ldflags)" DESTDIR="${D}" -C xen ${myopt} install
+
+       # make install likes to throw in some extra EFI bits if it built
+       use efi || rm -rf "${D}/usr/$(get_libdir)/efi"
 }
 
 pkg_postinst() {