summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cli_ure/CliLibrary_cli_basetypes.mk33
-rw-r--r--cli_ure/CliLibrary_cli_ure.mk33
-rw-r--r--cli_ure/CliNativeLibrary_cli_cppuhelper.mk25
-rw-r--r--cli_ure/CliUnoApi_cli_uretypes.mk22
-rw-r--r--cli_ure/CustomTarget_cli_ure_assemblies.mk62
-rw-r--r--cli_ure/Executable_climaker.mk41
-rw-r--r--cli_ure/Library_cli_cppuhelper_native.mk53
-rw-r--r--cli_ure/Library_cli_uno.mk36
-rw-r--r--cli_ure/Makefile7
-rw-r--r--cli_ure/Module_cli_ure.mk30
-rw-r--r--cli_ure/Package_config.mk17
-rw-r--r--cli_ure/Package_version.mk14
-rw-r--r--solenv/gbuild/CliUnoApi.mk3
13 files changed, 374 insertions, 2 deletions
diff --git a/cli_ure/CliLibrary_cli_basetypes.mk b/cli_ure/CliLibrary_cli_basetypes.mk
new file mode 100644
index 000000000000..d9f8a04d90c6
--- /dev/null
+++ b/cli_ure/CliLibrary_cli_basetypes.mk
@@ -0,0 +1,33 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+include $(SRCDIR)/cli_ure/version/version.txt
+
+$(eval $(call gb_CliLibrary_CliLibrary,cli_basetypes))
+
+$(eval $(call gb_CliLibrary_set_configfile,cli_basetypes,cli_ure/source/basetypes/cli_basetypes_config))
+
+$(eval $(call gb_CliLibrary_set_policy,cli_basetypes,$(CLI_BASETYPES_POLICY_ASSEMBLY),$(CLI_BASETYPES_POLICY_VERSION)))
+
+$(eval $(call gb_CliLibrary_add_csfiles,cli_basetypes,\
+ cli_ure/source/basetypes/uno/Any \
+ cli_ure/source/basetypes/uno/BoundAttribute \
+ cli_ure/source/basetypes/uno/ExceptionAttribute \
+ cli_ure/source/basetypes/uno/OnewayAttribute \
+ cli_ure/source/basetypes/uno/ParameterizedTypeAttribute \
+ cli_ure/source/basetypes/uno/PolymorphicType \
+ cli_ure/source/basetypes/uno/TypeArgumentsAttribute \
+ cli_ure/source/basetypes/uno/TypeParametersAttribute \
+))
+
+$(eval $(call gb_CliLibrary_add_generated_csfiles,cli_basetypes,\
+ CustomTarget/cli_ure/source/basetypes/assembly \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/cli_ure/CliLibrary_cli_ure.mk b/cli_ure/CliLibrary_cli_ure.mk
new file mode 100644
index 000000000000..1b9c1163b9dd
--- /dev/null
+++ b/cli_ure/CliLibrary_cli_ure.mk
@@ -0,0 +1,33 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+include $(SRCDIR)/cli_ure/version/version.txt
+
+$(eval $(call gb_CliLibrary_CliLibrary,cli_ure))
+
+$(eval $(call gb_CliLibrary_set_configfile,cli_ure,cli_ure/source/ure/cli_ure_config))
+
+$(eval $(call gb_CliLibrary_set_policy,cli_ure,$(CLI_URE_POLICY_ASSEMBLY),$(CLI_URE_POLICY_VERSION)))
+
+$(eval $(call gb_CliLibrary_use_assemblies,cli_ure,\
+ cli_uretypes \
+))
+
+$(eval $(call gb_CliLibrary_add_csfiles,cli_ure,\
+ cli_ure/source/ure/uno/util/DisposeGuard \
+ cli_ure/source/ure/uno/util/WeakAdapter \
+ cli_ure/source/ure/uno/util/WeakBase \
+ cli_ure/source/ure/uno/util/WeakComponentBase \
+))
+
+$(eval $(call gb_CliLibrary_add_generated_csfiles,cli_ure,\
+ CustomTarget/cli_ure/source/ure/assembly \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/cli_ure/CliNativeLibrary_cli_cppuhelper.mk b/cli_ure/CliNativeLibrary_cli_cppuhelper.mk
new file mode 100644
index 000000000000..23ed5fa8afbc
--- /dev/null
+++ b/cli_ure/CliNativeLibrary_cli_cppuhelper.mk
@@ -0,0 +1,25 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+include $(SRCDIR)/cli_ure/version/version.txt
+
+$(eval $(call gb_CliNativeLibrary_CliNativeLibrary,cli_cppuhelper))
+
+$(eval $(call gb_CliNativeLibrary_wrap_library,cli_cppuhelper,cli_cppuhelper_native))
+
+$(eval $(call gb_CliNativeLibrary_set_configfile,cli_cppuhelper,cli_ure/source/native/cli_cppuhelper_config))
+
+$(eval $(call gb_CliNativeLibrary_set_policy,cli_cppuhelper,$(CLI_CPPUHELPER_POLICY_ASSEMBLY),$(CLI_CPPUHELPER_POLICY_VERSION)))
+
+$(eval $(call gb_CliNativeLibrary_use_assemblies,cli_cppuhelper,\
+ cli_ure \
+ cli_uretypes \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/cli_ure/CliUnoApi_cli_uretypes.mk b/cli_ure/CliUnoApi_cli_uretypes.mk
new file mode 100644
index 000000000000..af3566e92a29
--- /dev/null
+++ b/cli_ure/CliUnoApi_cli_uretypes.mk
@@ -0,0 +1,22 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+include $(SRCDIR)/cli_ure/version/version.txt
+
+$(eval $(call gb_CliUnoApi_CliUnoApi,cli_uretypes))
+
+$(eval $(call gb_CliUnoApi_set_assembly_version,cli_uretypes,$(CLI_URETYPES_NEW_VERSION)))
+
+$(eval $(call gb_CliUnoApi_set_configfile,cli_uretypes,cli_ure/unotypes/cli_uretypes_config))
+
+$(eval $(call gb_CliUnoApi_set_policy,cli_uretypes,$(CLI_URETYPES_POLICY_ASSEMBLY),$(CLI_URETYPES_POLICY_VERSION)))
+
+$(eval $(call gb_CliUnoApi_wrap_api,cli_uretypes,udkapi))
+
+# vim: set noet sw=4 ts=4:
diff --git a/cli_ure/CustomTarget_cli_ure_assemblies.mk b/cli_ure/CustomTarget_cli_ure_assemblies.mk
new file mode 100644
index 000000000000..6773848e1e79
--- /dev/null
+++ b/cli_ure/CustomTarget_cli_ure_assemblies.mk
@@ -0,0 +1,62 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+cli_ure_source_MAKEFILE := $(lastword $(MAKEFILE_LIST))
+
+# FIXME move this to configure.in ?
+cli_ure_CCNUMVER = $(shell $(CXX) | $(gb_AWK) -v num=true -f $(SOLARENV)/bin/getcompver.awk)
+cli_ure_CCNUMVER_GOOD = $(shell expr $(cli_ure_CCNUMVER) '>=' 001399999999)
+
+include $(SRCDIR)/cli_ure/version/version.txt
+
+$(eval $(call gb_CustomTarget_CustomTarget,cli_ure/source))
+
+$(call gb_CustomTarget_get_target,cli_ure/source) : \
+ $(call gb_CustomTarget_get_workdir,cli_ure/source)/basetypes/assembly.cs \
+ $(call gb_CustomTarget_get_workdir,cli_ure/source)/native/assembly.cxx \
+ $(call gb_CustomTarget_get_workdir,cli_ure/source)/ure/assembly.cs
+
+$(call gb_CustomTarget_get_workdir,cli_ure/source)/basetypes/assembly.cs : \
+ $(SRCDIR)/cli_ure/source/basetypes/assembly.cs \
+ $(SRCDIR)/cli_ure/version/version.txt \
+ $(cli_ure_source_MAKEFILE) \
+ | $(call gb_CustomTarget_get_workdir,cli_ure/source)/basetypes/.dir
+
+$(call gb_CustomTarget_get_workdir,cli_ure/source)/native/assembly.cxx : \
+ $(SRCDIR)/cli_ure/source/native/assembly.cxx \
+ $(SRCDIR)/cli_ure/version/version.txt \
+ $(cli_ure_source_MAKEFILE) \
+ | $(call gb_CustomTarget_get_workdir,cli_ure/source)/native/.dir
+
+$(call gb_CustomTarget_get_workdir,cli_ure/source)/ure/assembly.cs : \
+ $(SRCDIR)/cli_ure/source/ure/assembly.cs \
+ $(SRCDIR)/cli_ure/version/version.txt \
+ $(cli_ure_source_MAKEFILE) \
+ | $(call gb_CustomTarget_get_workdir,cli_ure/source)/ure/.dir
+
+$(call gb_CustomTarget_get_workdir,cli_ure/source)/basetypes/assembly.cs :
+ $(GNUCOPY) $< $@.tmp && \
+ echo '[assembly:System.Reflection.AssemblyVersion( "$(CLI_BASETYPES_NEW_VERSION)" )]' >> $@.tmp && \
+ $(if $(cli_ure_CCNUMVER_GOOD),echo '[assembly:System.Reflection.AssemblyKeyFile( @"$(OUTDIR)/bin/cliuno.snk" )]' >> $@.tmp &&) \
+ mv $@.tmp $@
+
+# TODO use macros for this
+$(call gb_CustomTarget_get_workdir,cli_ure/source)/native/assembly.cxx :
+ $(GNUCOPY) $< $@.tmp && \
+ echo '[assembly:System::Reflection::AssemblyVersion( "$(CLI_CPPUHELPER_NEW_VERSION)" )];' >> $@.tmp && \
+ echo '[assembly:System::Reflection::AssemblyKeyFile( "$(OUTDIR)/bin/cliuno.snk" )];' >> $@.tmp && \
+ mv $@.tmp $@
+
+$(call gb_CustomTarget_get_workdir,cli_ure/source)/ure/assembly.cs :
+ $(GNUCOPY) $< $@.tmp && \
+ echo '[assembly:System.Reflection.AssemblyVersion( "$(CLI_URE_NEW_VERSION)" )]' >> $@.tmp && \
+ $(if $(cli_ure_CCNUMVER_GOOD),echo '[assembly:System.Reflection.AssemblyKeyFile( @"$(OUTDIR)/bin/cliuno.snk" )]' >> $@.tmp &&) \
+ mv $@.tmp $@
+
+# vim: set noet sw=4 ts=4:
diff --git a/cli_ure/Executable_climaker.mk b/cli_ure/Executable_climaker.mk
new file mode 100644
index 000000000000..9e67d66a1a26
--- /dev/null
+++ b/cli_ure/Executable_climaker.mk
@@ -0,0 +1,41 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+$(eval $(call gb_Executable_Executable,climaker))
+
+$(eval $(call gb_Executable_add_cxxflags,climaker,\
+ -AI $(gb_Helper_OUTDIRLIBDIR) \
+ -clr \
+ -LN \
+ -wd4339 \
+ -wd4715 \
+))
+
+$(eval $(call gb_Executable_use_internal_bootstrap_api,climaker,\
+ udkapi \
+))
+
+$(eval $(call gb_Executable_use_libraries,climaker,\
+ cppu \
+ cppuhelper \
+ mscoree \
+ $(if $(USE_DEBUG_RUNTIME) \
+ ,msvcmrtd \
+ ,msvcmrt \
+ ) \
+ sal \
+ $(gb_STDLIBS) \
+))
+
+$(eval $(call gb_Executable_add_exception_objects,climaker,\
+ cli_ure/source/climaker/climaker_app \
+ cli_ure/source/climaker/climaker_emit \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/cli_ure/Library_cli_cppuhelper_native.mk b/cli_ure/Library_cli_cppuhelper_native.mk
new file mode 100644
index 000000000000..3364803b2313
--- /dev/null
+++ b/cli_ure/Library_cli_cppuhelper_native.mk
@@ -0,0 +1,53 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+$(eval $(call gb_Library_Library,cli_cppuhelper_native))
+
+# When compiling for CLR, disable "warning C4339: use of undefined type detected
+# in CLR meta-data - use of this type may lead to a runtime exception":
+$(eval $(call gb_Library_add_cxxflags,cli_cppuhelper_native,\
+ -AI $(gb_Helper_OUTDIRLIBDIR) \
+ -clr:oldSyntax \
+ -wd4449 \
+))
+
+# TODO do not encode filenames here
+$(eval $(call gb_Library_add_ldflags,cli_cppuhelper_native,\
+ -delayload:cppuhelper3MSC.dll \
+ -delayload:cppu3.dll \
+ -delayload:sal3.dll \
+))
+
+$(eval $(call gb_Library_use_internal_bootstrap_api,cli_cppuhelper_native,\
+ udkapi \
+))
+
+$(eval $(call gb_Library_use_libraries,cli_cppuhelper_native,\
+ advapi32 \
+ cppu \
+ cppuhelper \
+ delayimp \
+ mscoree \
+ $(if $(USE_DEBUG_RUNTIME)\
+ ,msvcmrtd \
+ ,msvcmrt \
+ ) \
+ sal \
+))
+
+$(eval $(call gb_Library_add_exception_objects,cli_cppuhelper_native,\
+ cli_ure/source/native/native_bootstrap \
+ cli_ure/source/native/path \
+))
+
+$(eval $(call gb_Library_add_generated_exception_objects,cli_cppuhelper_native,\
+ CustomTarget/cli_ure/source/native/assembly \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/cli_ure/Library_cli_uno.mk b/cli_ure/Library_cli_uno.mk
new file mode 100644
index 000000000000..7d8fbe5d7b2d
--- /dev/null
+++ b/cli_ure/Library_cli_uno.mk
@@ -0,0 +1,36 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+$(eval $(call gb_Library_Library,cli_uno))
+
+$(eval $(call gb_Library_add_cxxflags,cli_uno,\
+ -AI $(gb_Helper_OUTDIRLIBDIR) \
+ -clr:oldSyntax \
+ -wd4339 \
+))
+
+$(eval $(call gb_Library_use_libraries,cli_uno,\
+ cppu \
+ mscoree \
+ $(if $(USE_DEBUG_RUNTIME)\
+ ,msvcmrtd \
+ ,msvcmrt \
+ ) \
+ sal \
+))
+
+$(eval $(call gb_Library_add_exception_objects,cli_uno,\
+ cli_ure/source/uno_bridge/cli_bridge \
+ cli_ure/source/uno_bridge/cli_data \
+ cli_ure/source/uno_bridge/cli_environment \
+ cli_ure/source/uno_bridge/cli_proxy \
+ cli_ure/source/uno_bridge/cli_uno \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/cli_ure/Makefile b/cli_ure/Makefile
new file mode 100644
index 000000000000..ccb1c85a04da
--- /dev/null
+++ b/cli_ure/Makefile
@@ -0,0 +1,7 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+
+module_directory:=$(dir $(realpath $(firstword $(MAKEFILE_LIST))))
+
+include $(module_directory)/../solenv/gbuild/partial_build.mk
+
+# vim: set noet sw=4 ts=4:
diff --git a/cli_ure/Module_cli_ure.mk b/cli_ure/Module_cli_ure.mk
new file mode 100644
index 000000000000..64f9bb916bd2
--- /dev/null
+++ b/cli_ure/Module_cli_ure.mk
@@ -0,0 +1,30 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+$(eval $(call gb_Module_Module,cli_ure))
+
+$(eval $(call gb_Module_add_targets,cli_ure,\
+ Package_version \
+))
+
+ifeq ($(COM),MSC)
+$(eval $(call gb_Module_add_targets,cli_ure,\
+ CliLibrary_cli_basetypes \
+ CliLibrary_cli_ure \
+ CliNativeLibrary_cli_cppuhelper \
+ CliUnoApi_cli_uretypes \
+ CustomTarget_cli_ure_assemblies \
+ Executable_climaker \
+ Library_cli_cppuhelper_native \
+ Library_cli_uno \
+ Package_config \
+))
+endif
+
+# vim: set noet sw=4 ts=4:
diff --git a/cli_ure/Package_config.mk b/cli_ure/Package_config.mk
new file mode 100644
index 000000000000..820f25e7fc75
--- /dev/null
+++ b/cli_ure/Package_config.mk
@@ -0,0 +1,17 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+$(eval $(call gb_Package_Package,cli_ure_cliuno,$(SRCDIR)/cli_ure/source))
+
+$(eval $(call gb_Package_add_files,bin,\
+ climaker/climaker.exe.config \
+ cliuno.snk \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/cli_ure/Package_version.mk b/cli_ure/Package_version.mk
new file mode 100644
index 000000000000..6ab670e188de
--- /dev/null
+++ b/cli_ure/Package_version.mk
@@ -0,0 +1,14 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+$(eval $(call gb_Package_Package,cli_ure_version,$(SRCDIR)/cli_ure/version))
+
+$(eval $(call gb_Package_add_file,cli_ure_version,bin/cliureversion.mk,version.txt))
+
+# vim: set noet sw=4 ts=4:
diff --git a/solenv/gbuild/CliUnoApi.mk b/solenv/gbuild/CliUnoApi.mk
index 6be9f992fb7c..b9ed03b25ed1 100644
--- a/solenv/gbuild/CliUnoApi.mk
+++ b/solenv/gbuild/CliUnoApi.mk
@@ -35,7 +35,7 @@ $(dir $(call gb_CliUnoApiTarget_get_target,%)).dir :
$(dir $(call gb_CliUnoApiTarget_get_target,%))%/.dir :
$(if $(wildcard $(dir $@)),,mkdir -p $(dir $@))
-$(call gb_CliUnoApiTarget_get_target,%) :
+$(call gb_CliUnoApiTarget_get_target,%) : $(gb_CliUnoApiTarget_TARGET)
$(call gb_CliUnoApiTarget__command,$@,$*,$<)
.PHONY : $(call gb_CliUnoApiTarget_get_clean_target,%)
@@ -52,7 +52,6 @@ $(call gb_CliUnoApiTarget_get_target,$(1)) : CLI_UNOAPI_DEPS :=
$(call gb_CliUnoApiTarget_get_target,$(1)) : CLI_UNOAPI_KEYFILE :=
$(call gb_CliUnoApiTarget_get_target,$(1)) : CLI_UNOAPI_VERSION :=
-$(call gb_CliUnoApiTarget_get_target,$(1)) : $(gb_CliUnoApiTarget_TARGET)
$(call gb_CliUnoApiTarget_get_target,$(1)) :| $(dir $(call gb_CliUnoApiTarget_get_target,$(1))).dir
endef