[Libreoffice-commits] libvisio.git: 2 commits - configure.ac .gitignore inc/libvisio
David Tardon
dtardon at redhat.com
Mon Nov 24 07:05:01 PST 2014
.gitignore | 1 +
configure.ac | 19 +++++++++++++++++++
inc/libvisio/VisioDocument.h | 4 ++++
3 files changed, 24 insertions(+)
New commits:
commit 6033e13300a7beff58a953241c0da6d760082827
Author: David Tardon <dtardon at redhat.com>
Date: Mon Nov 24 16:04:08 2014 +0100
add compile script to .gitignore
Change-Id: Ic14123f7f5e9048074f51d84c073ad79c4ac816f
diff --git a/.gitignore b/.gitignore
index f3bab2c..9e03dc5 100644
--- a/.gitignore
+++ b/.gitignore
@@ -3,6 +3,7 @@ Makefile.in
aclocal.m4
ar-lib
autom4te.cache
+compile
config.guess
config.h
config.h.in
commit 5bd7231abf5e138d6b31faeb4cf2466e6a53f716
Author: David Tardon <dtardon at redhat.com>
Date: Fri Aug 29 13:31:09 2014 +0200
only export public symbols
diff --git a/configure.ac b/configure.ac
index 9e4df06..d279ec1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -193,6 +193,25 @@ AS_CASE([$host],
AC_MSG_RESULT([$platform_win32])
AM_CONDITIONAL([PLATFORM_WIN32], [test "x$platform_win32" = "xyes"])
+AS_IF([test $platform_win32 == yes],
+ [],
+ [
+ AC_MSG_CHECKING([for -fvisibility=hidden compiler flag])
+ saved_CXXFLAGS="$CXXFLAGS"
+ CXXFLAGS="$CXXFLAGS -fvisibility=hidden"
+ AC_TRY_COMPILE([], [],
+ [
+ AC_MSG_RESULT([yes])
+ CXXFLAGS="$CXXFLAGS -DLIBVISIO_VISIBILITY"
+ ],
+ [
+ AC_MSG_RESULT([no])
+ CXXFLAGS="$saved_CXXFLAGS"
+ ]
+ )
+ ]
+)
+
# ================
# Check for cflags
# ================
diff --git a/inc/libvisio/VisioDocument.h b/inc/libvisio/VisioDocument.h
index 1354ed2..c44528d 100644
--- a/inc/libvisio/VisioDocument.h
+++ b/inc/libvisio/VisioDocument.h
@@ -18,9 +18,13 @@
#else
#define VSDAPI __declspec(dllimport)
#endif
+#else // !DLL_EXPORT
+#ifdef LIBVISIO_VISIBILITY
+#define VSDAPI __attribute__((visibility("default")))
#else
#define VSDAPI
#endif
+#endif
namespace libvisio
{
More information about the Libreoffice-commits
mailing list