build: Make sure configure uses configure.ac mtime.

Since we moved the rsync into the container, configure dependency on
configure.ac was broken, leading to it not being regenerated until a
second build. This is because timestamps are read by make earlier than
the rsync, which runs after the top-level rules are checked.
This commit is contained in:
Rémi Bernon 2023-12-09 08:53:50 +01:00 committed by Arkadiusz Hiler
parent 59699bb4d1
commit 9079a24016

View file

@ -7,14 +7,11 @@
define create-rules-autoconf define create-rules-autoconf
$(call create-rules-common,$(1),$(2),$(3),$(4)) $(call create-rules-common,$(1),$(2),$(3),$(4))
$$($(2)_SRC)/configure.ac: | $$(OBJ)/.$(1)-post-source $$($(2)_SRC)/configure: $$($(2)_ORIGIN)/configure.ac | $$(OBJ)/.$(1)-post-source
$$(OBJ)/.$(1)-pre-configure: $$($(2)_SRC)/configure.ac
@echo ":: autoreconfing $(1)..." >&2 @echo ":: autoreconfing $(1)..." >&2
cd "$$($(2)_SRC)" && autoreconf -fiv cd "$$($(2)_SRC)" && autoreconf -fiv
touch $$@
$$(OBJ)/.$(1)-configure$(3): $$(OBJ)/.$(1)-pre-configure $$(OBJ)/.$(1)-configure$(3): $$($(2)_SRC)/configure
@echo ":: configuring $(3)bit $(1)..." >&2 @echo ":: configuring $(3)bit $(1)..." >&2
rm -rf "$$($(2)_OBJ$(3))/config.cache" rm -rf "$$($(2)_OBJ$(3))/config.cache"