gnuboot-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH 19/20] use memtest86plus 6.x instead of 5.x


From: Leah Rowe
Subject: [PATCH 19/20] use memtest86plus 6.x instead of 5.x
Date: Sun, 14 Jan 2024 15:55:36 +0000

From: Leah Rowe <leah@libreboot.org>

the 6.x series is essentially a full rewrite, and it has many
improvements, most notably that it now also works on
corebootfb setups, not just text mode

Signed-off-by: Leah Rowe <leah@libreboot.org>
---
 ...d-central-Makefile-in-main-directory.patch | 41 +++++++++++++++++++
 ...-memtest86-linker-error-during-build.patch | 25 -----------
 resources/packages/memtest86plus/download     | 13 +++---
 resources/packages/roms_helper/boot           |  6 +--
 4 files changed, 49 insertions(+), 36 deletions(-)
 create mode 100644 
resources/memtest86plus/patch/0001-add-central-Makefile-in-main-directory.patch
 delete mode 100644 
resources/memtest86plus/patch/0001-fix-memtest86-linker-error-during-build.patch

diff --git 
a/resources/memtest86plus/patch/0001-add-central-Makefile-in-main-directory.patch
 
b/resources/memtest86plus/patch/0001-add-central-Makefile-in-main-directory.patch
new file mode 100644
index 0000000..8291bfb
--- /dev/null
+++ 
b/resources/memtest86plus/patch/0001-add-central-Makefile-in-main-directory.patch
@@ -0,0 +1,41 @@
+From 81d850494c3cde1da33cc2df44837c839c1f2c60 Mon Sep 17 00:00:00 2001
+From: Leah Rowe <leah@libreboot.org>
+Date: Fri, 6 Oct 2023 23:17:06 +0100
+Subject: [PATCH 1/1] add central Makefile in main directory
+
+it only does build64. i'm disabling use of 32-bit memtest in lbmk,
+until i can figure out a more consistent cross-compile method,
+rather than relying on hostcc.
+
+a user on irc reported build issues on pop os
+
+it's not pop's fault. lbmk needs to start handling cross
+compilers properly. (alternatively, i could rig memtest86+
+to use crossgcc. i'll explore that later)
+
+Signed-off-by: Leah Rowe <leah@libreboot.org>
+---
+ Makefile | 11 +++++++++++
+ 1 file changed, 11 insertions(+)
+ create mode 100644 Makefile
+
+diff --git a/Makefile b/Makefile
+new file mode 100644
+index 0000000..59fcbef
+--- /dev/null
++++ b/Makefile
+@@ -0,0 +1,11 @@
++# SPDX-License-Identifier: MIT
++# SPDX-FileCopyrightText: 2023 Leah Rowe <leah@libreboot.org>
++
++all:
++      make -C build64
++
++clean:
++      make -C build64 clean
++
++distclean:
++      make -C build64 clean
+-- 
+2.39.2
+
diff --git 
a/resources/memtest86plus/patch/0001-fix-memtest86-linker-error-during-build.patch
 
b/resources/memtest86plus/patch/0001-fix-memtest86-linker-error-during-build.patch
deleted file mode 100644
index b75e22d..0000000
--- 
a/resources/memtest86plus/patch/0001-fix-memtest86-linker-error-during-build.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From bed727867b7f5bc246067a4195a96abbc82aef35 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?F=C3=A9licien=20Pillot?= <felicien@gnu.org>
-Date: Tue, 8 Feb 2022 07:37:50 +0000
-Subject: [PATCH 1/1] fix memtest86+ linker error during build
-
----
- Makefile | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/Makefile b/Makefile
-index 7732491..23ea640 100644
---- a/Makefile
-+++ b/Makefile
-@@ -75,7 +75,7 @@ reloc.o: reloc.c
-       $(CC) -c $(CFLAGS) -fno-strict-aliasing reloc.c
- 
- test.o: test.c
--      $(CC) -c -Wall -march=i486 -m32 -O0 -fomit-frame-pointer -fno-builtin 
-ffreestanding -fno-strict-overflow test.c
-+      $(CC) -c -Wall -march=i486 -m32 -O0 -fomit-frame-pointer -fno-builtin 
-ffreestanding -fno-strict-overflow -fno-stack-protector test.c
- 
- random.o: random.c
-       $(CC) -c -Wall -march=i486 -m32 -O3 -fomit-frame-pointer -fno-builtin 
-ffreestanding random.c
--- 
-2.25.1
-
diff --git a/resources/packages/memtest86plus/download 
b/resources/packages/memtest86plus/download
index c0897c8..86eb915 100755
--- a/resources/packages/memtest86plus/download
+++ b/resources/packages/memtest86plus/download
@@ -49,20 +49,17 @@ printf "Downloading MemTest86+\n"
 
 rm -Rf "memtest86plus/"
 
-git clone https://review.coreboot.org/memtest86plus.git
+git clone https://github.com/memtest86plus/memtest86plus.git
 
-(
-cd "memtest86plus/"
-git reset --hard a78401b9704cfdd49c89bfb31d2df08f60521d0b
+git -C memtest86plus reset --hard 5dcd424ea7afb857c1171e747ef064d98d26afeb
 
-for patchfile in ../resources/memtest86plus/patch/*; do
+for patchfile in resources/memtest86plus/patch/*; do
        if [ ! -f "${patchfile}" ]; then
                continue
        fi
-       git am "${patchfile}"
+       git -C "memtest86plus" am "../${patchfile}"
 done
 
-rm -Rf .git*
-)
+rm -Rf memtest86plus/.git*
 
 printf "\n\n"
diff --git a/resources/packages/roms_helper/boot 
b/resources/packages/roms_helper/boot
index b9d24f4..ed82363 100755
--- a/resources/packages/roms_helper/boot
+++ b/resources/packages/roms_helper/boot
@@ -126,7 +126,7 @@ if [ "${payload_grub}" != "y" ] && [ "${payload_seabios}" 
!= "y" ]; then
 fi
 
 if [ "${payload_memtest}" = "y" ]; then
-       if [ ! -f "memtest86plus/memtest" ]; then
+       if [ ! -f "memtest86plus/build64/memtest.bin" ]; then
                ./build module memtest86plus
        fi
 fi
@@ -385,8 +385,8 @@ mkRoms() {
 
        mkCoreboot "${cbdir}" "${cbcfgpath}"
 
-       if [ "${displaymode}" = "txtmode" ] && [ "${payload_memtest}" = "y" ]; 
then
-               "${cbfstool}" "${corebootrom}" add-payload -f 
memtest86plus/memtest -n img/memtest -c lzma
+       if [ "${payload_memtest}" = "y" ]; then
+               "${cbfstool}" "${corebootrom}" add-payload -f 
memtest86plus/build64/memtest.bin -n img/memtest -c lzma
        fi
 
        if [ "${payload_seabios}" = "y" ]; then
-- 
2.39.2




reply via email to

[Prev in Thread] Current Thread [Next in Thread]