From 9a964bc7f58242d9fc71bf2fd532337737ca5107 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Ulrich=20M=C3=BCller?= Date: Sun, 19 May 2019 08:47:25 +0200 Subject: [PATCH] sys-kernel/linux-firmware: Update live ebuild. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Package-Manager: Portage-2.3.66, Repoman-2.3.12 Signed-off-by: Ulrich Müller --- .../linux-firmware-99999999.ebuild | 287 ++++++++++++++---- 1 file changed, 225 insertions(+), 62 deletions(-) diff --git a/sys-kernel/linux-firmware/linux-firmware-99999999.ebuild b/sys-kernel/linux-firmware/linux-firmware-99999999.ebuild index b96ea0707494..7625a280f3c5 100644 --- a/sys-kernel/linux-firmware/linux-firmware-99999999.ebuild +++ b/sys-kernel/linux-firmware/linux-firmware-99999999.ebuild @@ -1,7 +1,7 @@ # Copyright 1999-2019 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI="6" +EAPI=7 inherit savedconfig if [[ ${PV} == 99999999* ]]; then @@ -17,54 +17,60 @@ fi DESCRIPTION="Linux firmware files" HOMEPAGE="https://git.kernel.org/?p=linux/kernel/git/firmware/linux-firmware.git" -LICENSE="linux-firmware ( BSD ISC MIT no-source-code ) GPL-2 GPL-2+" +LICENSE="GPL-2 GPL-2+ GPL-3 BSD MIT || ( MPL-1.1 GPL-2 ) + redistributable? ( + linux-fw-redistributable ( BSD-2 BSD BSD-4 ISC MIT no-source-code ) ) + unknown-license? ( all-rights-reserved )" SLOT="0" -IUSE="savedconfig" +IUSE="+redistributable savedconfig unknown-license" +RESTRICT="binchecks strip + unknown-license? ( bindist )" -DEPEND="" RDEPEND="!savedconfig? ( - !sys-firmware/alsa-firmware[alsa_cards_ca0132] - !sys-firmware/alsa-firmware[alsa_cards_korg1212] - !sys-firmware/alsa-firmware[alsa_cards_maestro3] - !sys-firmware/alsa-firmware[alsa_cards_sb16] - !sys-firmware/alsa-firmware[alsa_cards_ymfpci] - !media-tv/cx18-firmware - ! ${PN}.conf - find * \( \! -type d -and \! -name ${PN}.conf \) >> ${PN}.conf + find * ! -type d ! -name ${PN}.conf >> ${PN}.conf if use savedconfig; then restore_config ${PN}.conf - ebegin "Removing all files not listed in config" - local file delete_file preserved_file preserved_files=() + local file preserved_files=() remove=() while IFS= read -r file; do # Ignore comments. @@ -95,23 +257,13 @@ src_prepare() { done < ${PN}.conf || die while IFS= read -d "" -r file; do - delete_file=true - for preserved_file in "${preserved_files[@]}"; do - if [[ "${file}" == "${preserved_file}" ]]; then - delete_file=false - fi - done - - if ${delete_file}; then - rm "${file}" || die - fi - done < <(find * \( \! -type d -and \! -name ${PN}.conf \) -print0 || die) - - eend || die - - # remove empty directories, bug #396073 - find -type d -empty -delete || die + has "${file}" "${preserved_files[@]}" || remove+=("${file}") + done < <(find * ! -type d ! -name ${PN}.conf -print0 || die) + printf "%s\0" "${remove[@]}" | xargs -0 --no-run-if-empty rm || die fi + + # remove empty directories, bug #396073 + find -type d -empty -delete || die } src_install() { @@ -132,4 +284,15 @@ pkg_preinst() { pkg_postinst() { elog "If you are only interested in particular firmware files, edit the saved" elog "configfile and remove those that you do not want." + + local ver + for ver in ${REPLACING_VERSIONS}; do + if ver_test ${ver} -lt 20190514; then + elog + elog 'Starting with version 20190514, installation of many firmware' + elog 'files is controlled by USE flags. Please review your USE flag' + elog 'and package.license settings if you are missing some files.' + break + fi + done } -- 2.26.2