[Libreoffice-commits] core.git: config_host.mk.in configure.ac download.lst external/libfreehand external/Module_external.mk Makefile.fetch RepositoryExternal.mk

Fridrich Å trba fridrich.strba at bluewin.ch
Thu Oct 31 13:51:09 CET 2013


 Makefile.fetch                                      |    1 
 RepositoryExternal.mk                               |   35 +++++++++++++++
 config_host.mk.in                                   |    3 +
 configure.ac                                        |    5 ++
 download.lst                                        |    2 
 external/Module_external.mk                         |    1 
 external/libfreehand/ExternalProject_libfreehand.mk |   44 ++++++++++++++++++++
 external/libfreehand/Makefile                       |    7 +++
 external/libfreehand/Module_libfreehand.mk          |   17 +++++++
 external/libfreehand/README                         |    1 
 external/libfreehand/UnpackedTarball_libfreehand.mk |   14 ++++++
 11 files changed, 130 insertions(+)

New commits:
commit 67153d76844fe8d8f3aba17f019443c96fbdd829
Author: Fridrich Å trba <fridrich.strba at bluewin.ch>
Date:   Thu Oct 31 12:42:50 2013 +0100

    bundle libfreehand
    
    Change-Id: I12de5e96754a8dba94dfdef3deb2aac18af28f22
    Reviewed-on: https://gerrit.libreoffice.org/6510
    Reviewed-by: Fridrich Strba <fridrich at documentfoundation.org>
    Tested-by: Fridrich Strba <fridrich at documentfoundation.org>

