summaryrefslogtreecommitdiffstats
path: root/external/libfreehand
diff options
context:
space:
mode:
Diffstat (limited to 'external/libfreehand')
-rw-r--r--external/libfreehand/ExternalProject_libfreehand.mk49
-rw-r--r--external/libfreehand/Makefile7
-rw-r--r--external/libfreehand/Module_libfreehand.mk17
-rw-r--r--external/libfreehand/README3
-rw-r--r--external/libfreehand/UnpackedTarball_libfreehand.mk24
-rw-r--r--external/libfreehand/icu-65-api-macros-with-semicolon.patch.112
6 files changed, 112 insertions, 0 deletions
diff --git a/external/libfreehand/ExternalProject_libfreehand.mk b/external/libfreehand/ExternalProject_libfreehand.mk
new file mode 100644
index 000000000..554017caf
--- /dev/null
+++ b/external/libfreehand/ExternalProject_libfreehand.mk
@@ -0,0 +1,49 @@
+# -*- 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 \
+ icu \
+ lcms2 \
+ revenge \
+ zlib \
+))
+
+$(call gb_ExternalProject_get_state_target,libfreehand,build) :
+ $(call gb_Trace_StartRange,libfreehand,EXTERNAL)
+ $(call gb_ExternalProject_run,build,\
+ export PKG_CONFIG="" \
+ && MAKE=$(MAKE) $(gb_RUN_CONFIGURE) ./configure \
+ --with-pic \
+ --enable-static \
+ --disable-shared \
+ --without-docs \
+ --disable-tests \
+ --disable-tools \
+ --disable-debug \
+ --disable-werror \
+ --disable-weffc \
+ $(if $(verbose),--disable-silent-rules,--enable-silent-rules) \
+ CXXFLAGS="$(gb_CXXFLAGS) $(call gb_ExternalProject_get_build_flags,libfreehand)" \
+ CPPFLAGS="$(CPPFLAGS) $(BOOST_CPPFLAGS)" \
+ LDFLAGS="$(call gb_ExternalProject_get_link_flags,libfreehand)" \
+ $(gb_CONFIGURE_PLATFORMS) \
+ && $(MAKE) \
+ )
+ $(call gb_Trace_EndRange,libfreehand,EXTERNAL)
+
+# vim: set noet sw=4 ts=4:
diff --git a/external/libfreehand/Makefile b/external/libfreehand/Makefile
new file mode 100644
index 000000000..e4968cf85
--- /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 000000000..b00efd16e
--- /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 000000000..7403eb1a0
--- /dev/null
+++ b/external/libfreehand/README
@@ -0,0 +1,3 @@
+Library for import of FreeHand drawings.
+
+[https://wiki.documentfoundation.org/DLP/Libraries/libfreehand]
diff --git a/external/libfreehand/UnpackedTarball_libfreehand.mk b/external/libfreehand/UnpackedTarball_libfreehand.mk
new file mode 100644
index 000000000..641b470e3
--- /dev/null
+++ b/external/libfreehand/UnpackedTarball_libfreehand.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,libfreehand))
+
+$(eval $(call gb_UnpackedTarball_set_tarball,libfreehand,$(FREEHAND_TARBALL)))
+
+$(eval $(call gb_UnpackedTarball_update_autoconf_configs,libfreehand))
+
+$(eval $(call gb_UnpackedTarball_set_patchlevel,libfreehand,0))
+
+# icu-65-api-macros-with-semicolon.patch.1
+# See http://site.icu-project.org/download/65 Migration Issues
+$(eval $(call gb_UnpackedTarball_add_patches,libfreehand,\
+ external/libfreehand/icu-65-api-macros-with-semicolon.patch.1 \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/external/libfreehand/icu-65-api-macros-with-semicolon.patch.1 b/external/libfreehand/icu-65-api-macros-with-semicolon.patch.1
new file mode 100644
index 000000000..20b0af801
--- /dev/null
+++ b/external/libfreehand/icu-65-api-macros-with-semicolon.patch.1
@@ -0,0 +1,12 @@
+diff -ur libfreehand.org/src/lib/libfreehand_utils.cpp libfreehand/src/lib/libfreehand_utils.cpp
+--- libfreehand.org/src/lib/libfreehand_utils.cpp 2017-09-16 12:28:50.000000000 +0200
++++ libfreehand/src/lib/libfreehand_utils.cpp 2019-10-28 23:02:38.581354923 +0100
+@@ -162,7 +162,7 @@
+ while (j < length)
+ {
+ UChar32 c;
+- U16_NEXT(s, j, length, c)
++ U16_NEXT(s, j, length, c);
+ unsigned char outbuf[U8_MAX_LENGTH+1];
+ int i = 0;
+ U8_APPEND_UNSAFE(&outbuf[0], i, c);