diff options
author | Michael Stahl <mstahl@redhat.com> | 2011-10-12 23:11:30 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2011-10-12 23:21:50 +0200 |
commit | eb15d03b906cfc183d455f69922eab3a8e6d0006 (patch) | |
tree | 77638e06dd523f358c6edeb3c8fbbd9e51eb0c12 | |
parent | 6659c12d12d5a00b618b9fe30c4b0d14df8f61d5 (diff) |
Configuration.mk: add nodeliver mode
Add a special mode where a Configuration does not deliver to the solver,
and use it in Configuration_mediawiki, preventing the files from
officecfg being overwritten by files from swext.
Should fix the annoying sc_test_filters failure and the smoketest
as well if the mediawiki extension is enabled.
-rw-r--r-- | solenv/gbuild/Configuration.mk | 30 | ||||
-rw-r--r-- | swext/Configuration_mediawiki.mk | 7 |
2 files changed, 25 insertions, 12 deletions
diff --git a/solenv/gbuild/Configuration.mk b/solenv/gbuild/Configuration.mk index b4441675de87..5f344871c9f4 100644 --- a/solenv/gbuild/Configuration.mk +++ b/solenv/gbuild/Configuration.mk @@ -311,13 +311,15 @@ $(call gb_Configuration_get_target,%) : $(call gb_Helper_abbreviate_dirs,\ mkdir -p $(dir $@) && touch $@) -# $(call gb_Configuration_Configuration,zipfile,repo) +# $(call gb_Configuration_Configuration,zipfile,repo,nodeliver) # cannot use target local variable for REPO because it's needed in prereq +# last parameter may be used to turn off delivering of files define gb_Configuration_Configuration $(if $(filter $(2),$(gb_Configuration_REPOSITORYNAMES)),,\ $(error Configuration: no or invalid repository given; known repositories: \ $(gb_Configuration_REPOSITORYNAMES))) $(eval gb_Configuration_REPO_$(1) := $(2)) +$(eval gb_Configuration_NODELIVER_$(1) := $(3)) $(foreach lang,$(gb_Configuration_LANGS),$(eval \ $(call gb_Zip_Zip,$(1)_$(lang),$(call gb_XcuResTarget_get_target,$(1)/$(lang))))) $(foreach lang,$(gb_Configuration_LANGS),$(eval \ @@ -331,15 +333,17 @@ $$(eval $$(call gb_Module_register_target,$(call gb_Configuration_get_target,$(1 endef # $(call gb_Configuration_add_schema,zipfile,prefix,xcsfile) +# FIXME this is always delivered because commands depend on it... +# hopefully extensions do not need to add schemas with same name as officecfg define gb_Configuration_add_schema $(call gb_Configuration_get_clean_target,$(1)) : \ $(call gb_XcsTarget_get_clean_target,$(2)/$(3)) -$(call gb_Configuration_get_target,$(1)) : \ - $(call gb_XcsTarget_get_outdir_target,$(3)) $(call gb_XcsTarget_get_target,$(2)/$(3)) : \ $(call gb_Configuration__get_source,$(1),$(2)/$(3)) $(call gb_XcsTarget_get_target,$(2)/$(3)) : XCSFILE := $(3) $(call gb_XcsTarget_get_clean_target,$(2)/$(3)) : XCSFILE := $(3) +$(call gb_Configuration_get_target,$(1)) : \ + $(call gb_XcsTarget_get_outdir_target,$(3)) $(call gb_XcsTarget_get_outdir_target,$(3)) : \ $(call gb_XcsTarget_get_target,$(2)/$(3)) $(call gb_Deliver_add_deliverable,$(call gb_XcsTarget_get_outdir_target,$(3)),\ @@ -357,19 +361,24 @@ endef define gb_Configuration_add_data $(call gb_Configuration_get_clean_target,$(1)) : \ $(call gb_XcuDataTarget_get_clean_target,$(2)/$(3)) -$(call gb_Configuration_get_target,$(1)) : \ - $(call gb_XcuDataTarget_get_outdir_target,$(3)) $(call gb_XcuDataTarget_get_target,$(2)/$(3)) : \ $(call gb_Configuration__get_source,$(1),$(2)/$(3)) \ $(call gb_XcsTarget_for_XcuTarget,$(3)) $(call gb_XcuDataTarget_get_target,$(2)/$(3)) : XCUFILE := $(3) $(call gb_XcuDataTarget_get_clean_target,$(2)/$(3)) : XCUFILE := $(3) +ifeq ($(strip $(gb_Configuration_NODELIVER_$(1))),) +$(call gb_Configuration_get_target,$(1)) : \ + $(call gb_XcuDataTarget_get_outdir_target,$(3)) $(call gb_XcuDataTarget_get_outdir_target,$(3)) : \ $(call gb_XcuDataTarget_get_target,$(2)/$(3)) $(call gb_Deliver_add_deliverable,\ $(call gb_XcuDataTarget_get_outdir_target,$(3)),\ $(call gb_XcuDataTarget_get_target,$(2)/$(3)),\ $(2)/$(3)) +else +$(call gb_Configuration_get_target,$(1)) : \ + $(call gb_XcuDataTarget_get_target,$(2)/$(3)) +endif endef @@ -383,18 +392,23 @@ endef define gb_Configuration_add_spool_module $(call gb_Configuration_get_clean_target,$(1)) : \ $(call gb_XcuModuleTarget_get_clean_target,$(2)/$(3)) -$(call gb_Configuration_get_target,$(1)) : \ - $(call gb_XcuModuleTarget_get_outdir_target,$(3)) $(call gb_XcuModuleTarget_get_target,$(2)/$(3)) : \ $(call gb_XcuDataSource_for_XcuModuleTarget,$(1),$(2)/$(3)) \ $(call gb_XcsTarget_for_XcuModuleTarget,$(3)) $(call gb_XcuModuleTarget_get_clean_target,$(2)/$(3)) : XCUFILE := $(3) +ifeq ($(strip $(gb_Configuration_NODELIVER_$(1))),) +$(call gb_Configuration_get_target,$(1)) : \ + $(call gb_XcuModuleTarget_get_outdir_target,$(3)) $(call gb_XcuModuleTarget_get_outdir_target,$(3)) : \ $(call gb_XcuModuleTarget_get_target,$(2)/$(3)) $(call gb_Deliver_add_deliverable,\ $(call gb_XcuModuleTarget_get_outdir_target,$(3)),\ $(call gb_XcuModuleTarget_get_target,$(2)/$(3)),\ $(2)/$(3)) +else +$(call gb_Configuration_get_target,$(1)) : \ + $(call gb_XcuModuleTarget_get_target,$(2)/$(3)) +endif endef @@ -405,6 +419,8 @@ $(foreach xcu,$(3),$(call gb_Configuration_add_spool_module,$(1),$(2),$(xcu))) endef define gb_Configuration__add_langpack +$(if $(gb_Configuration_NODELIVER_$(1)),\ + $(error TODO not needed yet: cannot add langpack if nodeliver)) $(call gb_Configuration_get_clean_target,$(1)) : \ $(call gb_XcuLangpackTarget_get_clean_target,$(2)/$(3)) $(call gb_Configuration_get_target,$(1)) : \ diff --git a/swext/Configuration_mediawiki.mk b/swext/Configuration_mediawiki.mk index 9ece045fdddc..23d10e77dba3 100644 --- a/swext/Configuration_mediawiki.mk +++ b/swext/Configuration_mediawiki.mk @@ -27,14 +27,11 @@ # instead of those above. # -$(eval $(call gb_Configuration_Configuration,mediawiki,SRCDIR)) +$(eval $(call gb_Configuration_Configuration,mediawiki,SRCDIR,nodeliver)) $(eval $(call gb_Configuration_add_datas,mediawiki,swext/mediawiki/src/registry/data,\ - org/openoffice/Office/Addons.xcu \ - org/openoffice/Office/OptionsDialog.xcu \ org/openoffice/Office/ProtocolHandler.xcu \ org/openoffice/Office/Paths.xcu \ - org/openoffice/Office/Custom/WikiExtension.xcu \ org/openoffice/TypeDetection/Filter.xcu \ org/openoffice/TypeDetection/Types.xcu \ )) @@ -47,4 +44,4 @@ $(eval $(call gb_Configuration_add_localized_datas,mediawiki,swext/mediawiki/src $(eval $(call gb_Configuration_add_schemas,mediawiki,swext/mediawiki/src/registry/schema,\ org/openoffice/Office/Custom/WikiExtension.xcs \ -)) +)) |