diff options
Diffstat (limited to 'sys-firmware')
17 files changed, 573 insertions, 91 deletions
diff --git a/sys-firmware/Manifest.gz b/sys-firmware/Manifest.gz Binary files differindex c6bd4ccbcb85..c721a0545ee5 100644 --- a/sys-firmware/Manifest.gz +++ b/sys-firmware/Manifest.gz diff --git a/sys-firmware/broadcom-bt-firmware/Manifest b/sys-firmware/broadcom-bt-firmware/Manifest index f27f0162f2cb..b067affe3ca4 100644 --- a/sys-firmware/broadcom-bt-firmware/Manifest +++ b/sys-firmware/broadcom-bt-firmware/Manifest @@ -1,5 +1,3 @@ -DIST broadcom-bt-firmware-12.0.1.1105_p3.tar.gz 2332072 BLAKE2B 819a95230a19c1f2dcdd0648ae9f29275ddfc133c86c0fcf85657aa1e52baede10e061e5b2a2c0c6b795d83813f86a67ea0378c21b0f2b961439a146241127d8 SHA512 96de9704d392c0d7bbdc4a094d7fbaf3904854af2ac05081cff7c29cfc11690a47e45674af82af33a0a9741a44c68bf6e3801ccdaaa84de8ba0d36039d89f412 DIST broadcom-bt-firmware-12.0.1.1105_p4.tar.gz 2332067 BLAKE2B cc6c2b7b30ec1d7b3cedb1a836be603db60e48d13b02108e7ce4b72dfddea9997d115a4af25f6192c54d4ad4c0acb259b7079885fadf41e9e2e58cdaabf62dad SHA512 f37017d6ae17ed89199e9c87e2f603ba21e278ba75c5c0a62f9b0ed8f2f9118f42e19486cc73b3e9153db79699909581a4f5154a6ce862343f50905eb43afcfa -EBUILD broadcom-bt-firmware-12.0.1.1105_p3.ebuild 437 BLAKE2B 94d271570822d53888f4556a830fb6a7bd01ac3901f67e6a95ee773834c49d9c6c29ba9721f8ffcab44d84bb47df0984d2b8420bf9a1f96929ed0b623717f5fa SHA512 c2926c9cd988d1b59bdc38bd4097472029850391719d8c904e7c56ebc5fe083ac647f3f2569d20cfcbd581ad0d2da5e8368c83bcfbcfc6fd49c03c4fe02e6f88 -EBUILD broadcom-bt-firmware-12.0.1.1105_p4-r1.ebuild 1615 BLAKE2B 23c0230d0166288f0d3e17c48b3f33d7be984f740674fbc76a69564a025f339f1cc426f0797f7abadde6525d8fc0a7699ad81751999d52d319668a7a4018a9a6 SHA512 91bcdbae7f4f5391a3bee5b158c8bb0c9f03bf16823ea08f9f0e152b3982ab99c8f2383d568b5e1b7283f43277160cd48c7b6d95e4db0a2db688adc0d144c7fa +EBUILD broadcom-bt-firmware-12.0.1.1105_p4-r1.ebuild 1613 BLAKE2B c9004ef2fd4a5c94090de7f4e24bebe2a25c13118a6824e60bda320f916ef26532690457eb8ae1722bf8dae312ffae1d55944def1e9ce03044e172b4af24a4c0 SHA512 f9fc88d3eba4c3cbe884920beb2c031994fbaa303024838e1a64cd5e2117152a106921d0d39c46d699c14551c2aa2507a0f5b4923e173371fb906661b478c2c3 MISC metadata.xml 739 BLAKE2B da665133a1c8ea34227c2b4c56b29afb030d25bfc2ff4df864cef17ca1aca38e06ffc535b63f2c0257ea5e4dd2d869118dc830ca6a233d55c0b07c738c1bc60d SHA512 7493ee8e24b9cac82100cd3cc62f8b11f7059f4dd8cd3f58f965d5773fd25844fd2f0263aa29515aaf073d2c50e24de6c81080d62792c54f7bfc5c4be6b3a87c diff --git a/sys-firmware/broadcom-bt-firmware/broadcom-bt-firmware-12.0.1.1105_p3.ebuild b/sys-firmware/broadcom-bt-firmware/broadcom-bt-firmware-12.0.1.1105_p3.ebuild deleted file mode 100644 index 14cb24207a0d..000000000000 --- a/sys-firmware/broadcom-bt-firmware/broadcom-bt-firmware-12.0.1.1105_p3.ebuild +++ /dev/null @@ -1,18 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -DESCRIPTION="Broadcom Bluetooth firmware" -HOMEPAGE="https://github.com/winterheart/broadcom-bt-firmware" -SRC_URI="https://github.com/winterheart/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" - -LICENSE="broadcom_bcm20702 MIT" -SLOT="0" -KEYWORDS="amd64 ~ppc64 x86" -IUSE="" - -src_install() { - insinto /lib/firmware - doins -r brcm -} diff --git a/sys-firmware/broadcom-bt-firmware/broadcom-bt-firmware-12.0.1.1105_p4-r1.ebuild b/sys-firmware/broadcom-bt-firmware/broadcom-bt-firmware-12.0.1.1105_p4-r1.ebuild index ad2af756d59c..ce54409bf8e9 100644 --- a/sys-firmware/broadcom-bt-firmware/broadcom-bt-firmware-12.0.1.1105_p4-r1.ebuild +++ b/sys-firmware/broadcom-bt-firmware/broadcom-bt-firmware-12.0.1.1105_p4-r1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2023 Gentoo Authors +# Copyright 1999-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -10,7 +10,7 @@ SRC_URI="https://github.com/winterheart/${PN}/archive/v${PV}.tar.gz -> ${P}.tar. LICENSE="broadcom_bcm20702 MIT" SLOT="0" -KEYWORDS="~amd64 ~ppc64 ~x86" +KEYWORDS="amd64 ~ppc64 x86" # Re-use compress-* USE flags from sys-kernel/linux-firmware. IUSE="compress-xz compress-zstd" REQUIRED_USE="?? ( compress-xz compress-zstd )" diff --git a/sys-firmware/edk2-ovmf/Manifest b/sys-firmware/edk2-ovmf/Manifest index 41fccf39a281..b24ae755f6f4 100644 --- a/sys-firmware/edk2-ovmf/Manifest +++ b/sys-firmware/edk2-ovmf/Manifest @@ -8,8 +8,14 @@ DIST edk2-ovmf-202105-r1-bin.tar.xz 2633188 BLAKE2B 93b4bd1c75da69406b5d27ac32d8 DIST edk2-ovmf-202105.tar.gz 13702868 BLAKE2B 3ec01d467562380ca2fd3bd807d2f6c55e4637c1afd71533f8f5b22cc634dc4c8cb63dab921677f8b315d17b3c9d0b6b00a0e2f3f8da61107033e9e81bf5a64d SHA512 c263345cbb243c63985f974a61f37c577a139d6a7099d2b8c9e1a553e5ebf16de12fb711b72624081c6bf637f8084bbf71731ab99e5747d81da460388ac25791 DIST edk2-ovmf-202202-qemu-firmware.tar.xz 664 BLAKE2B 1aa4e25804ce0f3c967c80999315de24eaef6682e42dddd81c274ce4603ec3d15186de752de49e2527c6bd5517080c002a357ed6bc389b5afd6f7a4d93edeb44 SHA512 f9a29212274a99796784673d873e0eee7d3e2a5cf9e63192453841ee3a4ef4b813c7b2357fc7000f39c71ed6c66636daab772abb51d3972a2a56ade8a4c68faf DIST edk2-ovmf-202202.tar.gz 14208170 BLAKE2B d8411e6808b335ccd551349a10c983b9448a357e73273fa6c30a07785e27feffed0224950ee98b668712c33f6739a9b006e5043b7dfd014f48dba9fd449b3354 SHA512 200690a4867331de06e0478869b85577bc510213ebe679f2103160efb84d94c82ac8481ef1f15c3e42c1e9f22b7c5ef0d6c8f2c655bce7702ce843551cf9bb83 +DIST edk2-ovmf-202405.tar.gz 17091190 BLAKE2B ee2f4c8674ecd7a17e4ee1b067cf1caffb46c3345f39ab15b715964b8e114d01538ae4d4152ab6a3eeebdae602128604d57c02fc0da83f46c291559fe39f49d2 SHA512 3bad4c8417b0c9b68fc6b6b85a4b15c5be8daf672177ce66d7b224b1da7a90f643021adbdd6bc96f95417fc8654c4c6b191cd39f6c1be955946360bfa8e2cb5f +DIST libspdm-370b5944c046bab043dd8b133727b2135af7747a.tar.gz 1962880 BLAKE2B 89606315fadcf00b2909f264a6edcb2b900dfe248357ea45c37c5a9c947a4d684866627d85132cc51d44d90853d63814eaf9d2b4acdd1a9621b1d6600ca4a0a4 SHA512 07b2b376a84e86647d7a831ee6686d1cf647033ac339afb7c4ea7846cf4e9f7f529a2866bc68ea172d44f1f1efadc8bf1646c3d7fe7e6b6175286ef9c743b206 +DIST mbedtls-370b5944c046bab043dd8b133727b2135af7747a.tar.gz 4587796 BLAKE2B c28df5c52ac3ed5ef6a2b9eba29f3894d3f5f11083869e8b137cd66d4f72b2a0971c91636ce4626869bd06eeb5e661d90160021f92564b9449fb13001b8e379f SHA512 a421c03c740867210f9e30457bc951928cafec3622e1e304f8c18ce5c5e27c5c8e6c7715180ecb74c6a997e4b91ee160e52b357e1bb65ff76ce8414a87ec4889 +DIST mipi-sys-t-370b5944c046bab043dd8b133727b2135af7747a.tar.gz 378522 BLAKE2B d3f1033e78ad814ebb991e66d8c1437aa3583e91481af9785b97b6021c7c45fb9dcb8d2d58d0a0fe84fbd9f108d24a27234df298eb8a2ba2340e5c9c85c89c40 SHA512 de6888577ceab7ab6915d792f3c48248cfa53357ccd310fc7f7eae4d25a932de8c7c23e5b898c9ebf61cf86cb538277273f2eb131a628b3bf0d46c9a3b9b6686 DIST openssl-d82e959e621a3d597f1e0d50ff8c2d8b96915fd7.tar.gz 10034310 BLAKE2B 6996979dc12a523d565830e7b0943feb682a376f71ddb6f20cb8b9976bb7f12e39f088abaa45d514933ef79c0e4a2933dc6f1af4774fedaa16e74c0081c358e7 SHA512 a89bc652dc4318c5e8a9c594a43d890ca05dfc1acd6b15e2a8ab8b5628b5f33994143ff8024230e07b9e67556b28ea3a5e36763aa72dec20b52022ca8c6f2a7e +DIST openssl-de90e54bbe82e5be4fb9608b6f5c308bb837d355.tar.gz 15337569 BLAKE2B bb0b2f4ee7838178e8e23317b6c63048611d805e20c81d6c875d9b515e6dbcf981cda38f031965c9ec45bcab3ac4725cfa793718b0212e92bf53b4c7fc3f4e32 SHA512 4bba15075dacc8c1772a95759cfe8620ff3a9d535e5d3d29bb15e4790cc543555ab45f0b239195361e534eca26249ae1b491b63cbf6b7ecda6f0840c7f6253ac DIST openssl-e2e09d9fba1187f8d6aafaa34d4172f56f1ffb72.tar.gz 9981169 BLAKE2B 33aac7364cdd45fec5654ab6caef84e1a829464380419c8a6bb311055c5a01c0aaff6e046a7c541a87e908fa9d26bae652f5be901461d03df36f2522f9c34b0c SHA512 db2087c04f0b428b3f4e1c8b3ac53cce69e0fd331ed2b86ba00facafd1685864d73f71c13eee48f4fe0af2bddad848f84a2b8ed2a17fabdf7fa2ed7d9eb39371 EBUILD edk2-ovmf-202105-r2.ebuild 5146 BLAKE2B 0b95c308f5eb022c48bb1f3fdeaae7ba6db80f4aa789078a0ea8c819c04635ed3b64e4f8c421daf768c89987cee2c3792d87097669d610a62dd80a377f585bbc SHA512 0ab8889e97dea11eb74140421e819911579e32d3b6c632c8b6ad66b2e79ecf0eba7a92c40480f66a815ee9c4ff6806b17f345f8c8ed7c33bc13b2c2038dc2bd9 EBUILD edk2-ovmf-202202.ebuild 4967 BLAKE2B 9fdf9c6b4ef25088ff83ea47e0cf6adcf18045cc60edbfbd4a64082c0df0c0c739c3d8c25564f97c29bf7ecaaf89d0cfb593e1a9e9363c84dde1a001403f7088 SHA512 a8e13032b229f7a528f5a75267600cada5aeccca7479cc31168e699458b55ccbc54286051ce7c45d71979f828c760e2629129dbfaa8f972954fde7168fa88022 +EBUILD edk2-ovmf-202405.ebuild 5711 BLAKE2B ccfe098446b4005b41b3f46f807ce42915fa7e6e8589a523007f1dfebc5fe6aba71f90612aaf2822b96d0a0097455d934b6e6b819d9cca8351cd092b2165868f SHA512 322de8cc1f77ad1826aee73c555a033c50efb2684041f858506fa2670854cf547a620f6ef2187f9e178ea961daf779cba80ba7221da633cb9c1ec332637c7ffb MISC metadata.xml 465 BLAKE2B b01ef675398176557e2f4099083231b60ad8c26ab84fbcfc24e0ef44963670aeda6aa625910964c56822299bb0e0e966f6a1e3768df2ddd2dec82c6c0b92a68a SHA512 f78ae0b027aaac140a23b85d0b219342b5ccc3692f337065f9f282622ec98289c270105af45eeb1d8fd4a707cee59e1d52ef13e947c297e52f2f8a1896276ef1 diff --git a/sys-firmware/edk2-ovmf/edk2-ovmf-202405.ebuild b/sys-firmware/edk2-ovmf/edk2-ovmf-202405.ebuild new file mode 100644 index 000000000000..252893dab349 --- /dev/null +++ b/sys-firmware/edk2-ovmf/edk2-ovmf-202405.ebuild @@ -0,0 +1,161 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_REQ_USE="sqlite" +PYTHON_COMPAT=( python3_12 ) + +inherit python-any-r1 readme.gentoo-r1 secureboot + +DESCRIPTION="UEFI firmware for 64-bit x86 virtual machines" +HOMEPAGE="https://github.com/tianocore/edk2" + +BUNDLED_OPENSSL_SUBMODULE_SHA="de90e54bbe82e5be4fb9608b6f5c308bb837d355" +BUNDLED_BROTLI_SUBMODULE_SHA="f4153a09f87cbb9c826d8fc12c74642bb2d879ea" +BUNDLED_MIPI_SYS_T_SUBMODULE_SHA="370b5944c046bab043dd8b133727b2135af7747a" +BUNDLED_MBEDTLS_SUBMODULE_SHA="8c89224991adff88d53cd380f42a2baa36f91454" +BUNDLED_LIBSPDM_SUBMODULE_SHA="828ef62524bcaeca4e90d0c021221e714872e2b5" + +SRC_URI="https://github.com/tianocore/edk2/archive/edk2-stable${PV}.tar.gz -> ${P}.tar.gz + https://github.com/openssl/openssl/archive/${BUNDLED_OPENSSL_SUBMODULE_SHA}.tar.gz -> openssl-${BUNDLED_OPENSSL_SUBMODULE_SHA}.tar.gz + https://github.com/google/brotli/archive/${BUNDLED_BROTLI_SUBMODULE_SHA}.tar.gz -> brotli-${BUNDLED_BROTLI_SUBMODULE_SHA}.tar.gz + https://github.com/MIPI-Alliance/public-mipi-sys-t/archive/${BUNDLED_MIPI_SYS_T_SUBMODULE_SHA}.tar.gz -> mipi-sys-t-${BUNDLED_MIPI_SYS_T_SUBMODULE_SHA}.tar.gz + https://github.com/Mbed-TLS/mbedtls/archive/${BUNDLED_MBEDTLS_SUBMODULE_SHA}.tar.gz -> mbedtls-${BUNDLED_MIPI_SYS_T_SUBMODULE_SHA}.tar.gz + https://github.com/DMTF/libspdm/archive/${BUNDLED_LIBSPDM_SUBMODULE_SHA}.tar.gz -> libspdm-${BUNDLED_MIPI_SYS_T_SUBMODULE_SHA}.tar.gz + https://dev.gentoo.org/~ajak/distfiles/${PN}-202202-qemu-firmware.tar.xz" + +S="${WORKDIR}/edk2-edk2-stable${PV}" + +LICENSE="BSD-2 MIT" +SLOT="0" +KEYWORDS="-* ~amd64" + +BDEPEND="app-emulation/qemu + >=dev-lang/nasm-2.0.7 + >=sys-power/iasl-20160729 + ${PYTHON_DEPS}" +RDEPEND="!sys-firmware/edk2-ovmf-bin" + +DISABLE_AUTOFORMATTING=true +DOC_CONTENTS="This package contains the tianocore edk2 UEFI firmware for 64-bit x86 +virtual machines. The firmware is located under + /usr/share/edk2-ovmf/OVMF_CODE.fd + /usr/share/edk2-ovmf/OVMF_VARS.fd + /usr/share/edk2-ovmf/OVMF_CODE.secboot.fd + +If USE=binary is enabled, we also install an OVMF variables file (coming from +fedora) that contains secureboot default keys + + /usr/share/edk2-ovmf/OVMF_VARS.secboot.fd + +If you have compiled this package by hand, you need to either populate all +necessary EFI variables by hand by booting + /usr/share/edk2-ovmf/UefiShell.(iso|img) +or creating OVMF_VARS.secboot.fd by hand: + https://github.com/puiterwijk/qemu-ovmf-secureboot + +The firmware does not support csm (due to no free csm implementation +available). If you need a firmware with csm support you have to download +one for yourself. Firmware blobs are commonly labeled + OVMF{,_CODE,_VARS}-with-csm.fd + +In order to use the firmware you can run qemu the following way + + $ qemu-system-x86_64 \ + -drive file=/usr/share/edk2-ovmf/OVMF.fd,if=pflash,format=raw,unit=0,readonly=on \ + ..." + +pkg_setup() { + python-any-r1_pkg_setup + secureboot_pkg_setup +} + +src_prepare() { + # Bundled submodules + cp -rl "${WORKDIR}/openssl-${BUNDLED_OPENSSL_SUBMODULE_SHA}"/* "CryptoPkg/Library/OpensslLib/openssl/" \ + || die "copying openssl failed" + cp -rl "${WORKDIR}/brotli-${BUNDLED_BROTLI_SUBMODULE_SHA}"/* "BaseTools/Source/C/BrotliCompress/brotli/" \ + || die "copying brotli failed" + cp -rl "${WORKDIR}/brotli-${BUNDLED_BROTLI_SUBMODULE_SHA}"/* \ + "MdeModulePkg/Library/BrotliCustomDecompressLib/brotli/" || die "copying brotli failed" + cp -rl "${WORKDIR}/public-mipi-sys-t-${BUNDLED_MIPI_SYS_T_SUBMODULE_SHA}"/* "MdePkg/Library/MipiSysTLib/mipisyst/" \ + || die "copying mipi-sys-t failed" + cp -rl "${WORKDIR}/mbedtls-${BUNDLED_MBEDTLS_SUBMODULE_SHA}"/* "CryptoPkg/Library/MbedTlsLib/mbedtls/" \ + || die "copying mbedtls failed" + cp -rl "${WORKDIR}/libspdm-${BUNDLED_LIBSPDM_SUBMODULE_SHA}"/* "SecurityPkg/DeviceSecurity/SpdmLib/libspdm" \ + || die "copying libspdm failed" + + default +} + +src_compile() { + TARGET_ARCH=X64 + TARGET_NAME=RELEASE + TARGET_TOOLS=GCC5 + + BUILD_FLAGS="-D TLS_ENABLE \ + -D HTTP_BOOT_ENABLE \ + -D NETWORK_IP6_ENABLE \ + -D TPM_ENABLE \ + -D TPM2_ENABLE -D TPM2_CONFIG_ENABLE \ + -D FD_SIZE_2MB" + + SECUREBOOT_BUILD_FLAGS="${BUILD_FLAGS} \ + -D SECURE_BOOT_ENABLE \ + -D SMM_REQUIRE \ + -D EXCLUDE_SHELL_FROM_FD" + + export LDFLAGS="-z notext" + export EXTRA_LDFLAGS="-z notext" + export DLINK_FLAGS="-z notext" + + emake ARCH=${TARGET_ARCH} -C BaseTools + + . ./edksetup.sh + + # Build all EFI firmware blobs: + + mkdir -p ovmf || die + + ./OvmfPkg/build.sh \ + -a "${TARGET_ARCH}" -b "${TARGET_NAME}" -t "${TARGET_TOOLS}" \ + ${BUILD_FLAGS} || die "OvmfPkg/build.sh failed" + + cp Build/OvmfX64/*/FV/OVMF_*.fd ovmf/ + rm -r Build/OvmfX64 || die + + ./OvmfPkg/build.sh \ + -a "${TARGET_ARCH}" -b "${TARGET_NAME}" -t "${TARGET_TOOLS}" \ + ${SECUREBOOT_BUILD_FLAGS} || die "OvmfPkg/build.sh failed" + + cp Build/OvmfX64/*/FV/OVMF_CODE.fd ovmf/OVMF_CODE.secboot.fd || die "cp failed" + cp Build/OvmfX64/*/X64/Shell.efi ovmf/ || die "cp failed" + cp Build/OvmfX64/*/X64/EnrollDefaultKeys.efi ovmf || die "cp failed" + + # Build a convenience UefiShell.img: + + mkdir -p iso_image/efi/boot || die "mkdir failed" + cp ovmf/Shell.efi iso_image/efi/boot/bootx64.efi || die "cp failed" + cp ovmf/EnrollDefaultKeys.efi iso_image || die "cp failed" + qemu-img convert --image-opts \ + driver=vvfat,floppy=on,fat-type=12,label=UEFI_SHELL,dir=iso_image \ + ovmf/UefiShell.img || die "qemu-img failed" +} + +src_install() { + insinto /usr/share/${PN} + doins ovmf/* + + insinto /usr/share/qemu/firmware + doins "${S}"/../edk2-edk2-stable202202/qemu/* + rm "${ED}"/usr/share/qemu/firmware/40-edk2-ovmf-x64-sb-enrolled.json || die "rm failed" + + secureboot_auto_sign --in-place + + readme.gentoo_create_doc +} + +pkg_postinst() { + readme.gentoo_print_elog +} diff --git a/sys-firmware/intel-microcode/Manifest b/sys-firmware/intel-microcode/Manifest index 0098c1aa2459..58401575e503 100644 --- a/sys-firmware/intel-microcode/Manifest +++ b/sys-firmware/intel-microcode/Manifest @@ -1,13 +1,16 @@ -AUX 35-intel-microcode-systemd.install 1274 BLAKE2B 302f5428a8ca7590ced274f3aef251fd7a00a922466d5599dde8f20c088a38438f9f1a4d4c99dd5752e5788927142bc3beff7c64ec6b93922af405a570dbe925 SHA512 cb1a2c8e31dd79550bcce854f7ddd4a955cac25caebc94b9fbe803274fc3e503055ea515420faaf750f39b341cddf9d8b436d05e5c1895a44d6d3c060a5549c2 -AUX 35-intel-microcode.install 1320 BLAKE2B 6b4209e1e622c50eefae1666d3192e2c5a2f1e558be25b0dabc8fda1d065495c398ef39162ce7c1e6729d30770fca47f1e58ba9c43e49570fbb0d3395998363d SHA512 2c36f6af1f26e5596c9cac120d82152ac84c7c32db722c8b50e43365f434562a7e4ae87a36bcc4c695793b6a4a4930811e8aa71e30fddfaff786c5ae4cd7b93b +AUX 35-intel-microcode-systemd.install 1441 BLAKE2B d730b8297190a11952e136b6471f174b6a62f85365281cab21006e82a73ce16c233c16d2203dd42e0f381352f100337eade1758f73fb824cee3d2138befca8c6 SHA512 8b4bf710f4684c08554a72f92d61b240a2fab808299e13f6cdc124ede67c98923271c9c734e23943e1db29193b715391f266168b4bcb61d37b2a7de109581bb1 +AUX 35-intel-microcode.install 1442 BLAKE2B 6f4bf74d05986836d4da4b4bd6a4d82243fe29f5f658f5475ff8a44ad45a3afd68001f18912865d5429d45788ffdd72be08d7862c65d40d108446f7828f22df9 SHA512 7d6a53ab788c3225ecda78997dabee7bc132245890a86a9cd5fcdfa633dd665de3870ee5b608a26b15276a0014d53312a69baa00d6a8ac9c5d33e1688128da5a DIST intel-microcode-collection-20240312.tar.xz 13484040 BLAKE2B 947f78698211b372472629e7fdf076021db97f156d812ec2a84c5ab3d5ee374e04191f7881c956c261c6a6a5935b2c779b837879677ee98d44cf8c753a4393b8 SHA512 de577f232035a92ce563475edb4572c6fa40a0a2ee8e76b858de1ca42f905d366d107bf02e4968127ad6fe150baf37e11ed93191e40c1c5913ba34fe77184c00 DIST intel-microcode-collection-20240514.tar.xz 13421016 BLAKE2B 83b7d213709bf8c1ea1b62456974cf6a2087470d9e2456ef3de93569007cfa8c94021a21a9f3f7b638ffe4b2ad0f516deda04a1c630e54f35709e92a113a7683 SHA512 4cc364b19355f133dae0178f7d10b50abcc0e6e7919e646cfc756c8ff8dc1d6d0819abae6f5cb7f659f0466ee31196625cf022bb994f500ab08e93238a66d104 DIST intel-microcode-collection-20240526.tar.xz 14673584 BLAKE2B 262f667ac46e190994e86f547c98ac776c73b1576c208fa32df96a2dd60af6cda9bd0b0367ca68bb6b85fd19f75913e73069d0064eb2b4c560068c3da50618c8 SHA512 4227c68ba60aea940b851f10d1006ee42b45d55425eb143210adeb363468238329d4a2720d117f5bdaeb9857ae29a6952a3df22769f4436638a9080ded6793ba +DIST intel-microcode-collection-20240815.tar.xz 15458512 BLAKE2B 17b3719961a30d18aecb7b5094de5250e36a6eaa2f880a020ca38762d8a037b7e25f322cc1cbb3000a520007beb0d47d6b4f4940c47fac2082c9c2a3fa3be5d4 SHA512 6faddcac20184424bbe0488dce8df31479b89da9affb5c2f2d93f2bccc045d41105d5a10e3c56ba48cf27853a089334adac6e42a27c5fb63e86f0ed7c51bbc42 DIST intel-ucode-sig_0x406e3-rev_0xd6.bin 101376 BLAKE2B 66d55867954d69dda1425febd93bb8c89f7aa836d504f8b5fee127f8505bcf2246f4fcc55cc245bc5e532528d60cca2eee278de7ab5174dc2862db7982a2b36f SHA512 248066b521bf512b5d8e4a8c7e921464ce52169c954d6e4ca580d8c172cd789519e22b4cf56c212e452b4191741f0202019f7061d322c9433b5af9ce5413b567 DIST microcode-20240312.tar.gz 12825665 BLAKE2B 43c771becef0f6dbfd41bf78a9a3cc8f6679a43ea48765d0e7f555c138dca6e3db42a4d33f743d8d51f38b0b6aa69322bba0c00ae9f1ff4c533b52166ee54747 SHA512 f5f3dfb1706675060b00057b5f017c2cb4ac0df74727139185fd167ca67fc6c611e205b1caeded23b006e4d8d314f87537007e7bafba2c87373f6d960988c911 DIST microcode-20240514.tar.gz 12870457 BLAKE2B 2a3a357ecf8d9f17fd20cd651386e5687fbbca8a3a323caf846e7c84d440241c3c99cadd00016642c8d11f297c1d2ab63c54ea062644839b74f84d66b04c703e SHA512 1c0f1707bf7db70d04e94a0728c0f61a1f9c25fead8c2c3716cafd20c976973cf636e411d12f81b34bf0076d7c7601c11b1bcd92a2e1be35d98003bb61ace569 DIST microcode-20240531.tar.gz 12870497 BLAKE2B 6a2c5ee6b6f3543b28f3753b30812e360bad50776b4f81e32a832e2169f38c11f8d5108ce0a81ddcdf1ecf7557baf1fd62c053a365f39a33ded5fd5018580b1f SHA512 fb9d772491f279ebb691248e4a665da45c986ca7b4668ecf311c5fcb91a42400f7a5b35e8bfc31ceb1c9d598e753c817359900e3fa316d825f8ecec21ec63cfe +DIST microcode-20240813.tar.gz 12879301 BLAKE2B f6a157de1f2c14e0e4d08ec71304451a52c7a0ffcfc79a1ebce7e8c16c7405587369c9cad994b8bdb0a987d4fe2769b2988948ffd9fe1e7f117eb624cf579b63 SHA512 ba1fa7d9bed7d90756ea959f5878afca0deacc9b1e932a936a15d74a411b7efb6103a4af75dc3731d9cbb2e464439ce9a7d448f75bc6f38b616907ff6dec6ee3 EBUILD intel-microcode-20240312_p20240312.ebuild 11701 BLAKE2B 311c85bb20393d56faf922bab93eb56ac9d4fcf61f25e00bb38e0610c74d6b90ac6d3f858be17bf4b701d66e95d637a57bf7e162284c799c347e4f1e58b9d1f9 SHA512 d6098dc85df3e8fe6e0538b95c24585d8c087e73f34b709c1f011492a50d91beb5bd627fa3d075a3d035e2817ac955f168b8da6f19675cf013ef92e2bf8bed59 EBUILD intel-microcode-20240514_p20240514.ebuild 11701 BLAKE2B 311c85bb20393d56faf922bab93eb56ac9d4fcf61f25e00bb38e0610c74d6b90ac6d3f858be17bf4b701d66e95d637a57bf7e162284c799c347e4f1e58b9d1f9 SHA512 d6098dc85df3e8fe6e0538b95c24585d8c087e73f34b709c1f011492a50d91beb5bd627fa3d075a3d035e2817ac955f168b8da6f19675cf013ef92e2bf8bed59 -EBUILD intel-microcode-20240531_p20240526-r1.ebuild 12041 BLAKE2B dfc50a9dcd8a1e334e206107d2d6d0c6c2f075fa24daa98ade7777274c678c5d3c8a61c31e12aefcd53e6d01bbc233868a1955b95a641572aa50fb024b8733ab SHA512 3fe2d5ba1fd6911600f4479de6281cdfa061a1f9003c64270873a5373d2c58d132f01b43e4c7fced562e833fe90f09274e840bf44afd83a4f232d9f4908601a8 +EBUILD intel-microcode-20240531_p20240526-r2.ebuild 12100 BLAKE2B 325631f9a46c1e94cd47f46267743b72507ae465abc27e723bf7a0a8b67d55dfa15e9e2f578a174489cd64c55de638c37aefa5ad1ecf13580e651744dc2b9c99 SHA512 dca8d2344f21e0ee2e4a72458825073c4309e2dd9b380d4cacda404bbdd2228c0cd15cfca7d95d1a5c5e1e3de501c1d8a71e9d3044860542ebba852316a450f7 +EBUILD intel-microcode-20240813_p20240815.ebuild 12102 BLAKE2B bb133f39838ca995b90019bae4d3b67ab8fc5e8f106ddeb0455448e1bb91d35bacbe0fbfcabd72e550f67b3ae23dc88ce07e09fbc6c4dc10483d23aa074cd3d3 SHA512 944574fe929fc18dd06dc63f03da44e54838fbed17f96ff85e35036c9b5249c5aa180818fd0f0433cc2614c18d8ff39a7878d41ceb9a9b13e9777280a690cf61 MISC metadata.xml 853 BLAKE2B b9103bc6c00cd36211b33060a28dc72159fa1309644f6dc8005c415c8eb435217f1e39ba70a289bf9f93a3edac7e73f2227bfe711e745f8743ae455e2d1caa4a SHA512 c425c341725210af9693ed50ae9b9f91cd4c44539f1abe5fff9f59c3441eed39aee6746c881f7a812aec1bab1a8c4974e111980211cf4cfb55e1bdb12e394631 diff --git a/sys-firmware/intel-microcode/files/35-intel-microcode-systemd.install b/sys-firmware/intel-microcode/files/35-intel-microcode-systemd.install index 7ad7b8c49e83..58593a675b37 100644 --- a/sys-firmware/intel-microcode/files/35-intel-microcode-systemd.install +++ b/sys-firmware/intel-microcode/files/35-intel-microcode-systemd.install @@ -35,13 +35,18 @@ opts=( --no-downgrade ) -if [[ ${KERNEL_INSTALL_VERBOSE} == 1 ]]; then - echo "Generating Intel CPU Microcode early initramfs image..." - opts+=( - --list-all - --list - ) +if [[ -d /lib/firmware/intel-ucode ]]; then + if [[ ${KERNEL_INSTALL_VERBOSE} == 1 ]]; then + echo "Generating Intel CPU Microcode early initramfs image..." + opts+=( + --list-all + --list + ) + fi + + iucode_tool /lib/firmware/intel-ucode "${opts[@]}" || + { echo "iucode_tool failed" && exit 1; } +else + [[ ${KERNEL_INSTALL_VERBOSE} == 1 ]] && echo \ + "No Intel CPU Microcode installed, nothing to do here." fi - -iucode_tool /lib/firmware/intel-ucode "${opts[@]}" || - { echo "iucode_tool failed" && exit 1; } diff --git a/sys-firmware/intel-microcode/files/35-intel-microcode.install b/sys-firmware/intel-microcode/files/35-intel-microcode.install index d4e9ef19d56b..513b3a84d08e 100644 --- a/sys-firmware/intel-microcode/files/35-intel-microcode.install +++ b/sys-firmware/intel-microcode/files/35-intel-microcode.install @@ -41,9 +41,13 @@ main() { --list ) - einfo "Generating Intel CPU Microcode early initramfs image..." - iucode_tool /lib/firmware/intel-ucode "${opts[@]}" || - die "iucode_tool failed" + if [[ -d /lib/firmware/intel-ucode ]]; then + einfo "Generating Intel CPU Microcode early initramfs image..." + iucode_tool /lib/firmware/intel-ucode "${opts[@]}" || + die "iucode_tool failed" + else + einfo "No Intel CPU Microcode installed, nothing to do here." + fi } main diff --git a/sys-firmware/intel-microcode/intel-microcode-20240531_p20240526-r2.ebuild b/sys-firmware/intel-microcode/intel-microcode-20240531_p20240526-r2.ebuild new file mode 100644 index 000000000000..3af9d1741d1e --- /dev/null +++ b/sys-firmware/intel-microcode/intel-microcode-20240531_p20240526-r2.ebuild @@ -0,0 +1,338 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit dist-kernel-utils linux-info mount-boot + +# Find updates by searching and clicking the first link (hopefully it's the one): +# https://www.intel.com/content/www/us/en/search.html?keyword=Processor+Microcode+Data+File +# +# +# Package Maintenance instructions: +# 1. The ebuild is in the form of intel-microcode-<INTEL_SNAPSHOT>_p<COLLECTION_SNAPSHOT>.ebuild +# 2. The INTEL_SNAPSHOT upstream is located at: https://github.com/intel/Intel-Linux-Processor-Microcode-Data-Files +# 3. The COLLECTION_SNAPSHOT is created manually using the following steps: +# a. Clone the repository https://github.com/platomav/CPUMicrocodes +# b. Rename the Intel directory to intel-microcode-collection-<YYYYMMDD> +# c. From the CPUMicrocodes directory tar and xz compress the contents of intel-microcode-collection-<YYYYMMDD>: +# tar -cJf intel-microcode-collection-<YYYYMMDD>.tar.xz intel-microcode-collection-<YYYYMMDD>/ +# d. This file can go in your devspace, add the URL to SRC_URI if it's not there +# https://dev.gentoo.org/~<dev nick>/dist/intel-microcode/intel-microcode-collection-${COLLECTION_SNAPSHOT}.tar.xz +# +# PV: +# * the first date is upstream +# * the second date is snapshot (use last commit date in repo) from intel-microcode-collection + +COLLECTION_SNAPSHOT="${PV##*_p}" +INTEL_SNAPSHOT="${PV/_p*}" +#NUM="28087" + +#https://downloadcenter.intel.com/Detail_Desc.aspx?DwnldID=${NUM} +#https://downloadmirror.intel.com/${NUM}/eng/microcode-${INTEL_SNAPSHOT}.tgz + +DESCRIPTION="Intel IA32/IA64 microcode update data" +HOMEPAGE="https://github.com/intel/Intel-Linux-Processor-Microcode-Data-Files https://github.com/platomav/CPUMicrocodes http://inertiawar.com/microcode/" +SRC_URI=" + https://github.com/intel/Intel-Linux-Processor-Microcode-Data-Files/archive/microcode-${INTEL_SNAPSHOT}.tar.gz + https://github.com/intel/Intel-Linux-Processor-Microcode-Data-Files/raw/437f382b1be4412b9d03e2bbdcda46d83d581242/intel-ucode/06-4e-03 -> intel-ucode-sig_0x406e3-rev_0xd6.bin + https://dev.gentoo.org/~mpagano/dist/intel-microcode/intel-microcode-collection-${COLLECTION_SNAPSHOT}.tar.xz + https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/intel-microcode-collection-${COLLECTION_SNAPSHOT}.tar.xz +" +S="${WORKDIR}" + +LICENSE="intel-ucode" +SLOT="0" +KEYWORDS="-* amd64 x86" +IUSE="dist-kernel hostonly +initramfs +split-ucode vanilla" +REQUIRED_USE=" + || ( initramfs split-ucode ) + dist-kernel? ( split-ucode ) +" +RESTRICT="binchecks strip" + +BDEPEND=">=sys-apps/iucode_tool-2.3" +# !<sys-apps/microcode-ctl-1.17-r2 due to bug #268586 +RDEPEND=" + dist-kernel? ( + virtual/dist-kernel + initramfs? ( + sys-apps/iucode_tool + ) + ) +" +IDEPEND=" + hostonly? ( sys-apps/iucode_tool ) + dist-kernel? ( + initramfs? ( sys-kernel/installkernel ) + ) +" + +# Blacklist bad microcode here. +# 0x000406f1 aka 06-4f-01 aka CPUID 406F1 require newer microcode loader +MICROCODE_BLACKLIST_DEFAULT="-s !0x000406f1" + +# https://github.com/intel/Intel-Linux-Processor-Microcode-Data-Files/issues/31 +MICROCODE_BLACKLIST_DEFAULT+=" -s !0x000406e3,0xc0,eq:0x00dc" + +# https://bugs.gentoo.org/722768 +MICROCODE_BLACKLIST_DEFAULT+=" -s !0x000406e3,0xc0,eq:0x00da" + +# https://github.com/intel/Intel-Linux-Processor-Microcode-Data-Files/commit/49bb67f32a2e3e631ba1a9a73da1c52e1cac7fd9 +MICROCODE_BLACKLIST_DEFAULT+=" -s !0x000806c1,0x80,eq:0x0068" + +# In case we want to set some defaults ... +MICROCODE_SIGNATURES_DEFAULT="" + +# Advanced users only! +# Set MIRCOCODE_SIGNATURES to merge with: +# only current CPU: MICROCODE_SIGNATURES="-S" +# only specific CPU: MICROCODE_SIGNATURES="-s 0x00000f4a -s 0x00010676" +# exclude specific CPU: MICROCODE_SIGNATURES="-s !0x00000686" + +pkg_pretend() { + if use initramfs; then + if use dist-kernel; then + # Check, but don't die because we can fix the problem and then + # emerge --config ... to re-run installation. + [[ -z ${ROOT} ]] && nonfatal mount-boot_check_status + else + mount-boot_pkg_pretend + fi + fi +} + +src_prepare() { + default + + if cd Intel-Linux-Processor-Microcode-Data* &>/dev/null; then + # new tarball format from GitHub + mv * ../ || die "Failed to move Intel-Linux-Processor-Microcode-Data*" + cd .. || die + rm -r Intel-Linux-Processor-Microcode-Data* || die + fi + + mkdir intel-ucode-old || die + cp "${DISTDIR}"/intel-ucode-sig_0x406e3-rev_0xd6.bin "${S}"/intel-ucode-old/ || die + + # Prevent "invalid file format" errors from iucode_tool + rm -f "${S}"/intel-ucod*/list || die + + # https://gitlab.com/iucode-tool/iucode-tool/-/issues/4 + rm "${S}"/intel-microcode-collection-${COLLECTION_SNAPSHOT}/cpu106C0_plat01_ver00000007_2007-08-24_PRD_923CDFA3.bin || die + + # Remove non-microcode file from list + rm -f "${S}"/intel-microcode-collection-${COLLECTION_SNAPSHOT}/LICENSE || die + rm -f "${S}"/intel-ucode*/LICENSE || die +} + +src_install() { + # This will take ALL of the upstream microcode sources: + # - microcode.dat + # - intel-ucode/ + # In some cases, they have not contained the same content (eg the directory has newer stuff). + MICROCODE_SRC=( + "${S}"/intel-ucode/ + "${S}"/intel-ucode-with-caveats/ + "${S}"/intel-ucode-old/ + ) + + # Allow users who are scared about microcode updates not included in Intel's official + # microcode tarball to opt-out and comply with Intel marketing + if ! use vanilla; then + MICROCODE_SRC+=( "${S}"/intel-microcode-collection-${COLLECTION_SNAPSHOT} ) + fi + + # These will carry into pkg_preinst via env saving. + : ${MICROCODE_BLACKLIST=${MICROCODE_BLACKLIST_DEFAULT}} + : ${MICROCODE_SIGNATURES=${MICROCODE_SIGNATUES_DEFAULT}} + + opts=( + ${MICROCODE_BLACKLIST} + ${MICROCODE_SIGNATURES} + # be strict about what we are doing + --overwrite + --strict-checks + --no-ignore-broken + # we want to install latest version + --no-downgrade + # show everything we find + --list-all + # show what we selected + --list + ) + + # Instruct Dracut on whether or not we want the microcode in initramfs + # Use here 15 instead of 10, intel-microcode overwrites linux-firmware + ( + insinto /usr/lib/dracut/dracut.conf.d + newins - 15-${PN}.conf <<<"early_microcode=$(usex initramfs)" + ) + if use initramfs; then + # Install installkernel/kernel-install hooks for non-dracut initramfs + # generators that don't bundled the microcode + ( + exeinto /usr/lib/kernel/preinst.d + doexe "${FILESDIR}/35-intel-microcode.install" + exeinto /usr/lib/kernel/install.d + doexe "${FILESDIR}/35-intel-microcode-systemd.install" + ) + fi + + # The earlyfw cpio needs to be in /boot because it must be loaded before + # rootfs is mounted. + if ! use dist-kernel && use initramfs; then + dodir /boot && opts+=( --write-earlyfw="${ED}/boot/intel-uc.img" ) + fi + + keepdir /lib/firmware/intel-ucode + opts+=( --write-firmware="${ED}/lib/firmware/intel-ucode" ) + + iucode_tool \ + "${opts[@]}" \ + "${MICROCODE_SRC[@]}" \ + || die "iucode_tool ${opts[@]} ${MICROCODE_SRC[@]}" + + dodoc releasenote.md +} + +pkg_preinst() { + if [[ ${MICROCODE_BLACKLIST} != ${MICROCODE_BLACKLIST_DEFAULT} ]]; then + ewarn "MICROCODE_BLACKLIST is set to \"${MICROCODE_BLACKLIST}\" instead of default \"${MICROCODE_BLACKLIST_DEFAULT}\". You are on your own!" + fi + + if [[ ${MICROCODE_SIGNATURES} != ${MICROCODE_SIGNATURES_DEFAULT} ]]; then + ewarn "Package was created using advanced options:" + ewarn "MICROCODE_SIGNATURES is set to \"${MICROCODE_SIGNATURES}\" instead of default \"${MICROCODE_SIGNATURES_DEFAULT}\"!" + fi + + # Make sure /boot is available if needed. + use initramfs && ! use dist-kernel && mount-boot_pkg_preinst + + local _initramfs_file="${ED}/boot/intel-uc.img" + + if use hostonly; then + # While this output looks redundant we do this check to detect + # rare cases where iucode_tool was unable to detect system's processor(s). + local _detected_processors=$(iucode_tool --scan-system 2>&1) + if [[ -z "${_detected_processors}" ]]; then + ewarn "Looks like iucode_tool was unable to detect any processor!" + else + einfo "Only installing ucode(s) for ${_detected_processors#iucode_tool: system has } due to USE=hostonly ..." + fi + + opts=( + --scan-system + # be strict about what we are doing + --overwrite + --strict-checks + --no-ignore-broken + # we want to install latest version + --no-downgrade + # show everything we find + --list-all + # show what we selected + --list + ) + + # The earlyfw cpio needs to be in /boot because it must be loaded before + # rootfs is mounted. + if ! use dist-kernel && use initramfs; then + opts+=( --write-earlyfw=${_initramfs_file} ) + fi + + if use split-ucode; then + opts+=( --write-firmware="${ED}/lib/firmware/intel-ucode" ) + fi + + opts+=( "${ED}/lib/firmware/intel-ucode-temp" ) + + mv "${ED}"/lib/firmware/intel-ucode{,-temp} || die + keepdir /lib/firmware/intel-ucode + + iucode_tool "${opts[@]}" || die "iucode_tool ${opts[@]}" + + rm -r "${ED}"/lib/firmware/intel-ucode-temp || die + + elif ! use split-ucode; then # hostonly disabled + rm -r "${ED}"/lib/firmware/intel-ucode || die + fi + + # Because it is possible that this package will install not one single file + # due to user selection which is still somehow unexpected we add the following + # check to inform user so that the user has at least a chance to detect + # a problem/invalid select. + local _has_installed_something= + if use initramfs && [[ -s "${_initramfs_file}" ]]; then + _has_installed_something="yes" + elif use split-ucode; then + _has_installed_something=$(find "${ED}/lib/firmware/intel-ucode" -maxdepth 0 -not -empty -exec echo yes \;) + fi + + if use hostonly && [[ -n "${_has_installed_something}" ]]; then + elog "You only installed ucode(s) for all currently available (=online)" + elog "processor(s). Remember to re-emerge this package whenever you" + elog "change the system's processor model." + elog "" + elif [[ -z "${_has_installed_something}" ]]; then + ewarn "WARNING:" + if [[ ${MICROCODE_SIGNATURES} != ${MICROCODE_SIGNATURES_DEFAULT} ]]; then + ewarn "No ucode was installed! Because you have created this package" + ewarn "using MICROCODE_SIGNATURES variable please double check if you" + ewarn "have an invalid select." + ewarn "It's rare but it is also possible that just no ucode update" + ewarn "is available for your processor(s). In this case it is safe" + ewarn "to ignore this warning." + else + ewarn "No ucode was installed! It's rare but it is also possible" + ewarn "that just no ucode update is available for your processor(s)." + ewarn "In this case it is safe to ignore this warning." + fi + + ewarn "" + + if use hostonly; then + ewarn "Unset \"hostonly\" USE flag to install all available ucodes." + ewarn "" + fi + fi +} + +pkg_prerm() { + # Make sure /boot is mounted so that we can remove /boot/intel-uc.img! + use initramfs && ! use dist-kernel && mount-boot_pkg_prerm +} + +pkg_postrm() { + # Don't forget to umount /boot if it was previously mounted by us. + use initramfs && ! use dist-kernel && mount-boot_pkg_postrm +} + +pkg_postinst() { + if use initramfs; then + if use dist-kernel; then + [[ -z ${ROOT} ]] && dist-kernel_reinstall_initramfs "${KV_DIR}" "${KV_FULL}" + else + # Don't forget to umount /boot if it was previously mounted by us. + mount-boot_pkg_postinst + fi + fi + + # We cannot give detailed information if user is affected or not: + # If MICROCODE_BLACKLIST wasn't modified, user can still use MICROCODE_SIGNATURES + # to to force a specific, otherwise blacklisted, microcode. So we + # only show a generic warning based on running kernel version: + if kernel_is -lt 4 14 34; then + ewarn "${P} contains microcode updates which require" + ewarn "additional kernel patches which aren't yet included in kernel <4.14.34." + ewarn "Loading such a microcode through kernel interface from an unpatched kernel" + ewarn "can crash your system!" + ewarn "" + ewarn "Those microcodes are blacklisted per default. However, if you have altered" + ewarn "MICROCODE_BLACKLIST or MICROCODE_SIGNATURES, you maybe have unintentionally" + ewarn "re-enabled those microcodes...!" + ewarn "" + ewarn "Check \"${EROOT}/usr/share/doc/${PN}-*/releasenot*\" if your microcode update" + ewarn "requires additional kernel patches or not." + fi +} diff --git a/sys-firmware/intel-microcode/intel-microcode-20240531_p20240526-r1.ebuild b/sys-firmware/intel-microcode/intel-microcode-20240813_p20240815.ebuild index 55f66f30803d..947e22ff9bc2 100644 --- a/sys-firmware/intel-microcode/intel-microcode-20240531_p20240526-r1.ebuild +++ b/sys-firmware/intel-microcode/intel-microcode-20240813_p20240815.ebuild @@ -45,16 +45,24 @@ LICENSE="intel-ucode" SLOT="0" KEYWORDS="-* ~amd64 ~x86" IUSE="dist-kernel hostonly +initramfs +split-ucode vanilla" -REQUIRED_USE="!dist-kernel? ( || ( initramfs split-ucode ) )" +REQUIRED_USE=" + || ( initramfs split-ucode ) + dist-kernel? ( split-ucode ) +" RESTRICT="binchecks strip" BDEPEND=">=sys-apps/iucode_tool-2.3" # !<sys-apps/microcode-ctl-1.17-r2 due to bug #268586 RDEPEND=" - dist-kernel? ( virtual/dist-kernel ) - hostonly? ( sys-apps/iucode_tool ) + dist-kernel? ( + virtual/dist-kernel + initramfs? ( + sys-apps/iucode_tool + ) + ) " IDEPEND=" + hostonly? ( sys-apps/iucode_tool ) dist-kernel? ( initramfs? ( sys-kernel/installkernel ) ) @@ -84,10 +92,10 @@ MICROCODE_SIGNATURES_DEFAULT="" pkg_pretend() { if use initramfs; then - if [[ -z ${ROOT} ]] && use dist-kernel; then + if use dist-kernel; then # Check, but don't die because we can fix the problem and then # emerge --config ... to re-run installation. - nonfatal mount-boot_check_status + [[ -z ${ROOT} ]] && nonfatal mount-boot_check_status else mount-boot_pkg_pretend fi @@ -302,8 +310,8 @@ pkg_postrm() { pkg_postinst() { if use initramfs; then - if [[ -z ${ROOT} ]] && use dist-kernel; then - dist-kernel_reinstall_initramfs "${KV_DIR}" "${KV_FULL}" + if use dist-kernel; then + [[ -z ${ROOT} ]] && dist-kernel_reinstall_initramfs "${KV_DIR}" "${KV_FULL}" else # Don't forget to umount /boot if it was previously mounted by us. mount-boot_pkg_postinst diff --git a/sys-firmware/seabios/Manifest b/sys-firmware/seabios/Manifest index 01535608c650..fea31a182b1f 100644 --- a/sys-firmware/seabios/Manifest +++ b/sys-firmware/seabios/Manifest @@ -11,5 +11,5 @@ DIST seabios-1.14.0-r2-bin.tar.xz 132256 BLAKE2B 7d38949de254d6e3699d463a66c3631 DIST seabios-1.14.0.tar.gz 628985 BLAKE2B cc1126925dab1551a655680d20d06ebf28c12c386500d1ee4df9e1a99403b4c5bc6a66c2cc5ef58b4c3d6d7226f35007506a6a1855c2cf2742469dcb7aba05bb SHA512 215c42f59425f8abd062be7b11fc0e39c977cee5001a2381551b0f851ac337d0dd53c065267e6dee0e710ffd700fa635f9007b89da8dfce0f47122c984ee8146 DIST seabios-1.16.0.tar.gz 635419 BLAKE2B b645f20bae341d56ce4fc4a7044446050d8490c6c136377f6dccf02c88100b0644bc13d210b4a517a8be6002d5671b0fba77120a2aca3a9bafbad5e88d037e40 SHA512 9daefcfb1c9edda4462a4b080c9bac552154d577ae19703a914928e43005e7a52edd86869c6507e94a7f0c61ce8b3e6f5dea38cd5146628cb138a130947c522f EBUILD seabios-1.14.0-r2.ebuild 4314 BLAKE2B 0f35981c962b29ae9c5a80457d8619c3475151a334296a557e9089d56d93c55b1edc5457526e9a5afd0f88c8317fad31cc34eff33ad5d58aa426ded3a66995c3 SHA512 75ca31a46284915179f7b27a5387901d481a253f188a3aa7703d80424f8f2d96d0e0a5493b80015c6db0c6273b021866c40388c63a4bc7101ce16c4b42c9918c -EBUILD seabios-1.16.0.ebuild 3395 BLAKE2B aec6bf0c3102c85c4064d38cc09492a11be216ae7e306a0c831e487145df2657380763132793ba81b6fcec1bb115d26d2362b6fa6d0836f8e55fc0a3d0941b3d SHA512 5e6ed55324558ff84d5e452c94371e86d739f36980b1975c424fd2e14e4bda1257ffcfcfed4eb0fd236951492b7390cb379868afb9b568f4ad803d512bfb5999 +EBUILD seabios-1.16.0.ebuild 3394 BLAKE2B 6971128e51ff846fb866d33274e90945edf2b10a54a48764f892d9da34d12776a89b75712fcffbd8672cdb313b9b37a34c41b651e18e3055b99c5a7a57a58cec SHA512 dfd3a3f34614e3e7b5ee0296a37121890a007e17c454873620d07cdf45f45151d613a02c86b5453b2f6aebb0b5e74293beb762fdf81a58100b016dabb2914843 MISC metadata.xml 444 BLAKE2B 5e72f141a955b94c490c8b72fcca3f1761cb74bbe8fc5a5315a5082a97ef5a703bbac08c1b329bb1935e689bc57f3d5519b5fa19609a35cb99ef594eea8be8ad SHA512 f2f6d17a6d186c4e10689f7d1ce113383f7f8537e58e185f418f74f79b8f5d1c0be3ee9b2341ec134c1356ae3499a16bc3249fbcdfb12e7daabd7f2cdcc88b61 diff --git a/sys-firmware/seabios/seabios-1.16.0.ebuild b/sys-firmware/seabios/seabios-1.16.0.ebuild index 6399287a3bf3..ac5f71a088cd 100644 --- a/sys-firmware/seabios/seabios-1.16.0.ebuild +++ b/sys-firmware/seabios/seabios-1.16.0.ebuild @@ -1,9 +1,9 @@ -# Copyright 1999-2023 Gentoo Authors +# Copyright 1999-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 -PYTHON_COMPAT=( python3_{9,10,11} ) +PYTHON_COMPAT=( python3_{10..12} ) inherit toolchain-funcs python-any-r1 diff --git a/sys-firmware/sof-firmware/Manifest b/sys-firmware/sof-firmware/Manifest index 29b2533f36ba..3c5c9ee6c4a3 100644 --- a/sys-firmware/sof-firmware/Manifest +++ b/sys-firmware/sof-firmware/Manifest @@ -1,7 +1,5 @@ -DIST sof-firmware-2023.12.1.tar.gz 5446189 BLAKE2B a901637ba25df51152f04c7db5330b70a18c92363b102c061568a4c3a8a7e2fc506ac9783abe715f680a27be8a040d63b7dd5b62682979ccf1e4eaeb30789d83 SHA512 e0175f3af5336f23548efcf8fa302bafbb6122fd173273203f687c05ee17fab4e7bd457b27cc7a62fd25ea77708ffdbf9e1fe3880d3df1cf2196d7073c6f7677 -DIST sof-firmware-2023.12.tar.gz 5427762 BLAKE2B 48169378609119555f9b655599cef55e5722be71fdfc8fb71b699188fcb3f62a68e217fc3fec8859cd3e1c252f046208d5123c961dd824bd9b6559bd1fb72325 SHA512 ed43e7597c93140b15499ba17bae1866dcf1e2959d910e81b3831e4db2224a1dcff790ef21afcd610d7cc9309251a08351bae1c959ded18e5e28a6b24ae99506 DIST sof-firmware-2024.03.tar.gz 8161590 BLAKE2B 23d73ff3ab30b5134086bb21e606805a7d9667adf1a5598a3d31068ba0254dc4c34464ee3913eb3530a8124e3614eff9ba28fa731e9816b28980ea05834c1037 SHA512 1e9891d3891f5a4413a77a68ea6d3a2e6ead8c1a67eaa7e9aaf30871753617ffce19bd3b85ebcbb617e606646f6aa0e1dafee5279c294ec72ef4b2885e009f72 -EBUILD sof-firmware-2023.12.1.ebuild 889 BLAKE2B 56d91db39fe4cd30314c52a307e504162a0c50b14b24bffc9796fff0f0742308c82e2ed7efc6d02457b17e47fd0cd7f15222d6d304783143ee5c4c803d3fe2ec SHA512 fb82f1b76f2e1ac137d535adfb5c737c03465dcf39dc3b9817a2e3a653cd9a2028cdcfa3f261c5150ddd92cfd67b65009bc22a8188d9b93e9966224ebbdf10d4 -EBUILD sof-firmware-2023.12.ebuild 889 BLAKE2B 56d91db39fe4cd30314c52a307e504162a0c50b14b24bffc9796fff0f0742308c82e2ed7efc6d02457b17e47fd0cd7f15222d6d304783143ee5c4c803d3fe2ec SHA512 fb82f1b76f2e1ac137d535adfb5c737c03465dcf39dc3b9817a2e3a653cd9a2028cdcfa3f261c5150ddd92cfd67b65009bc22a8188d9b93e9966224ebbdf10d4 -EBUILD sof-firmware-2024.03.ebuild 1125 BLAKE2B 532575d14965d0b685baec966e4ec001a4741bddd8513caade012c439f09b354ce166bbb9281b05b306310fb43b2fce3a5cbec35bc0e080dd786049c2f26dbe4 SHA512 40656572634ab323ab0cbf454550d297fc47d84d880e236709e15e9a488fc6bc3f677d0dda6285acdacf0352bc0d51f8b80b303d0f35992e115aa606ef2b965e +DIST sof-firmware-2024.06.tar.gz 9848270 BLAKE2B 31189e81400981b76db585019324e7dec9f81ff488c6bbc575534d4968ea974764ecf0b585918cc1871e99ef8cff45f77c8c7509bb954360693f3a283b391d6a SHA512 50dbd849b086158af88dd629566b80de4e841dd8a74b6ea8b1d99b3321be94a0d2d6f742b557f0445b9618a6dbeee3fec6a4e9822b320d511ede1ec1812c0d4d +EBUILD sof-firmware-2024.03.ebuild 1124 BLAKE2B 2ed38272b31f245b9874cdfc003de76a2eb75096f8156109348c5ab987ef9e82f805b23e1137fa53a1484c9180495e0beec35ba76696ec6c9da42b74acd32e58 SHA512 c1f1acebb053582913b47073be06f4a8cfd06058e8fbb302784c12890a590dcad4ed5d4bee4368487f9a382f12e527f35678a75977d8878c19eddb3976fe47af +EBUILD sof-firmware-2024.06.ebuild 1125 BLAKE2B 532575d14965d0b685baec966e4ec001a4741bddd8513caade012c439f09b354ce166bbb9281b05b306310fb43b2fce3a5cbec35bc0e080dd786049c2f26dbe4 SHA512 40656572634ab323ab0cbf454550d297fc47d84d880e236709e15e9a488fc6bc3f677d0dda6285acdacf0352bc0d51f8b80b303d0f35992e115aa606ef2b965e MISC metadata.xml 493 BLAKE2B fb1e626fd8c645e3e96e4f6b424cea55d009a1d13fc2d8ff019a4e95a9899d2412aecfc9c89391b194cf058e10dedb4e3bf1bfa004247762353fe4fa9148a9e8 SHA512 24142f67672b2af14b0b426d71c6f0d97319614309e1dc3c761bd270d021bde817551ed6d08f4be87d0a53450f7930193f637df35cde6fb2a9189aa8fc037645 diff --git a/sys-firmware/sof-firmware/sof-firmware-2023.12.ebuild b/sys-firmware/sof-firmware/sof-firmware-2023.12.ebuild deleted file mode 100644 index 5d36427294f2..000000000000 --- a/sys-firmware/sof-firmware/sof-firmware-2023.12.ebuild +++ /dev/null @@ -1,33 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DESCRIPTION="Sound Open Firmware (SOF) binary files" -HOMEPAGE="https://www.sofproject.org https://github.com/thesofproject/sof https://github.com/thesofproject/sof-bin" -SRC_URI="https://github.com/thesofproject/sof-bin/releases/download/v${PV}/sof-bin-${PV}.tar.gz -> ${P}.tar.gz" -S="${WORKDIR}"/sof-bin-${PV} - -LICENSE="BSD" -SLOT="0" -KEYWORDS="amd64" - -# Needed for sof-ctl -RDEPEND="media-libs/alsa-lib" - -QA_PREBUILT="usr/bin/sof-ctl - usr/bin/sof-logger - usr/bin/sof-probes" - -src_install() { - dodir /lib/firmware/intel - dodir /usr/bin - FW_DEST="${D}/lib/firmware/intel" TOOLS_DEST="${D}/usr/bin" "${S}/install.sh" || die -} - -pkg_preinst() { - local sofpath="${EROOT}/lib/firmware/intel/sof" - if [[ ! -L "${sofpath}" && -d "${sofpath}" ]] ; then - rm -r "${sofpath}" || die - fi -} diff --git a/sys-firmware/sof-firmware/sof-firmware-2024.03.ebuild b/sys-firmware/sof-firmware/sof-firmware-2024.03.ebuild index 105eaae58f37..33fbc19f20ac 100644 --- a/sys-firmware/sof-firmware/sof-firmware-2024.03.ebuild +++ b/sys-firmware/sof-firmware/sof-firmware-2024.03.ebuild @@ -10,7 +10,7 @@ S="${WORKDIR}"/sof-bin-${PV} LICENSE="BSD" SLOT="0" -KEYWORDS="~amd64" +KEYWORDS="amd64" IUSE="+tools" RDEPEND=" diff --git a/sys-firmware/sof-firmware/sof-firmware-2023.12.1.ebuild b/sys-firmware/sof-firmware/sof-firmware-2024.06.ebuild index 5d36427294f2..105eaae58f37 100644 --- a/sys-firmware/sof-firmware/sof-firmware-2023.12.1.ebuild +++ b/sys-firmware/sof-firmware/sof-firmware-2024.06.ebuild @@ -10,10 +10,15 @@ S="${WORKDIR}"/sof-bin-${PV} LICENSE="BSD" SLOT="0" -KEYWORDS="amd64" +KEYWORDS="~amd64" +IUSE="+tools" -# Needed for sof-ctl -RDEPEND="media-libs/alsa-lib" +RDEPEND=" + tools? ( + media-libs/alsa-lib + sys-libs/glibc + ) +" QA_PREBUILT="usr/bin/sof-ctl usr/bin/sof-logger @@ -23,10 +28,17 @@ src_install() { dodir /lib/firmware/intel dodir /usr/bin FW_DEST="${D}/lib/firmware/intel" TOOLS_DEST="${D}/usr/bin" "${S}/install.sh" || die + + # Drop tools if requested (i.e. useful for musl systems, where glibc + # is not available) + if ! use tools ; then + rm -rv "${D}"/usr/bin || die + fi } pkg_preinst() { - local sofpath="${EROOT}/lib/firmware/intel/sof" + # Fix sof-ace-tplg directory symlink collisions + local sofpath="${EROOT}/lib/firmware/intel/sof-ace-tplg" if [[ ! -L "${sofpath}" && -d "${sofpath}" ]] ; then rm -r "${sofpath}" || die fi |