[syslinux] EFI build problems

Ferenc Wagner wferi at niif.hu
Sat Jan 11 03:37:53 PST 2014


Gene Cumm <gene.cumm at gmail.com> writes:

> Could you try gnuefi-script-for-wferi-test branch on my repos at
>
>   git://git.zytor.com/users/genec/syslinux.git
>   git://github.com/geneC/syslinux.git
>
> These changes fixed my issues (aside from the concurrency issue which
> 2-3 passes solves for me).

Now this shows me something I haven't ever seen.  Build continuing in
the background after the main process exits?

wferi at lant:~/syslinux/genec$ make
[...]
gcc -Wp,-MT,isohdppx_f.o,-MD,./.isohdppx_f.o.d -m32 -march=i386 -mpreferred-stack-boundary=2 -mincoming-stack-boundary=2 -ffreestanding -fno-stack-protector -fwrapv -freg-struct-return -Os -fomit-frame-pointer -msoft-float -fno-exceptions -fno-asynchronous-unwind-tables -fno-strict-aliasing -falign-functions=0 -falign-jumps=0 -falign-labels=0 -falign-loops=0 -fvisibility=hidden -g -W -Wall -Wstrict-prototypes  -Wno-clobbered  -DDYNAMIC_DEBUG -Wno-sign-compare   -D__ASSEMBLY__ -Wa,-a=isohdppx_f.lst -DFORCE_80 -c -o isohdppx_f.o /home/wferi/syslinux/genec/mbr/isohdppx.S
ld -m elf_i386  -T /home/wferi/syslinux/genec/mbr/i386/mbr.ld -e _start -o isohdppx_f.elf isohdppx_f.o
objcopy -O binary isohdppx_f.elf isohdppx_f.bin
perl /home/wferi/syslinux/genec/mbr/checksize.pl isohdppx_f.bin
chmod -x isohdppx_f.bin
rm mbr_f.o isohdppx_c.o altmbr_c.o isohdppx_f.o gptmbr_c.o isohdppx.o altmbr_f.o altmbr.o isohdpfx_c.o mbr_c.o gptmbr_f.o gptmbr.o isohdpfx_f.o isohdpfx.o mbr.o
make[3]: Leaving directory `/home/wferi/syslinux/genec/efi32/mbr'
make -r -C sample SRC="/home/wferi/syslinux/genec/sample" OBJ="/home/wferi/syslinux/genec/efi32/sample" \
		-f /home/wferi/syslinux/genec/sample/Makefile all
make[3]: Entering directory `/home/wferi/syslinux/genec/efi32/sample'
gzip -cd /home/wferi/syslinux/genec/sample/syslogo.ppm.gz | \
		/home/wferi/syslinux/genec/utils/ppmtolss16 \#000000=0 \#d0d0d0=7 \#f6f6f6=15	\
		> syslogo.lss
204480 pixels, 25715 bytes, (74.85% compression)
make[3]: Leaving directory `/home/wferi/syslinux/genec/efi32/sample'
make -r -C efi SRC="/home/wferi/syslinux/genec/efi" OBJ="/home/wferi/syslinux/genec/efi32/efi" \
		-f /home/wferi/syslinux/genec/efi/Makefile all
make[3]: Entering directory `/home/wferi/syslinux/genec/efi32/efi'
Building gnu-efi for ia32
/home/wferi/syslinux/genec/efi/check-gnu-efi.sh ia32 /home/wferi/syslinux/genec /home/wferi/syslinux/genec/efi32
mkdir -p i386
gcc -Wp,-MT,adv.o,-MD,./.adv.o.d -I/home/wferi/syslinux/genec/efi32/include/efi -I/home/wferi/syslinux/genec/efi32/include/efi/ia32 -DEFI_FUNCTION_WRAPPER -fPIC -fshort-wchar -ffreestanding -Wall -I/home/wferi/syslinux/genec/com32/include -I/home/wferi/syslinux/genec/com32/include/sys -I/home/wferi/syslinux/genec/core/include -I/home/wferi/syslinux/genec/core/ -m32 -march=i386 -I/home/wferi/syslinux/genec/com32/lib/ -I/home/wferi/syslinux/genec/com32/libutil/include -std=gnu99 -DELF_DEBUG -DSYSLINUX_EFI -I/home/wferi/syslinux/genec/efi32 -W -Wall -Wstrict-prototypes  -Wno-clobbered  -DDYNAMIC_DEBUG -D__COM32__ -mno-red-zone -DLDLINUX=\"ldlinux.e32\" -fvisibility=hidden -Wno-unused-parameter -Wno-strict-prototypes -DDATE_STR='"4.03-pre3-2126-g73d08a5"' -c -o adv.o /home/wferi/syslinux/genec/efi/adv.c
In file included from /home/wferi/syslinux/genec/efi/adv.h:4:0,
                 from /home/wferi/syslinux/genec/efi/adv.c:29:
