futility: Use HOSTPKGCONFIG for host PKG_CONFIG
futility is built for the host. However, when cross-compiling, the target's pkg-config is called to get the library paths which can add paths from the cross-compilation tree instead of host. e.g. /build/elm/usr/bin/pkg-config gets called instead of /usr/bin/pkg-config . /build/elm/usr/bin/pkg-config adds the paths specific to the cross-compilation target e.g. /build/elm/usr/lib instead of /usr/lib. This causes linker to complain that files in library paths do not match the architecture. BFD produces a warning while LLD errors out. Fix this by passing PKG_CONFIG from host when building futility. BUG=chromium:999217 TEST=coreboot builds BRANCH=None Cq-Depend: chromium:1778519 Change-Id: Id3afbf25001cf3daa72f36a290c93136cf9f162d Signed-off-by: Patrick Georgi <pgeorgi@google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/35316 Reviewed-by: Julius Werner <jwerner@chromium.org> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
parent
1d260e6573
commit
297e9c826f
|
@ -5,6 +5,7 @@ $(objutil)/futility/build/futility/futility:
|
||||||
unset CFLAGS LDFLAGS; $(MAKE) -C $(VBOOT_SOURCE) \
|
unset CFLAGS LDFLAGS; $(MAKE) -C $(VBOOT_SOURCE) \
|
||||||
BUILD=$(abspath $@/../..) \
|
BUILD=$(abspath $@/../..) \
|
||||||
CC="$(HOSTCC)" \
|
CC="$(HOSTCC)" \
|
||||||
|
$(if $(HOSTPKGCONFIG), PKG_CONFIG="$(HOSTPKGCONFIG)") \
|
||||||
V=$(V) \
|
V=$(V) \
|
||||||
$(abspath $@)
|
$(abspath $@)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue