Kaydet (Commit) d61d02ba authored tarafından Michael Stahl's avatar Michael Stahl

gbuild: UnoApiTarget: fix spurious rebuilds:

Since commit 800f3882 there are spurious
rebuilds when a IDL file is rebuilt, because the rule for the idlc
invocation was changed to rebuild all IDL files, but the dummy rule for
.urd files only touched that when its own IDL file changes; this means
that the header target is not seen as outdated in this make run, but it
will be outdated in the next make run because then the .urd file
timestamp is checked and is newer.
The dummy rule for .urd files must touch the .urd file if and only if
the rule for the .done file re-builds that .urd file.

Change-Id: I37938aef0621c7d46809e02a06d22248de28271b
üst 169ee403
......@@ -67,10 +67,13 @@ define gb_UnoApiPartTarget__command
endef
# If idlc changed, rebuild everything; otherwise just the changed files.
# In order for this to work the .urd files need to have a dependency on
# idlc as well so their dummy rule fires if that changes.
$(call gb_UnoApiPartTarget_get_target,%.done) : \
$(gb_UnoApiPartTarget_IDLCTARGET) \
| $(gb_UCPPTARGET)
$(call gb_UnoApiPartTarget__command,$@,$*,$(filter-out $(gb_UnoApiPartTarget_IDLCTARGET),$^))
$(call gb_UnoApiPartTarget__command,$@,$*,$(filter-out $(gb_UnoApiPartTarget_IDLCTARGET),$(if $(filter $(gb_UnoApiPartTarget_IDLCTARGET),$?),$^,$?)))
ifeq ($(gb_FULLDEPS),$(true))
......@@ -179,8 +182,9 @@ define gb_UnoApiTarget__add_idlfile
$(call gb_UnoApiPartTarget_get_target,$(2)/idl.done) : \
$(call gb_UnoApiPartTarget_get_target,$(2)/$(3).urd)
$(call gb_UnoApiTarget__add_urdfile,$(1),$(call gb_UnoApiPartTarget_get_target,$(2)/$(3).urd))
$(call gb_UnoApiPartTarget_get_target,$(2)/$(3).urd) :| \
$(call gb_UnoApiPartTarget_get_target,$(2)/.dir)
$(call gb_UnoApiPartTarget_get_target,$(2)/$(3).urd) \
: $(gb_UnoApiPartTarget_IDLCTARGET) \
| $(call gb_UnoApiPartTarget_get_target,$(2)/.dir)
ifeq ($(gb_FULLDEPS),$(true))
$(call gb_UnoApiTarget_get_dep_target,$(1)) : UNOAPI_IDLFILES += $(2)/$(3).idl
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment