[Libreoffice-commits] .: testtools/CustomTarget_bridgetest.mk testtools/CustomTarget_bridgetest_climaker.mk testtools/CustomTarget_bridgetest_javamaker.mk testtools/CustomTarget_uno_test.mk
Michael Stahl
mst at kemper.freedesktop.org
Tue Jun 5 07:14:26 PDT 2012
testtools/CustomTarget_bridgetest.mk | 47 ++++++++++---------------
testtools/CustomTarget_bridgetest_climaker.mk | 9 ++--
testtools/CustomTarget_bridgetest_javamaker.mk | 10 ++---
testtools/CustomTarget_uno_test.mk | 11 +++--
4 files changed, 36 insertions(+), 41 deletions(-)
New commits:
commit 71dbf5bfd0b9622ad485a5b7620e11d8405ed474
Author: Michael Stahl <mstahl at redhat.com>
Date: Tue Jun 5 16:04:20 2012 +0200
normalize gbuild variable names in testtools.
Variables should have module name as prefix to prevent collisions.
Change-Id: I8937e1e04db422d629779ea470bfbd614aeb7524
diff --git a/testtools/CustomTarget_bridgetest.mk b/testtools/CustomTarget_bridgetest.mk
index 473613d..c30ac3d 100644
--- a/testtools/CustomTarget_bridgetest.mk
+++ b/testtools/CustomTarget_bridgetest.mk
@@ -26,44 +26,37 @@
$(eval $(call gb_CustomTarget_CustomTarget,testtools/bridgetest))
-workdir_SERVER := $(call gb_CustomTarget_get_workdir,testtools/bridgetest)
-UNO_EXE := $(OUTDIR)/bin/uno
+testtools_BRIDGEDIR := $(call gb_CustomTarget_get_workdir,testtools/bridgetest)
ifeq ($(OS),WNT)
-BATCH_SUFFIX := .bat
-GIVE_EXEC_RIGHTS=@echo
+testtools_BATCHSUFFIX := .bat
else
-BATCH_SUFFIX :=
-GIVE_EXEC_RIGHTS=chmod +x
+testtools_BATCHSUFFIX :=
endif
-bridgetest_TARGET := $(workdir_SERVER)/bridgetest_server$(BATCH_SUFFIX) \
- $(workdir_SERVER)/bridgetest_client$(BATCH_SUFFIX)
+$(call gb_CustomTarget_get_target,testtools/bridgetest) : \
+ $(testtools_BRIDGEDIR)/bridgetest_server$(testtools_BATCHSUFFIX) \
+ $(testtools_BRIDGEDIR)/bridgetest_client$(testtools_BATCHSUFFIX) \
+ $(if $(SOLAR_JAVA),\
+ $(testtools_BRIDGEDIR)/bridgetest_javaserver$(testtools_BATCHSUFFIX) \
+ $(testtools_BRIDGEDIR)/bridgetest_inprocess_java$(testtools_BATCHSUFFIX))
-ifneq ($(SOLAR_JAVA),)
-bridgetest_TARGET := $(bridgetest_TARGET) \
- $(workdir_SERVER)/bridgetest_javaserver$(BATCH_SUFFIX) \
- $(workdir_SERVER)/bridgetest_inprocess_java$(BATCH_SUFFIX)
-endif
-
-$(call gb_CustomTarget_get_target,testtools/bridgetest) : $(bridgetest_TARGET)
-
-$(workdir_SERVER)/bridgetest_server$(BATCH_SUFFIX) :| $(workdir_SERVER)/.dir
+$(testtools_BRIDGEDIR)/bridgetest_server$(testtools_BATCHSUFFIX) :| $(testtools_BRIDGEDIR)/.dir
$(call gb_Output_announce,$(subst $(WORKDIR)/,,$@),$(true),ECH,1)
$(call gb_Helper_abbreviate_dirs,\
- echo "$(UNO_EXE)" \
+ echo "$(call gb_Executable_get_target_for_build,uno)" \
"-ro $(OUTDIR)/xml/uno_services.rdb" \
"-ro $(OUTDIR)/bin/udkapi.rdb" \
"-ro $(WORKDIR)/UnoApiTarget/bridgetest.rdb" \
"-s com.sun.star.test.bridge.CppTestObject" \
"-u 'uno:socket$(COMMA)host=127.0.0.1$(COMMA)port=2002;urp;test'" \
"--singleaccept" > $@)
- $(GIVE_EXEC_RIGHTS) $@
+ $(if $(filter-out WNT,$(OS)),chmod +x $@)
testtools_MY_CLASSPATH := $(OUTDIR)/bin/ridl.jar$(gb_CLASSPATHSEP)$(OUTDIR)/bin/java_uno.jar$(gb_CLASSPATHSEP)$(OUTDIR)/bin/jurt.jar$(gb_CLASSPATHSEP)$(OUTDIR)/bin/juh.jar
-$(workdir_SERVER)/bridgetest_javaserver$(BATCH_SUFFIX) :| $(workdir_SERVER)/.dir
+$(testtools_BRIDGEDIR)/bridgetest_javaserver$(testtools_BATCHSUFFIX) :| $(testtools_BRIDGEDIR)/.dir
$(call gb_Output_announce,$(subst $(WORKDIR)/,,$@),$(true),ECH,1)
$(call gb_Helper_abbreviate_dirs,\
echo "java" \
@@ -71,14 +64,14 @@ $(workdir_SERVER)/bridgetest_javaserver$(BATCH_SUFFIX) :| $(workdir_SERVER)/.dir
"com.sun.star.comp.bridge.TestComponentMain" \
\""uno:socket$(COMMA)host=127.0.0.1$(COMMA)port=2002;urp;test"\" \
"singleaccept"> $@)
- $(GIVE_EXEC_RIGHTS) $@
+ $(if $(filter-out WNT,$(OS)),chmod +x $@)
-$(workdir_SERVER)/bridgetest_inprocess_java$(BATCH_SUFFIX) :| $(workdir_SERVER)/.dir
+$(testtools_BRIDGEDIR)/bridgetest_inprocess_java$(testtools_BATCHSUFFIX) :| $(testtools_BRIDGEDIR)/.dir
$(call gb_Output_announce,$(subst $(WORKDIR)/,,$@),$(true),ECH,1)
$(call gb_Helper_abbreviate_dirs,\
echo "JAVA_HOME=$(JAVA_HOME)" \
"LD_LIBRARY_PATH=$(OUTDIR)/lib" \
- "$(UNO_EXE)" \
+ "$(call gb_Executable_get_target_for_build,uno)" \
"-ro $(OUTDIR)/xml/ure/services.rdb" \
"-ro $(OUTDIR)/xml/uno_services.rdb" \
"-ro $(OUTDIR)/bin/udkapi.rdb" \
@@ -88,12 +81,12 @@ $(workdir_SERVER)/bridgetest_inprocess_java$(BATCH_SUFFIX) :| $(workdir_SERVER)/
"-env:URE_INTERNAL_LIB_DIR=file://$(OUTDIR)/lib" \
"-- com.sun.star.test.bridge.JavaTestObject noCurrentContext" \
> $@)
- $(GIVE_EXEC_RIGHTS) $@
+ $(if $(filter-out WNT,$(OS)),chmod +x $@)
-$(workdir_SERVER)/bridgetest_client$(BATCH_SUFFIX) :| $(workdir_SERVER)/.dir
+$(testtools_BRIDGEDIR)/bridgetest_client$(testtools_BATCHSUFFIX) :| $(testtools_BRIDGEDIR)/.dir
$(call gb_Output_announce,$(subst $(WORKDIR)/,,$@),$(true),ECH,1)
$(call gb_Helper_abbreviate_dirs,\
- echo "$(UNO_EXE)" \
+ echo "$(call gb_Executable_get_target_for_build,uno)" \
"-ro $(OUTDIR)/xml/ure/services.rdb" \
"-ro $(OUTDIR)/xml/uno_services.rdb" \
"-ro $(OUTDIR)/bin/udkapi.rdb" \
@@ -101,6 +94,6 @@ $(workdir_SERVER)/bridgetest_client$(BATCH_SUFFIX) :| $(workdir_SERVER)/.dir
"-s com.sun.star.test.bridge.BridgeTest --" \
"-u 'uno:socket$(COMMA)host=127.0.0.1$(COMMA)port=2002;urp;test'" \
> $@)
- $(GIVE_EXEC_RIGHTS) $@
+ $(if $(filter-out WNT,$(OS)),chmod +x $@)
# vim: set noet sw=4 ts=4:
diff --git a/testtools/CustomTarget_bridgetest_climaker.mk b/testtools/CustomTarget_bridgetest_climaker.mk
index 56c7f79..2f04fa6 100644
--- a/testtools/CustomTarget_bridgetest_climaker.mk
+++ b/testtools/CustomTarget_bridgetest_climaker.mk
@@ -26,14 +26,15 @@
$(eval $(call gb_CustomTarget_CustomTarget,testtools/bridgetest_climaker))
-climaker_DIR := $(call gb_CustomTarget_get_workdir,testtools/bridgetest_climaker)
+testtools_CLIDIR := $(call gb_CustomTarget_get_workdir,testtools/bridgetest_climaker)
$(call gb_CustomTarget_get_target,testtools/bridgetest_climaker) : \
- $(climaker_DIR)/cli_types_bridgetest.dll
+ $(testtools_CLIDIR)/cli_types_bridgetest.dll
-$(climaker_DIR)/cli_types_bridgetest.dll : \
+$(testtools_CLIDIR)/cli_types_bridgetest.dll : \
$(OUTDIR)/bin/types.rdb $(OUTDIR)/bin/cli_uretypes.dll \
- $(call gb_Executable_get_target_for_build,climaker) | $(climaker_DIR)/.dir
+ $(call gb_Executable_get_target_for_build,climaker) \
+ | $(testtools_CLIDIR)/.dir
$(call gb_Output_announce,$(subst $(WORKDIR)/,,$@),$(true),CLM,1)
$(call gb_Helper_abbreviate_dirs, \
$(call gb_Helper_execute,climaker) \
diff --git a/testtools/CustomTarget_bridgetest_javamaker.mk b/testtools/CustomTarget_bridgetest_javamaker.mk
index 593cf16..e509e04 100644
--- a/testtools/CustomTarget_bridgetest_javamaker.mk
+++ b/testtools/CustomTarget_bridgetest_javamaker.mk
@@ -26,14 +26,14 @@
$(eval $(call gb_CustomTarget_CustomTarget,testtools/bridgetest_javamaker))
-javamaker_DIR := $(call gb_CustomTarget_get_workdir,testtools/bridgetest_javamaker)
+testtools_JAVADIR := $(call gb_CustomTarget_get_workdir,testtools/bridgetest_javamaker)
-$(call gb_CustomTarget_get_target,testtools/bridgetest_javamaker) : $(javamaker_DIR)/done
+$(call gb_CustomTarget_get_target,testtools/bridgetest_javamaker) : $(testtools_JAVADIR)/done
-$(javamaker_DIR)/done : $(call gb_UnoApiTarget_get_target,bridgetest) \
- $(call gb_Executable_get_target_for_build,javamaker) | $(javamaker_DIR)/.dir
+$(testtools_JAVADIR)/done : $(call gb_UnoApiTarget_get_target,bridgetest) \
+ $(call gb_Executable_get_target_for_build,javamaker) | $(testtools_JAVADIR)/.dir
$(call gb_Output_announce,$(subst $(WORKDIR)/,,$@),$(true),JVM,1)
$(call gb_Helper_abbreviate_dirs, \
- $(call gb_Helper_execute,javamaker -BUCR -nD -O$(javamaker_DIR)/class -X$(OUTDIR)/bin/types.rdb $<) && touch $@)
+ $(call gb_Helper_execute,javamaker -BUCR -nD -O$(testtools_JAVADIR)/class -X$(OUTDIR)/bin/types.rdb $<) && touch $@)
# vim:set shiftwidth=4 tabstop=4 noexpandtab:
diff --git a/testtools/CustomTarget_uno_test.mk b/testtools/CustomTarget_uno_test.mk
index 89a8d27..3cbea08 100644
--- a/testtools/CustomTarget_uno_test.mk
+++ b/testtools/CustomTarget_uno_test.mk
@@ -25,15 +25,16 @@
# instead of those above.
$(eval $(call gb_CustomTarget_CustomTarget,testtools/uno_test))
-UNO_EXE := $(OUTDIR)/bin/uno
# this target is phony to run it every time
.PHONY : $(call gb_CustomTarget_get_target,testtools/uno_test)
-$(call gb_CustomTarget_get_target,testtools/uno_test) : $(call gb_Rdb_get_target,uno_services) \
- $(UNO_EXE) \
- $(call gb_InternalUnoApi_get_target,bridgetest)
- $(call gb_Helper_abbreviate_dirs, $(UNO_EXE) \
+$(call gb_CustomTarget_get_target,testtools/uno_test) : \
+ $(call gb_Rdb_get_target,uno_services) \
+ $(call gb_Executable_get_target_for_build,uno) \
+ $(call gb_InternalUnoApi_get_target,bridgetest)
+ $(call gb_Helper_abbreviate_dirs,\
+ $(call gb_Executable_get_target_for_build,uno) \
-ro $(OUTDIR)/xml/uno_services.rdb \
-ro $(OUTDIR)/bin/udkapi.rdb \
-ro $(WORKDIR)/UnoApiTarget/bridgetest.rdb \
More information about the Libreoffice-commits
mailing list