summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2013-04-17 20:58:36 +0000
committerMichał Górny <mgorny@gentoo.org>2013-04-17 20:58:36 +0000
commitb1b6437e1228ab74b300a67fb33811a6a0e1e819 (patch)
treed4e4f0a0d339731ff1fe5efa7ea6bda197bcc4ad /sys-apps
parentInitial import. (diff)
downloadgentoo-2-b1b6437e1228ab74b300a67fb33811a6a0e1e819.tar.gz
gentoo-2-b1b6437e1228ab74b300a67fb33811a6a0e1e819.tar.bz2
gentoo-2-b1b6437e1228ab74b300a67fb33811a6a0e1e819.zip
Introduce USE=firmware-loader, as suggested by williamh. Check whether kernel supports loading firmwares and warn properly.
(Portage version: 2.2.0_alpha173/cvs/Linux x86_64, signed Manifest commit with key 9627F456F9DA7643!)
Diffstat (limited to 'sys-apps')
-rw-r--r--sys-apps/systemd/ChangeLog7
-rw-r--r--sys-apps/systemd/metadata.xml1
-rw-r--r--sys-apps/systemd/systemd-201.ebuild22
-rw-r--r--sys-apps/systemd/systemd-9999.ebuild22
4 files changed, 43 insertions, 9 deletions
diff --git a/sys-apps/systemd/ChangeLog b/sys-apps/systemd/ChangeLog
index c186bc93fad3..775e51f7c50d 100644
--- a/sys-apps/systemd/ChangeLog
+++ b/sys-apps/systemd/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for sys-apps/systemd
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-apps/systemd/ChangeLog,v 1.122 2013/04/17 18:35:59 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/systemd/ChangeLog,v 1.123 2013/04/17 20:58:36 mgorny Exp $
+
+ 17 Apr 2013; Michał Górny <mgorny@gentoo.org> metadata.xml,
+ systemd-201.ebuild, systemd-9999.ebuild:
+ Introduce USE=firmware-loader, as suggested by williamh. Check whether kernel
+ supports loading firmwares and warn properly.
17 Apr 2013; Michał Górny <mgorny@gentoo.org> systemd-201.ebuild,
systemd-9999.ebuild:
diff --git a/sys-apps/systemd/metadata.xml b/sys-apps/systemd/metadata.xml
index d9a66eac4dca..3223fc38dd23 100644
--- a/sys-apps/systemd/metadata.xml
+++ b/sys-apps/systemd/metadata.xml
@@ -10,6 +10,7 @@
<flag name='audit'>Enable support for <pkg>sys-process/audit</pkg></flag>
<flag name='cryptsetup'>Use libcryptsetup</flag>
<flag name='efi'>Enable EFI support (installs bootctl)</flag>
+ <flag name='firmware-loader'>Enable user-space firmware loader (for kernels prior to 3.8)</flag>
<flag name='gcrypt'>Enable sealing of journal files using gcrypt</flag>
<flag name="gudev">enable libudev gobject interface</flag>
<flag name='http'>Enable embedded HTTP server in journald</flag>
diff --git a/sys-apps/systemd/systemd-201.ebuild b/sys-apps/systemd/systemd-201.ebuild
index bfd25d3e8fe8..b7e1f924c0da 100644
--- a/sys-apps/systemd/systemd-201.ebuild
+++ b/sys-apps/systemd/systemd-201.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-apps/systemd/systemd-201.ebuild,v 1.7 2013/04/17 18:35:59 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/systemd/systemd-201.ebuild,v 1.8 2013/04/17 20:58:36 mgorny Exp $
EAPI=5
@@ -14,8 +14,8 @@ SRC_URI="http://www.freedesktop.org/software/systemd/${P}.tar.xz"
LICENSE="GPL-2 LGPL-2.1 MIT"
SLOT="0"
KEYWORDS="~amd64 ~arm ~ppc64 ~x86"
-IUSE="acl audit cryptsetup doc gcrypt gudev http introspection keymap
- +kmod lzma openrc pam policykit python qrcode selinux static-libs
+IUSE="acl audit cryptsetup doc +firmware-loader gcrypt gudev http introspection
+ keymap +kmod lzma openrc pam policykit python qrcode selinux static-libs
tcpd vanilla xattr"
MINKV="2.6.39"
@@ -73,6 +73,15 @@ pkg_pretend() {
if kernel_is -lt ${MINKV//./ }; then
ewarn "Kernel version at least ${MINKV} required"
fi
+
+ if use firmware-loader; then
+ CONFIG_CHECK+=" ~FW_LOADER"
+ elif kernel_is -lt 3 8; then
+ ewarn "You seem to be using kernel older than 3.8. Those kernel versions"
+ ewarn "require systemd with USE=firmware-loader to support loading"
+ ewarn "firmware. Missing this flag may cause some hardware not to work."
+ fi
+
check_extra_config
fi
}
@@ -80,7 +89,6 @@ pkg_pretend() {
src_configure() {
local myeconfargs=(
--localstatedir=/var
- --with-firmware-path="/lib/firmware/updates:/lib/firmware"
# but pam modules have to lie in /lib*
--with-pamlibdir=$(getpam_mod_dir)
# make sure we get /bin:/sbin in $PATH
@@ -123,6 +131,12 @@ src_configure() {
# Keep using the one where the rules were installed.
MY_UDEVDIR=$(get_udevdir)
+ if use firmware-loader; then
+ myeconfargs+=(
+ --with-firmware-path="/lib/firmware/updates:/lib/firmware"
+ )
+ fi
+
# Work around bug 463846.
tc-export CC
diff --git a/sys-apps/systemd/systemd-9999.ebuild b/sys-apps/systemd/systemd-9999.ebuild
index 1de9f343abfb..79553009cf63 100644
--- a/sys-apps/systemd/systemd-9999.ebuild
+++ b/sys-apps/systemd/systemd-9999.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-apps/systemd/systemd-9999.ebuild,v 1.48 2013/04/17 18:35:59 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/systemd/systemd-9999.ebuild,v 1.49 2013/04/17 20:58:36 mgorny Exp $
EAPI=5
@@ -22,8 +22,8 @@ SRC_URI="http://www.freedesktop.org/software/systemd/${P}.tar.xz"
LICENSE="GPL-2 LGPL-2.1 MIT"
SLOT="0"
KEYWORDS="~amd64 ~arm ~ppc64 ~x86"
-IUSE="acl audit cryptsetup doc gcrypt gudev http introspection keymap
- +kmod lzma openrc pam policykit python qrcode selinux static-libs
+IUSE="acl audit cryptsetup doc +firmware-loader gcrypt gudev http introspection
+ keymap +kmod lzma openrc pam policykit python qrcode selinux static-libs
tcpd vanilla xattr"
MINKV="2.6.39"
@@ -97,6 +97,15 @@ pkg_pretend() {
if kernel_is -lt ${MINKV//./ }; then
ewarn "Kernel version at least ${MINKV} required"
fi
+
+ if use firmware-loader; then
+ CONFIG_CHECK+=" ~FW_LOADER"
+ elif kernel_is -lt 3 8; then
+ ewarn "You seem to be using kernel older than 3.8. Those kernel versions"
+ ewarn "require systemd with USE=firmware-loader to support loading"
+ ewarn "firmware. Missing this flag may cause some hardware not to work."
+ fi
+
check_extra_config
fi
}
@@ -104,7 +113,6 @@ pkg_pretend() {
src_configure() {
local myeconfargs=(
--localstatedir=/var
- --with-firmware-path="/lib/firmware/updates:/lib/firmware"
# but pam modules have to lie in /lib*
--with-pamlibdir=$(getpam_mod_dir)
# make sure we get /bin:/sbin in $PATH
@@ -147,6 +155,12 @@ src_configure() {
# Keep using the one where the rules were installed.
MY_UDEVDIR=$(get_udevdir)
+ if use firmware-loader; then
+ myeconfargs+=(
+ --with-firmware-path="/lib/firmware/updates:/lib/firmware"
+ )
+ fi
+
# Work around bug 463846.
tc-export CC