Open
Description
Using the HowTo instructions from the front page:
mkdir -p dev
cd dev
mkdir -p linuxboot-result
test -d linuxboot || git clone https://github.com/linuxboot/linuxboot
cd linuxboot
make \
BOARD=qemu \
KERNEL=~/dev/linuxboot-result/bzImage \
INITRD=~/dev/linuxboot-result/initrd.cpio.xz \
config
make
Is there a recommended build OS?
I'm getting errors building on several versions:
Centos6.10
Build stops at:
$ make
( cd edk2/OvmfPkg ; ./build.sh )
Initializing workspace
linuxboot/edk2/BaseTools
Loading previous configuration from linuxboot/edk2/Conf/BuildEnv.sh
WORKSPACE: linuxboot/edk2
EDK_TOOLS_PATH: linuxboot/edk2/BaseTools
CONF_PATH: linuxboot/edk2/Conf
using prebuilt tools
Running edk2 build for OvmfPkgX64
Traceback (most recent call last):
File "linuxboot/edk2/BaseTools/BinWrappers/PosixLike/../../Source/Python/build/build.py", line 34, in <module>
from Common import Misc as Utils
File "linuxboot/edk2/BaseTools/Source/Python/Common/Misc.py", line 2183
storeidset = {storeid for storeid, storename in self.DefaultStores.values() if storename in DefaultSIdList}
^
SyntaxError: invalid syntax
make: *** [boards/qemu/qemu.rom] Error 1
Centos7.8.2003
First I got:
cp edk2/Build/OvmfX64/DEBUG_GCC5/FV/OVMF.fd boards/qemu/qemu.rom
cp: cannot stat ‘edk2/Build/OvmfX64/DEBUG_GCC5/FV/OVMF.fd’: No such file or directory
make: *** [boards/qemu/qemu.rom] Error 1
Fixed with a symlink:
edk2/Build/OvmfX64/DEBUG_GCC5 -> DEBUG_GCC48/
now I get:
$ make
make: *** No rule to make target `~/dev/linuxboot-result/bzImage', needed by `build/qemu/Linux.ffs'. Stop.
Centos8.2.2004 & Ubuntu 20.04 & Fedora28
make[3]: Entering directory 'linuxboot/edk2/BaseTools/Source/C/Common'
gcc -c -MD -fshort-wchar -fno-strict-aliasing -Wall -Werror -Wno-deprecated-declarations -Wno-unused-result -nostdlib -c -g -I .. -I ../Include/Common -I ../Include/ -I ../Include/IndustryStandard -I ../Common/ -I .. -I . -I ../Include/X64/ -O2 EfiUtilityMsgs.c -o EfiUtilityMsgs.o
EfiUtilityMsgs.c: In function ‘PrintMessage’:
EfiUtilityMsgs.c:484:9: error: ‘strncat’ output may be truncated copying between 0 and 511 bytes from a string of length 511 [-Werror=stringop-truncation]
strncat (Line, Line2, MAX_LINE_LEN - strlen (Line) - 1);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
EfiUtilityMsgs.c:469:9: error: ‘strncat’ output may be truncated copying between 0 and 511 bytes from a string of length 511 [-Werror=stringop-truncation]
strncat (Line, Line2, MAX_LINE_LEN - strlen (Line) - 1);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
EfiUtilityMsgs.c:511:5: error: ‘strncat’ output may be truncated copying between 0 and 511 bytes from a string of length 511 [-Werror=stringop-truncation]
strncat (Line, Line2, MAX_LINE_LEN - strlen (Line) - 1);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make[3]: *** [../Makefiles/footer.makefile:27: EfiUtilityMsgs.o] Error 1
make[3]: Leaving directory 'linuxboot/edk2/BaseTools/Source/C/Common'
make[2]: *** [GNUmakefile:85: Common] Error 2
make[2]: Leaving directory 'linuxboot/edk2/BaseTools/Source/C'
make[1]: *** [GNUmakefile:25: Source/C] Error 2
make[1]: Leaving directory 'linuxboot/edk2/BaseTools'
make: *** [boards/qemu/Makefile.board:62: boards/qemu/qemu.rom] Error 2
Ubuntu18.04
GNUmakefile:314: recipe for target '~/dev/linuxboot/edk2/Build/OvmfX64/DEBUG_GCC5/X64/OvmfPkg/ResetVector/ResetVector/OUTPUT/ResetVector.bin' failed
make[1]: Leaving directory '~/dev/linuxboot/edk2/Build/OvmfX64/DEBUG_GCC5/X64/OvmfPkg/ResetVector/ResetVector'
make[1]: *** [~/dev/linuxboot/edk2/Build/OvmfX64/DEBUG_GCC5/X64/OvmfPkg/ResetVector/ResetVector/OUTPUT/ResetVector.bin] Error 127
build.py...
: error 7000: Failed to execute command
make tbuild [~/dev/linuxboot/edk2/Build/OvmfX64/DEBUG_GCC5/X64/OvmfPkg/ResetVector/ResetVector]
build.py...
: error F002: Failed to build module
~/dev/linuxboot/edk2/OvmfPkg/ResetVector/ResetVector.inf [X64, GCC5, DEBUG]
- Failed -
Build end time: 19:50:24, Jul.23 2020
Build total time: 00:00:06
boards/qemu/Makefile.board:62: recipe for target 'boards/qemu/qemu.rom' failed
make: *** [boards/qemu/qemu.rom] Error 1
Thanks.
Metadata
Metadata
Assignees
Labels
No labels