summaryrefslogtreecommitdiff
path: root/Build/source/libs/cairo
diff options
context:
space:
mode:
authorPeter Breitenlohner <peb@mppmu.mpg.de>2014-12-02 10:45:27 +0000
committerPeter Breitenlohner <peb@mppmu.mpg.de>2014-12-02 10:45:27 +0000
commit4745714e751cdaaaf25911db917ea20b34c072ef (patch)
tree1fe5502dd58d02a46c0c0cd4c2e9e1da1f33d722 /Build/source/libs/cairo
parentf42be3ee30adf8ed99f663941e792fc765757571 (diff)
libs/cairo: Hide symbols (for Luigi)
git-svn-id: svn://tug.org/texlive/trunk@35717 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/libs/cairo')
-rw-r--r--Build/source/libs/cairo/ChangeLog5
-rw-r--r--Build/source/libs/cairo/Makefile.am2
-rw-r--r--Build/source/libs/cairo/Makefile.in4
-rw-r--r--Build/source/libs/cairo/aclocal.m41
-rw-r--r--Build/source/libs/cairo/cairo/Makefile.in2
-rwxr-xr-xBuild/source/libs/cairo/configure51
-rw-r--r--Build/source/libs/cairo/configure.ac4
7 files changed, 66 insertions, 3 deletions
diff --git a/Build/source/libs/cairo/ChangeLog b/Build/source/libs/cairo/ChangeLog
index e3152846b47..1fa7b8e2bde 100644
--- a/Build/source/libs/cairo/ChangeLog
+++ b/Build/source/libs/cairo/ChangeLog
@@ -1,3 +1,8 @@
+2014-12-02 Peter Breitenlohner <peb@mppmu.mpg.de>
+
+ * configure.ac: Added KPSE_COMPILER_VISIBILITY.
+ * Makefile.am [AM_CFLAGS]: Added $(VISIBILITY_CFLAGS).
+
2014-10-15 Peter Breitenlohner <peb@mppmu.mpg.de>
Import cairo-1.14.0.
diff --git a/Build/source/libs/cairo/Makefile.am b/Build/source/libs/cairo/Makefile.am
index 148d5365c99..650f31dafcf 100644
--- a/Build/source/libs/cairo/Makefile.am
+++ b/Build/source/libs/cairo/Makefile.am
@@ -24,7 +24,7 @@ dist-hook:
SUBDIRS = . cairo
AM_CPPFLAGS = -I$(top_srcdir)/$(CAIRO_SRC) $(PIXMAN_INCLUDES) -DCAIRO_NO_MUTEX
-AM_CFLAGS = $(CAIRO_ATTRIBUTE_FLAG)
+AM_CFLAGS = $(CAIRO_ATTRIBUTE_FLAG) $(VISIBILITY_CFLAGS)
noinst_LIBRARIES = libcairo.a
diff --git a/Build/source/libs/cairo/Makefile.in b/Build/source/libs/cairo/Makefile.in
index be9496be886..70effb4cfb5 100644
--- a/Build/source/libs/cairo/Makefile.in
+++ b/Build/source/libs/cairo/Makefile.in
@@ -158,6 +158,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/cairo-bigendian.m4 \
$(top_srcdir)/m4/cairo-features.m4 $(top_srcdir)/m4/float.m4 \
$(top_srcdir)/../../m4/kpse-common.m4 \
$(top_srcdir)/../../m4/kpse-pixman-flags.m4 \
+ $(top_srcdir)/../../m4/kpse-visibility.m4 \
$(top_srcdir)/../../m4/kpse-warnings.m4 \
$(top_srcdir)/version.ac $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
@@ -850,6 +851,7 @@ SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
STRIP = @STRIP@
VERSION = @VERSION@
+VISIBILITY_CFLAGS = @VISIBILITY_CFLAGS@
WARNING_CFLAGS = @WARNING_CFLAGS@
abs_builddir = @abs_builddir@
abs_srcdir = @abs_srcdir@
@@ -905,7 +907,7 @@ EXTRA_DIST = $(CAIRO_TREE) $(CAIRO_TREE)-PATCHES
CAIRO_SRC = $(CAIRO_TREE)/src
SUBDIRS = . cairo
AM_CPPFLAGS = -I$(top_srcdir)/$(CAIRO_SRC) $(PIXMAN_INCLUDES) -DCAIRO_NO_MUTEX
-AM_CFLAGS = $(CAIRO_ATTRIBUTE_FLAG)
+AM_CFLAGS = $(CAIRO_ATTRIBUTE_FLAG) $(VISIBILITY_CFLAGS)
noinst_LIBRARIES = libcairo.a
libcairo_a_SOURCES = @CAIRO_TREE@/src/cairo-analysis-surface.c \
@CAIRO_TREE@/src/cairo-arc.c @CAIRO_TREE@/src/cairo-array.c \
diff --git a/Build/source/libs/cairo/aclocal.m4 b/Build/source/libs/cairo/aclocal.m4
index 4ef8628bf14..e125205b232 100644
--- a/Build/source/libs/cairo/aclocal.m4
+++ b/Build/source/libs/cairo/aclocal.m4
@@ -1188,4 +1188,5 @@ m4_include([m4/cairo-features.m4])
m4_include([m4/float.m4])
m4_include([../../m4/kpse-common.m4])
m4_include([../../m4/kpse-pixman-flags.m4])
+m4_include([../../m4/kpse-visibility.m4])
m4_include([../../m4/kpse-warnings.m4])
diff --git a/Build/source/libs/cairo/cairo/Makefile.in b/Build/source/libs/cairo/cairo/Makefile.in
index a77fd8e87ce..61371cf9255 100644
--- a/Build/source/libs/cairo/cairo/Makefile.in
+++ b/Build/source/libs/cairo/cairo/Makefile.in
@@ -93,6 +93,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/cairo-bigendian.m4 \
$(top_srcdir)/m4/cairo-features.m4 $(top_srcdir)/m4/float.m4 \
$(top_srcdir)/../../m4/kpse-common.m4 \
$(top_srcdir)/../../m4/kpse-pixman-flags.m4 \
+ $(top_srcdir)/../../m4/kpse-visibility.m4 \
$(top_srcdir)/../../m4/kpse-warnings.m4 \
$(top_srcdir)/version.ac $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
@@ -177,6 +178,7 @@ SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
STRIP = @STRIP@
VERSION = @VERSION@
+VISIBILITY_CFLAGS = @VISIBILITY_CFLAGS@
WARNING_CFLAGS = @WARNING_CFLAGS@
abs_builddir = @abs_builddir@
abs_srcdir = @abs_srcdir@
diff --git a/Build/source/libs/cairo/configure b/Build/source/libs/cairo/configure
index c7c69947a0a..fce04bd9916 100755
--- a/Build/source/libs/cairo/configure
+++ b/Build/source/libs/cairo/configure
@@ -699,6 +699,7 @@ CAIRO_HAS_FC_FONT_TRUE
build_FALSE
build_TRUE
CAIRO_ATTRIBUTE_FLAG
+VISIBILITY_CFLAGS
LN_S
RANLIB
WARNING_CFLAGS
@@ -5709,6 +5710,56 @@ esac
esac
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking CFLAGS for C to hide external symbols" >&5
+$as_echo_n "checking CFLAGS for C to hide external symbols... " >&6; }
+if ${kpse_cv_visibility_cflags+:} false; then :
+ $as_echo_n "(cached) " >&6
+else
+ ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
+kpse_cv_visibility_cflags=unknown
+kpse_save_flags=$CFLAGS
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+#include <stdio.h>
+ extern void foo(void);
+ void foo(void){printf("foo\n");}
+_ACEOF
+# FIXME: Add tests for non-GNU compilers
+for kpse_flag in '-fvisibility=hidden -fvisibility-inlines-hidden' '-fvisibility=hidden'; do
+ CFLAGS="$kpse_save_flags -Werror $kpse_flag"
+ if ac_fn_c_try_compile "$LINENO"; then :
+ kpse_cv_visibility_cflags=$kpse_flag; break
+fi
+rm -f core conftest.err conftest.$ac_objext
+done
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $kpse_cv_visibility_cflags" >&5
+$as_echo "$kpse_cv_visibility_cflags" >&6; }
+CFLAGS=$kpse_save_flags
+case $kpse_cv_visibility_cflags in #(
+ unknown) :
+ ;; #(
+ *) :
+ VISIBILITY_CFLAGS=$kpse_cv_visibility_cflags
+ ;;
+esac
+
+
+
+
+
cairo_attribute_flag=
if test "x$GCC" = xyes; then
case `$CC -dumpversion` in #(
diff --git a/Build/source/libs/cairo/configure.ac b/Build/source/libs/cairo/configure.ac
index 27fe9c7c35e..8818bcc142b 100644
--- a/Build/source/libs/cairo/configure.ac
+++ b/Build/source/libs/cairo/configure.ac
@@ -22,10 +22,12 @@ AC_PROG_RANLIB
AC_PROG_LN_S
CAIRO_BIGENDIAN
+KPSE_COMPILER_VISIBILITY
+
cairo_attribute_flag=
if test "x$GCC" = xyes; then
AS_CASE([`$CC -dumpversion`],
- [4.@<:@01@:>@.* ], [],
+ [4.[[01]].* ], [],
[4.* | 5.*], [cairo_attribute_flag=-Wno-attributes])
fi
AC_SUBST([CAIRO_ATTRIBUTE_FLAG], [$cairo_attribute_flag])