[Libreoffice-commits] .: configure.in

Norbert Thiebaud nthiebaud at kemper.freedesktop.org
Mon Jul 4 00:20:49 PDT 2011


 configure.in | 6958 +++++++++++++++++++++++++++++------------------------------
 1 file changed, 3489 insertions(+), 3469 deletions(-)

New commits:
commit 4979089a055d53816a7f2788fba20e757ea8204e
Author: Norbert Thiebaud <nthiebaud at gmail.com>
Date:   Mon Jul 4 02:20:26 2011 -0500

    clean-up configure.in intendations

diff --git a/configure.in b/configure.in
index 3550498..cb80a22 100755
--- a/configure.in
+++ b/configure.in
@@ -350,8 +350,8 @@ AC_ARG_ENABLE(kde4,
 AC_ARG_ENABLE(unix-qstart-libpng,
     AS_HELP_STRING([--disable-unix-qstart-libpng],
         [On UNIX systems, we have a faster splash app, that can use libpng to
-	 render its splash, if we can safely link to the system libpng then
-	 enabling this is a good idea (ie. for Linux Distro packaging).]),
+         render its splash, if we can safely link to the system libpng then
+         enabling this is a good idea (ie. for Linux Distro packaging).]),
 ,enable_unix_libpng=yes)
 
 AC_ARG_ENABLE(binfilter,
@@ -438,33 +438,33 @@ AC_ARG_ENABLE(cl-x64,
 
 AC_ARG_ENABLE(extra-gallery,
     AS_HELP_STRING([--enable-extra-gallery],
-	[Add extra gallery content.]),
+        [Add extra gallery content.]),
 ,)
 
 AC_ARG_ENABLE(extra-template,
     AS_HELP_STRING([--enable-extra-template],
-	[Add extra template content.]),
+        [Add extra template content.]),
 ,)
 
 AC_ARG_ENABLE(extra-sample,
     AS_HELP_STRING([--enable-extra-sample],
-	[Add extra sample content.]),
+        [Add extra sample content.]),
 ,)
 
 AC_ARG_ENABLE(extra-font,
     AS_HELP_STRING([--enable-extra-font],
-	[Add extra font content.]),
+        [Add extra font content.]),
 ,)
 
 AC_ARG_ENABLE(lomenubar,
     AS_HELP_STRING([--enable-lomenubar],
-	[Enable global menu support.]),
+        [Enable global menu support.]),
 ,)
 
 AC_ARG_ENABLE(online-update,
     AS_HELP_STRING([--enable-online-update],
-	[Enable the online update service that will check for new versions of
-	 LibreOffice. By default, it is on on Windows and Mac, and off on Linux.]),
+        [Enable the online update service that will check for new versions of
+         LibreOffice. By default, it is on on Windows and Mac, and off on Linux.]),
 ,)
 
 AC_ARG_ENABLE(release-build,
@@ -500,8 +500,8 @@ AC_ARG_WITH(external-tar,
 AC_ARG_WITH(linked-git,
     AS_HELP_STRING([--with-linked-git=<OTHER_CLONE_DIR>],
         [Specify another checkout's clonedir to re-use. This makes use of
-		 git-new-workdir, and saves a lot of diskspace when having multiple
-		 trees side-by-side.]),
+                 git-new-workdir, and saves a lot of diskspace when having multiple
+                 trees side-by-side.]),
     GIT_LINK_SRC=$withval ,
 )
 
@@ -529,13 +529,13 @@ AC_ARG_WITH(vba-package-format,
 
 AC_ARG_WITH(theme,
     AS_HELP_STRING([--with-theme="theme1 theme2..."],
-	[Choose which themes to include. By default those themes with an '*' are included.
+        [Choose which themes to include. By default those themes with an '*' are included.
          Possible choices: *default, *crystal, *hicontrast, *oxygen, *tango, classic, industrial.]),
 ,)
 
 AC_ARG_WITH(theme,
     AS_HELP_STRING([--with-theme="theme1 theme2..."],
-	[Choose which themes to include. By default those themes with an '*' are included.
+        [Choose which themes to include. By default those themes with an '*' are included.
          Possible choices: *default, *crystal, *hicontrast, *oxygen, *tango, classic, industrial.]),
 ,)
 
@@ -1290,17 +1290,17 @@ dnl ===================================================================
 AC_CANONICAL_SYSTEM
 
 if test "$cross_compiling" = "yes"; then
-  CROSS_COMPILING=YES
+    CROSS_COMPILING=YES
 else
-  CROSS_COMPILING=
-  BUILD_TYPE="$BUILD_TYPE NATIVE"
+    CROSS_COMPILING=
+    BUILD_TYPE="$BUILD_TYPE NATIVE"
 fi
 AC_SUBST(CROSS_COMPILING)
 
 if test "$build_os" = "cygwin"; then
-  EXEEXT_FOR_BUILD=.exe
+    EXEEXT_FOR_BUILD=.exe
 else
-  EXEEXT_FOR_BUILD=
+    EXEEXT_FOR_BUILD=
 fi
 AC_SUBST(EXEEXT_FOR_BUILD)
 
@@ -1310,7 +1310,7 @@ dnl ===================================================================
 cat /dev/null > warn
 
 if test "$EUID" -eq "0"  -a "z`uname -o 2>/dev/null`" = "zCygwin" ; then
-   AC_MSG_ERROR([You must build LibreOffice as a normal user - not using an administrative account])
+    AC_MSG_ERROR([You must build LibreOffice as a normal user - not using an administrative account])
 fi
 
 save_CC=$CC
@@ -1320,27 +1320,27 @@ AC_PROG_EGREP
 AC_PROG_AWK
 AC_PATH_PROG( AWK, $AWK)
 if test -z "$AWK"; then
-   AC_MSG_ERROR([install awk to run this script])
+    AC_MSG_ERROR([install awk to run this script])
 fi
 
 AC_PATH_PROGS(SED, sed )
 if test -z "$SED"; then
-   AC_MSG_ERROR([install sed to run this script])
+    AC_MSG_ERROR([install sed to run this script])
 fi
 
 AC_PATH_PROG(BASH, bash)
 if test -z "$BASH"; then
-   AC_MSG_ERROR([bash not found in \$PATH])
+    AC_MSG_ERROR([bash not found in \$PATH])
 fi
 AC_SUBST(BASH)
 
 AC_MSG_CHECKING([for GNU or BSD tar])
 for a in $GNUTAR gtar gnutar tar; do
-      $a --version 2> /dev/null | egrep "GNU|bsdtar"  2>&1 > /dev/null
-      if test $? -eq 0;  then
-           GNUTAR=$a
-           break
-      fi
+    $a --version 2> /dev/null | egrep "GNU|bsdtar"  2>&1 > /dev/null
+    if test $? -eq 0;  then
+        GNUTAR=$a
+        break
+    fi
 done
 AC_MSG_RESULT($GNUTAR)
 if test -z "$GNUTAR"; then
@@ -1359,172 +1359,185 @@ test_cups=yes
 test_fontconfig=yes
 
 case "$host_os" in
-    solaris*)
-        test_gtk=yes
-        build_gstreamer=yes
-        test_kde=yes
-        test_freetype=yes
-        test_gstreamer=yes
-        _os=SunOS
-        AC_PATH_PROG( GNUTAR, gtar,,$PATH:/usr/sfw/bin)
-        if test -z "$GNUTAR"; then
-            AC_MSG_ERROR([gtar (GNU tar) not found but needed. Install it (Sun Freeware package).])
-        fi
-        AC_SUBST(GNUTAR)
 
-        dnl ===========================================================
-        dnl Check whether we're using Solaris 6,7,8 - SPARC or Intel.
-        dnl ===========================================================
-           AC_MSG_CHECKING([the Solaris operating system release])
-           _os_release=`echo $host_os | $SED -e s/solaris2\.//`
-        if test "$_os_release" -lt "6"; then
-                  AC_MSG_ERROR([use Solaris >= 6 to build LibreOffice])
-           else
-                  AC_MSG_RESULT([ok ($_os_release)])
-           fi
+solaris*)
+    test_gtk=yes
+    build_gstreamer=yes
+    test_kde=yes
+    test_freetype=yes
+    test_gstreamer=yes
+    _os=SunOS
+    AC_PATH_PROG( GNUTAR, gtar,,$PATH:/usr/sfw/bin)
+    if test -z "$GNUTAR"; then
+        AC_MSG_ERROR([gtar (GNU tar) not found but needed. Install it (Sun Freeware package).])
+    fi
+    AC_SUBST(GNUTAR)
+
+    dnl ===========================================================
+    dnl Check whether we're using Solaris 6,7,8 - SPARC or Intel.
+    dnl ===========================================================
+    AC_MSG_CHECKING([the Solaris operating system release])
+    _os_release=`echo $host_os | $SED -e s/solaris2\.//`
+    if test "$_os_release" -lt "6"; then
+        AC_MSG_ERROR([use Solaris >= 6 to build LibreOffice])
+    else
+        AC_MSG_RESULT([ok ($_os_release)])
+    fi
 
-           dnl Check whether we're using a SPARC or i386 processor
-           AC_MSG_CHECKING([the processor type])
-           if test "$host_cpu" = "sparc" -o "$host_cpu" = "i386"; then
-                  AC_MSG_RESULT([ok ($host_cpu)])
-           else
-                  AC_MSG_ERROR([only SPARC and i386 processors are supported])
-           fi
-        ;;
-    linux-gnu*|k*bsd*-gnu*)
-        test_gtk=yes
-        build_gstreamer=yes
-        test_kde=yes
-        test_kde4=yes
-        test_freetype=yes
-        test_unix_quickstarter=yes
-        _os=Linux
-        ;;
-    gnu)
-        test_randr=no
-        test_cups=no
-        _os=GNU
-        ;;
-    cygwin*|interix*|mingw32*)
-
-        # When building on Windows normally with MSVC under Cygwin,
-        # configure thinks that the host platform (the platform the
-        # built code will run on) is Cygwin, even if it obviously is
-        # Windows, which in Autoconf terminology is called
-        # "mingw32". (Which is misleading as MinGW is the name of the
-        # tool-chain, not an operating system.)
-
-        # Somewhat confusing, yes. But this configure script doesn't
-        # look at $host etc that much, it mostly uses its own $_os
-        # variable, set here in this case statement.
-
-        # When cross-compiling to Windows from Unix, the host platform
-        # is "mingw32" (because in that case it is the MinGW
-        # tool-chain that is used).
-
-        test_cups=no
-        test_randr=no
-        test_freetype=no
-        test_fontconfig=no
-        _os=WINNT
-        # Confusingly, if the host OS matches "mingw32*", that means
-        # we are using the MinGW compiler, either natively (unlikely)
-        # or cross-compiling. We use WITH_MINGW to indicate
-        # use of MinGW in both cases.
-        case "$host_os" in
-            mingw32*)
-            WITH_MINGW=yes
-            ;;
-        esac
-        ;;
-    darwin*) # Mac OS X or iOS
-        test_gtk=yes
-        test_randr=no
-        test_freetype=no
-        test_fontconfig=no
-        if test "$host_cpu" = "arm"; then
-	    _os=iOS
-            test_gtk=no
-        else
-            _os=Darwin
-        fi
-        enable_systray=no
-        ;;
-    freebsd*)
-        test_gtk=yes
-        build_gstreamer=yes
-        test_kde=yes
-        test_kde4=yes
-        test_freetype=yes
-        AC_MSG_CHECKING([the FreeBSD operating system release])
-        if test -n "$with_os_version"; then
-            OSVERSION="$with_os_version"
-        else
-            OSVERSION=`/sbin/sysctl -n kern.osreldate`
-        fi
-        AC_MSG_RESULT([found OSVERSION=$OSVERSION])
-        AC_MSG_CHECKING([which thread library to use])
-        if test "$OSVERSION" -lt "500016"; then
-            PTHREAD_CFLAGS="-D_THREAD_SAFE"
-            PTHREAD_LIBS="-pthread"
-        elif test "$OSVERSION" -lt "502102"; then
-            PTHREAD_CFLAGS="-D_THREAD_SAFE"
-            PTHREAD_LIBS="-lc_r"
-        else
-            PTHREAD_CFLAGS=""
-            PTHREAD_LIBS="-pthread"
-        fi
-        AC_MSG_RESULT([$PTHREAD_LIBS])
-        _os=FreeBSD
-        ;;
-    *netbsd*)
-        test_gtk=yes
-        build_gstreamer=yes
-        test_kde=no
-        test_kde4=yes
-        test_freetype=yes
-        PTHREAD_LIBS="-pthread -lpthread"
-        _os=NetBSD
-        ;;
-    aix*)
-        test_cups=no
-        test_randr=no
-        test_freetype=yes
-        PTHREAD_LIBS=-pthread
-        _os=AIX
+    dnl Check whether we're using a SPARC or i386 processor
+    AC_MSG_CHECKING([the processor type])
+    if test "$host_cpu" = "sparc" -o "$host_cpu" = "i386"; then
+        AC_MSG_RESULT([ok ($host_cpu)])
+    else
+        AC_MSG_ERROR([only SPARC and i386 processors are supported])
+    fi
+    ;;
+
+linux-gnu*|k*bsd*-gnu*)
+    test_gtk=yes
+    build_gstreamer=yes
+    test_kde=yes
+    test_kde4=yes
+    test_freetype=yes
+    test_unix_quickstarter=yes
+    _os=Linux
+    ;;
+
+gnu)
+    test_randr=no
+    test_cups=no
+    _os=GNU
+     ;;
+
+cygwin*|interix*|mingw32*)
+
+    # When building on Windows normally with MSVC under Cygwin,
+    # configure thinks that the host platform (the platform the
+    # built code will run on) is Cygwin, even if it obviously is
+    # Windows, which in Autoconf terminology is called
+    # "mingw32". (Which is misleading as MinGW is the name of the
+    # tool-chain, not an operating system.)
+
+    # Somewhat confusing, yes. But this configure script doesn't
+    # look at $host etc that much, it mostly uses its own $_os
+    # variable, set here in this case statement.
+
+    # When cross-compiling to Windows from Unix, the host platform
+    # is "mingw32" (because in that case it is the MinGW
+    # tool-chain that is used).
+
+    test_cups=no
+    test_randr=no
+    test_freetype=no
+    test_fontconfig=no
+    _os=WINNT
+    # Confusingly, if the host OS matches "mingw32*", that means
+    # we are using the MinGW compiler, either natively (unlikely)
+    # or cross-compiling. We use WITH_MINGW to indicate
+    # use of MinGW in both cases.
+    case "$host_os" in
+
+    mingw32*)
+        WITH_MINGW=yes
         ;;
-    openbsd*)
-        test_gtk=yes
-        test_kde=yes
-        test_freetype=yes
+    esac
+    ;;
+
+darwin*) # Mac OS X or iOS
+    test_gtk=yes
+    test_randr=no
+    test_freetype=no
+    test_fontconfig=no
+    if test "$host_cpu" = "arm"; then
+        _os=iOS
+        test_gtk=no
+    else
+        _os=Darwin
+    fi
+    enable_systray=no
+;;
+
+freebsd*)
+    test_gtk=yes
+    build_gstreamer=yes
+    test_kde=yes
+    test_kde4=yes
+    test_freetype=yes
+    AC_MSG_CHECKING([the FreeBSD operating system release])
+    if test -n "$with_os_version"; then
+        OSVERSION="$with_os_version"
+    else
+        OSVERSION=`/sbin/sysctl -n kern.osreldate`
+    fi
+    AC_MSG_RESULT([found OSVERSION=$OSVERSION])
+    AC_MSG_CHECKING([which thread library to use])
+    if test "$OSVERSION" -lt "500016"; then
         PTHREAD_CFLAGS="-D_THREAD_SAFE"
         PTHREAD_LIBS="-pthread"
-        _os=OpenBSD
-        ;;
-    dragonfly*)
-        test_gtk=yes
-        build_gstreamer=yes
-        test_kde=yes
-        test_kde4=yes
-        test_freetype=yes
+    elif test "$OSVERSION" -lt "502102"; then
+        PTHREAD_CFLAGS="-D_THREAD_SAFE"
+        PTHREAD_LIBS="-lc_r"
+    else
+        PTHREAD_CFLAGS=""
         PTHREAD_LIBS="-pthread"
