From c0c62ebbae1d22c1882026cad41d530fa9854175 Mon Sep 17 00:00:00 2001 From: Thomas Heijligen Date: Tue, 29 Nov 2022 19:51:03 +0100 Subject: libpayload: bin/lpgcc allow to call without files When building libflashrom ontop of libpayload, meson calls the lpgcc wrapper with -xc but without a file to obtain information about the C compiler. To make this work guard $_LIBGCC with -xnone in the lpgcc wrapper. -xnone tells the compiler to interpret the following files of libpayload by their suffix, not the privious given -x option. Change-Id: I9e037ff44c0a6d0585d8a6f8aeabae6e651142e2 Signed-off-by: Thomas Heijligen Reviewed-on: https://review.coreboot.org/c/coreboot/+/70117 Reviewed-by: Julius Werner Tested-by: build bot (Jenkins) Reviewed-by: Nico Huber --- payloads/libpayload/bin/lpgcc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'payloads') diff --git a/payloads/libpayload/bin/lpgcc b/payloads/libpayload/bin/lpgcc index 5e418e84bd6d..35fa5584a80c 100755 --- a/payloads/libpayload/bin/lpgcc +++ b/payloads/libpayload/bin/lpgcc @@ -229,5 +229,5 @@ else # header to be placed below 0x2000 in the resulting image. See: # http://www.gnu.org/software/grub/manual/multiboot/html_node/OS-image-format.html - $DEFAULT_CC $_LDFLAGS $HEAD_O $CMDLINE $_CFLAGS -lpayload $_LIBGCC + $DEFAULT_CC $_LDFLAGS $HEAD_O $CMDLINE $_CFLAGS -lpayload -xnone $_LIBGCC fi -- cgit v1.2.3