From: Mike Gilbert Date: Wed, 3 May 2017 19:32:32 +0000 (-0400) Subject: sys-kernel/dracut: use pkg-config at runtime for systemd X-Git-Url: http://git.tremily.us/gitweb.cgi?a=commitdiff_plain;h=268c6a2f07b64c01a1314f740050cc2cd1e5c8f6;p=gentoo.git sys-kernel/dracut: use pkg-config at runtime for systemd sys-apps/systemd may be moving from /usr/lib/systemd to /lib/systemd in a future release. dracut will automatically call pkg-config at run time if these paths are not in the config file. Package-Manager: Portage-2.3.5_p31, Repoman-2.3.2_p61 --- diff --git a/sys-kernel/dracut/dracut-044-r2.ebuild b/sys-kernel/dracut/dracut-044-r3.ebuild similarity index 88% rename from sys-kernel/dracut/dracut-044-r2.ebuild rename to sys-kernel/dracut/dracut-044-r3.ebuild index 89b9eaf1e9e0..2af888711a72 100644 --- a/sys-kernel/dracut/dracut-044-r2.ebuild +++ b/sys-kernel/dracut/dracut-044-r3.ebuild @@ -16,7 +16,10 @@ IUSE="debug selinux systemd" RESTRICT="test" CDEPEND="virtual/udev - systemd? ( >=sys-apps/systemd-199 ) + systemd? ( + >=sys-apps/systemd-199 + virtual/pkgconfig + ) " RDEPEND="${CDEPEND} app-arch/cpio @@ -95,23 +98,7 @@ src_prepare() { sed -r -e "s|^(udevdir=).*$|\1${udevdir}|" \ -i "${S}/dracut.conf.d/gentoo.conf.example" || die - if use systemd; then - local systemdutildir="$(systemd_get_utildir)" - local systemdsystemunitdir="$(systemd_get_systemunitdir)" - local systemdsystemconfdir="$("$(tc-getPKG_CONFIG)" systemd \ - --variable=systemdsystemconfdir)" - [[ ${systemdsystemconfdir} ]] \ - || systemdsystemconfdir=/etc/systemd/system - einfo "Setting systemdutildir to ${systemdutildir} and ..." - sed -e "5asystemdutildir=\"${systemdutildir}\"" \ - -i "${S}/dracut.conf.d/gentoo.conf.example" || die - einfo "Setting systemdsystemunitdir to ${systemdsystemunitdir} and..." - sed -e "6asystemdsystemunitdir=\"${systemdsystemunitdir}\"" \ - -i "${S}/dracut.conf.d/gentoo.conf.example" || die - einfo "Setting systemdsystemconfdir to ${systemdsystemconfdir}..." - sed -e "7asystemdsystemconfdir=\"${systemdsystemconfdir}\"" \ - -i "${S}/dracut.conf.d/gentoo.conf.example" || die - else + if ! use systemd; then local systemdutildir="/lib/systemd" einfo "Setting systemdutildir for standalone udev to" \ "${systemdutildir}..."