-        _os=DragonFly
-        ;;
-    androideabi*)
-        build_gstreamer=no
-	test_cups=no
-        test_fontconfig=no
-        test_freetype=no
-        test_gtk=no
-        test_kde=no
-        test_kde4=no
-        test_randr=no
-        test_unix_quickstarter=no
-        _os=Android
-        ;;
-   *)
-   AC_MSG_ERROR([$host_os operating system is not suitable to build LibreOffice!])
-   ;;
+    fi
+    AC_MSG_RESULT([$PTHREAD_LIBS])
+    _os=FreeBSD
+    ;;
+
+*netbsd*)
+    test_gtk=yes
+    build_gstreamer=yes
+    test_kde=no
+    test_kde4=yes
+    test_freetype=yes
+    PTHREAD_LIBS="-pthread -lpthread"
+    _os=NetBSD
+    ;;
+
+aix*)
+    test_cups=no
+    test_randr=no
+    test_freetype=yes
+    PTHREAD_LIBS=-pthread
+    _os=AIX
+    ;;
+
+openbsd*)
+    test_gtk=yes
+    test_kde=yes
+    test_freetype=yes
+    PTHREAD_CFLAGS="-D_THREAD_SAFE"
+    PTHREAD_LIBS="-pthread"
+    _os=OpenBSD
+    ;;
+
+dragonfly*)
+    test_gtk=yes
+    build_gstreamer=yes
+    test_kde=yes
+    test_kde4=yes
+    test_freetype=yes
+    PTHREAD_LIBS="-pthread"
+    _os=DragonFly
+    ;;
+
+androideabi*)
+    build_gstreamer=no
+    test_cups=no
+    test_fontconfig=no
+    test_freetype=no
+    test_gtk=no
+    test_kde=no
+    test_kde4=no
+    test_randr=no
+    test_unix_quickstarter=no
+    _os=Android
+    ;;
+
+*)
+    AC_MSG_ERROR([$host_os operating system is not suitable to build LibreOffice!])
+    ;;
 esac
 
 AC_SUBST(WITH_MINGW)
@@ -1547,12 +1560,12 @@ if test $_os != iOS -a $_os != Android; then
 fi
 
 if test $build_os = "cygwin"; then
-   dnl ===================================================================
-   dnl If $CC is set to a MinGW compiler, set WITH_MINGW
-   dnl ===================================================================
-   if test "$WITH_MINGW" != "yes" -a -n "$CC" -a "`$CC -dumpmachine 2>/dev/null | $SED -e 's/^.*-//'`" = "mingw32"; then
-      WITH_MINGW="yes"
-   fi
+    dnl ===================================================================
+    dnl If $CC is set to a MinGW compiler, set WITH_MINGW
+    dnl ===================================================================
+    if test "$WITH_MINGW" != "yes" -a -n "$CC" -a "`$CC -dumpmachine 2>/dev/null | $SED -e 's/^.*-//'`" = "mingw32"; then
+        WITH_MINGW="yes"
+    fi
 fi
 
 dnl ===================================================================
@@ -1561,12 +1574,12 @@ dnl and g++ to build guw.exe although MSVC or MinGW is used to
 dnl build LibreOffice.
 dnl ===================================================================
 if test "build_os" = "cygwin" ; then
-   AC_MSG_CHECKING([for Cygwin gcc/g++])
-   if which gcc > /dev/null && which g++ > /dev/null ; then
-      AC_MSG_RESULT([found])
-   else
-      AC_MSG_ERROR([Cygwin gcc and g++ are needed, please install them.])
-   fi
+    AC_MSG_CHECKING([for Cygwin gcc/g++])
+    if which gcc > /dev/null && which g++ > /dev/null ; then
+        AC_MSG_RESULT([found])
+    else
+        AC_MSG_ERROR([Cygwin gcc and g++ are needed, please install them.])
+    fi
 fi
 
 dnl ===================================================================
@@ -1576,12 +1589,12 @@ dnl ===================================================================
 GCC_HOME_SET="true"
 AC_MSG_CHECKING([gcc home])
 if test -z "$with_gcc_home"; then
-   if test -n "$enable_icecream" && test "$enable_icecream" != "no" ; then
-      GCC_HOME="/opt/icecream"
-   else
-      GCC_HOME=`which gcc | $SED -e s,/bin/gcc,,`
-      GCC_HOME_SET="false"
-   fi
+    if test -n "$enable_icecream" && test "$enable_icecream" != "no" ; then
+        GCC_HOME="/opt/icecream"
+    else
+        GCC_HOME=`which gcc | $SED -e s,/bin/gcc,,`
+        GCC_HOME_SET="false"
+    fi
 else
     GCC_HOME="$with_gcc_home"
 fi
@@ -1589,17 +1602,17 @@ AC_MSG_RESULT($GCC_HOME)
 AC_SUBST(GCC_HOME)
 
 if test "$GCC_HOME_SET" = "true" ; then
-   if test -z "$CC"; then
-      CC="$GCC_HOME/bin/gcc"
-   fi
-   if test -z "$CXX"; then
-      CXX="$GCC_HOME/bin/g++"
-   fi
+    if test -z "$CC"; then
+        CC="$GCC_HOME/bin/gcc"
+    fi
+    if test -z "$CXX"; then
+        CXX="$GCC_HOME/bin/g++"
+    fi
 fi
 
 dnl The following checks for gcc, cc and then cl (if it weren't guarded for win32)
 if test "$_os" != "WINNT" -o "$WITH_MINGW" = "yes"; then
-   AC_PROG_CC
+    AC_PROG_CC
 fi
 
 COMPATH=`dirname "$CC"`
@@ -1615,45 +1628,45 @@ dnl  Test the gcc version,  3 is OK
 dnl ===================================================================
 if test \( "$_os" != "WINNT" -o "$WITH_MINGW" = "yes" \) -a "$GCC" = "yes"; then
     AC_MSG_CHECKING([the GNU C compiler version])
-   _gcc_version=`$CC -dumpversion`
-   _gcc_major=`echo $_gcc_version | $AWK -F. '{ print \$1 }'`
-   GCCVER=`echo $_gcc_version | $AWK -F. '{ print \$1*10000+\$2*100+\$3 }'`
-
-   if test "$_os" = "Darwin" -a "$GCCVER" -ge "040100" ; then
-      if test -z "$save_CC" -a -x "$GCC_HOME/bin/gcc-4.0" ; then
-         export CC=$GCC_HOME/bin/gcc-4.0
-          dnl  export CC to have it available in set_soenv -> config.guess
-         GCCVER2=`"$CC" -dumpversion | $AWK -F. '{ print \$1*10000+\$2*100+\$3 }'`
-         if test "$GCCVER2" -ge "040000" -a "$GCCVER2" -lt "040100" ; then
-            GCCVER=$GCCVER2
-         fi
-      fi
-      if test "$GCCVER" -ge "040100" ; then
-         AC_MSG_ERROR([You need to use the gcc-4.0 compiler (gcc $_gcc_version won't work with the MacOSX10.4u.sdk) - set CC accordingly])
-      else
-         AC_MSG_RESULT([implicitly using CC=$CC])
-      fi
-   else
-      AC_MSG_RESULT([checked (gcc $_gcc_version)])
-   fi
+    _gcc_version=`$CC -dumpversion`
+    _gcc_major=`echo $_gcc_version | $AWK -F. '{ print \$1 }'`
+    GCCVER=`echo $_gcc_version | $AWK -F. '{ print \$1*10000+\$2*100+\$3 }'`
+
+    if test "$_os" = "Darwin" -a "$GCCVER" -ge "040100" ; then
+        if test -z "$save_CC" -a -x "$GCC_HOME/bin/gcc-4.0" ; then
+            export CC=$GCC_HOME/bin/gcc-4.0
+            dnl  export CC to have it available in set_soenv -> config.guess
+            GCCVER2=`"$CC" -dumpversion | $AWK -F. '{ print \$1*10000+\$2*100+\$3 }'`
+            if test "$GCCVER2" -ge "040000" -a "$GCCVER2" -lt "040100" ; then
+                GCCVER=$GCCVER2
+            fi
+        fi
+        if test "$GCCVER" -ge "040100" ; then
+            AC_MSG_ERROR([You need to use the gcc-4.0 compiler (gcc $_gcc_version won't work with the MacOSX10.4u.sdk) - set CC accordingly])
+        else
+            AC_MSG_RESULT([implicitly using CC=$CC])
+        fi
+    else
+        AC_MSG_RESULT([checked (gcc $_gcc_version)])
+    fi
 fi
 
 HAVE_LD_BSYMBOLIC_FUNCTIONS=
 if test "$GCC" = "yes"; then
-   AC_MSG_CHECKING( for -Bsymbolic-functions linker support )
-   bsymbolic_functions_ldflags_save=$LDFLAGS
-   LDFLAGS="$LDFLAGS -Wl,-Bsymbolic-functions -Wl,--dynamic-list-cpp-new -Wl,--dynamic-list-cpp-typeinfo"
-   AC_LINK_IFELSE([AC_LANG_PROGRAM([
-   #include <stdio.h>
-   ],[
-    printf ("hello world\n");
-   ])], HAVE_LD_BSYMBOLIC_FUNCTIONS=TRUE, [])
-   if test "z$HAVE_LD_BSYMBOLIC_FUNCTIONS" = "zTRUE"; then
-     AC_MSG_RESULT( found )
-   else
-     AC_MSG_RESULT( not found )
-   fi
-   LDFLAGS=$bsymbolic_functions_ldflags_save
+    AC_MSG_CHECKING( for -Bsymbolic-functions linker support )
+    bsymbolic_functions_ldflags_save=$LDFLAGS
+    LDFLAGS="$LDFLAGS -Wl,-Bsymbolic-functions -Wl,--dynamic-list-cpp-new -Wl,--dynamic-list-cpp-typeinfo"
+    AC_LINK_IFELSE([AC_LANG_PROGRAM([
+#include <stdio.h>
+        ],[
+printf ("hello world\n");
+        ])], HAVE_LD_BSYMBOLIC_FUNCTIONS=TRUE, [])
+    if test "z$HAVE_LD_BSYMBOLIC_FUNCTIONS" = "zTRUE"; then
+        AC_MSG_RESULT( found )
+    else
+        AC_MSG_RESULT( not found )
+    fi
+    LDFLAGS=$bsymbolic_functions_ldflags_save
 fi
 AC_SUBST(HAVE_LD_BSYMBOLIC_FUNCTIONS)
 
@@ -1664,24 +1677,24 @@ dnl ===================================================================
 
 m4_pattern_allow([PKG_CONFIG_FOR_BUILD])
 if test "$cross_compiling" = "yes"; then
-  AC_MSG_CHECKING([for BUILD platform configuration])
-  echo
-  rm -rf CONF-FOR-BUILD Env.Build.sh
-  mkdir CONF-FOR-BUILD
-  tar cf - \
-	configure \
-	config.guess \
-	oowintool \
-	solenv/inc/minor.mk \
-	solenv/inc/postset.mk \
-	solenv/inc/langlist.mk \
-	set_soenv.in \
-	bootstrap.1 \
-	post_download.in \
-	ooo.lst.in \
-	Makefile.in \
-	bin/repo-list.in | (cd CONF-FOR-BUILD && tar xf -)
-  (
+    AC_MSG_CHECKING([for BUILD platform configuration])
+    echo
+    rm -rf CONF-FOR-BUILD Env.Build.sh
+    mkdir CONF-FOR-BUILD
+    tar cf - \
+        configure \
+        config.guess \
+        oowintool \
+        solenv/inc/minor.mk \
+        solenv/inc/postset.mk \
+        solenv/inc/langlist.mk \
+        set_soenv.in \
+        bootstrap.1 \
+        post_download.in \
+        ooo.lst.in \
+        Makefile.in \
+        bin/repo-list.in | (cd CONF-FOR-BUILD && tar xf -)
+    (
     unset COM GUI GUIBASE OS CPU CPUNAME
     unset CC CXX SYSBASE CFLAGS
     unset AR NM OBJDUMP PKG_CONFIG RANLIB STRIP
@@ -1694,43 +1707,43 @@ if test "$cross_compiling" = "yes"; then
     test $with_junit = no && sub_conf_opts="$sub_conf_opts --without-junit"
     test -n "$TARFILE_LOCATION" && sub_conf_opts="$sub_conf_opts --with-external-tar=$TARFILE_LOCATION"
     ./configure \
-	--disable-mozilla \
-	--disable-build-mozilla \
-	--disable-zenity \
+        --disable-mozilla \
+        --disable-build-mozilla \
+        --disable-zenity \
         $sub_conf_opts \
-	2>&1 | sed -e 's/^/    /'
+        2>&1 | sed -e 's/^/    /'
     test -f ./*Env.Set.sh 2>/dev/null || exit
     cp *Env.Set.sh ../Env.Build.sh
     . ./*Env.Set.sh
     for V in COM GUI GUIBASE OS CPU CPUNAME CC CXX GXX_INCLUDE_PATH MACOSX_DEPLOYMENT_TARGET INPATH OUTPATH \
              SYSTEM_LIBXSLT; do
-      VV='$'$V
-      VV=`eval "echo $VV"`
-      if test -n "$VV"; then
-	line=${V}_FOR_BUILD='${'${V}_FOR_BUILD:-$VV'}'
-        echo "$line" >>build-config
-      fi
+        VV='$'$V
+        VV=`eval "echo $VV"`
+        if test -n "$VV"; then
+            line=${V}_FOR_BUILD='${'${V}_FOR_BUILD:-$VV'}'
+            echo "$line" >>build-config
+        fi
     done
 
     for V in OUTDIR PATH SOLARINC SOLARLIB WORKDIR; do
-      VV='$'$V
-      VV=`eval "echo $VV"`
-      VV=`echo $VV | sed -e 's,/CONF-FOR-BUILD,,g'`
-      if test -n "$VV"; then
-	line="${V}_FOR_BUILD='$VV'"
-        echo "$line" >>build-config
-      fi
+        VV='$'$V
+        VV=`eval "echo $VV"`
+        VV=`echo $VV | sed -e 's,/CONF-FOR-BUILD,,g'`
+        if test -n "$VV"; then
+            line="${V}_FOR_BUILD='$VV'"
+            echo "$line" >>build-config
+        fi
     done
-  )
-  test -f CONF-FOR-BUILD/build-config || AC_MSG_ERROR([Running configure script for BUILD system failed, see CONF-FOR-BUILD/config.log])
-  test -f Env.Build.sh || AC_MSG_ERROR([A file called Env.Build.sh was supposed to have been copied here, but it isn't found])
-  perl -pi -e 's,/CONF-FOR-BUILD,,g' Env.Build.sh
-  eval `cat CONF-FOR-BUILD/build-config`
-  AC_MSG_RESULT([checking for BUILD platform configuration... done])
-  rm -rf CONF-FOR-BUILD
+    )
+    test -f CONF-FOR-BUILD/build-config || AC_MSG_ERROR([Running configure script for BUILD system failed, see CONF-FOR-BUILD/config.log])
+    test -f Env.Build.sh || AC_MSG_ERROR([A file called Env.Build.sh was supposed to have been copied here, but it isn't found])
+    perl -pi -e 's,/CONF-FOR-BUILD,,g' Env.Build.sh
+    eval `cat CONF-FOR-BUILD/build-config`
+    AC_MSG_RESULT([checking for BUILD platform configuration... done])
+    rm -rf CONF-FOR-BUILD
 else
-  CC_FOR_BUILD="$CC"
-  CXX_FOR_BUILD="$CXX"
+    CC_FOR_BUILD="$CC"
+    CXX_FOR_BUILD="$CXX"
 fi
 AC_SUBST(COM_FOR_BUILD)
 AC_SUBST(GUI_FOR_BUILD)
@@ -1753,13 +1766,13 @@ AC_SUBST(SOLARLIB_FOR_BUILD)
 AC_SUBST(WORKDIR_FOR_BUILD)
 
 if test -e solenv/inc/minor.mk; then
-   # Get UPD number from ./solenv/inc/minor.mk
-   UPD="`grep RSCVERSION= solenv/inc/minor.mk | $AWK -F"=" '{ print $2 }'`"
-   AC_SUBST(UPD)
-   SOURCEVERSION="`grep SOURCEVERSION= solenv/inc/minor.mk | $AWK -F"=" '{ print $2 }'`"
-   AC_SUBST(SOURCEVERSION)
+    # Get UPD number from ./solenv/inc/minor.mk
+    UPD="`grep RSCVERSION= solenv/inc/minor.mk | $AWK -F"=" '{ print $2 }'`"
+    AC_SUBST(UPD)
+    SOURCEVERSION="`grep SOURCEVERSION= solenv/inc/minor.mk | $AWK -F"=" '{ print $2 }'`"
+    AC_SUBST(SOURCEVERSION)
 else
-   AC_MSG_ERROR([solenv/inc/minor.mk missing but needed for architecture/os detecion and proper environment script generation...])
+    AC_MSG_ERROR([solenv/inc/minor.mk missing but needed for architecture/os detecion and proper environment script generation...])
 fi
 
 dnl ===================================================================
@@ -1767,12 +1780,12 @@ dnl Set the ENABLE_CRASHDUMP variable.
 dnl ===================================================================
 AC_MSG_CHECKING([whether to enable crashdump feature])
 if test "$enable_crashdump" = "yes"; then
-   ENABLE_CRASHDUMP="TRUE"
-   BUILD_TYPE="$BUILD_TYPE CRASHREP"
-   AC_MSG_RESULT([yes])
+    ENABLE_CRASHDUMP="TRUE"
+    BUILD_TYPE="$BUILD_TYPE CRASHREP"
+    AC_MSG_RESULT([yes])
 else
-   ENABLE_CRASHDUMP=""
-   AC_MSG_RESULT([no])
+    ENABLE_CRASHDUMP=""
+    AC_MSG_RESULT([no])
 fi
 AC_SUBST(ENABLE_CRASHDUMP)
 
@@ -1782,71 +1795,71 @@ dnl Windows specific tests and stuff
 dnl ===================================================================
 if test "$_os" = "WINNT"; then
 
-   dnl Include twain scanners
-   BUILD_TYPE="$BUILD_TYPE TWAIN"
-
-   dnl Set the CL_X64 variable if we are building a 64-bit LibreOffice.
-   AC_MSG_CHECKING([whether to build a 64-bit LibreOffice])
-   if test "z$enable_cl_x64" = "z" -o "$enable_cl_x64" = "no"; then
-      CL_X64=""
-      AC_MSG_RESULT([no])
-   else
-      CL_X64="TRUE"
-      AC_MSG_RESULT([yes])
-   fi
-   AC_SUBST(CL_X64)
-
-   AC_MSG_CHECKING([whether to use DirectX])
-   if test "$enable_directx" = "yes" -o "$enable_directx" = ""; then
-      ENABLE_DIRECTX="TRUE"
-      AC_MSG_RESULT([yes])
-   else
-      ENABLE_DIRECTX=""
-      AC_MSG_RESULT([no])
-   fi
-   AC_SUBST(ENABLE_DIRECTX)
-
-   AC_MSG_CHECKING([whether to use ActiveX])
-   if test "$enable_activex" = "yes" -o "$enable_activex" = "TRUE" -o "$enable_activex" = ""; then
-      DISABLE_ACTIVEX=""
-      AC_MSG_RESULT([yes])
-   else
-      DISABLE_ACTIVEX="TRUE"
-      AC_MSG_RESULT([no])
-   fi
-   AC_SUBST(DISABLE_ACTIVEX)
-
-   AC_MSG_CHECKING([whether to use ATL])
-   if test "$enable_atl" = "yes" -o "$enable_atl" = "TRUE"; then
-      DISABLE_ATL=""
-      AC_MSG_RESULT([yes])
-   elif test "$enable_atl" = ""; then
-      if test "$WITH_MINGW" = "yes"; then
-         DISABLE_ATL="TRUE"
-         AC_MSG_RESULT([no])
-      else
-         DISABLE_ATL=""
-         AC_MSG_RESULT([yes])
-      fi
-   else
-      DISABLE_ATL="TRUE"
-      AC_MSG_RESULT([no])
-   fi
-   AC_SUBST(DISABLE_ATL)
+    dnl Include twain scanners
+    BUILD_TYPE="$BUILD_TYPE TWAIN"
+
+    dnl Set the CL_X64 variable if we are building a 64-bit LibreOffice.
+    AC_MSG_CHECKING([whether to build a 64-bit LibreOffice])
+    if test "z$enable_cl_x64" = "z" -o "$enable_cl_x64" = "no"; then
+        CL_X64=""
+        AC_MSG_RESULT([no])
+    else
+        CL_X64="TRUE"
+        AC_MSG_RESULT([yes])
+    fi
+    AC_SUBST(CL_X64)
+
+    AC_MSG_CHECKING([whether to use DirectX])
+    if test "$enable_directx" = "yes" -o "$enable_directx" = ""; then
+        ENABLE_DIRECTX="TRUE"
+        AC_MSG_RESULT([yes])
+    else
+        ENABLE_DIRECTX=""
+        AC_MSG_RESULT([no])
+    fi
+    AC_SUBST(ENABLE_DIRECTX)
+
+    AC_MSG_CHECKING([whether to use ActiveX])
+    if test "$enable_activex" = "yes" -o "$enable_activex" = "TRUE" -o "$enable_activex" = ""; then
+        DISABLE_ACTIVEX=""
+        AC_MSG_RESULT([yes])
+    else
+        DISABLE_ACTIVEX="TRUE"
+        AC_MSG_RESULT([no])
+    fi
+    AC_SUBST(DISABLE_ACTIVEX)
+
+    AC_MSG_CHECKING([whether to use ATL])
+    if test "$enable_atl" = "yes" -o "$enable_atl" = "TRUE"; then
+        DISABLE_ATL=""
+        AC_MSG_RESULT([yes])
+    elif test "$enable_atl" = ""; then
+        if test "$WITH_MINGW" = "yes"; then
+            DISABLE_ATL="TRUE"
+            AC_MSG_RESULT([no])
+        else
+            DISABLE_ATL=""
+            AC_MSG_RESULT([yes])
+        fi
+    else
+        DISABLE_ATL="TRUE"
+        AC_MSG_RESULT([no])
+    fi
+    AC_SUBST(DISABLE_ATL)
 fi
 
 dnl Set the ENABLE_WERROR variable. (Activate --enable-werror)
 dnl ===================================================================
 AC_MSG_CHECKING([whether to turn warnings to errors])
 if test -n "$enable_werror" && test "$enable_werror" != "no"; then
-   ENABLE_WERROR="TRUE"
-   AC_MSG_RESULT([yes])
-   AC_MSG_WARN([Turning warnings to errors has no effect in modules or])
-   AC_MSG_WARN([on platforms where it has been disabled explicitly])
-   echo "Turning warnings to errors has no effect in modules or on platforms where it has been disabled explicitly" >> warn
+    ENABLE_WERROR="TRUE"
+    AC_MSG_RESULT([yes])
+    AC_MSG_WARN([Turning warnings to errors has no effect in modules or])
+    AC_MSG_WARN([on platforms where it has been disabled explicitly])
+    echo "Turning warnings to errors has no effect in modules or on platforms where it has been disabled explicitly" >> warn
 else
-   ENABLE_WERROR="FALSE"
-   AC_MSG_RESULT([no])
+    ENABLE_WERROR="FALSE"
+    AC_MSG_RESULT([no])
 fi
 AC_SUBST(ENABLE_WERROR)
 
@@ -1854,14 +1867,14 @@ dnl Set the ENABLE_DEBUG variable. (Activate --enable-symbols)
 dnl ===================================================================
 AC_MSG_CHECKING([whether to do a debug build])
 if test -n "$enable_debug" && test "$enable_debug" != "no"; then
-   ENABLE_DEBUG="TRUE"
-   ENABLE_DEBUG_STL="TRUE"
-   enable_symbols="yes"
-   AC_MSG_RESULT([yes])
+    ENABLE_DEBUG="TRUE"
+    ENABLE_DEBUG_STL="TRUE"
+    enable_symbols="yes"
+    AC_MSG_RESULT([yes])
 else
-   ENABLE_DEBUG="FALSE"
-   ENABLE_DEBUG_STL="FALSE"
-   AC_MSG_RESULT([no])
+    ENABLE_DEBUG="FALSE"
+    ENABLE_DEBUG_STL="FALSE"
+    AC_MSG_RESULT([no])
 fi
 AC_SUBST(ENABLE_DEBUG)
 AC_SUBST(ENABLE_DEBUG_STL)
@@ -1870,15 +1883,15 @@ dnl Set the ENABLE_DBGUTIL variable
 dnl ===================================================================
 AC_MSG_CHECKING([whether to build with additional debug utilities])
 if test -n "$enable_dbgutil" && test "$enable_dbgutil" != "no"; then
-   PROEXT=""
-   PRODUCT=""
-   PROFULLSWITCH=""
-   AC_MSG_RESULT([yes])
+    PROEXT=""
+    PRODUCT=""
+    PROFULLSWITCH=""
+    AC_MSG_RESULT([yes])
 else
-   PRODUCT="full"
-   PROFULLSWITCH="product=full"
-   PROEXT=".pro"
-   AC_MSG_RESULT([no, full product build])
+    PRODUCT="full"
+    PROFULLSWITCH="product=full"
+    PROEXT=".pro"
+    AC_MSG_RESULT([no, full product build])
 fi
 AC_SUBST(PRODUCT)
 AC_SUBST(PROFULLSWITCH)
@@ -1888,11 +1901,11 @@ dnl whether to include symbols into final build.
 dnl ===================================================================
 AC_MSG_CHECKING([whether to include symbols])
 if test -n "$enable_symbols" -a "$enable_symbols" != "no"; then
-   ENABLE_SYMBOLS="TRUE"
-   AC_MSG_RESULT([yes])
+    ENABLE_SYMBOLS="TRUE"
+    AC_MSG_RESULT([yes])
 else
-   ENABLE_SYMBOLS=
-   AC_MSG_RESULT([no])
+    ENABLE_SYMBOLS=
+    AC_MSG_RESULT([no])
 fi
 AC_SUBST(ENABLE_SYMBOLS)
 
@@ -1900,16 +1913,16 @@ dnl Determine if the solver is to be stripped or not.
 dnl ===================================================================
 AC_MSG_CHECKING([whether to strip the solver or not.])
 if test "z$enable_strip_solver" = "zno"; then
-   DISABLE_STRIP="TRUE"
-   AC_MSG_RESULT([no])
+    DISABLE_STRIP="TRUE"
+    AC_MSG_RESULT([no])
 else
-   if test -n "$ENABLE_SYMBOLS"; then
-      DISABLE_STRIP="TRUE"
-      AC_MSG_RESULT([no])
-   else
-      DISABLE_STRIP=
-      AC_MSG_RESULT([yes])
-   fi
+    if test -n "$ENABLE_SYMBOLS"; then
+        DISABLE_STRIP="TRUE"
+        AC_MSG_RESULT([no])
+    else
+        DISABLE_STRIP=
+        AC_MSG_RESULT([yes])
+    fi
 fi
 AC_SUBST(DISABLE_STRIP)
 
@@ -1917,16 +1930,16 @@ dnl check for cups support
 dnl ===================================================================
 AC_MSG_CHECKING([whether to enable native cups support])
 if test "$test_cups" = "yes" -a "z$enable_cups" != "zno"; then
-   ENABLE_CUPS="TRUE"
-   AC_MSG_RESULT([yes])
-   AC_CHECK_LIB(cups, cupsPrintFiles)
-   AC_CHECK_HEADER(cups/cups.h, AC_DEFINE(HAVE_CUPS_H))
-   if test "$ac_cv_lib_cups_cupsPrintFiles" != "yes" -a "$ac_cv_header_cups_cups_h" != "yes"; then
+    ENABLE_CUPS="TRUE"
+    AC_MSG_RESULT([yes])
+    AC_CHECK_LIB(cups, cupsPrintFiles)
+    AC_CHECK_HEADER(cups/cups.h, AC_DEFINE(HAVE_CUPS_H))
+    if test "$ac_cv_lib_cups_cupsPrintFiles" != "yes" -a "$ac_cv_header_cups_cups_h" != "yes"; then
         AC_MSG_ERROR([Could not find CUPS. Install libcupsys2-dev or cups???-devel.])
-   fi
+    fi
 else
-   ENABLE_CUPS=""
-   AC_MSG_RESULT([no])
+    ENABLE_CUPS=""
+    AC_MSG_RESULT([no])
 fi
 AC_SUBST(ENABLE_CUPS)
 
@@ -1934,12 +1947,12 @@ AC_SUBST(ENABLE_CUPS)
 # check for fontconfig support
 AC_MSG_CHECKING([whether we need fontconfig])
 if test "z$test_fontconfig" = "zyes"; then
-   ENABLE_FONTCONFIG="TRUE"
-   AC_MSG_RESULT([yes])
-   PKG_CHECK_MODULES([FONTCONFIG], [fontconfig >= 2.2.0])
+    ENABLE_FONTCONFIG="TRUE"
+    AC_MSG_RESULT([yes])
+    PKG_CHECK_MODULES([FONTCONFIG], [fontconfig >= 2.2.0])
 else
-   ENABLE_FONTCONFIG=""
-   AC_MSG_RESULT([no])
+    ENABLE_FONTCONFIG=""
+    AC_MSG_RESULT([no])
 fi
 AC_SUBST(ENABLE_FONTCONFIG)
 AC_SUBST(FONTCONFIG_CFLAGS)
@@ -1948,12 +1961,12 @@ AC_SUBST(FONTCONFIG_LIBS)
 dnl whether to find & fetch external tarballs?
 dnl ===================================================================
 if test -z "$TARFILE_LOCATION"; then
-   TARFILE_LOCATION="DEFAULT"
+    TARFILE_LOCATION="DEFAULT"
 fi
 AC_SUBST(TARFILE_LOCATION)
 
 if test "z$enable_fetch_external" != "zno" ; then
-   DO_FETCH_TARBALLS="YES"
+    DO_FETCH_TARBALLS="YES"
 fi
 AC_SUBST(DO_FETCH_TARBALLS)
 
@@ -1966,23 +1979,23 @@ dnl Disable legacy binary file formats filters
 dnl ===================================================================
 AC_MSG_CHECKING([whether to enable filters for legacy binary file formats (StarOffice 5.2)])
 if test "$enable_binfilter" = "no"; then
-   WITH_BINFILTER="NO"
-   AC_MSG_RESULT([no])
+    WITH_BINFILTER="NO"
+    AC_MSG_RESULT([no])
 else
-   WITH_BINFILTER="YES"
-   BUILD_TYPE="$BUILD_TYPE BINFILTER"
-   AC_MSG_RESULT([yes])
+    WITH_BINFILTER="YES"
+    BUILD_TYPE="$BUILD_TYPE BINFILTER"
+    AC_MSG_RESULT([yes])
 fi
 AC_SUBST(WITH_BINFILTER)
 
 dnl Enable ugly pieces of code we're better off without
 dnl ===================================================================
 if test "$enable_ugly" = "yes"; then
-  BUILD_TYPE="$BUILD_TYPE DICTIONARIES"
-  SCPDEFS="$SCPDEFS -DWITH_UGLY"
-  ENABLE_UGLY=YES
+    BUILD_TYPE="$BUILD_TYPE DICTIONARIES"
+    SCPDEFS="$SCPDEFS -DWITH_UGLY"
+    ENABLE_UGLY=YES
 else
-  ENABLE_UGLY=NO
+    ENABLE_UGLY=NO
 fi
 AC_SUBST(ENABLE_UGLY)
 
@@ -1991,9 +2004,9 @@ dnl Disable rpath in shared libraries?
 dnl ===================================================================
 AC_MSG_CHECKING([whether to use RPATH in shared libraries])
 if test "$enable_rpath" = "no"; then
-   ENABLE_RPATH="no"
+    ENABLE_RPATH="no"
 else
-   ENABLE_RPATH="yes"
+    ENABLE_RPATH="yes"
 fi
 AC_MSG_RESULT([$ENABLE_RPATH])
 AC_SUBST(ENABLE_RPATH)
@@ -2002,12 +2015,12 @@ dnl Test whether to include MySpell dictionaries
 dnl ===================================================================
 AC_MSG_CHECKING([whether to include MySpell dictionaries])
 if test -z "$with_myspell_dicts" || test "$with_myspell_dicts" = "yes"; then
-  AC_MSG_RESULT([yes])
-  WITH_MYSPELL_DICTS=YES
-  BUILD_TYPE="$BUILD_TYPE DICTIONARIES"
+    AC_MSG_RESULT([yes])
+    WITH_MYSPELL_DICTS=YES
+    BUILD_TYPE="$BUILD_TYPE DICTIONARIES"
 else
-  AC_MSG_RESULT([no])
-  WITH_MYSPELL_DICTS=NO
+    AC_MSG_RESULT([no])
+    WITH_MYSPELL_DICTS=NO
 fi
 AC_SUBST(WITH_MYSPELL_DICTS)
 
@@ -2037,8 +2050,8 @@ if test -n "$with_system_dicts" -a "$with_system_dicts" = "yes"; then
     fi
     AC_MSG_RESULT([$THES_SYSTEM_DIR])
 else
-        AC_MSG_RESULT([no])
-        SYSTEM_DICTS=NO
+    AC_MSG_RESULT([no])
+    SYSTEM_DICTS=NO
 fi
 AC_SUBST(SYSTEM_DICTS)
 AC_SUBST(DICT_SYSTEM_DIR)
@@ -2050,20 +2063,20 @@ dnl Set the ENABLE_PCH variable. (Activate --enable-pch)
 dnl ===================================================================
 AC_MSG_CHECKING([whether to enable pch feature])
 if test -n "$enable_pch" && test "$enable_pch" != "no"; then
-   if test "$_os" = "WINNT" -a "$WITH_MINGW" != "yes"; then
-       ENABLE_PCH="TRUE"
-       AC_MSG_RESULT([yes])
+    if test "$_os" = "WINNT" -a "$WITH_MINGW" != "yes"; then
+        ENABLE_PCH="TRUE"
+        AC_MSG_RESULT([yes])
 dnl There is no PCH support in GCC versions prior to this
-   elif test "$GCC" = "yes"; then
-       ENABLE_PCH="TRUE"
-       AC_MSG_RESULT([yes])
-   else
-       ENABLE_PCH=""
-       AC_MSG_WARN([Precompiled header not yet supported for your platform/compiler])
-   fi
-else
-   ENABLE_PCH=""
-   AC_MSG_RESULT([no])
+    elif test "$GCC" = "yes"; then
+        ENABLE_PCH="TRUE"
+        AC_MSG_RESULT([yes])
+    else
+        ENABLE_PCH=""
+        AC_MSG_WARN([Precompiled header not yet supported for your platform/compiler])
+    fi
+else
+    ENABLE_PCH=""
+    AC_MSG_RESULT([no])
 fi
 AC_SUBST(ENABLE_PCH)
 
@@ -2072,11 +2085,11 @@ dnl Search all the common names for GNU make
 dnl ===================================================================
 AC_MSG_CHECKING([for GNU make])
 for a in "$MAKE" $GNUMAKE make gmake gnumake; do
-      $a --version 2> /dev/null | grep GNU  2>&1 > /dev/null
-      if test $? -eq 0;  then
-           GNUMAKE=$a
-           break
-      fi
+    $a --version 2> /dev/null | grep GNU  2>&1 > /dev/null
+    if test $? -eq 0;  then
+        GNUMAKE=$a
+        break
+    fi
 done
 AC_MSG_RESULT($GNUMAKE)
 if test -z "$GNUMAKE"; then
@@ -2089,7 +2102,7 @@ _make_longver=`echo $_make_version | $AWK -F. '{ print \$1*10000+\$2*100+\$3 }'`
 if test "$_make_longver" -ge "038100" ; then
     AC_MSG_RESULT([$GNUMAKE $_make_version])
 else
-   AC_MSG_ERROR([failed ($GNUMAKE version >= 3.81 needed])
+    AC_MSG_ERROR([failed ($GNUMAKE version >= 3.81 needed])
 fi
 AC_SUBST(GNUMAKE)
 
@@ -2097,64 +2110,65 @@ dnl ===================================================================
 dnl  Test the Solaris compiler version
 dnl ===================================================================
 if test "$_os" = "SunOS"; then
-   if test "$CC" = "cc"; then
-      AC_PATH_PROGS(_cc, cc)
-      COMPATH=`echo $_cc | $SED -n "s/\/bin\/cc//p"`
-      AC_MSG_CHECKING([the SunStudio C/C++ compiler version])
-      dnl cc -V outputs to standard error!!!!
-      _sunstudio_string=`$CC -V 2>&1 | grep '^cc' | $SED -e 's/.* C //'`
-      _sunstudio_version=`echo $_sunstudio_string | $AWK '{ print $1 }'`
-      _sunstudio_major=`echo $_sunstudio_version | $AWK -F. '{ print $1 }'`
-      if test "$_sunstudio_major" != "5"; then
-         AC_MSG_ERROR([found version "$_sunstudio_version", use version 5.5, 5.7, 5.8 or 5.9 of the SunStudio C/C++ compiler])
-      else
-         _sunstudio_minor=`echo $_sunstudio_version | $AWK -F. '{ if ($2 == 5) print "true"; else if ($2 == 7) print "true"; else if ($2 == 8) print "true"; else if ($2 == 9) print "true"; else print "false" }'`
-         if test "$_sunstudio_minor" = "false"; then
+    if test "$CC" = "cc"; then
+        AC_PATH_PROGS(_cc, cc)
+        COMPATH=`echo $_cc | $SED -n "s/\/bin\/cc//p"`
+        AC_MSG_CHECKING([the SunStudio C/C++ compiler version])
+        dnl cc -V outputs to standard error!!!!
+        _sunstudio_string=`$CC -V 2>&1 | grep '^cc' | $SED -e 's/.* C //'`
+        _sunstudio_version=`echo $_sunstudio_string | $AWK '{ print $1 }'`
+        _sunstudio_major=`echo $_sunstudio_version | $AWK -F. '{ print $1 }'`
+        if test "$_sunstudio_major" != "5"; then
             AC_MSG_ERROR([found version "$_sunstudio_version", use version 5.5, 5.7, 5.8 or 5.9 of the SunStudio C/C++ compiler])
-         else
-            dnl compiler will do
-            AC_MSG_RESULT([checked])
-         fi
-      fi
-   fi
+        else
+            _sunstudio_minor=`echo $_sunstudio_version | $AWK -F. '{ if ($2 == 5) print "true"; else if ($2 == 7) print "true"; else if ($2 == 8) print "true"; else if ($2 == 9) print "true"; else print "false" }'`
+            if test "$_sunstudio_minor" = "false"; then
+                AC_MSG_ERROR([found version "$_sunstudio_version", use version 5.5, 5.7, 5.8 or 5.9 of the SunStudio C/C++ compiler])
+            else
+                dnl compiler will do
+                AC_MSG_RESULT([checked])
+            fi
+        fi
+    fi
 fi
 
 HAVE_LD_HASH_STYLE=FALSE
 WITH_LINKER_HASH_STYLE=
 AC_MSG_CHECKING( for --hash-style gcc linker support )
 if test "$GCC" = "yes" ; then
-   if test -z "$with_linker_hash_style" -o "$with_linker_hash_style" = "yes" ; then
-      hash_styles="gnu sysv"
-   elif test "$with_linker_hash_style" = "no" ; then
-      hash_styles=
-   else
-      hash_styles="$with_linker_hash_style"
-   fi
-
-   for hash_style in $hash_styles ; do
-      test "$HAVE_LD_HASH_STYLE" = "TRUE" && continue
-      hash_style_ldflags_save=$LDFLAGS
-      LDFLAGS="$LDFLAGS -Wl,--hash-style=$hash_style"
-
-      AC_LINK_IFELSE([AC_LANG_PROGRAM([
-	  #include <stdio.h>
-	],[
-	  printf ("");
-	])],
-	[ if ./conftest$EXEEXT; then
-	    HAVE_LD_HASH_STYLE=TRUE
-	    WITH_LINKER_HASH_STYLE=$hash_style
-          fi],
-	[HAVE_LD_HASH_STYLE=FALSE])
-       LDFLAGS=$hash_style_ldflags_save
-   done
-
-   if test "$HAVE_LD_HASH_STYLE" = "TRUE"; then
-     AC_MSG_RESULT( $WITH_LINKER_HASH_STYLE )
-   else
-     AC_MSG_RESULT( no )
-   fi
-   LDFLAGS=$hash_style_ldflags_save
+    if test -z "$with_linker_hash_style" -o "$with_linker_hash_style" = "yes" ; then
+        hash_styles="gnu sysv"
+    elif test "$with_linker_hash_style" = "no" ; then
+        hash_styles=
+    else
+        hash_styles="$with_linker_hash_style"
+    fi
+
+    for hash_style in $hash_styles ; do
+        test "$HAVE_LD_HASH_STYLE" = "TRUE" && continue
+        hash_style_ldflags_save=$LDFLAGS
+        LDFLAGS="$LDFLAGS -Wl,--hash-style=$hash_style"
+
+        AC_LINK_IFELSE([AC_LANG_PROGRAM(
+            [
+#include <stdio.h>
+            ],[
+printf ("");
+            ])],
+            [ if ./conftest$EXEEXT; then
+                  HAVE_LD_HASH_STYLE=TRUE
+                  WITH_LINKER_HASH_STYLE=$hash_style
+              fi],
+            [HAVE_LD_HASH_STYLE=FALSE])
+        LDFLAGS=$hash_style_ldflags_save
+    done
+
+    if test "$HAVE_LD_HASH_STYLE" = "TRUE"; then
+        AC_MSG_RESULT( $WITH_LINKER_HASH_STYLE )
+    else
+        AC_MSG_RESULT( no )
+    fi
+    LDFLAGS=$hash_style_ldflags_save
 else
     AC_MSG_RESULT( no )
 fi
@@ -2165,15 +2179,15 @@ dnl ===================================================================
 dnl Check whether there's a Perl version available.
 dnl ===================================================================
 if test -z "$with_perl_home"; then
-   AC_PATH_PROG(PERL, perl)
+    AC_PATH_PROG(PERL, perl)
 else
-   test "$build_os" = "cygwin" && with_perl_home=`cygpath -u "$with_perl_home"`
-   _perl_path="$with_perl_home/bin/perl"
-   if test -x "$_perl_path"; then
-      PERL=$_perl_path
-   else
-      AC_MSG_ERROR([$_perl_path not found])
-   fi
+    test "$build_os" = "cygwin" && with_perl_home=`cygpath -u "$with_perl_home"`
+    _perl_path="$with_perl_home/bin/perl"
+    if test -x "$_perl_path"; then
+        PERL=$_perl_path
+    else
+        AC_MSG_ERROR([$_perl_path not found])
+    fi
 fi
 
 dnl ===================================================================
@@ -2181,15 +2195,15 @@ dnl Testing for Perl version 5 or greater.
 dnl $] is the Perl version variable, it is returned as an integer
 dnl ===================================================================
 if test "$PERL"; then
-   AC_MSG_CHECKING([the Perl version])
-   ${PERL} -e "exit($]);"
-   _perl_version=$?
-   if test "$_perl_version" -lt 5; then
-      AC_MSG_ERROR([found Perl version "$_perl_version", use version 5 of Perl])
-   fi
-   AC_MSG_RESULT([checked (perl $_perl_version)])
+    AC_MSG_CHECKING([the Perl version])
+    ${PERL} -e "exit($]);"
+    _perl_version=$?
+    if test "$_perl_version" -lt 5; then
+        AC_MSG_ERROR([found Perl version "$_perl_version", use version 5 of Perl])
+    fi
+    AC_MSG_RESULT([checked (perl $_perl_version)])
 else
-   AC_MSG_ERROR([Perl not found, install version 5 of Perl])
+    AC_MSG_ERROR([Perl not found, install version 5 of Perl])
 fi
 AC_SUBST(PERL)
 
@@ -2299,7 +2313,7 @@ if test "$_os" = "WINNT"; then
             export INCLUDE=`cygpath -d "$COMPATH/Include"`
             dnl  Check which Microsoft C/C++ compiler is found
             AC_MSG_CHECKING([the Version of Microsoft C/C++ Compiler])
-	    # The following finds Microsoft, matches nn.nn.nnnn then pulls numbers out.
+            # The following finds Microsoft, matches nn.nn.nnnn then pulls numbers out.
             CCNUMVER=`$CC 2>&1 | $AWK "/Microsoft/ && /..\\...\\...../ {
                             x = match( \\\$0, /..\\...\\...../ )
                             CCversion = substr( \\\$0, RSTART, RLENGTH)
@@ -2335,52 +2349,52 @@ if test "$_os" = "WINNT"; then
             AC_MSG_RESULT(["$SHOWINCLUDES_PREFIX"])
         fi
 
-	# Check for 64-bit (cross-)compiler to use to build the 64-bit
-	# version of the Explorer extension (and maybe other small
-	# bits, too) needed when installing a 32-bit LibreOffice on a
-	# 64-bit OS. The 64-bit Explorer extension is a feature that
-	# has been present since long in OOo. Don't confuse it with
-	# building LibreOffice itself as 64-bit code, which is
-	# unfished work and highly experimental.
-
-	BUILD_X64=
-	CC_X64_BINARY=
-	LINK_X64_BINARY=
-	LIBMGR_X64_BINARY=
-
-	if test "$CL_X64" = ""; then
-	    AC_MSG_CHECKING([for a x64 compiler])
-
-	    # Prefer native x64 compiler to cross-compiler, in case we are running
-	    # the build on a 64-bit OS.
-	    if "$with_cl_home/bin/amd64/cl.exe" -? </dev/null >/dev/null 2>&1; then
-		BUILD_X64=TRUE
-		CC_X64_BINARY="$with_cl_home/bin/amd64/cl.exe"
-		CXX_X64_BINARY="$with_cl_home/bin/amd64/cl.exe"
-		LINK_X64_BINARY="$with_cl_home/bin/amd64/link.exe"
-		LIBMGR_X64_BINARY="$with_cl_home/bin/amd64/lib.exe"
-	    elif "$with_cl_home/bin/x86_amd64/cl.exe" -? </dev/null >/dev/null 2>&1; then
-		BUILD_X64=TRUE
-		CC_X64_BINARY="$with_cl_home/bin/x86_amd64/cl.exe"
-		CXX_X64_BINARY="$with_cl_home/bin/x86_amd64/cl.exe"
-		LINK_X64_BINARY="$with_cl_home/bin/x86_amd64/link.exe"
-		LIBMGR_X64_BINARY="$with_cl_home/bin/x86_amd64/lib.exe"
-	    fi
-	    if test "$BUILD_X64" = TRUE; then
-		AC_MSG_RESULT([found])
-	    else
-		AC_MSG_RESULT([not found])
-		AC_MSG_WARN([Installation set will not contain the 64-bit Explorer extension])
-	    fi
-	fi
-	AC_SUBST(BUILD_X64)
-
-	# These are passed to the environment through set_soenv.in as usual, and then
-	# used in set_wntx64.mk
-	AC_SUBST(CC_X64_BINARY)
-	AC_SUBST(CXX_X64_BINARY)
-	AC_SUBST(LINK_X64_BINARY)
-	AC_SUBST(LIBMGR_X64_BINARY)
+        # Check for 64-bit (cross-)compiler to use to build the 64-bit
+        # version of the Explorer extension (and maybe other small
+        # bits, too) needed when installing a 32-bit LibreOffice on a
+        # 64-bit OS. The 64-bit Explorer extension is a feature that
+        # has been present since long in OOo. Don't confuse it with
+        # building LibreOffice itself as 64-bit code, which is
+        # unfished work and highly experimental.
+
+        BUILD_X64=
+        CC_X64_BINARY=
+        LINK_X64_BINARY=
+        LIBMGR_X64_BINARY=
+
+        if test "$CL_X64" = ""; then
+            AC_MSG_CHECKING([for a x64 compiler])
+
+            # Prefer native x64 compiler to cross-compiler, in case we are running
+            # the build on a 64-bit OS.
+            if "$with_cl_home/bin/amd64/cl.exe" -? </dev/null >/dev/null 2>&1; then
+                BUILD_X64=TRUE
+                CC_X64_BINARY="$with_cl_home/bin/amd64/cl.exe"
+                CXX_X64_BINARY="$with_cl_home/bin/amd64/cl.exe"
+                LINK_X64_BINARY="$with_cl_home/bin/amd64/link.exe"
+                LIBMGR_X64_BINARY="$with_cl_home/bin/amd64/lib.exe"
+            elif "$with_cl_home/bin/x86_amd64/cl.exe" -? </dev/null >/dev/null 2>&1; then
+                BUILD_X64=TRUE
+                CC_X64_BINARY="$with_cl_home/bin/x86_amd64/cl.exe"
+                CXX_X64_BINARY="$with_cl_home/bin/x86_amd64/cl.exe"
+                LINK_X64_BINARY="$with_cl_home/bin/x86_amd64/link.exe"
+                LIBMGR_X64_BINARY="$with_cl_home/bin/x86_amd64/lib.exe"
+            fi
+            if test "$BUILD_X64" = TRUE; then
+                AC_MSG_RESULT([found])
+            else
+                AC_MSG_RESULT([not found])
+                AC_MSG_WARN([Installation set will not contain the 64-bit Explorer extension])
+            fi
+        fi
+        AC_SUBST(BUILD_X64)
+
+        # These are passed to the environment through set_soenv.in as usual, and then
+        # used in set_wntx64.mk
+        AC_SUBST(CC_X64_BINARY)
+        AC_SUBST(CXX_X64_BINARY)
+        AC_SUBST(LINK_X64_BINARY)
+        AC_SUBST(LIBMGR_X64_BINARY)
 
     else
         AC_MSG_CHECKING([the compiler is MinGW])
@@ -2411,19 +2425,19 @@ fi
 
 if test "$_os" != "WINNT" -o "$WITH_MINGW" = "yes"; then
 
-   # If you use CC=/path/to/compiler/foo-gcc or even CC="ccache
-   # /path/to/compiler/foo-gcc" you need to set the AR etc env vars
-   # explicitly. Or put /path/to/compiler in PATH yourself.
+    # If you use CC=/path/to/compiler/foo-gcc or even CC="ccache
+    # /path/to/compiler/foo-gcc" you need to set the AR etc env vars
+    # explicitly. Or put /path/to/compiler in PATH yourself.
 
-   AC_CHECK_TOOL(AR,ar)
-   AC_CHECK_TOOL(NM,nm)
-   AC_CHECK_TOOL(OBJDUMP,objdump)
-   AC_CHECK_TOOL(RANLIB,ranlib)
-   AC_CHECK_TOOL(STRIP,strip)
-   if test "$_os" = "WINNT"; then
-      AC_CHECK_TOOL(DLLTOOL,dlltool)
-      AC_CHECK_TOOL(WINDRES,windres)
-   fi
+    AC_CHECK_TOOL(AR,ar)
+    AC_CHECK_TOOL(NM,nm)
+    AC_CHECK_TOOL(OBJDUMP,objdump)
+    AC_CHECK_TOOL(RANLIB,ranlib)
+    AC_CHECK_TOOL(STRIP,strip)
+    if test "$_os" = "WINNT"; then
+        AC_CHECK_TOOL(DLLTOOL,dlltool)
+        AC_CHECK_TOOL(WINDRES,windres)
+    fi
 fi
 AC_SUBST(AR)
 AC_SUBST(DLLTOOL)
@@ -2439,18 +2453,18 @@ dnl pkg-config checks on Mac OS X
 dnl ===================================================================
 
 if test $_os = Darwin; then
-   AC_MSG_CHECKING([for bogus pkg-config])
-   if test -n "$PKG_CONFIG"; then
-      if test "$PKG_CONFIG" = /usr/bin/pkg-config && ls -l /usr/bin/pkg-config | grep -q Mono.framework; then
-         AC_MSG_RESULT([yes, from Mono])
-      else
-         AC_MSG_RESULT([yes, from unknown origin])
-      fi
-      AC_MSG_WARN([This might have unexpected consequences, please consider hiding $PKG_CONFIG])
-      echo "Having a $PKG_CONFIG might have unexpected consequences, please consider hiding it" >>warn
-   else
-      AC_MSG_RESULT([no])
-   fi
+    AC_MSG_CHECKING([for bogus pkg-config])
+    if test -n "$PKG_CONFIG"; then
+        if test "$PKG_CONFIG" = /usr/bin/pkg-config && ls -l /usr/bin/pkg-config | grep -q Mono.framework; then
+            AC_MSG_RESULT([yes, from Mono])
+        else
+            AC_MSG_RESULT([yes, from unknown origin])
+        fi
+        AC_MSG_WARN([This might have unexpected consequences, please consider hiding $PKG_CONFIG])
+        echo "Having a $PKG_CONFIG might have unexpected consequences, please consider hiding it" >>warn
+    else
+        AC_MSG_RESULT([no])
+    fi
 fi
 
 dnl ===================================================================
@@ -2476,10 +2490,10 @@ if test "$build_os" = "cygwin"; then
         MIDL_PATH="$with_cl_home/../Common7/Tools/Bin"
     fi
     if test -z "$MIDL_PATH" ; then
-      vstest=`./oowintool --msvs-productdir`;
-      if test -x "$vstest/Common7/Tools/Bin/midl.exe" ; then
-          MIDL_PATH="$vstest/Common7/Tools/Bin"
-      fi
+        vstest=`./oowintool --msvs-productdir`;
+        if test -x "$vstest/Common7/Tools/Bin/midl.exe" ; then
+            MIDL_PATH="$vstest/Common7/Tools/Bin"
+        fi
     fi
     if test -z "$MIDL_PATH" ; then
         winsdktest=`./oowintool --windows-sdk-home`
@@ -2507,7 +2521,7 @@ if test "$build_os" = "cygwin"; then
     else
        csctest=`./oowintool --csc-compilerdir`;
        if test -x "$csctest/csc.exe"; then
-          CSC_PATH="$csctest"
+           CSC_PATH="$csctest"
        fi
     fi
     if test ! -x "$CSC_PATH/csc.exe"; then
@@ -2518,28 +2532,28 @@ if test "$build_os" = "cygwin"; then
     CSC_PATH=`cygpath -u "$CSC_PATH"`
 
     dnl Check mscoree.lib / .NET Framework dir
-        AC_MSG_CHECKING(.NET Framework)
-        if test -n "$with_dotnet_framework_home"; then
+    AC_MSG_CHECKING(.NET Framework)
+    if test -n "$with_dotnet_framework_home"; then
         with_dotnet_framework_home=`cygpath -u "$with_dotnet_framework_home"`
-        fi
-        if test -f "$with_dotnet_framework_home/lib/mscoree.lib"; then
-            DOTNET_FRAMEWORK_HOME="$with_dotnet_framework_home"
-        fi
-        if test -z "$DOTNET_FRAMEWORK_HOME" ; then
-          frametest=`./oowintool --dotnetsdk-dir`
-          if test -f "$frametest/lib/mscoree.lib"; then
-             DOTNET_FRAMEWORK_HOME="$frametest"
-          else
-             frametest=`./oowintool --windows-sdk-home`
-             if test -f "$frametest/lib/mscoree.lib"; then
+    fi
+    if test -f "$with_dotnet_framework_home/lib/mscoree.lib"; then
+        DOTNET_FRAMEWORK_HOME="$with_dotnet_framework_home"
+    fi
+    if test -z "$DOTNET_FRAMEWORK_HOME" ; then
+        frametest=`./oowintool --dotnetsdk-dir`
+        if test -f "$frametest/lib/mscoree.lib"; then
+            DOTNET_FRAMEWORK_HOME="$frametest"
+        else
+            frametest=`./oowintool --windows-sdk-home`
+            if test -f "$frametest/lib/mscoree.lib"; then
                 DOTNET_FRAMEWORK_HOME="$frametest"
-             fi
-          fi
-        fi
-        if test ! -f "$DOTNET_FRAMEWORK_HOME/lib/mscoree.lib"; then
-            AC_MSG_ERROR([mscoree.lib (.NET Framework) not found. Make sure you use --with-dotnet-framework-home])
+            fi
         fi
-        AC_MSG_RESULT(found)
+    fi
+    if test ! -f "$DOTNET_FRAMEWORK_HOME/lib/mscoree.lib"; then
+        AC_MSG_ERROR([mscoree.lib (.NET Framework) not found. Make sure you use --with-dotnet-framework-home])
+    fi
+    AC_MSG_RESULT(found)
     # Convert to posix path with 8.3 filename restrictions ( No spaces )
     DOTNET_FRAMEWORK_HOME=`cygpath -d "$DOTNET_FRAMEWORK_HOME"`
     DOTNET_FRAMEWORK_HOME=`cygpath -u "$DOTNET_FRAMEWORK_HOME"`
@@ -2552,47 +2566,47 @@ dnl ===================================================================
 dnl Check if stdc headers are available excluding MSVC.
 dnl ===================================================================
 if test "$_os" != "WINNT" -o "$WITH_MINGW" = "yes"; then
-   AC_HEADER_STDC
+    AC_HEADER_STDC
 fi
 
 if test "$_os" != "WINNT" -o "$WITH_MINGW" = "yes"; then
-   dnl ===================================================================
-   dnl Find pre-processors.
-   dnl ===================================================================
-
-   AC_PROG_CXXCPP
-
-   dnl Check whether there's a C pre-processor.
-   dnl ===================================================================
-   dnl When using SunStudio compiler, there is a bug with the cc
-   dnl preprocessor, so use CC preprocessor as the cc preprocessor
-   dnl See Issuezilla #445.
-   dnl ===================================================================
-   if test "$_os" = "SunOS"; then
-      CPP=$CXXCPP
-   else
-      AC_PROG_CPP
-   fi
-
-   dnl Find integral type sizes and alignments
-
-   AC_CHECK_SIZEOF(long)
-   AC_CHECK_SIZEOF(short)
-   AC_CHECK_SIZEOF(int)
-   AC_CHECK_SIZEOF(long long)
-   AC_CHECK_SIZEOF(double)
-   AC_CHECK_SIZEOF(void*)
-
-   SIZEOF_SHORT=$ac_cv_sizeof_short
-   SIZEOF_INT=$ac_cv_sizeof_int
-   SIZEOF_LONG=$ac_cv_sizeof_long
-   SIZEOF_LONGLONG=$ac_cv_sizeof_long_long
-   SIZEOF_DOUBLE=$ac_cv_sizeof_double
-   SIZEOF_POINTER=$ac_cv_sizeof_voidp
-
-   dnl Allow build without AC_CHECK_ALIGNOF, grrr
-   m4_pattern_allow([AC_CHECK_ALIGNOF])
-   m4_ifdef([AC_CHECK_ALIGNOF],
+    dnl ===================================================================
+    dnl Find pre-processors.
+    dnl ===================================================================
+
+    AC_PROG_CXXCPP
+
+    dnl Check whether there's a C pre-processor.
+    dnl ===================================================================
+    dnl When using SunStudio compiler, there is a bug with the cc
+    dnl preprocessor, so use CC preprocessor as the cc preprocessor
+    dnl See Issuezilla #445.
+    dnl ===================================================================
+    if test "$_os" = "SunOS"; then
+        CPP=$CXXCPP
+    else
+        AC_PROG_CPP
+    fi
+
+    dnl Find integral type sizes and alignments
+
+    AC_CHECK_SIZEOF(long)
+    AC_CHECK_SIZEOF(short)
+    AC_CHECK_SIZEOF(int)
+    AC_CHECK_SIZEOF(long long)
+    AC_CHECK_SIZEOF(double)
+    AC_CHECK_SIZEOF(void*)
+
+    SIZEOF_SHORT=$ac_cv_sizeof_short
+    SIZEOF_INT=$ac_cv_sizeof_int
+    SIZEOF_LONG=$ac_cv_sizeof_long
+    SIZEOF_LONGLONG=$ac_cv_sizeof_long_long
+    SIZEOF_DOUBLE=$ac_cv_sizeof_double
+    SIZEOF_POINTER=$ac_cv_sizeof_voidp
+
+    dnl Allow build without AC_CHECK_ALIGNOF, grrr
+    m4_pattern_allow([AC_CHECK_ALIGNOF])
+    m4_ifdef([AC_CHECK_ALIGNOF],
       ,
       [
          dnl We know that the ALIGNOF_ variables are used only when cross-compiling
@@ -2607,44 +2621,44 @@ if test "$_os" != "WINNT" -o "$WITH_MINGW" = "yes"; then
             ])
       ])
 
-   AC_CHECK_ALIGNOF(short,[#include <stddef.h>])
-   AC_CHECK_ALIGNOF(int,[#include <stddef.h>])
-   AC_CHECK_ALIGNOF(long,[#include <stddef.h>])
-   AC_CHECK_ALIGNOF(double,[#include <stddef.h>])
-
-   ALIGNOF_SHORT=$ac_cv_alignof_short
-   ALIGNOF_INT=$ac_cv_alignof_int
-   ALIGNOF_LONG=$ac_cv_alignof_long
-   ALIGNOF_DOUBLE=$ac_cv_alignof_double
-
-   AC_C_BIGENDIAN
-   WORDS_BIGENDIAN=$ac_cv_c_bigendian
-
-   dnl Check for large file support
-   AC_SYS_LARGEFILE
-   if test -n "$ac_cv_sys_file_offset_bits"; then
-      LFS_CFLAGS="-D_FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits"
-   fi
-   if test -n "$ac_cv_sys_large_files" && test "$ac_cv_sys_large_files" != "no"; then
-      LFS_CFLAGS="$LFS_CFLAGS -D_LARGE_FILES"
-   fi
-else
-   # Hardcode for MSVC
-   SIZEOF_SHORT=2
-   SIZEOF_INT=4
-   SIZEOF_LONG=4
-   SIZEOF_LONGLONG=8
-   if test "$CL_X64" = ""; then
-     SIZEOF_POINTER=4
-   else
-     SIZEOF_POINTER=8
-   fi
-   ALIGNOF_SHORT=2
-   ALIGNOF_INT=4
-   ALIGNOF_LONG=4
-   ALIGNOF_DOUBLE=8
-   WORDS_BIGENDIAN=no
-   LFS_CFLAGS=''
+    AC_CHECK_ALIGNOF(short,[#include <stddef.h>])
+    AC_CHECK_ALIGNOF(int,[#include <stddef.h>])
+    AC_CHECK_ALIGNOF(long,[#include <stddef.h>])
+    AC_CHECK_ALIGNOF(double,[#include <stddef.h>])
+
+    ALIGNOF_SHORT=$ac_cv_alignof_short
+    ALIGNOF_INT=$ac_cv_alignof_int
+    ALIGNOF_LONG=$ac_cv_alignof_long
+    ALIGNOF_DOUBLE=$ac_cv_alignof_double
+
+    AC_C_BIGENDIAN
+    WORDS_BIGENDIAN=$ac_cv_c_bigendian
+
+    dnl Check for large file support
+    AC_SYS_LARGEFILE
+    if test -n "$ac_cv_sys_file_offset_bits"; then
+        LFS_CFLAGS="-D_FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits"
+    fi
+    if test -n "$ac_cv_sys_large_files" && test "$ac_cv_sys_large_files" != "no"; then
+        LFS_CFLAGS="$LFS_CFLAGS -D_LARGE_FILES"
+    fi
+else
+    # Hardcode for MSVC
+    SIZEOF_SHORT=2
+    SIZEOF_INT=4
+    SIZEOF_LONG=4
+    SIZEOF_LONGLONG=8
+    if test "$CL_X64" = ""; then
+        SIZEOF_POINTER=4
+    else
+        SIZEOF_POINTER=8
+    fi
+    ALIGNOF_SHORT=2
+    ALIGNOF_INT=4
+    ALIGNOF_LONG=4
+    ALIGNOF_DOUBLE=8
+    WORDS_BIGENDIAN=no
+    LFS_CFLAGS=''
 fi
 AC_SUBST(WORDS_BIGENDIAN)
 AC_SUBST(LFS_CFLAGS)
@@ -2664,23 +2678,23 @@ dnl ===================================================================
 dnl Check if valgrind.h is available
 dnl ===================================================================
 if test "$cross_compiling" != "yes" -a "$enable_dbgutil" != "no"; then
-   dnl Test $prefix (currently only testing for /usr and /usr/local)
-   dnl so that VALGRIND_CFLAGS = -I$prefix/include/valgrind
-   VALGRIND_CFLAGS=""
-   prev_cppflags=$CPPFLAGS
-   if test -z "$VALGRIND_CFLAGS"; then
-      CPPFLAGS="-I/usr/include/valgrind"
-      AC_CHECK_HEADER([valgrind.h], [VALGRIND_CFLAGS=$CPPFLAGS], [unset ac_cv_header_valgrind_h])
-   fi
-   if test -z "$VALGRIND_CFLAGS"; then
-      CPPFLAGS="-I/usr/local/include/valgrind"
-      AC_CHECK_HEADER([valgrind.h], [VALGRIND_CFLAGS=$CPPFLAGS], [])
-   fi
-   if test -n "$VALGRIND_CFLAGS"; then
-      CPPFLAGS=$VALGRIND_CFLAGS
-      AC_CHECK_HEADER([memcheck.h], [], [VALGRIND_CFLAGS=""])
-   fi
-   CPPFLAGS=$prev_cppflags
+    dnl Test $prefix (currently only testing for /usr and /usr/local)
+    dnl so that VALGRIND_CFLAGS = -I$prefix/include/valgrind
+    VALGRIND_CFLAGS=""
+    prev_cppflags=$CPPFLAGS
+    if test -z "$VALGRIND_CFLAGS"; then
+        CPPFLAGS="-I/usr/include/valgrind"
+        AC_CHECK_HEADER([valgrind.h], [VALGRIND_CFLAGS=$CPPFLAGS], [unset ac_cv_header_valgrind_h])
+    fi
+    if test -z "$VALGRIND_CFLAGS"; then
+        CPPFLAGS="-I/usr/local/include/valgrind"
+        AC_CHECK_HEADER([valgrind.h], [VALGRIND_CFLAGS=$CPPFLAGS], [])
+    fi
+    if test -n "$VALGRIND_CFLAGS"; then
+        CPPFLAGS=$VALGRIND_CFLAGS
+        AC_CHECK_HEADER([memcheck.h], [], [VALGRIND_CFLAGS=""])
+    fi
+    CPPFLAGS=$prev_cppflags
 fi
 AC_SUBST([VALGRIND_CFLAGS])
 
@@ -2688,65 +2702,64 @@ dnl ===================================================================
 dnl Testing for C++ compiler and version...
 dnl ===================================================================
 if test "$_os" = "WINNT" -a "$WITH_MINGW" != "yes"; then
-   if test -n "$CC" -a -z "$CXX"; then
-      CXX="$CC"
-   fi
+    if test -n "$CC" -a -z "$CXX"; then
+        CXX="$CC"
+    fi
 fi
 
 dnl Autoconf 2.53 can do this test for cl.exe, 2.13 can't!
 if test "$_os" != "WINNT" -o "$WITH_MINGW" = "yes"; then
-   AC_PROG_CXX
+    AC_PROG_CXX
 fi
 
 dnl check if we are using a buggy version of g++ (currently 3.4.0, 3.4.1 and trunk)
 if test "$GXX" = "yes"; then
-   AC_MSG_CHECKING([the GNU C++ compiler version])
+    AC_MSG_CHECKING([the GNU C++ compiler version])
 
-   _gpp_version=`$CXX -dumpversion`
-   _gpp_majmin=`echo $_gpp_version | $AWK -F. '{ print \$1*100+\$2 }'`
+    _gpp_version=`$CXX -dumpversion`
+    _gpp_majmin=`echo $_gpp_version | $AWK -F. '{ print \$1*100+\$2 }'`
 
-   if test "$_os" = "Darwin" -a "$_gpp_majmin" -ge "401" ; then
-      if test -z "$save_CXX" -a -x "$GCC_HOME/bin/g++-4.0" ; then
-         CXX=$GCC_HOME/bin/g++-4.0
-         _gpp_majmin_2=`"$CXX" -dumpversion | $AWK -F. '{ print \$1*100+\$2 }'`
-         if test "$_gpp_majmin_2" -ge "400" -a "$_gpp_majmin_2" -lt "401" ; then
-            _gpp_majmin=$_gpp_majmin_2
-         fi
-      fi
-      if test "$_gpp_majmin" -ge "401" ; then
-         AC_MSG_ERROR([You need to use the g++-4.0 compiler (g++ $_gpp_version won't work with the MacOSX10.4u.sdk) - set CXX accordingly])
-      else
-         AC_MSG_RESULT([implicitly using CXX=$CXX])
-      fi
-   else
-      AC_MSG_RESULT([checked (g++ $_gpp_version)])
-   fi
-
-   if test "$_gpp_majmin" = "304"; then
-      AC_MSG_CHECKING([whether $CXX has the enum bug])
-AC_TRY_RUN([
-extern "C" void abort (void);
-extern "C" void exit (int status);
-
-enum E { E0, E1, E2, E3, E4, E5 };
-
-void
-test (enum E e)
-{
-  if (e == E2 || e == E3 || e == E1)
-  exit (1);
-}
+    if test "$_os" = "Darwin" -a "$_gpp_majmin" -ge "401" ; then
+        if test -z "$save_CXX" -a -x "$GCC_HOME/bin/g++-4.0" ; then
+            CXX=$GCC_HOME/bin/g++-4.0
+            _gpp_majmin_2=`"$CXX" -dumpversion | $AWK -F. '{ print \$1*100+\$2 }'`
+            if test "$_gpp_majmin_2" -ge "400" -a "$_gpp_majmin_2" -lt "401" ; then
+                _gpp_majmin=$_gpp_majmin_2
+            fi
+        fi
+        if test "$_gpp_majmin" -ge "401" ; then
+            AC_MSG_ERROR([You need to use the g++-4.0 compiler (g++ $_gpp_version won't work with the MacOSX10.4u.sdk) - set CXX accordingly])
+        else
+            AC_MSG_RESULT([implicitly using CXX=$CXX])
+        fi
+    else
+        AC_MSG_RESULT([checked (g++ $_gpp_version)])
+    fi
 
-int
-main (void)
-{
-  test (E4);
-  test (E5);
-  test (E0);
-  return 0;
-}
-],[AC_MSG_ERROR([your version of the GNU C++ compile has a bug which prevents LibreOffice from being compiled correctly - please check http://gcc.gnu.org/ml/gcc-patches/2004-07/msg00968.html for details.])], [AC_MSG_RESULT([no])])
-   fi
+    if test "$_gpp_majmin" = "304"; then
+        AC_MSG_CHECKING([whether $CXX has the enum bug])
+        AC_TRY_RUN([
+            extern "C" void abort (void);
+            extern "C" void exit (int status);
+
+            enum E { E0, E1, E2, E3, E4, E5 };
+
+            void test (enum E e)
+            {
+                if (e == E2 || e == E3 || e == E1)
+                    exit (1);
+            }
+
+            int main (void)
+            {
+                test (E4);
+                test (E5);
+                test (E0);
+                return 0;
+            }
+            ],
+            [AC_MSG_ERROR([your version of the GNU C++ compile has a bug which prevents LibreOffice from being compiled correctly - please check http://gcc.gnu.org/ml/gcc-patches/2004-07/msg00968.html for details.])], [AC_MSG_RESULT([no])])
+    fi
 fi
 
 dnl ===================================================================
@@ -2755,31 +2768,31 @@ dnl ===================================================================
 # Removed the special FreeBSD treatment. The problem was that with_gxx_include_path
 # often contains an i386 which is expanded as a macro.
 if test "$GXX" = "yes"; then
-   AC_MSG_CHECKING([for g++ include path])
-   if test -z "$with_gxx_include_path"; then
-      with_gxx_include_path=`echo "#include <cstring>" | $CXX -E -xc++ - | $SED -n '/.*1*"\(.*\)\/cstring".*/s//\1/p' | head -n 1`
-      if test "$with_gxx_include_path" = "/usr/libexec/(null)/include"; then
-          with_gxx_include_path="/usr/include"
-      fi
-      if test "$build_os" = "cygwin" -a "$WITH_MINGW" = "yes"; then
-         with_gxx_include_path=`cygpath -d "$with_gxx_include_path"`
-         with_gxx_include_path=`cygpath -u "$with_gxx_include_path"`
-      fi
-      if echo $with_gxx_include_path | grep -q linux; then
-         # workaround for Mandriva - issue 100049
-         with_gxx_include_path=`cd $with_gxx_include_path && pwd`
-      fi
-   fi
-   dnl This is the original code...
-   dnl with_gxx_include_path=`$CXX -print-search-dirs | grep instal |$AWK '{ print \$2 }'`/include
-   if test -z "$with_gxx_include_path"; then
-      with_gxx_include_path="NO_GXX_INCLUDE"
-      AC_MSG_RESULT([none])
-   else
-      AC_MSG_RESULT([$with_gxx_include_path])
-   fi
-else
-   with_gxx_include_path="NO_GXX_INCLUDE"
+    AC_MSG_CHECKING([for g++ include path])
+    if test -z "$with_gxx_include_path"; then
+        with_gxx_include_path=`echo "#include <cstring>" | $CXX -E -xc++ - | $SED -n '/.*1*"\(.*\)\/cstring".*/s//\1/p' | head -n 1`
+        if test "$with_gxx_include_path" = "/usr/libexec/(null)/include"; then
+            with_gxx_include_path="/usr/include"
+        fi
+        if test "$build_os" = "cygwin" -a "$WITH_MINGW" = "yes"; then
+            with_gxx_include_path=`cygpath -d "$with_gxx_include_path"`
+            with_gxx_include_path=`cygpath -u "$with_gxx_include_path"`
+        fi
+        if echo $with_gxx_include_path | grep -q linux; then
+            # workaround for Mandriva - issue 100049
+            with_gxx_include_path=`cd $with_gxx_include_path && pwd`
+        fi
+    fi
+    dnl This is the original code...
+    dnl with_gxx_include_path=`$CXX -print-search-dirs | grep instal |$AWK '{ print \$2 }'`/include
+    if test -z "$with_gxx_include_path"; then
+        with_gxx_include_path="NO_GXX_INCLUDE"
+        AC_MSG_RESULT([none])
+    else
+        AC_MSG_RESULT([$with_gxx_include_path])
+    fi
+else
+    with_gxx_include_path="NO_GXX_INCLUDE"
 fi
 GXX_INCLUDE_PATH="$with_gxx_include_path"
 AC_SUBST(GXX_INCLUDE_PATH)
@@ -2788,136 +2801,136 @@ dnl ===================================================================
 dnl Set the MinGW include directories
 dnl ===================================================================
 if test "$WITH_MINGW" = "yes"; then
-   AC_MSG_CHECKING([for MinGW runtime include path])
-   cat >conftest.$ac_ext <<_ACEOF
+    AC_MSG_CHECKING([for MinGW runtime include path])
+    cat >conftest.$ac_ext <<_ACEOF
 #include <stddef.h>
 #include <bits/c++config.h>
 _ACEOF
-   _mingw_lib_include_path=`$CXX -E -xc++ conftest.$ac_ext | $SED -n -e '/.*1*"\(.*\)\/stddef.h".*/s//\1/p' -e '/.*1*"\(.*\)\/bits\/c++config.h".*/s//\1/p' | sort -u | xargs echo`
-   rm conftest.$ac_ext
-   if test "$build_os" = "cygwin" -a -n "$_mingw_lib_include_path"; then
-      _temp=""
-      for a in $_mingw_lib_include_path
-         do
+    _mingw_lib_include_path=`$CXX -E -xc++ conftest.$ac_ext | $SED -n -e '/.*1*"\(.*\)\/stddef.h".*/s//\1/p' -e '/.*1*"\(.*\)\/bits\/c++config.h".*/s//\1/p' | sort -u | xargs echo`
+    rm conftest.$ac_ext
+    if test "$build_os" = "cygwin" -a -n "$_mingw_lib_include_path"; then
+        _temp=""
+        for a in $_mingw_lib_include_path
+        do
             a=`cygpath -d "$a"`
             _temp="$_temp "`cygpath -u "$a"`
-         done
-      _mingw_lib_include_path=$_temp
-   fi
-   if test -z "$_mingw_lib_include_path"; then
-      _mingw_lib_include_path="NO_LIB_INCLUDE"
-      AC_MSG_RESULT([no MinGW include path])
-   else
-      AC_MSG_RESULT([$_mingw_lib_include_path])
-   fi
-  MINGW_LIB_INCLUDE_PATH="$_mingw_lib_include_path"
-  AC_SUBST(MINGW_LIB_INCLUDE_PATH)
-dnl mingw gcc 4.4.0 needs backward in include path to use hash_set/hash_map
-   AC_MSG_CHECKING([for MinGW C++ backward include path])
-   cat >conftest.$ac_ext <<_ACEOF
+        done
+        _mingw_lib_include_path=$_temp
+    fi
+    if test -z "$_mingw_lib_include_path"; then
+        _mingw_lib_include_path="NO_LIB_INCLUDE"
+        AC_MSG_RESULT([no MinGW include path])
+    else
+        AC_MSG_RESULT([$_mingw_lib_include_path])
+    fi
+    MINGW_LIB_INCLUDE_PATH="$_mingw_lib_include_path"
+    AC_SUBST(MINGW_LIB_INCLUDE_PATH)
+    dnl mingw gcc 4.4.0 needs backward in include path to use hash_set/hash_map
+    AC_MSG_CHECKING([for MinGW C++ backward include path])
+    cat >conftest.$ac_ext <<_ACEOF
 #include <hash_set>
 _ACEOF
-   _mingw_backward_include_path=`$CXX -E -xc++ -Wno-deprecated conftest.$ac_ext 2>&5| $SED -n -e '/.*1*"\(.*\)\/hash_set".*/s//\1/p' | sort -u | xargs echo`
-   rm conftest.$ac_ext
-   if test "$build_os" = "cygwin" -a -n "$_mingw_backward_include_path"; then
-      _mingw_backward_include_path=`cygpath -d $_mingw_backward_include_path`
-      _mingw_backward_include_path=`cygpath -u $_mingw_backward_include_path`
-      AC_MSG_RESULT([$_mingw_backward_include_path])
-   else
-      _mingw_backward_include_path="NO_BACKWARD_INCLUDE"
-      AC_MSG_RESULT([no MinGW C++ backward includes])
-   fi
-  MINGW_BACKWARD_INCLUDE_PATH="$_mingw_backward_include_path"
-  AC_SUBST(MINGW_BACKWARD_INCLUDE_PATH)
-  mingw_crtbegin=`$CC -print-file-name=crtbegin.o`
-  MINGW_CLIB_DIR=`dirname $mingw_crtbegin`
-
-  # How to do this crack when cross-compiling?
-  AC_MSG_CHECKING([whether to use dynamic libgcc])
-  if test "$build_os" = "cygwin" -a -e "$MINGW_CLIB_DIR/libgcc_s.a"; then
-    AC_MSG_CHECKING([dynamic libgcc name])
-    MINGW_GCCDLL_pattern=`nm $MINGW_CLIB_DIR/libgcc_s.a | $SED -ne 's at .* _libgcc\(.*\)_dll_iname at libgcc\1.dll at p' | uniq | $SED -e 's at _@?@g'`
-    MINGW_GCCDLL=`cd $COMPATH/bin && ls $MINGW_GCCDLL_pattern 2>/dev/null`
-    if test -n "$MINGW_GCCDLL"; then
-        MINGW_SHARED_GCCLIB=YES
-        AC_MSG_RESULT([use $MINGW_GCCDLL])
+    _mingw_backward_include_path=`$CXX -E -xc++ -Wno-deprecated conftest.$ac_ext 2>&5| $SED -n -e '/.*1*"\(.*\)\/hash_set".*/s//\1/p' | sort -u | xargs echo`
+    rm conftest.$ac_ext
+    if test "$build_os" = "cygwin" -a -n "$_mingw_backward_include_path"; then
+        _mingw_backward_include_path=`cygpath -d $_mingw_backward_include_path`
+        _mingw_backward_include_path=`cygpath -u $_mingw_backward_include_path`
+        AC_MSG_RESULT([$_mingw_backward_include_path])
+    else
+        _mingw_backward_include_path="NO_BACKWARD_INCLUDE"
+        AC_MSG_RESULT([no MinGW C++ backward includes])
+    fi
+    MINGW_BACKWARD_INCLUDE_PATH="$_mingw_backward_include_path"
+    AC_SUBST(MINGW_BACKWARD_INCLUDE_PATH)
+    mingw_crtbegin=`$CC -print-file-name=crtbegin.o`
+    MINGW_CLIB_DIR=`dirname $mingw_crtbegin`
+
+    # How to do this crack when cross-compiling?
+    AC_MSG_CHECKING([whether to use dynamic libgcc])
+    if test "$build_os" = "cygwin" -a -e "$MINGW_CLIB_DIR/libgcc_s.a"; then
+        AC_MSG_CHECKING([dynamic libgcc name])
+        MINGW_GCCDLL_pattern=`nm $MINGW_CLIB_DIR/libgcc_s.a | $SED -ne 's at .* _libgcc\(.*\)_dll_iname at libgcc\1.dll at p' | uniq | $SED -e 's at _@?@g'`
+        MINGW_GCCDLL=`cd $COMPATH/bin && ls $MINGW_GCCDLL_pattern 2>/dev/null`
+        if test -n "$MINGW_GCCDLL"; then
+            MINGW_SHARED_GCCLIB=YES
+            AC_MSG_RESULT([use $MINGW_GCCDLL])
+        else
+            AC_MSG_RESULT([no])
+        fi
     else
         AC_MSG_RESULT([no])
     fi
-  else
-    AC_MSG_RESULT([no])
-  fi
-  if test -e "$MINGW_CLIB_DIR/libgcc_eh.a"; then
-      MINGW_GCCLIB_EH=YES
-  fi
+    if test -e "$MINGW_CLIB_DIR/libgcc_eh.a"; then
+        MINGW_GCCLIB_EH=YES
+    fi
 
-  AC_MSG_CHECKING([whether to use dynamic libstdc++])
-  MINGW_SHARED_LIBSTDCPP=
-  if test -e "$MINGW_CLIB_DIR/libstdc++_s.a" ; then
-    MINGW_SHARED_LIBSTDCPP=stdc++_s
-  fi
-  if test -e "$MINGW_CLIB_DIR/libstdc++.dll.a" ; then
-    MINGW_SHARED_LIBSTDCPP=stdc++.dll
-  fi
-  if test "$build_os" = "cygwin" -a -n "$MINGW_SHARED_LIBSTDCPP" ; then
-    AC_MSG_CHECKING([dynamic libstdc++ name])
-    MINGW_GXXDLL_pattern=`nm $MINGW_CLIB_DIR/lib$MINGW_SHARED_LIBSTDCPP.a | sed -ne 's at .* _libstdc__\(.*\)_dll_iname at libstdc++\1.dll at p' | uniq | sed -e 's at _@?@g'`
-    MINGW_GXXDLL=`cd $COMPATH/bin && ls $MINGW_GXXDLL_pattern 2>/dev/null`
-    if test -n "$MINGW_GXXDLL"; then
-        MINGW_SHARED_LIBSTDCPP=-l$MINGW_SHARED_LIBSTDCPP
-        MINGW_SHARED_GXXLIB=YES
-        AC_MSG_RESULT([use $MINGW_GXXDLL])
+    AC_MSG_CHECKING([whether to use dynamic libstdc++])
+    MINGW_SHARED_LIBSTDCPP=
+    if test -e "$MINGW_CLIB_DIR/libstdc++_s.a" ; then
+        MINGW_SHARED_LIBSTDCPP=stdc++_s
+    fi
+    if test -e "$MINGW_CLIB_DIR/libstdc++.dll.a" ; then
+        MINGW_SHARED_LIBSTDCPP=stdc++.dll
+    fi
+    if test "$build_os" = "cygwin" -a -n "$MINGW_SHARED_LIBSTDCPP" ; then
+        AC_MSG_CHECKING([dynamic libstdc++ name])
+        MINGW_GXXDLL_pattern=`nm $MINGW_CLIB_DIR/lib$MINGW_SHARED_LIBSTDCPP.a | sed -ne 's at .* _libstdc__\(.*\)_dll_iname at libstdc++\1.dll at p' | uniq | sed -e 's at _@?@g'`
+        MINGW_GXXDLL=`cd $COMPATH/bin && ls $MINGW_GXXDLL_pattern 2>/dev/null`
+        if test -n "$MINGW_GXXDLL"; then
+            MINGW_SHARED_LIBSTDCPP=-l$MINGW_SHARED_LIBSTDCPP
+            MINGW_SHARED_GXXLIB=YES
+            AC_MSG_RESULT([use $MINGW_GXXDLL])
+        else
+            MINGW_SHARED_LIBSTDCPP=
+            AC_MSG_RESULT([no])
+        fi
     else
-        MINGW_SHARED_LIBSTDCPP=
         AC_MSG_RESULT([no])
     fi
-  else
-    AC_MSG_RESULT([no])
-  fi
-  test "$build_os" = "cygwin" && MINGW_CLIB_DIR=`cygpath $MINGW_CLIB_DIR`
-  AC_SUBST(MINGW_CLIB_DIR)
-  AC_SUBST(MINGW_SHARED_GCCLIB)
-  AC_SUBST(MINGW_GCCLIB_EH)
-  AC_SUBST(MINGW_SHARED_GXXLIB)
-  AC_SUBST(MINGW_SHARED_LIBSTDCPP)
-  AC_SUBST(MINGW_GCCDLL)
-  AC_SUBST(MINGW_GXXDLL)
+    test "$build_os" = "cygwin" && MINGW_CLIB_DIR=`cygpath $MINGW_CLIB_DIR`
+    AC_SUBST(MINGW_CLIB_DIR)
+    AC_SUBST(MINGW_SHARED_GCCLIB)
+    AC_SUBST(MINGW_GCCLIB_EH)
+    AC_SUBST(MINGW_SHARED_GXXLIB)
+    AC_SUBST(MINGW_SHARED_LIBSTDCPP)
+    AC_SUBST(MINGW_GCCDLL)
+    AC_SUBST(MINGW_GXXDLL)
 fi
 
 dnl ===================================================================
 dnl Extra checking for the SunOS compiler
 dnl ===================================================================
 if test "$_os" = "SunOS"; then
-   dnl SunStudio C++ compiler packaged with SunStudio C compiler
-   if test "$CC" = "cc"; then
-   AC_MSG_CHECKING([SunStudio C++ Compiler])
-      if test "$CXX" != "CC"; then
-         AC_MSG_WARN([SunStudio C++ was not found])
-         echo "SunStudio C++ was not found" >> warn
-      else
-         AC_MSG_RESULT([checked])
-      fi
-   fi
+    dnl SunStudio C++ compiler packaged with SunStudio C compiler
+    if test "$CC" = "cc"; then
+    AC_MSG_CHECKING([SunStudio C++ Compiler])
+        if test "$CXX" != "CC"; then
+            AC_MSG_WARN([SunStudio C++ was not found])
+            echo "SunStudio C++ was not found" >> warn
+        else
+            AC_MSG_RESULT([checked])
+        fi
+    fi
 fi
 
 dnl *************************************************************
 dnl Testing for exception handling - dwarf2 or sjlj exceptions...
 dnl *************************************************************
 if test "$WITH_MINGW" = "yes"; then
-  AC_MSG_CHECKING([exception type])
-  AC_LANG_PUSH([C++])
-  AC_TRY_LINK(
-    [#include <iostream>
+    AC_MSG_CHECKING([exception type])
+    AC_LANG_PUSH([C++])
+    AC_TRY_LINK(
+        [#include <iostream>
 
-extern "C" void _Unwind_SjLj_RaiseException(void) __attribute__ ((__noreturn__));
+        extern "C" void _Unwind_SjLj_RaiseException(void) __attribute__ ((__noreturn__));
 
-    ],
-    [_Unwind_SjLj_RaiseException() ],
-    [exceptions_type="sjlj"],
-    [exceptions_type="dwarf2"]
-  )
-  AC_MSG_RESULT($exceptions_type)
-  AC_LANG_POP([C++])
+        ],
+        [_Unwind_SjLj_RaiseException() ],
+        [exceptions_type="sjlj"],
+        [exceptions_type="dwarf2"]
+    )
+    AC_MSG_RESULT($exceptions_type)
+    AC_LANG_POP([C++])
 fi
 
 EXCEPTIONS="$exceptions_type"
@@ -2928,100 +2941,100 @@ dnl Testing for required  Solaris and SunStudio compiler patches...
 dnl **************************************************************
 dnl Check whether the OS is SunOS.
 if test "$_os" = "SunOS"; then
-   _temp=`showrev -p | $AWK -F" " '{ print $2 }'`
-   if test "$_os_release" = "7"; then
-      dnl ***************
-      dnl patch 106327-06
-      dnl ***************
-      AC_MSG_CHECKING([for patch 106327-06 or greater])
-      _patch=`echo $_temp | $AWK '/106327-06/ { print "found" }'`
-      _patch="false"
-      for i in $_temp
-      do
-         _patch_major=`echo $i | $AWK -F"-" '{ print $1 }'`
-         if test "$_patch_major" = "106327"; then
-            _patch_rev=`echo $i | $AWK -F"-" '{ print $2 }'`
-            if test "$_patch_rev" -ge "6"; then
-               _patch="found"
+    _temp=`showrev -p | $AWK -F" " '{ print $2 }'`
+    if test "$_os_release" = "7"; then
+        dnl ***************
+        dnl patch 106327-06
+        dnl ***************
+        AC_MSG_CHECKING([for patch 106327-06 or greater])
+        _patch=`echo $_temp | $AWK '/106327-06/ { print "found" }'`
+        _patch="false"
+        for i in $_temp
+        do
+            _patch_major=`echo $i | $AWK -F"-" '{ print $1 }'`
+            if test "$_patch_major" = "106327"; then
+                _patch_rev=`echo $i | $AWK -F"-" '{ print $2 }'`
+                if test "$_patch_rev" -ge "6"; then
+                    _patch="found"
+                fi
             fi
+        done
+        if test "$_patch" = "found"; then
+            AC_MSG_RESULT([found])
+        else
+            AC_MSG_WARN([patch 106327-06 not found, please install compiler patch 106327-06 or greater])
+            echo "patch 106327-06 not found, please install compiler patch 106327-06 or greater" >> warn
         fi
-      done
-      if test "$_patch" = "found"; then
-         AC_MSG_RESULT([found])
-      else
-         AC_MSG_WARN([patch 106327-06 not found, please install compiler patch 106327-06 or greater])
-         echo "patch 106327-06 not found, please install compiler patch 106327-06 or greater" >> warn
-      fi
-      dnl ***************
-      dnl patch 106950-11
-      dnl ***************
-      AC_MSG_CHECKING([for patch 106950-11 or greater])
-      _patch=`echo $_temp | $AWK '/106950-11/ { print "found" }'`
-      _patch="false"
-      for i in $_temp
-      do
-         _patch_major=`echo $i | $AWK -F"-" '{ print $1 }'`
-         if test "$_patch_major" = "106950"; then
-            _patch_rev=`echo $i | $AWK -F"-" '{ print $2 }'`
-            if test "$_patch_rev" -ge "11"; then
-               _patch="found"
-            fi
-         fi
-      done
-      if test "$_patch" = "found"; then
-         AC_MSG_RESULT([found])
-      else
-         AC_MSG_WARN([patch 106950-11 not found, please install linker patch 106950-11 or greater])
-         echo "patch 106950-11 not found, please install linker patch 106950-11 or greater" >> warn
-      fi
-   else
-      if test "$_os_release" = "6"; then
-         dnl ***************
-         dnl patch 105591-09
-         dnl ***************
-         AC_MSG_CHECKING([for patch 105591-09 or greater])
-         _patch=`echo $_temp | $AWK '/105591-09/ { print "found" }'`
-         _patch="false"
-         for i in $_temp
-         do
+        dnl ***************
+        dnl patch 106950-11
+        dnl ***************
+        AC_MSG_CHECKING([for patch 106950-11 or greater])
+        _patch=`echo $_temp | $AWK '/106950-11/ { print "found" }'`
+        _patch="false"
+        for i in $_temp
+        do
             _patch_major=`echo $i | $AWK -F"-" '{ print $1 }'`
-            if test "$_patch_major" = "105591"; then
-               _patch_rev=`echo $i | $AWK -F"-" '{ print $2 }'`
-               if test "$_patch_rev" -ge "9"; then
-                  _patch="found"
-               fi
-           fi
-         done
-         if test "$_patch" = "found"; then
+            if test "$_patch_major" = "106950"; then
+                _patch_rev=`echo $i | $AWK -F"-" '{ print $2 }'`
+                if test "$_patch_rev" -ge "11"; then
+                    _patch="found"
+                fi
+            fi
+        done
+        if test "$_patch" = "found"; then
             AC_MSG_RESULT([found])
-         else
-            AC_MSG_WARN([patch 105591-09 not found, please install compiler patch 105591-09 or greater])
-            echo "patch 105591-09 not found, please install compiler patch 105591-09 or greater" >> warn
-         fi
-         dnl ***************
-         dnl patch 107733-08
-         dnl ***************
-         AC_MSG_CHECKING([for patch 107733-08 or greater])
-         _patch=`echo $_temp | $AWK '/107733-08/ { print "found" }'`
-         _patch="false"
-         for i in $_temp
-         do
-            _patch_major=`echo $i | $AWK -F"-" '{ print $1 }'`
-            if test "$_patch_major" = "107733"; then
-               _patch_rev=`echo $i | $AWK -F"-" '{ print $2 }'`
-               if test "$_patch_rev" -ge "8"; then
-                  _patch="found"
+        else
+            AC_MSG_WARN([patch 106950-11 not found, please install linker patch 106950-11 or greater])
+            echo "patch 106950-11 not found, please install linker patch 106950-11 or greater" >> warn
+        fi
+    else
+        if test "$_os_release" = "6"; then
+            dnl ***************
+            dnl patch 105591-09
+            dnl ***************
+            AC_MSG_CHECKING([for patch 105591-09 or greater])
+            _patch=`echo $_temp | $AWK '/105591-09/ { print "found" }'`
+            _patch="false"
+            for i in $_temp
+            do
+                _patch_major=`echo $i | $AWK -F"-" '{ print $1 }'`
+                if test "$_patch_major" = "105591"; then
+                    _patch_rev=`echo $i | $AWK -F"-" '{ print $2 }'`
+                    if test "$_patch_rev" -ge "9"; then
+                        _patch="found"
+                    fi
                fi
-           fi
-         done
-         if test "$_patch" = "found"; then
-            AC_MSG_RESULT([found])
-         else
-            AC_MSG_WARN([patch 107733-06 not found, please install linker patch 107733-08 or greater])
-            echo "patch 107733-06 not found, please install linker patch 107733-08 or greater" >> warn
-         fi
-      fi
-   fi
+            done
+            if test "$_patch" = "found"; then
+                AC_MSG_RESULT([found])
+            else
+                AC_MSG_WARN([patch 105591-09 not found, please install compiler patch 105591-09 or greater])
+                echo "patch 105591-09 not found, please install compiler patch 105591-09 or greater" >> warn
+            fi
+            dnl ***************
+            dnl patch 107733-08
+            dnl ***************
+            AC_MSG_CHECKING([for patch 107733-08 or greater])
+            _patch=`echo $_temp | $AWK '/107733-08/ { print "found" }'`
+            _patch="false"
+            for i in $_temp
+            do
+                _patch_major=`echo $i | $AWK -F"-" '{ print $1 }'`
+                if test "$_patch_major" = "107733"; then
+                    _patch_rev=`echo $i | $AWK -F"-" '{ print $2 }'`
+                    if test "$_patch_rev" -ge "8"; then
+                        _patch="found"
+                    fi
+                fi
+            done
+            if test "$_patch" = "found"; then
+                AC_MSG_RESULT([found])
+            else
+                AC_MSG_WARN([patch 107733-06 not found, please install linker patch 107733-08 or greater])
+                echo "patch 107733-06 not found, please install linker patch 107733-08 or greater" >> warn
+            fi
+        fi
+    fi
 fi
 
 dnl ===================================================================
@@ -3030,45 +3043,46 @@ dnl ===================================================================
 AC_MSG_CHECKING([Whether building STLPort library makes sense])
 BUILD_STLPORT="no"
 if test "$_os" = "Linux"; then
-  case "$host_cpu" in
+    case "$host_cpu" in
     i?86)
-      case "$host_os" in k*bsd*-gnu*)
-        BUILD_STLPORT="no"
-        ;;
-      *)
-        BUILD_STLPORT="yes"
+        case "$host_os" in
+        k*bsd*-gnu*)
+            BUILD_STLPORT="no"
+            ;;
+        *)
+            BUILD_STLPORT="yes"
+            ;;
+        esac
         ;;
-      esac
-      ;;
     *)
-      BUILD_STLPORT="no"
-      ;;
-  esac
+        BUILD_STLPORT="no"
+        ;;
+    esac
 elif test "$_os" = "SunOS"; then
-   BUILD_STLPORT="yes"
+    BUILD_STLPORT="yes"
 elif test "$_os" = "WINNT" -a "$WITH_MINGW" != "yes"; then
-   BUILD_STLPORT="yes"
+    BUILD_STLPORT="yes"
 elif test "$_os" = "FreeBSD"; then
-   BUILD_STLPORT="yes"
+    BUILD_STLPORT="yes"
 fi
 if test "$BUILD_STLPORT" = "yes" ; then
-   AC_MSG_RESULT([yes])
+    AC_MSG_RESULT([yes])
 else
-   AC_MSG_RESULT([no])
+    AC_MSG_RESULT([no])
 fi
 
 AC_MSG_CHECKING([Whether STLPort library will be actually built])
 if test "$with_stlport" = "auto" -o "$BUILD_STLPORT" = "no"; then
-   with_stlport=$BUILD_STLPORT
+    with_stlport=$BUILD_STLPORT
 fi
 if test "$with_stlport" = "yes" ; then
-   AC_MSG_RESULT([yes])
-       WITH_STLPORT=YES
-       SCPDEFS="$SCPDEFS -DWITH_STLPORT"
-       BUILD_TYPE="$BUILD_TYPE STLPORT"
+    AC_MSG_RESULT([yes])
+    WITH_STLPORT=YES
+    SCPDEFS="$SCPDEFS -DWITH_STLPORT"
+    BUILD_TYPE="$BUILD_TYPE STLPORT"
 else
-   WITH_STLPORT=NO
-   AC_MSG_RESULT([no])
+    WITH_STLPORT=NO
+    AC_MSG_RESULT([no])
 fi
 
 AC_SUBST(WITH_STLPORT)
@@ -3077,40 +3091,40 @@ dnl ===================================================================
 dnl visibility and c++0x features
 dnl ===================================================================
 if test "$GCC" = "yes"; then
-   AC_MSG_CHECKING([whether $CC supports -fvisibility=hidden])
-   save_CFLAGS=$CFLAGS
-   CFLAGS="$CFLAGS -Werror -fvisibility=hidden"
-   AC_TRY_LINK([], [ return 0; ], [ HAVE_GCC_VISIBILITY_FEATURE=TRUE ], [])
-   CFLAGS=$save_CFLAGS
-   if test "$HAVE_GCC_VISIBILITY_FEATURE" = "TRUE"; then
-      AC_MSG_RESULT([yes])
-   else
-      AC_MSG_RESULT([no])
-   fi
-
-   AC_MSG_CHECKING([whether $CC supports -std=c++0x without Language Defect 757])
-   save_CXXFLAGS=$CFLAGS
-   CXXFLAGS="$CXXFLAGS -std=c++0x"
-   AC_LANG_PUSH([C++])
-
-   AC_TRY_COMPILE([
+    AC_MSG_CHECKING([whether $CC supports -fvisibility=hidden])
+    save_CFLAGS=$CFLAGS
+    CFLAGS="$CFLAGS -Werror -fvisibility=hidden"
+    AC_TRY_LINK([], [ return 0; ], [ HAVE_GCC_VISIBILITY_FEATURE=TRUE ], [])
+    CFLAGS=$save_CFLAGS
+    if test "$HAVE_GCC_VISIBILITY_FEATURE" = "TRUE"; then
+        AC_MSG_RESULT([yes])
+    else
+        AC_MSG_RESULT([no])
+    fi
+
+    AC_MSG_CHECKING([whether $CC supports -std=c++0x without Language Defect 757])
+    save_CXXFLAGS=$CFLAGS
+    CXXFLAGS="$CXXFLAGS -std=c++0x"
+    AC_LANG_PUSH([C++])
+
+    AC_TRY_COMPILE([
 #include <stddef.h>
 
 template <typename T, size_t S> char (&sal_n_array_size( T(&)[S] ))[S];
 
 namespace
 {
-	struct b
-	{
-		int i;
-		int j;
-	};
+        struct b
+        {
+                int i;
+                int j;
+        };
 }
 ],[
 struct a
 {
-	int i;
-	int j;
+        int i;
+        int j;
 };
 a thinga[]={{0,0}, {1,1}};
 b thingb[]={{0,0}, {1,1}};
@@ -3119,13 +3133,13 @@ size_t j = sizeof(sal_n_array_size(thingb));
 return !(i != 0 && j != 0);
 ], HAVE_CXX0X=TRUE,)
 
-   AC_LANG_POP([C++])
-   CXXFLAGS=$save_CXXFLAGS
-   if test "$HAVE_CXX0X" = "TRUE"; then
-      AC_MSG_RESULT([yes])
-   else
-      AC_MSG_RESULT([no])
-   fi
+    AC_LANG_POP([C++])
+    CXXFLAGS=$save_CXXFLAGS
+    if test "$HAVE_CXX0X" = "TRUE"; then
+        AC_MSG_RESULT([yes])
+    else
+        AC_MSG_RESULT([no])
+    fi
 fi
 
 AC_SUBST(HAVE_CXX0X)
@@ -3137,40 +3151,40 @@ dnl need to check for ccache version: otherwise prevents
 dnl caching of the results (like "-x objective-c++" for Mac)
 AC_MSG_CHECKING([whether we are able to use --ccache-skip])
 if test "$_os" != "Darwin" ; then
-   AC_MSG_RESULT([only used on Mac currently, skipping])
-else
-   # checking for ccache presence/version
-   AC_MSG_RESULT([probing...])
-   AC_PATH_PROG([CCACHE],[ccache],[not_found])
-   if test "$CCACHE" = "not_found" ; then
-      AC_MSG_NOTICE([not enabling --ccache-skip (ccache not found)])
-   else
-      # check ccache version
-      AC_MSG_CHECKING([whether version of ccache is suitable])
-      CCACHE_VERSION=`"$CCACHE" -V | "$AWK" '/^ccache version/{print $3}'`
-      CCACHE_NUMVER=`echo $CCACHE_VERSION | $AWK -F. '{ print \$1*10000+\$2*100+\$3 }'`
-      if test "$CCACHE_VERSION" = "2.4_OOo" -o "$CCACHE_NUMVER" -ge "030100"; then
-         AC_MSG_RESULT([yes])
-         AC_MSG_CHECKING([whether ccache is actually used for the build])
-         AC_LANG_PUSH([C++])
-         save_CXXFLAGS=$CXXFLAGS
-         CXXFLAGS="$CXXFLAGS --ccache-skip -O2"
-         dnl an empty program will do, we're checking the compiler flags
-         AC_COMPILE_IFELSE([AC_LANG_PROGRAM([],[])],
-            [use_ccache=yes], [use_ccache=no])
-         if test $use_ccache = yes ; then
-            AC_MSG_RESULT([yes, will enable --ccache-skip])
-            AC_SUBST([USE_CCACHE], [YES])
-         else
-            AC_MSG_RESULT([no, will not enable --ccache-skip])
-         fi
-         CXXFLAGS=$save_CXXFLAGS
-         AC_LANG_POP([C++])
-      else
-         AC_MSG_RESULT([no])
-         AC_MSG_NOTICE([ccache version $CCACHE_VERSION not accepted. ccache will not be used.])
-      fi
-   fi
+    AC_MSG_RESULT([only used on Mac currently, skipping])
+else
+    # checking for ccache presence/version
+    AC_MSG_RESULT([probing...])
+    AC_PATH_PROG([CCACHE],[ccache],[not_found])
+    if test "$CCACHE" = "not_found" ; then
+        AC_MSG_NOTICE([not enabling --ccache-skip (ccache not found)])
+    else
+        # check ccache version
+        AC_MSG_CHECKING([whether version of ccache is suitable])
+        CCACHE_VERSION=`"$CCACHE" -V | "$AWK" '/^ccache version/{print $3}'`
+        CCACHE_NUMVER=`echo $CCACHE_VERSION | $AWK -F. '{ print \$1*10000+\$2*100+\$3 }'`
+        if test "$CCACHE_VERSION" = "2.4_OOo" -o "$CCACHE_NUMVER" -ge "030100"; then
+            AC_MSG_RESULT([yes])
+            AC_MSG_CHECKING([whether ccache is actually used for the build])
+            AC_LANG_PUSH([C++])
+            save_CXXFLAGS=$CXXFLAGS
+            CXXFLAGS="$CXXFLAGS --ccache-skip -O2"
+            dnl an empty program will do, we're checking the compiler flags
+            AC_COMPILE_IFELSE([AC_LANG_PROGRAM([],[])],
+                [use_ccache=yes], [use_ccache=no])
+            if test $use_ccache = yes ; then
+                AC_MSG_RESULT([yes, will enable --ccache-skip])
+                AC_SUBST([USE_CCACHE], [YES])
+            else
+                AC_MSG_RESULT([no, will not enable --ccache-skip])
+            fi
+            CXXFLAGS=$save_CXXFLAGS
+            AC_LANG_POP([C++])
+        else
+            AC_MSG_RESULT([no])
+            AC_MSG_NOTICE([ccache version $CCACHE_VERSION not accepted. ccache will not be used.])
+        fi
+    fi
 fi
 
 dnl ===================================================================
@@ -3179,43 +3193,48 @@ dnl ===================================================================
 HAVE_GCC_VISIBILITY_BROKEN=
 if test \( "$_os" != "WINNT" -o "$WITH_MINGW" = "yes" \) ; then
 
-   AC_LANG_PUSH([C++])
-
-   if test "$HAVE_GCC_VISIBILITY_FEATURE" = "TRUE"; then
-      AC_MSG_CHECKING([if STL headers are visibility safe])
-      AC_EGREP_HEADER(visibility push, string, stlvisok=yes, stlvisok=no)
-      AC_MSG_RESULT([$stlvisok])
-      if test "$stlvisok" = "no"; then
-         AC_MSG_WARN([Your gcc STL headers are not visibility safe. Disabling visibility])
-         echo "Your gcc STL headers are not visibility safe. Disabling visibility" >> warn
-         unset HAVE_GCC_VISIBILITY_FEATURE
-      fi
-   fi
-
-   if test "$HAVE_GCC_VISIBILITY_FEATURE" = "TRUE"; then
-      sharedlink_ldflags_save=$LDFLAGS
-      LDFLAGS="$LDFLAGS -fvisibility-inlines-hidden -fpic -shared"
-
-      AC_MSG_CHECKING([if gcc is -fvisibility-inlines-hidden safe with STL headers])
-      AC_TRY_LINK([#include <sstream>
+    AC_LANG_PUSH([C++])
+
+    if test "$HAVE_GCC_VISIBILITY_FEATURE" = "TRUE"; then
+        AC_MSG_CHECKING([if STL headers are visibility safe])
+        AC_EGREP_HEADER(visibility push, string, stlvisok=yes, stlvisok=no)
+        AC_MSG_RESULT([$stlvisok])
+        if test "$stlvisok" = "no"; then
+            AC_MSG_WARN([Your gcc STL headers are not visibility safe. Disabling visibility])
+            echo "Your gcc STL headers are not visibility safe. Disabling visibility" >> warn
+            unset HAVE_GCC_VISIBILITY_FEATURE
+        fi
+    fi
+
+    if test "$HAVE_GCC_VISIBILITY_FEATURE" = "TRUE"; then
+        sharedlink_ldflags_save=$LDFLAGS
+        LDFLAGS="$LDFLAGS -fvisibility-inlines-hidden -fpic -shared"
+
+        AC_MSG_CHECKING([if gcc is -fvisibility-inlines-hidden safe with STL headers])
+        AC_TRY_LINK(
+            [
+#include <sstream>
 using namespace std;
-],[istringstream strm( "test" ); return 0;],
-      $EGREP -q  unresolvable conftest.err;
-      if test $? -eq 0; then gccvisok=no; else gccvisok=yes; fi,
-      gccvisok=no)
-      AC_MSG_RESULT([$gccvisok])
-      if test "$gccvisok" = "no"; then
-         AC_MSG_WARN([Your gcc is not -fvisibility-inlines-hidden safe, disabling that.])
-         echo "Your gcc is not -fvisibility-inlines-hidden safe, disabling that." >> warn
-         HAVE_GCC_VISIBILITY_BROKEN="TRUE"
-      fi
-
-      LDFLAGS=$sharedlink_ldflags_save
-   fi
-
-   if test "$HAVE_GCC_VISIBILITY_FEATURE" = "TRUE"; then
-      AC_MSG_CHECKING([if gcc has a visibility bug with class-level attributes (GCC bug 26905)])
-      cat >visibility.cxx <<_ACEOF
+            ],[
+istringstream strm( "test" ); return 0;
+            ],
+            $EGREP -q  unresolvable conftest.err;
+            if test $? -eq 0; then gccvisok=no; else gccvisok=yes; fi,
+            gccvisok=no
+        )
+        AC_MSG_RESULT([$gccvisok])
+        if test "$gccvisok" = "no"; then
+            AC_MSG_WARN([Your gcc is not -fvisibility-inlines-hidden safe, disabling that.])
+            echo "Your gcc is not -fvisibility-inlines-hidden safe, disabling that." >> warn
+            HAVE_GCC_VISIBILITY_BROKEN="TRUE"
+        fi
+
+        LDFLAGS=$sharedlink_ldflags_save
+    fi
+
+    if test "$HAVE_GCC_VISIBILITY_FEATURE" = "TRUE"; then
+        AC_MSG_CHECKING([if gcc has a visibility bug with class-level attributes (GCC bug 26905)])
+        cat >visibility.cxx <<_ACEOF
 #pragma GCC visibility push(hidden)
 struct __attribute__ ((visibility ("default"))) TestStruct {
   static void Init();
@@ -3224,37 +3243,37 @@ __attribute__ ((visibility ("default"))) void TestFunc() {
   TestStruct::Init();
 }
 _ACEOF
-      if ! $CXX $CXXFLAGS $CPPFLAGS -fpic -S visibility.cxx 2>/dev/null > /dev/null; then
-         gccvisbroken=yes
-      else
-         case "$host_cpu" in
+        if ! $CXX $CXXFLAGS $CPPFLAGS -fpic -S visibility.cxx 2>/dev/null > /dev/null; then
+            gccvisbroken=yes
+        else
+            case "$host_cpu" in
             i?86|x86_64)
-               if test "$_os" = "Darwin"; then
-                  gccvisbroken=no
-               else
-                  if $EGREP -q '@PLT' visibility.s; then
-                     gccvisbroken=no
-                  else
-                     gccvisbroken=yes
-                  fi
-               fi
-               ;;

... etc. - the rest is truncated


More information about the Libreoffice-commits mailing list