summaryrefslogtreecommitdiff
path: root/solenv/gbuild
diff options
context:
space:
mode:
authorDavid Tardon <dtardon@redhat.com>2013-05-24 15:47:38 +0200
committerDavid Tardon <dtardon@redhat.com>2013-05-24 16:52:00 +0200
commitf546f4fc968bcbd490159e2c80bf04a95a35df49 (patch)
tree29460a8bae7b3633eb037dd19c93b7c3fcf254a8 /solenv/gbuild
parent1d95129bdc48cd93d1aba2591bdf87ee6ab7b296 (diff)
gbuild: simplify reg. of targets for Postprocess
Change-Id: Id184df89c5c15c55e42f376ed06c83174c486f67
Diffstat (limited to 'solenv/gbuild')
-rw-r--r--solenv/gbuild/AllLangResTarget.mk2
-rw-r--r--solenv/gbuild/Executable.mk2
-rw-r--r--solenv/gbuild/Library.mk2
-rw-r--r--solenv/gbuild/Module.mk3
-rw-r--r--solenv/gbuild/Package.mk3
-rw-r--r--solenv/gbuild/Postprocess.mk6
-rw-r--r--solenv/gbuild/UIConfig.mk2
-rw-r--r--solenv/gbuild/gbuild.mk2
8 files changed, 15 insertions, 7 deletions
diff --git a/solenv/gbuild/AllLangResTarget.mk b/solenv/gbuild/AllLangResTarget.mk
index cb22a46aaa03..37262d2116c2 100644
--- a/solenv/gbuild/AllLangResTarget.mk
+++ b/solenv/gbuild/AllLangResTarget.mk
@@ -454,7 +454,6 @@ $(call gb_AllLangResTarget_get_target,%) :
mkdir -p $(dir $@) && touch $@)
define gb_AllLangResTarget_AllLangResTarget
-$(call gb_Postprocess_get_target,AllResources) : $(call gb_AllLangResTarget_get_target,$(1))
$(foreach lang,$(gb_AllLangResTarget_LANGS),\
$(call gb_ResTarget_ResTarget,$(1)$(lang),$(1),$(lang)))
@@ -471,6 +470,7 @@ endif
$$(eval $$(call gb_Module_register_target,$(call gb_AllLangResTarget_get_target,$(1)),$(call gb_AllLangResTarget_get_clean_target,$(1))))
$(call gb_Helper_make_userfriendly_targets,$(1),AllLangResTarget)
+$(call gb_Postprocess_register_target,AllResources,AllLangResTarget,$(1))
endef
diff --git a/solenv/gbuild/Executable.mk b/solenv/gbuild/Executable.mk
index d2d6b4186f6a..b3e5fb8a5071 100644
--- a/solenv/gbuild/Executable.mk
+++ b/solenv/gbuild/Executable.mk
@@ -58,7 +58,7 @@ gb_Executable__get_dir_for_layer = $(patsubst $(1):%,%,$(filter $(1):%,$(gb_Exec
gb_Executable__get_instdir = $(call gb_Executable__get_dir_for_layer,$(call gb_Executable_get_layer,$(1)))
define gb_Executable_Executable
-$(call gb_Postprocess_get_target,AllExecutables) : $(call gb_Executable_get_target,$(1))
+$(call gb_Postprocess_register_target,AllExecutables,Executable,$(1))
ifeq (,$$(findstring $(1),$$(gb_Executable_KNOWN)))
$$(eval $$(call gb_Output_info,Currently known executables: $(sort $(gb_Executable_KNOWN)),ALL))
$$(eval $$(call gb_Output_error,Executable $(1) must be registered in Repository.mk))
diff --git a/solenv/gbuild/Library.mk b/solenv/gbuild/Library.mk
index cee2d67a9848..918898da231c 100644
--- a/solenv/gbuild/Library.mk
+++ b/solenv/gbuild/Library.mk
@@ -58,7 +58,7 @@ gb_Library__get_dir_for_layer = $(patsubst $(1):%,%,$(filter $(1):%,$(gb_Library
gb_Library_get_instdir = $(call gb_Library__get_dir_for_layer,$(call gb_Library_get_layer,$(1)))
define gb_Library_Library
-$(call gb_Postprocess_get_target,AllLibraries) : $(call gb_Library_get_target,$(1))
+$(call gb_Postprocess_register_target,AllLibraries,Library,$(1))
ifeq (,$$(findstring $(1),$$(gb_Library_KNOWNLIBS)))
$$(eval $$(call gb_Output_info,Currently known libraries are: $(sort $(gb_Library_KNOWNLIBS)),ALL))
$$(eval $$(call gb_Output_error,Library $(1) must be registered in Repository.mk))
diff --git a/solenv/gbuild/Module.mk b/solenv/gbuild/Module.mk
index e4515635ea27..4b859ce1a5b0 100644
--- a/solenv/gbuild/Module.mk
+++ b/solenv/gbuild/Module.mk
@@ -167,7 +167,6 @@ gb_Module__debug_enabled = \
$(filter all $(1)/,$(ENABLE_DEBUGINFO_FOR)))
define gb_Module_Module
-$(if $(filter-out libreoffice instsetoo_native android ios,$(1)),$(call gb_Postprocess_get_target,AllModulesButInstsetNative) : $(call gb_Module_get_target,$(1)))
gb_Module_ALLMODULES += $(1)
gb_Module_MODULELOCATIONS += $(1):$(dir $(realpath $(lastword $(MAKEFILE_LIST))))
gb_Module_TARGETSTACK := $(call gb_Module_get_target,$(1)) $(gb_Module_TARGETSTACK)
@@ -178,6 +177,8 @@ gb_Module_CLEANTARGETSTACK := $(call gb_Module_get_clean_target,$(1)) $(gb_Modul
gb_Module_CURRENTMODULE_DEBUG_ENABLED := $(call gb_Module__debug_enabled,$(1))
gb_Module_CURRENTMODULE_NAME := $(1)
$(call gb_Helper_make_userfriendly_targets,$(1),Module)
+$(if $(filter-out libreoffice instsetoo_native android ios,$(1)),\
+ $(call gb_Postprocess_register_target,AllModulesButInstsetNative,Module,$(1)))
endef
diff --git a/solenv/gbuild/Package.mk b/solenv/gbuild/Package.mk
index dc5b44121b3a..63da3865e519 100644
--- a/solenv/gbuild/Package.mk
+++ b/solenv/gbuild/Package.mk
@@ -100,7 +100,8 @@ $(call gb_Package_get_target,$(1)) :| $(dir $(call gb_Package_get_target,$(1))).
endef
define gb_Package_Package
-$(if $(filter postprocess% instsetoo_native%,$(1)),,$(call gb_Postprocess_get_target,AllPackages) : $(call gb_Package_get_target,$(1)))
+$(if $(filter postprocess% instsetoo_native%,$(1)),,\
+ $(call gb_Postprocess_register_target,AllPackages,Package,$(1)))
$(call gb_Package_Package_internal,$(1),$(2))
$$(eval $$(call gb_Module_register_target,$(call gb_Package_get_target,$(1)),$(call gb_Package_get_clean_target,$(1))))
$(call gb_Helper_make_userfriendly_targets,$(1),Package)
diff --git a/solenv/gbuild/Postprocess.mk b/solenv/gbuild/Postprocess.mk
index 972a795538f0..7e6eec0b5fce 100644
--- a/solenv/gbuild/Postprocess.mk
+++ b/solenv/gbuild/Postprocess.mk
@@ -22,6 +22,12 @@ $(call gb_Postprocess_get_target,$(1)) :| $(dir $(call gb_Postprocess_get_target
endef
+# gb_Postprocess_register_target category class targetname
+define gb_Postprocess_register_target
+$(call gb_Postprocess_get_target,$(1)) : $(call gb_$(2)_get_target,$(3))
+
+endef
+
define gb_Postprocess_make_targets
$(call gb_Postprocess_Postprocess,AllExecutables,All executables)
$(call gb_Postprocess_Postprocess,AllLibraries,All libraries)
diff --git a/solenv/gbuild/UIConfig.mk b/solenv/gbuild/UIConfig.mk
index 52cffe59f1a5..82ff5a7bba3d 100644
--- a/solenv/gbuild/UIConfig.mk
+++ b/solenv/gbuild/UIConfig.mk
@@ -216,7 +216,6 @@ $(call gb_PackageSet_add_package,$(call gb_UIConfig_get_packagesetname,$(1)),$(c
$(call gb_UIConfig_get_target,$(1)) :| $(dir $(call gb_UIConfig_get_target,$(1))).dir
$(call gb_UIConfig_get_imagelist_target,$(1)) :| $(dir $(call gb_UIConfig_get_imagelist_target,$(1))).dir
$(call gb_UIConfig_get_target,$(1)) : $(call gb_PackageSet_get_target,$(call gb_UIConfig_get_packagesetname,$(1)))
-$(call gb_Postprocess_get_target,AllUIConfigs) : $(call gb_UIConfig_get_target,$(1))
$(call gb_UIConfig_get_clean_target,$(1)) : $(call gb_PackageSet_get_clean_target,$(call gb_UIConfig_get_packagesetname,$(1)))
ifneq ($(gb_UIConfig_LANGS),)
@@ -225,6 +224,7 @@ endif
$$(eval $$(call gb_Module_register_target,$(call gb_UIConfig_get_target,$(1)),$(call gb_UIConfig_get_clean_target,$(1))))
$(call gb_Helper_make_userfriendly_targets,$(1),UIConfig)
+$(call gb_Postprocess_register_target,AllUIConfigs,UIConfig,$(1))
endef
diff --git a/solenv/gbuild/gbuild.mk b/solenv/gbuild/gbuild.mk
index 866434d7e4d8..f2647ee9cb5f 100644
--- a/solenv/gbuild/gbuild.mk
+++ b/solenv/gbuild/gbuild.mk
@@ -302,6 +302,7 @@ $(eval $(call gb_Deliver_init))
include $(foreach class, \
ComponentTarget \
+ Postprocess \
AllLangResTarget \
WinResTarget \
LinkTarget \
@@ -345,7 +346,6 @@ include $(foreach class, \
InstallModule \
InstallScript \
AutoInstallLibs \
- Postprocess \
PackageSet \
GeneratedPackage \
,$(GBUILDDIR)/$(class).mk)