diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2012-02-17 15:50:38 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2012-02-17 15:51:49 +0100 |
commit | 28137a5177de7823351b7d61149a6c194c46bb54 (patch) | |
tree | 302418427d485bf3195a65b9ebc4555798bbd3d0 /solenv/gbuild/JavaClassSet.mk | |
parent | a3aa7ada194c33a9bedd2b5ce0506b1c5f3604a6 (diff) |
Various fixes for JunitTests
Diffstat (limited to 'solenv/gbuild/JavaClassSet.mk')
-rw-r--r-- | solenv/gbuild/JavaClassSet.mk | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/solenv/gbuild/JavaClassSet.mk b/solenv/gbuild/JavaClassSet.mk index 838b957620ae..d21f649b489f 100644 --- a/solenv/gbuild/JavaClassSet.mk +++ b/solenv/gbuild/JavaClassSet.mk @@ -69,8 +69,8 @@ $(call gb_JavaClassSet_get_preparation_target,%) : mkdir -p $(dir $@) && touch $@ define gb_JavaClassSet_JavaClassSet -$(call gb_JavaClassSet_get_target,$(1)) : JARDEPS := $(call gb_JavaClassSet_get_preparation_target,$(1)) $(call gb_JavaClassSet_get_target,$(1)) : $(call gb_JavaClassSet_get_preparation_target,$(1)) +$(call gb_JavaClassSet_get_target,$(1)) : JARDEPS := $(call gb_JavaClassSet_get_preparation_target,$(1)) endef @@ -112,16 +112,15 @@ endef # build order dependency is a hack to get these prerequisites out of the way in the build command define gb_JavaClassSet_add_jar $(call gb_JavaClassSet_get_target,$(1)) : $(2) -$(call gb_JavaClassSet_get_target,$(1)) : T_CP := $$(T_CP)$(gb_CLASSPATHSEP)$(strip $(2)) $(call gb_JavaClassSet_get_target,$(1)) : JARDEPS += $(2) +$(call gb_JavaClassSet_get_target,$(1)) : T_CP := $$(if $$(T_CP),$$(T_CP)$(gb_CLASSPATHSEP))$(strip $(2)) $(2) :| $(gb_Helper_PHONY) endef # this does not generate dependency on the jar define gb_JavaClassSet_add_system_jar -$(call gb_JavaClassSet_get_target,$(1)) : T_CP := $$(T_CP)$(gb_CLASSPATHSEP)$(strip $(2)) -$(call gb_JavaClassSet_get_target,$(1)) : JARDEPS += $(2) +$(call gb_JavaClassSet_get_target,$(1)) : T_CP := $$(if $$(T_CP),$$(T_CP)$(gb_CLASSPATHSEP))$(strip $(2)) endef @@ -135,6 +134,19 @@ $(foreach jar,$(2),$(call gb_JavaClassSet_add_system_jar,$(1),$(jar))) endef +# gb_JavaClassSet_add_jar_classset: Like gb_JavaClassSet_add_jar, but instead of +# using the jar, use the directory tree with the class files that make up the +# jar. This is sometimes necessary in JunitTests that have test classes in +# packages that belong to a sealed jar. +# $1: token identifying this JavaClassSet +# $2: token identifying the Jar being used +define gb_JavaClassSet_add_jar_classset +$(call gb_JavaClassSet_get_target,$(1)) : $(call gb_JavaClassSet_get_target,$(call gb_Jar_get_classsetname,$(2))) +$(call gb_JavaClassSet_get_target,$(1)) : JARDEPS += $(call gb_JavaClassSet_get_target,$(call gb_Jar_get_classsetname,$(2))) +$(call gb_JavaClassSet_get_target,$(1)) : T_CP := $$(if $$(T_CP),$$(T_CP)$(gb_CLASSPATHSEP))$(call gb_JavaClassSet_get_classdir,$(call gb_Jar_get_classsetname,$(2))) + +endef + # this forwards to functions that must be defined in RepositoryExternal.mk. # $(eval $(call gb_LinkTarget_use_external,library,external)) define gb_JavaClassSet_use_external |