diff --git a/Makefile.fetch b/Makefile.fetch
index be6c2e9..81acd0f 100644
--- a/Makefile.fetch
+++ b/Makefile.fetch
@@ -76,6 +76,7 @@ $(WORKDIR)/download: $(BUILDDIR)/config_host.mk $(SRCDIR)/download.lst $(SRCDIR)
 	$(foreach item, \
 		$(call fetch_Optional,LIBATOMIC_OPS,LIBATOMIC_OPS_TARBALL) \
 		$(call fetch_Optional,CDR,CDR_TARBALL) \
+		$(call fetch_Optional,FREEHAND,FREEHAND_TARBALL) \
 		$(call fetch_Optional,ETONYEK,ETONYEK_TARBALL) \
 		$(call fetch_Optional,FIREBIRD,FIREBIRD_TARBALL) \
 		$(call fetch_Optional,HARFBUZZ,HARFBUZZ_TARBALL) \
diff --git a/RepositoryExternal.mk b/RepositoryExternal.mk
index f0138aa..d1b0b08 100644
--- a/RepositoryExternal.mk
+++ b/RepositoryExternal.mk
@@ -1466,6 +1466,41 @@ endef
 endif # SYSTEM_ETONYEK
 
 
+ifeq ($(SYSTEM_FREEHAND),YES)
+
+define gb_LinkTarget__use_freehand
+$(call gb_LinkTarget_set_include,$(1),\
+	$$(INCLUDE) \
+    $(FREEHAND_CFLAGS) \
+)
+$(call gb_LinkTarget_add_libs,$(1),$(FREEHAND_LIBS))
+
+endef
+
+gb_ExternalProject__use_freehand :=
+
+else # !SYSTEM_FREEHAND
+
+define gb_LinkTarget__use_freehand
+$(call gb_LinkTarget_set_include,$(1),\
+	$(FREEHAND_CFLAGS) \
+	$$(INCLUDE) \
+)
+$(call gb_LinkTarget_add_libs,$(1),\
+	$(call gb_UnpackedTarball_get_dir,libfreehand)/src/lib/.libs/libfreehand-0.0$(gb_StaticLibrary_PLAINEXT) \
+)
+$(call gb_LinkTarget_use_external_project,$(1),libfreehand)
+
+endef
+
+define gb_ExternalProject__use_freehand
+$(call gb_ExternalProject_use_external_project,$(1),libfreehand)
+
+endef
+
+endif # SYSTEM_FREEHAND
+
+
 ifeq ($(SYSTEM_ODFGEN),YES)
 
 define gb_LinkTarget__use_odfgen
diff --git a/config_host.mk.in b/config_host.mk.in
index 1c88ba1..7c59af6 100644
--- a/config_host.mk.in
+++ b/config_host.mk.in
@@ -179,6 +179,8 @@ export FLEX=@FLEX@
 export FLUTE_JAR=@FLUTE_JAR@
 export FONTCONFIG_CFLAGS=$(gb_SPACE)@FONTCONFIG_CFLAGS@
 export FONTCONFIG_LIBS=$(gb_SPACE)@FONTCONFIG_LIBS@
+export FREEHAND_CFLAGS=$(gb_SPACE)@FREEHAND_CFLAGS@
+export FREEHAND_LIBS=$(gb_SPACE)@FREEHAND_LIBS@
 export FREETYPE_CFLAGS=$(gb_SPACE)@FREETYPE_CFLAGS@
 export FREETYPE_LIBS=$(gb_SPACE)@FREETYPE_LIBS@
 export GCC_VERSION=@GCC_VERSION@
@@ -514,6 +516,7 @@ export SYSTEM_LCMS2=@SYSTEM_LCMS2@
 export SYSTEM_CDR=@SYSTEM_CDR@
 export SYSTEM_CMIS=@SYSTEM_CMIS@
 export SYSTEM_ETONYEK=@SYSTEM_ETONYEK@
+export SYSTEM_FREEHAND=@SYSTEM_FREEHAND@
 export SYSTEM_LIBATOMIC_OPS=@SYSTEM_LIBATOMIC_OPS@
 export SYSTEM_LIBEXTTEXTCAT=@SYSTEM_LIBEXTTEXTCAT@
 export SYSTEM_LIBEXTTEXTCAT_DATA=@SYSTEM_LIBEXTTEXTCAT_DATA@
diff --git a/configure.ac b/configure.ac
index 10a9055..11baeae 100644
--- a/configure.ac
+++ b/configure.ac
@@ -7721,6 +7721,11 @@ dnl ===================================================================
 libo_CHECK_SYSTEM_MODULE([libetonyek],[ETONYEK],[libetonyek-0.0],["-I${WORKDIR}/UnpackedTarball/libetonyek/inc"],["-L${WORKDIR}/UnpackedTarball/libetonyek/src/lib/.libs -letonyek-0.0"])
 
 dnl ===================================================================
+dnl Check for system libfreehand
+dnl ===================================================================
+libo_CHECK_SYSTEM_MODULE([libfreehand],[FREEHAND],[libfreehand-0.0],["-I${WORKDIR}/UnpackedTarball/libfreehand/inc"],["-L${WORKDIR}/UnpackedTarball/libfreehand/src/lib/.libs -lfreehand-0.0"])
+
+dnl ===================================================================
 dnl Check for system libodfgen
 dnl ===================================================================
 libo_CHECK_SYSTEM_MODULE([libodfgen],[ODFGEN],[libodfgen-0.0])
diff --git a/download.lst b/download.lst
index e8cbc2a..ca0c9d0 100644
--- a/download.lst
+++ b/download.lst
@@ -2,6 +2,8 @@ CDR_MD5SUM := d88f9b94df880d2c05be943b000ca112
 export CDR_TARBALL := libcdr-0.0.14.tar.bz2
 ETONYEK_MD5SUM := f1753366de8bd37c6fb033a7771fa616
 export ETONYEK_TARBALL := libetonyek-0.0.0.tar.bz2
+FREEHAND_MD5SUM := 496dd00028afcc19f896b01394769043
+export FREEHAND_TARBALL := libfreehand-0.0.0.tar.bz2
 MSPUB_MD5SUM := 1120705cd0f0d9bd5506360bf57b6c2e
 export MSPUB_TARBALL := libmspub-0.0.6.tar.bz2
 MWAW_MD5SUM := 828dd03510791fbe037081a2b4a1a8ff
diff --git a/external/Module_external.mk b/external/Module_external.mk
index 09246fe..02c4f75 100644
--- a/external/Module_external.mk
+++ b/external/Module_external.mk
@@ -34,6 +34,7 @@ $(eval $(call gb_Module_add_moduledirs,external,\
 	$(call gb_Helper_optional,EXPAT,expat) \
 	$(call gb_Helper_optional,FIREBIRD,firebird) \
 	$(call gb_Helper_optional,FONTCONFIG,fontconfig) \
+	$(call gb_Helper_optional,FREEHAND,libfreehand) \
 	$(call gb_Helper_optional,FREETYPE,freetype) \
 	$(call gb_Helper_optional,GRAPHITE,graphite) \
 	$(call gb_Helper_optional,HARFBUZZ,harfbuzz) \
diff --git a/external/libfreehand/ExternalProject_libfreehand.mk b/external/libfreehand/ExternalProject_libfreehand.mk
new file mode 100644
index 0000000..24bda09
--- /dev/null
+++ b/external/libfreehand/ExternalProject_libfreehand.mk
@@ -0,0 +1,44 @@
+# -*- 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,libfreehand))
+
+$(eval $(call gb_ExternalProject_use_autoconf,libfreehand,build))
+
+$(eval $(call gb_ExternalProject_register_targets,libfreehand,\
+	build \
+))
+
+$(eval $(call gb_ExternalProject_use_externals,libfreehand,\
+	boost_headers \
+	libxml2 \
+	wpd \
+	zlib \
+))
+
+$(call gb_ExternalProject_get_state_target,libfreehand,build) :
+	$(call gb_ExternalProject_run,build,\
+		export PKG_CONFIG="" \
+		&& ./configure \
+			--with-pic \
+			--enable-static \
+			--disable-shared \
+			--without-docs \
+			--disable-debug \
+			--disable-werror \
+			--disable-weffc \
+			--without-tools \
+			BOOST_CFLAGS="$(if $(filter NO,$(SYSTEM_BOOST)),-I$(call gb_UnpackedTarball_get_dir,boost),$(BOOST_CPPFLAGS))" \
+			XML_CFLAGS="$(if $(filter NO,$(SYSTEM_LIBXML)),-I$(call gb_UnpackedTarball_get_dir,xml2)/include,$(LIBXML_CFLAGS))" \
+			XML_LIBS="$(LIBXML_LIBS)" \
+			$(if $(filter YES,$(CROSS_COMPILING)),--build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM)) \
+		&& $(MAKE) $(if $(VERBOSE)$(verbose),V=1) \
+	)
+
+# vim: set noet sw=4 ts=4:
diff --git a/external/libfreehand/Makefile b/external/libfreehand/Makefile
new file mode 100644
index 0000000..e4968cf
--- /dev/null
+++ b/external/libfreehand/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/libfreehand/Module_libfreehand.mk b/external/libfreehand/Module_libfreehand.mk
new file mode 100644
index 0000000..b00efd1
--- /dev/null
+++ b/external/libfreehand/Module_libfreehand.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,libfreehand))
+
+$(eval $(call gb_Module_add_targets,libfreehand,\
+	ExternalProject_libfreehand \
+	UnpackedTarball_libfreehand \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/external/libfreehand/README b/external/libfreehand/README
new file mode 100644
index 0000000..dafad78
--- /dev/null
+++ b/external/libfreehand/README
@@ -0,0 +1 @@
+Library for import of FreeHand drawings.
diff --git a/external/libfreehand/UnpackedTarball_libfreehand.mk b/external/libfreehand/UnpackedTarball_libfreehand.mk
new file mode 100644
index 0000000..a6cf1c7
--- /dev/null
+++ b/external/libfreehand/UnpackedTarball_libfreehand.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_UnpackedTarball_UnpackedTarball,libfreehand))
+
+$(eval $(call gb_UnpackedTarball_set_tarball,libfreehand,$(FREEHAND_TARBALL)))
+
+# vim: set noet sw=4 ts=4:


More information about the Libreoffice-commits mailing list