Re: [Libreoffice] [PATCH] update configure.in

2011-09-03 Thread Peter Foley

Sorry, but I just found a bug in this patch please disregard it.
I'll send a revised version shortly.

Thanks,

Peter
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH] update configure.in

2011-09-03 Thread Peter Foley

This patch updates configure.in using recomendations from autoupdate 
2.68.
It also raises the required version of autoconf from 2.50 to 2.58
because versions of autoconf less then 2.58 don't work with the current 
configure.in.
It also moves the generation of ooo.lst next to the other generated files 
so that config.status is only generated once.

From 89798c9f8661e7ab1a180424cdb7d8cc42fd Mon Sep 17 00:00:00 2001
From: Peter Foley pefol...@verizon.net
Date: Sat, 3 Sep 2011 20:23:32 -0400
Subject: [PATCH] update configure.in

---
 configure.in |  114 --
 1 files changed, 47 insertions(+), 67 deletions(-)
 mode change 100755 = 100644 configure.in

diff --git a/configure.in b/configure.in
old mode 100755
new mode 100644
index f2c3cba..7ab4995
--- a/configure.in
+++ b/configure.in
@@ -2,8 +2,8 @@ dnl -*- Mode: Autoconf; tab-width: 8; indent-tabs-mode: nil -*-
 dnl configure.in serves as input for the GNU autoconf package
 dnl in order to create a configure script.
 
-AC_INIT([LibreOffice], [3.5],,, [http://documentfoundation.org/])
-AC_PREREQ(2.50)
+AC_INIT([LibreOffice],[3.5],[],[],[http://documentfoundation.org/])
+AC_PREREQ([2.58])
 echo $@ config.parms
 
 dnl ===
@@ -1466,7 +1466,7 @@ echo 
 dnl ===
 dnl checks build and host OSes
 dnl ===
-AC_CANONICAL_SYSTEM
+AC_CANONICAL_HOST
 
 if test $cross_compiling = yes; then
 CROSS_COMPILING=YES
@@ -3035,7 +3035,7 @@ if test $GXX = yes; then
 
 if test $_gpp_majmin = 304; then
 AC_MSG_CHECKING([whether $CXX has the enum bug])
-AC_TRY_RUN([
+AC_RUN_IFELSE([AC_LANG_SOURCE([[
 extern C void abort (void);
 extern C void exit (int status);
 
@@ -3054,8 +3054,7 @@ if test $GXX = yes; then
 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])])
+]])],[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
 
@@ -3274,12 +3273,10 @@ _ACEOF
 AC_LANG_PUSH([C++])
 
 AC_MSG_CHECKING([for dynamic libgcc])
-AC_TRY_LINK([
+AC_LINK_IFELSE([AC_LANG_PROGRAM([[
 #include iostream
 using namespace std;
-],  
-[ try { throw 42; } catch (int e) { cout  Yep,   e  endl; } ],
-[   
+]], [[ try { throw 42; } catch (int e) { cout  Yep,   e  endl; } 
]])],[   
 MINGW_GCCDLL=`$OBJDUMP -p conftest.exe | grep 'DLL Name: libgcc' | 
$SED -e 's@.*DLL Name: @@'`
 if test -n $MINGW_GCCDLL; then
 MINGW_SHARED_GCCLIB=YES
@@ -3288,18 +3285,15 @@ using namespace std;
 MINGW_SHARED_GCCLIB=NO
 AC_MSG_RESULT([no])
 fi
-   ],
-   [ AC_MSG_RESULT([no])
-   ]
-)
+   ],[ AC_MSG_RESULT([no])
+   
+])
 
 AC_MSG_CHECKING([for dynamic libstdc++])
-AC_TRY_LINK([
+AC_LINK_IFELSE([AC_LANG_PROGRAM([[
 #include iostream
 using namespace std;
-],  
-[ cout  Hello there.  endl; ],
-[   
+]], [[ cout  Hello there.  endl; ]])],[   
 MINGW_GXXDLL=`$OBJDUMP -p conftest.exe | grep 'DLL Name: 
libstdc++' | $SED -e 's@.*DLL Name: @@'`
 if test -n $MINGW_GXXDLL; then
 mingw_gxxdll_root=${MINGW_GXXDLL%.dll}
@@ -3311,10 +3305,9 @@ using namespace std;
 MINGW_SHARED_GXXLIB=NO
 AC_MSG_RESULT([no])
 fi
-   ],
-   [ AC_MSG_RESULT([no])
-   ]
-)
+   ],[ AC_MSG_RESULT([no])
+   
+])
 
 AC_LANG_POP([C++])
 
@@ -3348,16 +3341,12 @@ dnl 
*
 if test $WITH_MINGW = yes; then
 AC_MSG_CHECKING([exception type])
 AC_LANG_PUSH([C++])
-AC_TRY_LINK(
-[#include iostream
+AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include iostream
 
 extern C void _Unwind_SjLj_RaiseException(void) __attribute__ 
((__noreturn__));
 
-],
-[_Unwind_SjLj_RaiseException() ],
-[exceptions_type=sjlj],
-[exceptions_type=dwarf2]
-)
+]], [[_Unwind_SjLj_RaiseException() 
]])],[exceptions_type=sjlj],[exceptions_type=dwarf2
+])
 AC_MSG_RESULT($exceptions_type)
 AC_LANG_POP([C++])
 fi
@@ -3422,7 +3411,7 @@ if test $GCC = yes; then
 AC_MSG_CHECKING([whether $CC supports -fvisibility=hidden])
 save_CFLAGS=$CFLAGS
 CFLAGS=$CFLAGS -Werror -fvisibility=hidden
-AC_TRY_LINK([], [