From b980eca67edd8e3dd43d8717dbd90a2104450f85 Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Tue, 18 Dec 2012 14:19:01 +0100 Subject: [PATCH] Adapt ure/source/uretest/ to passive component registration (regview only works for old binary .rdb files, so test-regview needs to use types.rdb now) Change-Id: Icd68122c08ae723010c42a8515e09c2d81f0cdda --- ure/source/uretest/JavaTest.java | 6 ------ ure/source/uretest/Makefile | 9 +++------ ure/source/uretest/Makefile.pln | 13 ++++--------- ure/source/uretest/cpptest.cc | 7 ------- ure/source/uretest/services.rdb.in | 24 ++++++++++++++++++++++++ 5 files changed, 31 insertions(+), 28 deletions(-) create mode 100644 ure/source/uretest/services.rdb.in diff --git a/ure/source/uretest/JavaTest.java b/ure/source/uretest/JavaTest.java index a57c248e1a49..2bc1b0c72056 100644 --- a/ure/source/uretest/JavaTest.java +++ b/ure/source/uretest/JavaTest.java @@ -32,12 +32,6 @@ public final class JavaTest implements XTest { throw new TestException("test", this); } - public static boolean __writeRegistryServiceInfo(XRegistryKey key) { - return - FactoryHelper.writeRegistryServiceInfo( - IMPLEMENTATION_NAME, SERVICE_NAME, key); - } - public static XSingleServiceFactory __getServiceFactory( String name, XMultiServiceFactory factory, XRegistryKey key) { diff --git a/ure/source/uretest/Makefile b/ure/source/uretest/Makefile index e988a70f6a49..8c399075d51a 100644 --- a/ure/source/uretest/Makefile +++ b/ure/source/uretest/Makefile @@ -279,13 +279,10 @@ out.sdk/types.urd: types.idl | out.sdk $(IDLC) -O$(@D) -I$(IDL_DIR) -cid -we $< -out.sdk/services.rdb: out.sdk/cpptest.uno.$(SHAREDLIB_EXT) \ - out.sdk/javatest.uno.jar | out.sdk +out.sdk/services.rdb: services.rdb.in | out.sdk/cpptest.uno.$(SHAREDLIB_EXT) \ + out.sdk/javatest.uno.jar out.sdk $(DEL) $(subst /,$(PS),$@) - $(REGCOMP) -register -r $@ \ - -c $(URLPREFIX)$(cwd)/out.sdk/cpptest.uno.$(SHAREDLIB_EXT) - $(REGCOMP) -register -br "$(URE_TYPES)" -br "$(URE_SERVICES)" -r $@ \ - -c $(URLPREFIX)$(cwd)/out.sdk/javatest.uno.jar + sed -e s/@SHAREDLIB_EXT@/$(SHAREDLIB_EXT)/ < $^ > $@ out.sdk: diff --git a/ure/source/uretest/Makefile.pln b/ure/source/uretest/Makefile.pln index 9a21e4aa92f6..fef981a10913 100644 --- a/ure/source/uretest/Makefile.pln +++ b/ure/source/uretest/Makefile.pln @@ -33,7 +33,7 @@ URE_HOME ?= /opt/openoffice.org/ure check: test-regview test-cpptest test-javatest test-javanative test-clientserver .PHONY: test-regview -test-regview: out.pln/services.rdb +test-regview: out.pln/types.rdb $(URE_HOME)/bin/regview $< > /dev/null .PHONY: test-cpptest @@ -263,14 +263,9 @@ out.pln/types.urd: types.idl | out.pln -I$(SDK_HOME)/idl -cid -we $< -out.pln/services.rdb: out.pln/cpptest.uno.so out.pln/javatest.uno.jar | out.pln - rm -f $@ - $(URE_HOME)/bin/regcomp -register -r $@ \ - -c file://$(PWD)/out.pln/cpptest.uno.so - $(URE_HOME)/bin/regcomp -register \ - -br $(URE_HOME)/share/misc/types.rdb \ - -br $(URE_HOME)/share/misc/services.rdb -r $@ \ - -c file://$(PWD)/out.pln/javatest.uno.jar +out.pln/services.rdb: services.rdb.in | out.pln/cpptest.uno.so \ + out.pln/javatest.uno.jar out.pln + sed -e s/@SHAREDLIB_EXT@/so/ < $^ > $@ out.pln/lib/libuno_cppu.so: | out.pln/lib diff --git a/ure/source/uretest/cpptest.cc b/ure/source/uretest/cpptest.cc index d1d641582b96..30950ec8483e 100644 --- a/ure/source/uretest/cpptest.cc +++ b/ure/source/uretest/cpptest.cc @@ -93,13 +93,6 @@ cppu::ImplementationEntry entries[] = { } -extern "C" SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL component_writeInfo( - void * serviceManager, void * registryKey) -{ - return cppu::component_writeInfoHelper( - serviceManager, registryKey, entries); -} - extern "C" SAL_DLLPUBLIC_EXPORT void * SAL_CALL component_getFactory( char const * implName, void * serviceManager, void * registryKey) { diff --git a/ure/source/uretest/services.rdb.in b/ure/source/uretest/services.rdb.in new file mode 100644 index 000000000000..0bec749e8e6b --- /dev/null +++ b/ure/source/uretest/services.rdb.in @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + +