build error

25 views
Skip to first unread message

Marek Matejka

unread,
Apr 29, 2021, 5:20:50 AM4/29/21
to EFI Boot Guard
Hello,

I'm getting the following compilation error:

| gcc  -std=gnu99 -DHAVE_CONFIG_H -I. -I../git  -I../git/include -I../git -include config.h -I../git/tools -isystem/data/meta-iot2000/build/tmp/work/x86_64-linux/efibootguard-native/0.7-r0/recipe-sysroot-native/usr/include -Wno-unused-parameter -Wmissing-prototypes -fshort-wchar -DHAVE_ENDIAN_H -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -Werror -isystem/data/meta-iot2000/build/tmp/work/x86_64-linux/efibootguard-native/0.7-r0/recipe-sysroot-native/usr/include -O2 -pipe -c -o tools/libebgenv_a-ebgpart.o `test -f 'tools/ebgpart.c' || echo '../git/'`tools/ebgpart.c
| In file included from /usr/include/fcntl.h:77:0,
|                  from ../git/include/ebgpart.h:46,
|                  from ../git/tools/ebgpart.c:19:
| /usr/include/bits/stat.h:106:31: error: expected identifier or ‘(’ before ‘[’ token
|      __syscall_slong_t __unused[3];
|                                ^
| /usr/include/bits/stat.h:164:31: error: expected identifier or ‘(’ before ‘[’ token
|      __syscall_slong_t __unused[3];
|                                ^
| gcc  -std=gnu99 -DHAVE_CONFIG_H -I. -I../git  -I../git/include -I../git -include config.h -isystem/data/meta-iot2000/build/tmp/work/x86_64-linux/efibootguard-native/0.7-r0/recipe-sysroot-native/usr/include -Wno-unused-parameter -Wmissing-prototypes -fshort-wchar -DHAVE_ENDIAN_H -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -Werror -isystem/data/meta-iot2000/build/tmp/work/x86_64-linux/efibootguard-native/0.7-r0/recipe-sysroot-native/usr/include -O2 -pipe -c -o tools/bg_setenv-bg_setenv.o `test -f 'tools/bg_setenv.c' || echo '../git/'`tools/bg_setenv.c
| make: *** [tools/libebgenv_a-ebgpart.o] Error 1
| make: *** Waiting for unfinished jobs....
| WARNING: /data/meta-iot2000/build/tmp/work/x86_64-linux/efibootguard-native/0.7-r0/temp/run.do_compile.14380:1 exit 1 from 'exit 1'
|
ERROR: Task (virtual:native:/data/meta-iot2000/meta-efibootguard/recipes-bsp/efibootguard/efibootguard_0.7.bb:do_compile) failed with exit code '1'

What am I doing wrong ?

Thank you for answer.

Best Regards
Marek Matejka

Jan Kiszka

unread,
Apr 29, 2021, 5:28:07 AM4/29/21
to Marek Matejka, EFI Boot Guard
This might be specific to the integration done in meta-iot2000. Maybe
start with opening an issue with
https://github.com/siemens/meta-iot2000/issues, describing which version
you built and how exactly.

Jan

--
Siemens AG, T RDA IOT
Corporate Competence Center Embedded Linux

Christian Storm

unread,
Apr 29, 2021, 5:40:26 AM4/29/21
to EFI Boot Guard
Hi,
Looks to me like you're trying to build a 64bit binary (and hence using
the headers for this) for a probably 32bit target?


Kind regards,
Christian

--
Dr. Christian Storm
Siemens AG, Technology, T RDA IOT SES-DE
Otto-Hahn-Ring 6, 81739 München, Germany

Marek Matejka

unread,
Apr 29, 2021, 6:09:53 AM4/29/21
to EFI Boot Guard
Hi,

Probably yes.

Build Configuration:
BB_VERSION           = "1.46.0"
BUILD_SYS            = "x86_64-linux"
NATIVELSBSTRING      = "universal-4.8"
TARGET_SYS           = "i586-poky-linux"
MACHINE              = "iot2000"
DISTRO               = "poky-iot2000"
DISTRO_VERSION       = "V3.1.1"
TUNE_FEATURES        = "m32 i586-nlp"

But I don't know how to change that. Build is automatic process:

$ kas build meta-iot2000/kas-example.yml

Matejka

Dne čtvrtek 29. dubna 2021 v 11:40:26 UTC+2 uživatel Christian Storm napsal:

Jan Kiszka

unread,
Apr 29, 2021, 8:21:57 AM4/29/21
to Marek Matejka, EFI Boot Guard
On 29.04.21 12:09, Marek Matejka wrote:
> Hi,
>
> Probably yes.
>
> Build Configuration:
> BB_VERSION           = "1.46.0"
> BUILD_SYS            = "x86_64-linux"
> NATIVELSBSTRING      = "universal-4.8"
> TARGET_SYS           = "i586-poky-linux"
> MACHINE              = "iot2000"
> DISTRO               = "poky-iot2000"
> DISTRO_VERSION       = "V3.1.1"
> TUNE_FEATURES        = "m32 i586-nlp"
>
> But I don't know how to change that. Build is automatic process:
>
> $ kas build meta-iot2000/kas-example.yml
>

See https://github.com/siemens/meta-iot2000/issues/167 - unsupported
host OS for this Yocto build.


But we also don't build without patches against CentOS 7 (possibly also
newer) due to different packaging of gnu-efi there:

CCLD efibootguardx64.so
ld: cannot open linker script file /usr/lib64/elf_x86_64_efi.lds: No
such file or directory

It's under /usr/lib64/gnuefi on that OS.
Reply all
Reply to author
Forward
0 new messages