mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2025-12-21 21:17:37 -08:00
sys-apps/memtest86+: add 8.00
Signed-off-by: Ben Kohler <bkohler@gentoo.org>
This commit is contained in:
parent
247d0465e8
commit
ce2de42b3e
@ -1,3 +1,4 @@
|
||||
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
|
||||
DIST memtest86+-8.00.tar.gz 278468 BLAKE2B e48300edbe587325ab7b73c4e9cfcd624a85931b1e72538e511bf37e41fa04f198b1be1cd4d41b72de590757623d4cae7b74b7a407062558b57e71fb22a9089f SHA512 e363af146903c6cc5b49c957b3f206dfa0f63f29780520f2a75589fb5fa6cec7ee3c611fc7455c6806c35bcb8b32697ba53b7684bc6d552dbb68943ef99fb625
|
||||
|
||||
70
sys-apps/memtest86+/files/39_memtest86+-r3
Normal file
70
sys-apps/memtest86+/files/39_memtest86+-r3
Normal file
@ -0,0 +1,70 @@
|
||||
#!/bin/sh
|
||||
|
||||
. /usr/share/grub/grub-mkconfig_lib
|
||||
|
||||
mt32=/boot/memtest86plus/memtest.i586
|
||||
mt64=/boot/memtest86plus/memtest.x86_64
|
||||
|
||||
if [ $(ls /boot/memtest86plus | wc -l) -gt 1 ]; then
|
||||
multiple_memtest=true
|
||||
fi
|
||||
|
||||
submenu_indentation=""
|
||||
if [ "${multiple_memtest}" = "true" ] && [ "${GRUB_DISABLE_SUBMENU}" != "y" ]; then
|
||||
submenu_indentation="${grub_tab}"
|
||||
cat <<EOF
|
||||
submenu 'Memtest86+' {
|
||||
EOF
|
||||
fi
|
||||
|
||||
# Start i586
|
||||
if [ -f "${mt32}" ]; then
|
||||
gettext_printf "Found memtest image: %s\n" "${mt32}" >&2
|
||||
|
||||
device="$("${grub_probe}" --target=device "${mt32}")"
|
||||
path="$(make_system_path_relative_to_its_root "${mt32}")"
|
||||
cat <<EOF
|
||||
${submenu_indentation}menuentry 'Memtest86+ 32bit' {
|
||||
EOF
|
||||
|
||||
if [ -n "${submenu_indentation}" ]; then
|
||||
prepare_grub_to_access_device "${device}" | grub_add_tab | grub_add_tab
|
||||
else
|
||||
prepare_grub_to_access_device "${device}" | grub_add_tab
|
||||
fi
|
||||
|
||||
cat <<EOF
|
||||
${submenu_indentation}linux "${path}"
|
||||
${submenu_indentation}}
|
||||
EOF
|
||||
fi
|
||||
# End i586
|
||||
|
||||
# Start x86_64
|
||||
if [ -f "${mt64}" ]; then
|
||||
gettext_printf "Found memtest image: %s\n" "${mt64}" >&2
|
||||
|
||||
device="$("${grub_probe}" --target=device "${mt64}")"
|
||||
path="$(make_system_path_relative_to_its_root "${mt64}")"
|
||||
cat <<EOF
|
||||
${submenu_indentation}menuentry 'Memtest86+ 64bit' {
|
||||
EOF
|
||||
|
||||
if [ -n "{submenu_indentation}" ]; then
|
||||
prepare_grub_to_access_device "${device}" | grub_add_tab | grub_add_tab
|
||||
else
|
||||
prepare_grub_to_access_device "${device}" | grub_add_tab
|
||||
fi
|
||||
|
||||
cat <<EOF
|
||||
${submenu_indentation}linux "${path}"
|
||||
${submenu_indentation}}
|
||||
EOF
|
||||
fi
|
||||
# End x86_64
|
||||
|
||||
if [ "${multiple_memtest}" = "true" ] && [ "${GRUB_DISABLE_SUBMENU}" != "y" ]; then
|
||||
cat <<EOF
|
||||
}
|
||||
EOF
|
||||
fi
|
||||
122
sys-apps/memtest86+/memtest86+-8.00.ebuild
Normal file
122
sys-apps/memtest86+/memtest86+-8.00.ebuild
Normal file
@ -0,0 +1,122 @@
|
||||
# Copyright 2022-2025 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"
|
||||
|
||||
S=${WORKDIR}/memtest86plus-${MY_PV}
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS=""
|
||||
IUSE="bios32 bios64 +boot uefi32 uefi64 iso32 iso64"
|
||||
|
||||
ISODEPS="
|
||||
dev-libs/libisoburn
|
||||
sys-fs/dosfstools
|
||||
sys-fs/mtools
|
||||
"
|
||||
BDEPEND="
|
||||
iso32? ( ${ISODEPS} )
|
||||
iso64? ( ${ISODEPS} )
|
||||
sys-devel/gcc:*
|
||||
"
|
||||
|
||||
pkg_setup() {
|
||||
if use uefi32 || use uefi64; then
|
||||
secureboot_pkg_setup
|
||||
fi
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
sed -i \
|
||||
-e 's#/sbin/mkdosfs#mkfs.vfat#' \
|
||||
-e 's/shell size/shell $(SIZE)/' \
|
||||
build/{i586,x86_64,loongarch64}/Makefile || die
|
||||
|
||||
if ! tc-is-gcc; then
|
||||
ewarn "clang doesn't support indirect goto in function with no address-of-label expressions"
|
||||
ewarn "Ignoring CC=$(tc-getCC) and forcing ${CHOST}-gcc"
|
||||
export CC=${CHOST}-gcc AR=${CHOST}-gcc-ar
|
||||
tc-is-gcc || die "tc-is-gcc failed in spite of CC=${CC}"
|
||||
fi
|
||||
|
||||
default
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
tc-export OBJCOPY
|
||||
export SIZE=$(tc-getPROG SIZE size)
|
||||
|
||||
if use loong; then
|
||||
# a different build directory has to be selected for loong, and
|
||||
# there's no "BIOS" support.
|
||||
pushd build/loongarch64
|
||||
use uefi64 && emake mt86plus
|
||||
use iso64 && emake iso
|
||||
popd
|
||||
return
|
||||
fi
|
||||
|
||||
pushd build/i586
|
||||
use bios32 || use uefi32 && emake mt86plus
|
||||
use iso32 && emake iso
|
||||
popd
|
||||
|
||||
pushd build/x86_64
|
||||
use bios64 || use uefi64 && emake mt86plus
|
||||
use iso64 && emake iso
|
||||
popd
|
||||
}
|
||||
|
||||
install_memtest_images() {
|
||||
if use loong; then
|
||||
use uefi64 && newins build/loongarch64/mt86plus memtest.loongarch64
|
||||
return
|
||||
fi
|
||||
|
||||
use bios32 || use uefi32 && newins build/i586/mt86plus memtest.i586
|
||||
use bios64 || use uefi64 && newins build/x86_64/mt86plus memtest.x86_64
|
||||
}
|
||||
|
||||
src_install() {
|
||||
default
|
||||
if use boot; then
|
||||
exeinto /etc/grub.d/
|
||||
newexe "${FILESDIR}"/39_memtest86+-r3 39_memtest86+
|
||||
insinto /boot/memtest86plus
|
||||
install_memtest_images
|
||||
fi
|
||||
|
||||
insinto /usr/share/${PN}
|
||||
install_memtest_images
|
||||
if use loong; then
|
||||
use iso64 && newins build/loongarch64/memtest.iso memtest64.iso
|
||||
else
|
||||
use iso32 && newins build/i586/memtest.iso memtest.i586.iso
|
||||
use iso64 && newins build/x86_64/memtest.iso memtest.x86_64.iso
|
||||
fi
|
||||
|
||||
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
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user