Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add meta-coreboot and meta-dasharo to meta-rte build, #84

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

Al-an-21
Copy link

drop coreboot-utils, and install dcu package.

@Al-an-21 Al-an-21 self-assigned this Nov 22, 2024
@Al-an-21 Al-an-21 marked this pull request as draft November 22, 2024 15:13
@Al-an-21 Al-an-21 force-pushed the add-coreboot-dasharo-to-rte branch from 8e04b2f to 53f5e9c Compare November 22, 2024 15:33
@Al-an-21 Al-an-21 marked this pull request as ready for review November 22, 2024 15:33
@m-iwanicki m-iwanicki force-pushed the add-coreboot-dasharo-to-rte branch 2 times, most recently from 5efb7d4 to b14a365 Compare December 9, 2024 11:08
@m-iwanicki m-iwanicki requested a review from macpijan December 9, 2024 11:11
@m-iwanicki
Copy link

meta-rte used coreboot/coreboot version after changes we are using dasharo/coreboot from meta-coreboot

@m-iwanicki m-iwanicki force-pushed the add-coreboot-dasharo-to-rte branch 2 times, most recently from de3d691 to a739293 Compare December 9, 2024 13:17
@m-iwanicki
Copy link

@macpijan after changing to dasharo/coreboot I get errors when trying to build cbfstool:

error: 'memcpy' specified bound between 2147483648 and 4294967295 exceeds maximum object size 2147483647 [-Werror=stringop-overflow=]

