diff options
author | Aleksas Pantechovskis <alex.pantec@gmail.com> | 2016-06-22 19:02:29 +0300 |
---|---|---|
committer | David Tardon <dtardon@redhat.com> | 2016-06-23 15:39:52 +0000 |
commit | aaed6fe55a67ee3e92bedf9eed2e2f7c044be19d (patch) | |
tree | bf0161906efd08c45fb85c09a48514c807036e6e /external | |
parent | 878a860dff10bd91491d6c9f2f4e2308bfe4f0b2 (diff) |
integrate libzmf
Change-Id: I0c7ea5b56ea4ed4839ff38798c0b915aaca81774
Reviewed-on: https://gerrit.libreoffice.org/26574
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: David Tardon <dtardon@redhat.com>
Diffstat (limited to 'external')
-rw-r--r-- | external/Module_external.mk | 1 | ||||
-rw-r--r-- | external/libzmf/ExternalProject_libzmf.mk | 43 | ||||
-rw-r--r-- | external/libzmf/Makefile | 7 | ||||
-rw-r--r-- | external/libzmf/Module_libzmf.mk | 17 | ||||
-rw-r--r-- | external/libzmf/README | 6 | ||||
-rw-r--r-- | external/libzmf/UnpackedTarball_libzmf.mk | 24 | ||||
-rw-r--r-- | external/libzmf/ubsan-visibility.patch | 11 |
7 files changed, 109 insertions, 0 deletions
diff --git a/external/Module_external.mk b/external/Module_external.mk index 44280e3250ea..9c014a7e2092 100644 --- a/external/Module_external.mk +++ b/external/Module_external.mk @@ -86,6 +86,7 @@ $(eval $(call gb_Module_add_moduledirs,external,\ $(call gb_Helper_optional,ORCUS,liborcus) \ $(call gb_Helper_optional,OWNCLOUD_ANDROID_LIB,owncloud-android-lib) \ $(call gb_Helper_optional,PAGEMAKER,libpagemaker) \ + $(call gb_Helper_optional,ZMF,libzmf) \ $(call gb_Helper_optional,POPPLER,poppler) \ $(call gb_Helper_optional,POSTGRESQL,postgresql) \ $(call gb_Helper_optional,PYTHON,$(if $(filter $(PYTHON_VERSION_MINOR),3),python33,python3)) \ diff --git a/external/libzmf/ExternalProject_libzmf.mk b/external/libzmf/ExternalProject_libzmf.mk new file mode 100644 index 000000000000..713d55d7e4ec --- /dev/null +++ b/external/libzmf/ExternalProject_libzmf.mk @@ -0,0 +1,43 @@ +# -*- 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_ExternalProject_ExternalProject,libzmf)) + +$(eval $(call gb_ExternalProject_use_autoconf,libzmf,build)) + +$(eval $(call gb_ExternalProject_register_targets,libzmf,\ + build \ +)) + +$(eval $(call gb_ExternalProject_use_externals,libzmf,\ + boost_headers \ + revenge \ +)) + +$(call gb_ExternalProject_get_state_target,libzmf,build) : + $(call gb_ExternalProject_run,build,\ + export PKG_CONFIG="" \ + && MAKE=$(MAKE) ./configure \ + --with-pic \ + --enable-static \ + --disable-shared \ + --without-docs \ + --disable-tools \ + --disable-debug \ + --disable-werror \ + --disable-weffc \ + $(if $(verbose),--disable-silent-rules,--enable-silent-rules) \ + CXXFLAGS="$(CXXFLAGS) $(CXXFLAGS_CXX11) $(if $(SYSTEM_BOOST),$(BOOST_CPPFLAGS),-I$(call gb_UnpackedTarball_get_dir,boost))" \ + REVENGE_GENERATORS_CFLAGS=' ' REVENGE_GENERATORS_LIBS=' ' REVENGE_STREAM_CFLAGS=' ' REVENGE_STREAM_LIBS=' ' \ + ax_cv_cxx_compile_cxx11=yes \ + $(if $(CROSS_COMPILING),--build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM)) \ + && $(MAKE) -C src/lib \ + ) + +# vim: set noet sw=4 ts=4: diff --git a/external/libzmf/Makefile b/external/libzmf/Makefile new file mode 100644 index 000000000000..e4968cf85fb6 --- /dev/null +++ b/external/libzmf/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/external/libzmf/Module_libzmf.mk b/external/libzmf/Module_libzmf.mk new file mode 100644 index 000000000000..c024e697cc98 --- /dev/null +++ b/external/libzmf/Module_libzmf.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_Module_Module,libzmf)) + +$(eval $(call gb_Module_add_targets,libzmf,\ + ExternalProject_libzmf \ + UnpackedTarball_libzmf \ +)) + +# vim: set noet sw=4 ts=4: diff --git a/external/libzmf/README b/external/libzmf/README new file mode 100644 index 000000000000..26e05fc5f763 --- /dev/null +++ b/external/libzmf/README @@ -0,0 +1,6 @@ +libzmf is a library and a set of tools for reading and converting +Zoner Draw and Zebra file formats. + +libzmf requires boost and librevenge to build. + +The library is available under MPL 2.0+ license. diff --git a/external/libzmf/UnpackedTarball_libzmf.mk b/external/libzmf/UnpackedTarball_libzmf.mk new file mode 100644 index 000000000000..324638479ebb --- /dev/null +++ b/external/libzmf/UnpackedTarball_libzmf.mk @@ -0,0 +1,24 @@ +# -*- 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_UnpackedTarball_UnpackedTarball,libzmf)) + +$(eval $(call gb_UnpackedTarball_set_tarball,libzmf,$(ZMF_TARBALL))) + +$(eval $(call gb_UnpackedTarball_set_patchlevel,libzmf,0)) + +ifeq ($(COM_IS_CLANG),TRUE) +ifneq ($(filter -fsanitize=%,$(CC)),) +$(eval $(call gb_UnpackedTarball_add_patches,libzmf, \ + external/libzmf/ubsan-visibility.patch \ +)) +endif +endif + +# vim: set noet sw=4 ts=4: diff --git a/external/libzmf/ubsan-visibility.patch b/external/libzmf/ubsan-visibility.patch new file mode 100644 index 000000000000..90ead2b844b2 --- /dev/null +++ b/external/libzmf/ubsan-visibility.patch @@ -0,0 +1,11 @@ +--- configure ++++ configure +@@ -16787,7 +16787,7 @@ + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -fvisibility=hidden compiler flag" >&5 + $as_echo_n "checking for -fvisibility=hidden compiler flag... " >&6; } + saved_CXXFLAGS="$CXXFLAGS" +- CXXFLAGS="$CXXFLAGS -fvisibility=hidden" ++ CXXFLAGS="$CXXFLAGS -fvisibility-ms-compat" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ + |