diff options
author | Ben Kohler <bkohler@gentoo.org> | 2024-11-14 13:00:51 -0600 |
---|---|---|
committer | Ben Kohler <bkohler@gentoo.org> | 2024-11-14 13:01:08 -0600 |
commit | 67581424ba3f12245f7ded4287232b32e17b89d7 (patch) | |
tree | 345952ddd1017a2814502a4960921d64552753ef /sys-apps | |
parent | media-gfx/inkscape: Fix build w/ app-text/poppler-24.11.0 (diff) | |
download | gentoo-67581424ba3f12245f7ded4287232b32e17b89d7.tar.gz gentoo-67581424ba3f12245f7ded4287232b32e17b89d7.tar.bz2 gentoo-67581424ba3f12245f7ded4287232b32e17b89d7.zip |
sys-apps/memtest86+: add 7.20
Signed-off-by: Ben Kohler <bkohler@gentoo.org>
Diffstat (limited to 'sys-apps')
-rw-r--r-- | sys-apps/memtest86+/Manifest | 1 | ||||
-rw-r--r-- | sys-apps/memtest86+/memtest86+-7.20.ebuild | 100 |
2 files changed, 101 insertions, 0 deletions
diff --git a/sys-apps/memtest86+/Manifest b/sys-apps/memtest86+/Manifest index 0cdbeac150a6..9c3e2ed00c9d 100644 --- a/sys-apps/memtest86+/Manifest +++ b/sys-apps/memtest86+/Manifest @@ -1,2 +1,3 @@ DIST memtest86+-6.20.tar.gz 232436 BLAKE2B 6e3bea4b18049446f27da2cb1313300c578ef7fdb774b6a20df603271b66a6c0066be64a91b0a6d4ffcc63f1e139132942290a8111f6a991cccc0a5586cac966 SHA512 b12856bd6ba82dac6308bb9f611ddb16df68c3da4d00ad9abf23bcf5d3f2e5c424fc1bccedd8c0732b4c68013c421ed20c5db56c39b619bbe77c4c1f5e8504f0 DIST memtest86+-7.00.tar.gz 244385 BLAKE2B 608f4e31ddaee01d828cb1574086196c26f5e96c5049806ac3ab174ddf669db8cdcb8f336bec5a1ce74439d96fca505fea81311a06581bb43a8034156a4f8165 SHA512 1325ee08b280404fb47d37b62d65e51de21dd09b96bef29ece193072b09ff3c6eea8657b2e7c98801bf81ba4288c2bff580a91eb45d5a93744b0a273652266c4 +DIST memtest86+-7.20.tar.gz 269027 BLAKE2B f53570e9364f7fc15c946d925b449139f72bdfab6e2c69e40f7edf6aa034c6b46e40194d32eb56122365b6badc199ed9eeb8f3281d1908adb85495ffd25ea5f7 SHA512 6982f6e9dfebf226b82c7385c10322ad49ac821400a07d577727bfca65b0c430d2680237ede7b4e532fa37dcc6d37a6a3bfb8858a6036ddcb01d644b0707e5a5 diff --git a/sys-apps/memtest86+/memtest86+-7.20.ebuild b/sys-apps/memtest86+/memtest86+-7.20.ebuild new file mode 100644 index 000000000000..88b05cadc68a --- /dev/null +++ b/sys-apps/memtest86+/memtest86+-7.20.ebuild @@ -0,0 +1,100 @@ +# Copyright 2022-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit mount-boot secureboot toolchain-funcs + +MY_PV=${PV/_/-} + +DESCRIPTION="Memory tester based on PCMemTest" +HOMEPAGE="https://www.memtest.org/" +SRC_URI="https://github.com/memtest86plus/memtest86plus/archive/refs/tags/v${MY_PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="bios32 bios64 +boot uefi32 uefi64 iso32 iso64" + +ISODEPS=" + dev-libs/libisoburn + sys-fs/dosfstools + sys-fs/mtools +" +BDEPEND=" + iso32? ( ${ISODEPS} ) + iso64? ( ${ISODEPS} ) +" + +S=${WORKDIR}/memtest86plus-${MY_PV} + +pkg_setup() { + if use uefi32 || use uefi64; then + secureboot_pkg_setup + fi +} + +src_prepare() { + sed -i \ + -e 's#/sbin/mkdosfs#mkfs.vfat#' \ + -e 's/^AS = as/AS +=/' \ + -e '/^CC/d' \ + -e 's/= objcopy/?= $(OBJCOPY)/' \ + -e 's/shell size/shell $(SIZE)/' \ + build{32,64}/Makefile || die + default +} + +src_compile() { + tc-export OBJCOPY + export SIZE=$(tc-getPROG SIZE size) + pushd build32 + use bios32 && emake memtest.bin + use uefi32 && emake memtest.efi + use iso32 && emake iso + popd + + pushd build64 + use bios64 && emake memtest.bin + use uefi64 && emake memtest.efi + use iso64 && emake iso + popd +} + +install_memtest_images() { + use bios32 && newins build32/memtest.bin memtest32.bios + use bios64 && newins build64/memtest.bin memtest64.bios + use uefi32 && newins build32/memtest.efi memtest.efi32 + use uefi64 && newins build64/memtest.efi memtest.efi64 +} + +src_install() { + default + if use boot; then + exeinto /etc/grub.d/ + newexe "${FILESDIR}"/39_memtest86+-r2 39_memtest86+ + insinto /boot/memtest86plus + install_memtest_images + fi + + insinto /usr/share/${PN} + install_memtest_images + use iso32 && newins build32/memtest.iso memtest32.iso + use iso64 && newins build64/memtest.iso memtest64.iso + + if use uefi32 || use uefi64; then + secureboot_auto_sign --in-place + fi +} + +pkg_pretend() { + use boot && mount-boot_pkg_pretend +} + +pkg_preinst() { + use boot && mount-boot_pkg_preinst +} + +pkg_prerm() { + use boot && mount-boot_pkg_prerm +} |