summaryrefslogtreecommitdiffstats
path: root/external/fontconfig
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 16:51:28 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 16:51:28 +0000
commit940b4d1848e8c70ab7642901a68594e8016caffc (patch)
treeeb72f344ee6c3d9b80a7ecc079ea79e9fba8676d /external/fontconfig
parentInitial commit. (diff)
downloadlibreoffice-upstream/1%7.0.4.tar.xz
libreoffice-upstream/1%7.0.4.zip
Adding upstream version 1:7.0.4.upstream/1%7.0.4upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r--external/fontconfig/ExternalProject_fontconfig.mk36
-rw-r--r--external/fontconfig/Makefile7
-rw-r--r--external/fontconfig/Module_fontconfig.mk17
-rw-r--r--external/fontconfig/README6
-rw-r--r--external/fontconfig/UnpackedTarball_fontconfig.mk18
-rw-r--r--external/fontconfig/fontconfig-2.12.1.patch.1135
6 files changed, 219 insertions, 0 deletions
diff --git a/external/fontconfig/ExternalProject_fontconfig.mk b/external/fontconfig/ExternalProject_fontconfig.mk
new file mode 100644
index 000000000..b82c76573
--- /dev/null
+++ b/external/fontconfig/ExternalProject_fontconfig.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_ExternalProject_ExternalProject,fontconfig))
+
+$(eval $(call gb_ExternalProject_use_externals,fontconfig,\
+ expat \
+ freetype \
+))
+
+$(eval $(call gb_ExternalProject_register_targets,fontconfig,\
+ build \
+))
+
+$(call gb_ExternalProject_get_state_target,fontconfig,build) :
+ $(call gb_Trace_StartRange,fontconfig,EXTERNAL)
+ $(call gb_ExternalProject_run,build,\
+ CFLAGS="$(if $(debug),-g) $(gb_VISIBILITY_FLAGS)" $(if $(filter ANDROID,$(OS)),LIBS="-lm") \
+ ./configure \
+ --disable-shared \
+ --disable-silent-rules \
+ $(if $(filter ANDROID,$(OS)),--with-arch=arm) \
+ --with-expat-includes=$(call gb_UnpackedTarball_get_dir,expat)/lib \
+ --with-expat-lib=$(gb_StaticLibrary_WORKDIR) \
+ --build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM) \
+ && $(MAKE) -C src \
+ )
+ $(call gb_Trace_EndRange,fontconfig,EXTERNAL)
+
+# vim: set noet sw=4 ts=4:
diff --git a/external/fontconfig/Makefile b/external/fontconfig/Makefile
new file mode 100644
index 000000000..e4968cf85
--- /dev/null
+++ b/external/fontconfig/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/fontconfig/Module_fontconfig.mk b/external/fontconfig/Module_fontconfig.mk
new file mode 100644
index 000000000..e755f8610
--- /dev/null
+++ b/external/fontconfig/Module_fontconfig.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,fontconfig))
+
+$(eval $(call gb_Module_add_targets,fontconfig,\
+ ExternalProject_fontconfig \
+ UnpackedTarball_fontconfig \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/external/fontconfig/README b/external/fontconfig/README
new file mode 100644
index 000000000..220ee6078
--- /dev/null
+++ b/external/fontconfig/README
@@ -0,0 +1,6 @@
+This "bundled" fontconfig is built only in an Android build
+
+Fontconfig is a font configuration and customization library. It is designed to locate fonts
+within the system and select them according to requirements specified by applications.
+
+From [ http://packages.debian.org/squeeze/fontconfig ] \ No newline at end of file
diff --git a/external/fontconfig/UnpackedTarball_fontconfig.mk b/external/fontconfig/UnpackedTarball_fontconfig.mk
new file mode 100644
index 000000000..6026a817c
--- /dev/null
+++ b/external/fontconfig/UnpackedTarball_fontconfig.mk
@@ -0,0 +1,18 @@
+# -*- 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,fontconfig))
+
+$(eval $(call gb_UnpackedTarball_set_tarball,fontconfig,$(FONTCONFIG_TARBALL),,fontconfig))
+
+$(eval $(call gb_UnpackedTarball_add_patches,fontconfig,\
+ external/fontconfig/fontconfig-2.12.1.patch.1 \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/external/fontconfig/fontconfig-2.12.1.patch.1 b/external/fontconfig/fontconfig-2.12.1.patch.1
new file mode 100644
index 000000000..f348d2aa8
--- /dev/null
+++ b/external/fontconfig/fontconfig-2.12.1.patch.1
@@ -0,0 +1,135 @@
+diff -up fontconfig/configure.dt fontconfig/configure
+--- fontconfig/configure.dt 2017-02-01 22:07:29.671668568 +0100
++++ fontconfig/configure 2017-02-01 22:09:53.335215490 +0100
+@@ -10469,7 +10469,7 @@ _LT_EOF
+ case $host_cpu in
+ powerpc)
+ # see comment about AmigaOS4 .so support
+- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
++ archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $lib'
+ archive_expsym_cmds=''
+ ;;
+ m68k)
+@@ -10485,7 +10485,7 @@ _LT_EOF
+ allow_undefined_flag=unsupported
+ # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
+ # support --undefined. This deserves some investigation. FIXME
+- archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
++ archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags -o $lib'
+ else
+ ld_shlibs=no
+ fi
+@@ -10519,7 +10519,7 @@ _LT_EOF
+ ;;
+
+ haiku*)
+- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
++ archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $lib'
+ link_all_deplibs=yes
+ ;;
+
+@@ -10614,13 +10614,13 @@ _LT_EOF
+ *Sun\ F*) # Sun Fortran 8.3
+ tmp_sharedflag='-G' ;;
+ esac
+- archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
++ archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags -o $lib'
+
+ if test yes = "$supports_anon_versioning"; then
+ archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
+ cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
+ echo "local: *; };" >> $output_objdir/$libname.ver~
+- $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
++ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
+ fi
+
+ case $cc_basename in
+@@ -10650,8 +10650,8 @@ _LT_EOF
+ archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
+ wlarc=
+ else
+- archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
+- archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
++ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags -o $lib'
++ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-retain-symbols-file $wl$export_symbols -o $lib'
+ fi
+ ;;
+
+@@ -10669,8 +10669,8 @@ _LT_EOF
+
+ _LT_EOF
+ elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
+- archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
+- archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
++ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags -o $lib'
++ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-retain-symbols-file $wl$export_symbols -o $lib'
+ else
+ ld_shlibs=no
+ fi
+@@ -10698,8 +10698,8 @@ _LT_EOF
+ # requires that you compile everything twice, which is a pain.
+ if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
+ hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
+- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
+- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
++ archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $lib'
++ archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-retain-symbols-file $wl$export_symbols -o $lib'
+ else
+ ld_shlibs=no
+ fi
+@@ -10716,8 +10716,8 @@ _LT_EOF
+
+ *)
+ if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
+- archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
+- archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
++ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags -o $lib'
++ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-retain-symbols-file $wl$export_symbols -o $lib'
+ else
+ ld_shlibs=no
+ fi
+@@ -11016,7 +11016,7 @@ fi
+ case $host_cpu in
+ powerpc)
+ # see comment about AmigaOS4 .so support
+- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
++ archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $lib'
+ archive_expsym_cmds=''
+ ;;
+ m68k)
+@@ -11285,7 +11285,7 @@ fi
+
+ irix5* | irix6* | nonstopux*)
+ if test yes = "$GCC"; then
+- archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
++ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
+ # Try to use the -exported_symbol ld option, if it does not
+ # work, assume that -exports_file does not work either and
+ # implicitly export all symbols.
+@@ -11313,7 +11313,7 @@ fi
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
+ $as_echo "$lt_cv_irix_exported_symbol" >&6; }
+ if test yes = "$lt_cv_irix_exported_symbol"; then
+- archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib'
++ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib'
+ fi
+ else
+ archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
+@@ -11408,7 +11408,7 @@ $as_echo "$lt_cv_irix_exported_symbol" >
+ osf3*)
+ if test yes = "$GCC"; then
+ allow_undefined_flag=' $wl-expect_unresolved $wl\*'
+- archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
++ archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
+ else
+ allow_undefined_flag=' -expect_unresolved \*'
+ archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
+@@ -11421,7 +11421,7 @@ $as_echo "$lt_cv_irix_exported_symbol" >
+ osf4* | osf5*) # as osf3* with the addition of -msym flag
+ if test yes = "$GCC"; then
+ allow_undefined_flag=' $wl-expect_unresolved $wl\*'
+- archive_cmds='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
++ archive_cmds='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
+ hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
+ else
+ allow_undefined_flag=' -expect_unresolved \*'