2016-02-01 12:03:04 +01:00
|
|
|
additional-dirs += $(objutil)/futility
|
|
|
|
|
2020-03-09 03:58:37 +01:00
|
|
|
VBOOT_FUTILITY = $(VBOOT_HOST_BUILD)/futility/futility
|
|
|
|
|
2020-06-29 21:10:44 +02:00
|
|
|
HOSTPKGCONFIG ?= pkg-config
|
|
|
|
|
2020-11-11 14:50:01 +01:00
|
|
|
$(VBOOT_FUTILITY): | check-openssl-presence
|
2016-02-01 12:03:04 +01:00
|
|
|
@printf " MAKE $(subst $(objutil)/,,$(@))\n"
|
2016-07-24 12:10:38 +02:00
|
|
|
unset CFLAGS LDFLAGS; $(MAKE) -C $(VBOOT_SOURCE) \
|
2020-03-09 03:58:37 +01:00
|
|
|
BUILD=$(VBOOT_HOST_BUILD) \
|
2016-02-01 12:03:04 +01:00
|
|
|
CC="$(HOSTCC)" \
|
2020-06-29 21:10:44 +02:00
|
|
|
PKG_CONFIG="$(HOSTPKGCONFIG)" \
|
2016-02-01 12:03:04 +01:00
|
|
|
V=$(V) \
|
2021-12-20 03:26:07 +01:00
|
|
|
USE_FLASHROM=0 \
|
2020-03-09 03:58:37 +01:00
|
|
|
$@
|
2016-02-01 12:03:04 +01:00
|
|
|
|
2020-06-29 21:10:44 +02:00
|
|
|
.PHONY: check-openssl-presence
|
|
|
|
check-openssl-presence:
|
2022-02-24 05:04:25 +01:00
|
|
|
@$(HOSTPKGCONFIG) --exists libcrypto || \
|
2020-06-29 21:10:44 +02:00
|
|
|
(echo "Error: Ensure that pkg-config and openssl's libcrypto, including header files, are installed."; exit 1)
|
|
|
|
|
2020-03-09 03:58:37 +01:00
|
|
|
$(objutil)/futility/futility: $(VBOOT_FUTILITY)
|
|
|
|
mkdir -p $(dir $@)
|
2016-02-01 12:03:04 +01:00
|
|
|
cp $< $@.tmp
|
|
|
|
mv $@.tmp $@
|