/home/wferi/syslinux/genec/efi/efi.h:23:17: fatal error: efi.h: No such file or directory
compilation terminated.
make[3]: *** [adv.o] Error 1
make[3]: Leaving directory `/home/wferi/syslinux/genec/efi32/efi'
make[2]: *** [efi] Error 2
make[2]: Leaving directory `/home/wferi/syslinux/genec/efi32'
make[1]: *** [efi32] Error 2
make[1]: Leaving directory `/home/wferi/syslinux/genec'
make: *** [all] Error 2
wferi at lant:~/syslinux/genec$ Submodule 'gnu-efi' (git://git.code.sf.net/p/gnu-efi/code) registered for path 'gnu-efi'
Cloning into 'gnu-efi'...
remote: Counting objects: 330, done.
remote: Compressing objects: 100% (283/283), done.
remote: Total 330 (delta 139), reused 112 (delta 18)
Receiving objects: 100% (330/330), 196.25 KiB | 136 KiB/s, done.
Resolving deltas: 100% (139/139), done.
Submodule path 'gnu-efi': checked out '27cdb748654bc90d5695e35a1f38cfdd6b5499fc'
make[4]: Entering directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0'
[...]
make[4]: Leaving directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0'
make[4]: Entering directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0'
make[5]: Entering directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/lib'
mkdir -p ///home/wferi/syslinux/genec/efi32/lib
install -m 644 libefi.a ///home/wferi/syslinux/genec/efi32/lib
make[5]: Leaving directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/lib'
make[5]: Entering directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/gnuefi'
mkdir -p ///home/wferi/syslinux/genec/efi32/lib
install -m 644 crt0-efi-ia32.o libgnuefi.a ///home/wferi/syslinux/genec/efi32/lib
install -m 644 elf_ia32_efi.lds ///home/wferi/syslinux/genec/efi32/lib
make[5]: Leaving directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/gnuefi'
make[5]: Entering directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/inc'
mkdir -p //home/wferi/syslinux/genec/efi32/include/efi
mkdir -p //home/wferi/syslinux/genec/efi32/include/efi/protocol
mkdir -p //home/wferi/syslinux/genec/efi32/include/efi/ia32
install -m 644 *.h //home/wferi/syslinux/genec/efi32/include/efi
install -m 644 protocol/*.h //home/wferi/syslinux/genec/efi32/include/efi/protocol
install -m 644 ia32/*.h //home/wferi/syslinux/genec/efi32/include/efi/ia32
make[5]: Leaving directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/inc'
make[5]: Entering directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/apps'
make[5]: Nothing to be done for `install'.
make[5]: Leaving directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/apps'
make[4]: Leaving directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0'
make[4]: Entering directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0'
rm -f *~
make[5]: Entering directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/lib'
rm -f libefi.a *~ boxdraw.o smbios.o console.o crc.o data.o debug.o dpath.o error.o event.o guid.o hand.o hw.o init.o lock.o misc.o print.o sread.o str.o runtime/rtlock.o runtime/efirtlib.o runtime/rtstr.o runtime/vm.o runtime/rtdata.o ia32/initplat.o ia32/math.o */*.o
make[5]: Leaving directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/lib'
make[5]: Entering directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/gnuefi'
rm -f crt0-efi-ia32.o libgnuefi.a *~ *.o reloc_ia32.o setjmp_ia32.o
make[5]: Leaving directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/gnuefi'
make[5]: Entering directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/inc'
make[5]: Nothing to be done for `clean'.
make[5]: Leaving directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/inc'
make[5]: Entering directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/apps'
rm -f t.efi t2.efi t3.efi t4.efi t5.efi t6.efi printenv.efi t7.efi tcc.efi modelist.efi route80h.efi drv0_use.efi AllocPages.efi FreePages.efi drv0.efi  *~ *.o *.so
make[5]: Leaving directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/apps'
make[4]: Leaving directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0'
wferi at lant:~/syslinux/genec$ echo $?
2

It took me some time to find the error way back in the log...

The second make gave a similar result:

gcc -Wp,-MT,adv.o,-MD,./.adv.o.d -I/home/wferi/syslinux/genec/efi64/include/efi -I/home/wferi/syslinux/genec/efi64/include/efi/x86_64 -DEFI_FUNCTION_WRAPPER -fPIC -fshort-wchar -ffreestanding -Wall -I/home/wferi/syslinux/genec/com32/include -I/home/wferi/syslinux/genec/com32/include/sys -I/home/wferi/syslinux/genec/core/include -I/home/wferi/syslinux/genec/core/ -m64 -march=x86-64 -I/home/wferi/syslinux/genec/com32/lib/ -I/home/wferi/syslinux/genec/com32/libutil/include -std=gnu99 -DELF_DEBUG -DSYSLINUX_EFI -I/home/wferi/syslinux/genec/efi64 -W -Wall -Wstrict-prototypes  -Wno-clobbered  -DDYNAMIC_DEBUG -D__COM32__ -mno-red-zone -DLDLINUX=\"ldlinux.e64\" -fvisibility=hidden -Wno-unused-parameter -Wno-strict-prototypes -DDATE_STR='"4.03-pre3-2126-g73d08a5"' -c -o adv.o /home/wferi/syslinux/genec/efi/adv.c
In file included from /home/wferi/syslinux/genec/efi/adv.h:4:0,
                 from /home/wferi/syslinux/genec/efi/adv.c:29:
/home/wferi/syslinux/genec/efi/efi.h:23:17: fatal error: efi.h: No such file or directory
compilation terminated.
Submodule 'gnu-efi' () registered for path 'gnu-efi'
make[4]: Entering directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0'
mkdir -p lib
make -C lib -f ./../lib/Makefile SRCDIR=./../lib ARCH=x86_64
make[5]: Entering directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/lib'
for sdir in ia32 x86_64 ia64 runtime; do mkdir -p $sdir; done
/usr/bin/gcc -I./../lib -I./../lib/../inc -I./../lib/../inc/x86_64 -I./../lib/../inc/protocol -mno-red-zone -mno-mmx -mno-sse  -O2 -fpic -Wall -fshort-wchar -fno-strict-aliasing -fno-merge-constants -ffreestanding -fno-stack-protector -fno-stack-check -DGNU_EFI_USE_MS_ABI -maccumulate-outgoing-args --std=c11 -DCONFIG_x86_64 -c boxdraw.c -o boxdraw.o
make[3]: *** [adv.o] Error 1
make[3]: Leaving directory `/home/wferi/syslinux/genec/efi64/efi'
make[2]: *** [efi] Error 2
make[2]: Leaving directory `/home/wferi/syslinux/genec/efi64'
make[1]: *** [efi64] Error 2
make[1]: Leaving directory `/home/wferi/syslinux/genec'
make: *** [all] Error 2
wferi at lant:~/syslinux/genec$ /usr/bin/ar rv libefi.a boxdraw.o
/usr/bin/ar: creating libefi.a
a - boxdraw.o
[...]
make[5]: Leaving directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0/apps'
make[4]: Leaving directory `/home/wferi/syslinux/genec/gnu-efi/gnu-efi-3.0'

wferi at lant:~/syslinux/genec$ echo $?
2

But the third one finally succeeded indeed!  I hope these concurrency
issues can also be sorted out soon, they carry a sloppy feeling.
Recursive make is considered harmful for a reason, I guess... :)

Also wouldn't relying on the INSTALLROOT support in the gnu-efi build
system make our build scripts simpler?

While we are at it: make spotless also ran fine afterwards, but left
some files under bios, and some more under the efi dirs.  I don't know
how much of that is intentional, just noting it.

> We still should get a check and warning about multilib in there.

That would have helped me immensely.  Sorry for my ignorance, and thanks
for the support!

Hmm, I've got gnu-efi 3.0u installed system-wide, I wonder if that makes
a difference...  It really should not, though.
-- 
Regards,
Feri.


More information about the Syslinux mailing list