diff options
author | Michael Stahl <mstahl@redhat.com> | 2014-06-12 16:46:22 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2014-06-12 16:52:31 +0200 |
commit | 9850c7258b2cb62b204895a72c4b01269ebb5110 (patch) | |
tree | 61700210d153aa1182f59f83f2c8f0d451f64e92 /officecfg | |
parent | c353153898c691dcd24b6f66153e9f8ec2d37eb0 (diff) |
officecfg: fix build of officecfg_qa_allheaders.hxx with Win32 make
The "#" character and line-breaks make it difficult to use the
non-$(file) var2file here so add a hacky conditional.
Change-Id: I1618a96b54209588cfe24190bfcbcda5b83f980f
Diffstat (limited to 'officecfg')
-rw-r--r-- | officecfg/CustomTarget_registry.mk | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/officecfg/CustomTarget_registry.mk b/officecfg/CustomTarget_registry.mk index 2bda037d6714..9aa17171f0f2 100644 --- a/officecfg/CustomTarget_registry.mk +++ b/officecfg/CustomTarget_registry.mk @@ -13,14 +13,24 @@ $(call gb_CustomTarget_get_target,officecfg/registry) : \ $(foreach i,officecfg_qa_allheaders $(officecfg_XCSFILES),\ $(call gb_CustomTarget_get_workdir,officecfg/registry)/officecfg/$(i).hxx) +# via define so it can end with a newline +define officecfg_geninclude +#include <officecfg/$(1).hxx> + +endef + # auto generated header file for unit test qa/cppheader.cxx $(call gb_CustomTarget_get_workdir,officecfg/registry)/officecfg/officecfg_qa_allheaders.hxx: \ $(SRCDIR)/officecfg/files.mk $(call gb_Output_announce,officecfg_qa_allheaders.hxx,$(true),CAT,1) +ifeq ($(HAVE_GNUMAKE_FILE_FUNC),) mkdir -p $(dir $@) && \ rm -f $@ \ $(foreach file,$(officecfg_XCSFILES),\ && echo "#include <officecfg/$(file).hxx>" >> $@) +else + mv $(call var2file,$(shell mkdir -p $(dir $@) && truncate -s 0 $@.tmp && echo $@.tmp),100,$(foreach file,$(officecfg_XCSFILES),$(call officecfg_geninclude,$(file)))) $@ +endif # pass the stem as space separated path elements and get a set of --stringparam ns<level> <element> in return officecfg_xsltparams=$(if $(filter-out $(lastword $1),$1),$(call officecfg_xsltparams,$(filter-out $(lastword $1),$1))) --stringparam ns$(words $1) $(lastword $1) |