ERROR: cbfstool-4.21+git-r0 do_compile: oe_runmake failed
ERROR: cbfstool-4.21+git-r0 do_compile: ExecutionError('/build/tmp/work/cortexa7t2hf-neon-rte-linux-gnueabi/cbfstool/4.21+git/temp/run.do_compile.940', 1, None, None)
ERROR: Logfile of failure stored in: /build/tmp/work/cortexa7t2hf-neon-rte-linux-gnueabi/cbfstool/4.21+git/temp/log.do_compile.940
Log data follows:
| DEBUG: Executing shell function do_compile
| NOTE: make -j 32 DESTDIR="/build/tmp/work/cortexa7t2hf-neon-rte-linux-gnueabi/cbfstool/4.21+git/image" PREFIX="/usr" -C util/cbfstool cbfstool
| make: Entering directory '/build/tmp/work/cortexa7t2hf-neon-rte-linux-gnueabi/cbfstool/4.21+git/git/util/cbfstool'
|     HOSTCC     cbfstool/cbfstool.o
|     HOSTCC     cbfstool/common.o
|     HOSTCC     cbfstool/cbfs_image.o
|     HOSTCC     cbfstool/cbfs-mkstage.o
|     HOSTCC     cbfstool/cbfs-mkpayload.o
|     HOSTCC     cbfstool/elfheaders.o
|     HOSTCC     cbfstool/rmodule.o
|     HOSTCC     cbfstool/xdr.o
|     HOSTCC     cbfstool/partitioned_file.o
|     HOSTCC     cbfstool/platform_fixups.o
|     HOSTCC     cbfstool/cbfs_private.o
|     HOSTCC     cbfstool/fsp_relocate.o
|     HOSTCC     cbfstool/fmap.o
|     HOSTCC     cbfstool/kv_pair.o
|     HOSTCC     cbfstool/valstr.o
|     HOSTCC     cbfstool/linux_trampoline.o
|     HOSTCC     cbfstool/cbfs-payload-linux.o
|     HOSTCC     cbfstool/compress.o
|     HOSTCC     cbfstool/lz4.o
|     HOSTCC     cbfstool/lz4hc.o
|     HOSTCC     cbfstool/lz4frame.o
|     HOSTCC     cbfstool/xxhash.o
|     HOSTCC     cbfstool/lz4_wrapper.o
|     HOSTCC     cbfstool/lzma.o
|     HOSTCC     cbfstool/LzFind.o
|     HOSTCC     cbfstool/LzmaDec.o
|     HOSTCC     cbfstool/LzmaEnc.o
|     MAKE       /build/tmp/work/cortexa7t2hf-neon-rte-linux-gnueabi/cbfstool/4.21+git/git/util/vboot_lib/libvboot_host.a
| make[1]: Entering directory '/build/tmp/work/cortexa7t2hf-neon-rte-linux-gnueabi/cbfstool/4.21+git/git/3rdparty/vboot'
| vboot SHA256 built with tight loops (slower, smaller code size)
|     CC            cgpt/cgpt_add.o
|     CC            cgpt/cgpt_boot.o
|     CC            cgpt/cgpt_common.o
|     CC            cgpt/cgpt_create.o
|     CC            cgpt/cgpt_edit.o
|     CC            cgpt/cgpt_find.o
|     CC            cgpt/cgpt_prioritize.o
|     CC            cgpt/cgpt_repair.o
|     CC            cgpt/cgpt_show.o
|     CC            firmware/2lib/2common.o
|     CC            firmware/2lib/2context.o
|     CC            firmware/2lib/2crc8.o
|     CC            firmware/2lib/2crypto.o
|     CC            firmware/2lib/2hmac.o
|     CC            firmware/2lib/2kernel.o
|     CC            firmware/2lib/2nvstorage.o
|     CC            firmware/2lib/2recovery_reasons.o
|     CC            firmware/2lib/2rsa.o
|     CC            firmware/2lib/2sha1.o
|     CC            firmware/2lib/2sha256.o
|     CC            firmware/2lib/2sha512.o
|     CC            firmware/2lib/2sha_utility.o
|     CC            firmware/2lib/2struct.o
|     CC            firmware/2lib/2stub.o
|     CC            firmware/2lib/2stub_hwcrypto.o
|     CC            firmware/lib/cgptlib/cgptlib_internal.o
|     CC            firmware/lib/cgptlib/crc32.o
|     CC            firmware/lib/gpt_misc.o
|     CC            firmware/stub/tpm_lite_stub.o
|     CC            firmware/stub/vboot_api_stub_disk.o
|     CC            futility/dump_kernel_config_lib.o
|     CC            host/arch/x86_64/lib/crossystem_arch.o
|     CC            host/lib/chromeos_config.o
|     CC            host/lib/crossystem.o
|     CC            host/lib/crypto.o
|     CC            host/lib/extract_vmlinuz.o
|     CC            host/lib/subprocess.o
|     CC            host/lib/cbfstool.o
|     CC            host/lib/fmap.o
|     CC            host/lib/host_misc.o
|     CC            host/lib21/host_misc.o
|     CC            firmware/lib/tpm_lite/tlcl.o
| host/lib/extract_vmlinuz.c: In function 'ExtractVmlinuz':
| host/lib/extract_vmlinuz.c:67:9: error: 'memcpy' specified bound between 2147483648 and 4294967295 exceeds maximum object size 2147483647 [-Werror=stringop-overflow=]
|    67 |         memcpy(vmlinuz, kpart_data + vmlinuz_header_offset,
|       |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|    68 |                vmlinuz_header_size);
|       |                ~~~~~~~~~~~~~~~~~~~~
| At top level:
| cc1: note: unrecognized command-line option '-Wno-unknown-warning' may have been intended to silence earlier diagnostics
| cc1: all warnings being treated as errors
| make[1]: *** [Makefile:1163: /build/tmp/work/cortexa7t2hf-neon-rte-linux-gnueabi/cbfstool/4.21+git/git/util/vboot_lib/host/lib/extract_vmlinuz.o] Error 1
| make[1]: *** Waiting for unfinished jobs....
| make[1]: Leaving directory '/build/tmp/work/cortexa7t2hf-neon-rte-linux-gnueabi/cbfstool/4.21+git/git/3rdparty/vboot'
| make: *** [Makefile.inc:155: /build/tmp/work/cortexa7t2hf-neon-rte-linux-gnueabi/cbfstool/4.21+git/git/util/vboot_lib/libvboot_host.a] Error 2
| make: *** Waiting for unfinished jobs....
| make: Leaving directory '/build/tmp/work/cortexa7t2hf-neon-rte-linux-gnueabi/cbfstool/4.21+git/git/util/cbfstool'
| ERROR: oe_runmake failed
| WARNING: exit code 1 from a shell command.
ERROR: Task (/build/../work/meta-coreboot/recipes-bsp/coreboot-utils/cbfstool_git.bb:do_compile) failed with exit code '1'
NOTE: Tasks Summary: Attempted 834 tasks of which 827 didn't need to be rerun and 1 failed.

@m-iwanicki
Copy link

Added fix here: fcce000
@krystian-hebel said that error might be due to treating some variable (maybe pointer?) as a signed value instead of unsigned.
Build completed successfully

Copy link
Member

@macpijan macpijan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks ok but there are two pre-commit failures. If we do not like them, we can silence them or disable in config.

Al-an-21 and others added 2 commits December 10, 2024 22:33
Needed to ignore `'memcpy' specified bound between 2147483648 and
4294967295 exceeds maximum object size 2147483647`.

Signed-off-by: Michał Iwanicki <[email protected]>
@m-iwanicki m-iwanicki force-pushed the add-coreboot-dasharo-to-rte branch from fcce000 to 2e591bf Compare December 10, 2024 21:33
@m-iwanicki
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants