--- rpl/Attic/configure.in 2010/09/07 12:54:03 1.41 +++ rpl/Attic/configure.in 2011/06/27 14:01:48 1.68 @@ -1,5 +1,5 @@ dnl Process this file with autoconf to produce a configure script. -AC_INIT([rpl],[4.0.19]) +AC_INIT([rpl],[4.1.0]) AC_CANONICAL_TARGET AC_CANONICAL_TARGET AM_INIT_AUTOMAKE @@ -7,16 +7,23 @@ AC_SUBST(target_cpu) AC_CONFIG_HEADERS([rplconfig.h]) dnl Libraries -NCURSES=ncurses-5.7-20100619 -READLINE=readline-6.1 +NCURSES=ncurses-5.9 +READLINE=readline-6.2 UNITS=units-1.88 -GSL=gsl-1.14 +GSL=gsl-1.15 GPP=gpp-2.24 -GNUPLOT=gnuplot-4.4.0 +GNUPLOT=gnuplot-4.4.3 FILE=file-5.03 ICONV=libiconv-1.13.1 -SQLITE=sqlite-3.7.2 -OPENSSL=openssl-1.0.0a +SQLITE=sqlite-3.7.6.3 +OPENSSL=openssl-1.0.0d + +GMP=gmp-5.0.1 +MPFR=mpfr-3.0.1 +NTL=ntl-5.5.2 +COCOA=CoCoALib-0.9943 +PARI=pari-2.3.5 +GIAC=giac-0.9.1 dnl Checks for C compiler AC_PROG_CC(gcc) @@ -107,6 +114,19 @@ if test "$ac_x_libraries" != "no"; then fi fi +dnl 32 bits ABI +AC_ARG_WITH(32bits, +[ --with-32bits-abi force 32bits ABI (multilib)],[ +if test "$with-32bits-abi" = "no"; then +else + ABI=-m32 +fi],[ + ABI=-m32 + ] +) + +SUBST(ABI) + dnl Options AC_ARG_ENABLE(optimization, [ --enable-optimization set compiler flags [[default=environment variables -O3]]], [ @@ -237,12 +257,9 @@ AC_ARG_ENABLE(debug, [ --enable-debug enable debug code [[default=no]]], [ if test "$enableval" = "no"; then DEBUG="-UDEBUG_MEMOIRE -UDEBUG_ERREURS" - MALLOC="\$(top_builddir)/ptmalloc3/libptmalloc3.a" else DEBUG="-DDEBUG_MEMOIRE -UDEBUG_ERREURS" - MALLOC="" -fi], [DEBUG="-UDEBUG_MEMOIRE -UDEBUG_ERREURS" - MALLOC="\$(top_builddir)/ptmalloc3/libptmalloc3.a"]) +fi], [DEBUG="-UDEBUG_MEMOIRE -UDEBUG_ERREURS"]) AC_ARG_ENABLE(profile, [ --enable-profile enable profile code [[default=no]]], [ @@ -260,6 +277,10 @@ fi if test ! -d "$srcdir"/tools/$NCURSES; then gunzip -c "$srcdir"/tools/$NCURSES.tar.gz | \ (cd "$srcdir/tools" && tar -xf -) + (cd "$srcdir/tools/"$NCURSES && \ + for i in ../$NCURSES*.patch.gz; + do gunzip -c $i | patch -p1; + done); fi if test ! -d "$srcdir"/tools/$READLINE; then gunzip -c "$srcdir"/tools/$READLINE.tar.gz | \ @@ -295,12 +316,38 @@ fi if test ! -d "$srcdir"/tools/$SQLITE; then gunzip -c "$srcdir"/tools/$SQLITE.tar.gz | \ (cd "$srcdir/tools" && tar -xf -) - (cd "$srcdir/tools"/$SQLITE && gunzip -c ../$SQLITE.diff.gz | patch -p1) fi if test ! -d tools/$OPENSSL; then gunzip -c "$srcdir"/tools/$OPENSSL.tar.gz | \ (cd tools && tar -xf -) fi +if test ! -d rplcas; then + mkdir rplcas +fi +if test ! -d "$srcdir"/rplcas/$GMP; then + gunzip -c "$srcdir"/rplcas/$GMP.tar.gz | \ + (cd "$srcdir/rplcas" && tar -xf -) +fi +if test ! -d "$srcdir"/rplcas/$MPFR; then + gunzip -c "$srcdir"/rplcas/$MPFR.tar.gz | \ + (cd "$srcdir/rplcas" && tar -xf -) +fi +if test ! -d rplcas/$NTL; then + gunzip -c "$srcdir"/rplcas/$NTL.tar.gz | \ + (cd rplcas && tar -xf -) +fi +if test ! -d rplcas/$COCOA; then + gunzip -c "$srcdir"/rplcas/$COCOA.tar.gz | \ + (cd rplcas && tar -xf -) +fi +if test ! -d rplcas/$PARI; then + gunzip -c "$srcdir"/rplcas/$PARI.tar.gz | \ + (cd rplcas && tar -xf -) +fi +if test ! -d "$srcdir"/rplcas/$GIAC; then + gunzip -c "$srcdir"/rplcas/$GIAC.tar.gz | \ + (cd "$srcdir/rplcas" && tar -xf -) +fi dnl Default installation directory AC_PREFIX_DEFAULT(/usr/local) @@ -761,6 +808,37 @@ AC_SUBST(POSTGRESQL_SUPPORT) AC_SUBST(libPgSQLinc) AC_SUBST(libPgSQLlib) +# with_postgresql : check [pas défini], yes [uniquement --with], +# no [--without], valeur [--with=valeur]. +AC_ARG_WITH(bourne_shell, +[ --with-bourne-shell=PATH specify path for OS/2 bourne shell], +[], [with_bourne_shell=no]) + +if test "x$with_bourne_shell" = xyes; then + AC_MSG_ERROR([You have to specify a valide shell path !]) +fi + +if test "x$with_bourne_shell" = xno; then + if test $(uname) = "OS/2"; then + AC_MSG_ERROR([With OS/2 or eComstation, you have to specify a valide shell path !]) + fi + + BSH_PATH= +else + if test ! -x $with_bourne_shell; then + AC_MSG_ERROR([$with_bourne_shell is not executable !]) + fi + + if test $(uname) = "OS/2"; then + with_os2_bourne_shell=$(echo $with_bourne_shell | \ + sed -e '1,$s/\//\\\\\\\\/g') + BSH_PATH=-DBOURNE_SHELL=\"\\\"$with_os2_bourne_shell\\\"\" + else + AC_MSG_WARN([--with-bourne-shell ignored]) + BSH_PATH= + fi +fi + dnl Checks for sizes AC_CHECK_SIZEOF(void *, 4) AC_CHECK_SIZEOF(char, 1) @@ -918,6 +996,7 @@ AC_SUBST(OS) DATE_FR=$(env LC_ALL=fr_FR date +'%A %x, %X %Z') DATE=$(env LC_ALL=C date +'%A %x, %X %Z') +MALLOC= case $OS in @@ -928,7 +1007,7 @@ case $OS in IPCS_SYSV=-UIPCS_SYSV CXXFLAGS="$CXXFLAGS -D_GLIBCXX_FULLY_DYNAMIC_STRING" ac_configure_args="$ac_configure_args --with-readline=builtin \ - --disable-shared --enable-static" + --disable-shared --enable-static --enable-threads" C_STANDARD=-std=gnu99 break ;; @@ -938,7 +1017,7 @@ case $OS in SEMAPHORES_NOMMES=-USEMAPHORES_NOMMES IPCS_SYSV=-UIPCS_SYSV ac_configure_args="$ac_configure_args --with-readline=builtin \ - --disable-shared --enable-static" + --disable-shared --enable-static --enable-threads" C_STANDARD=-std=gnu99 break ;; @@ -948,7 +1027,7 @@ case $OS in SEMAPHORES_NOMMES=-USEMAPHORES_NOMMES IPCS_SYSV=-UIPCS_SYSV ac_configure_args="$ac_configure_args --with-readline=builtin \ - --disable-shared --enable-static" + --disable-shared --enable-static --enable-threads" C_STANDARD=-std=gnu99 break;; @@ -958,12 +1037,11 @@ case $OS in SEMAPHORES_NOMMES=-DSEMAPHORES_NOMMES IPCS_SYSV=-UIPCS_SYSV ac_configure_args="$ac_configure_args --with-readline=builtin \ - --disable-shared --enable-static" + --disable-shared --enable-static --enable-threads" C_STANDARD=-std=gnu99 break ;; OS/2) - MALLOC= if test $FORCED_FINAL_ENCODING -eq 0; then \ FINAL_ENCODING=CP850; \ fi; @@ -973,7 +1051,8 @@ case $OS in SEMAPHORES_NOMMES=-USEMAPHORES_NOMMES IPCS_SYSV=-DIPCS_SYSV ac_configure_args="$ac_configure_args --without-readline \ - --without-cairo --disable-shared --enable-static" + --without-cairo --disable-shared --enable-static \ + --enable-threads" C_STANDARD= break;; @@ -986,10 +1065,27 @@ case $OS in SEMAPHORES_NOMMES=-USEMAPHORES_NOMMES IPCS_SYSV=-DIPCS_SYSV ac_configure_args="$ac_configure_args --with-readline=builtin \ - --disable-shared --enable-static" + --disable-shared --enable-static --enable-threads" C_STANDARD=-std=gnu99 break;; + SunOS) + EXPORT_DYNAMIC=-Wl,--export-dynamic + NESTED_FUNCTIONS= + SEMAPHORES_NOMMES=-USEMAPHORES_NOMMES + + if test $IPCS_SYSV = no; then + IPCS_SYSV=-UIPCS_SYSV + else + IPCS_SYSV=-DIPCS_SYSV + fi + + ac_configure_args="$ac_configure_args --with-readline=builtin \ + --disable-shared --enable-static --enable-threads" + C_STANDARD=-std=gnu99 + MALLOC=-lumem + break ;; + *) EXPORT_DYNAMIC=-Wl,--export-dynamic NESTED_FUNCTIONS= @@ -1002,7 +1098,7 @@ case $OS in fi ac_configure_args="$ac_configure_args --with-readline=builtin \ - --disable-shared --enable-static" + --disable-shared --enable-static --enable-threads" C_STANDARD=-std=gnu99 break ;; @@ -1016,6 +1112,7 @@ AC_SUBST(IPCS_SYSV) AC_SUBST(SEMUN) AC_SUBST(IPV6) AC_SUBST(BROKEN_SIGINFO) +AC_SUBST(BSH_PATH) AC_SUBST(NCURSES) AC_SUBST(READLINE) @@ -1030,8 +1127,14 @@ AC_SUBST(OPENSSL) AC_SUBST(FINAL_ENCODING) AC_SUBST(DATE) AC_SUBST(DATE_FR) -AC_SUBST(MALLOC) AC_SUBST(EXT_SQL) +AC_SUBST(MALLOC) +AC_SUBST(GMP) +AC_SUBST(MPFR) +AC_SUBST(NTL) +AC_SUBST(COCOA) +AC_SUBST(PARI) +AC_SUBST(GIAC) AC_SUBST(CFLAGS) AC_SUBST(CXXFLAGS) @@ -1052,10 +1155,10 @@ AC_CONFIG_FILES(scripts/rpllink) AC_CONFIG_FILES(rpltags/Makefile) AC_CONFIG_FILES(rpliconv/Makefile) AC_CONFIG_FILES(rplsums/Makefile) +AC_CONFIG_FILES(rplcas/Makefile) AC_CONFIG_FILES(rplawk/Makefile) AC_CONFIG_FILES(lapack/lapack/Makefile) AC_CONFIG_FILES(lapack/blas/Makefile) -AC_CONFIG_FILES(ptmalloc3/Makefile) AC_CONFIG_FILES(man/rpl.1) AC_CONFIG_FILES(man/rplcc.1)