Annotation of rpl/configure.ac, revision 1.124

1.1       bertrand    1: dnl Process this file with autoconf to produce a configure script.
1.123     bertrand    2: AC_INIT([rpl],[4.1.22])
1.1       bertrand    3: AC_CANONICAL_TARGET
                      4: AC_CANONICAL_TARGET
1.8       bertrand    5: AM_INIT_AUTOMAKE(silent-rules)
1.9       bertrand    6: AM_SILENT_RULES([yes])
1.1       bertrand    7: AC_SUBST(target_cpu)
                      8: AC_CONFIG_HEADERS([rplconfig.h])
                      9: 
                     10: dnl Libraries
                     11: NCURSES=ncurses-5.9
1.87      bertrand   12: READLINE=readline-6.3
1.119     bertrand   13: UNITS=units-2.11
1.76      bertrand   14: GSL=gsl-1.16
1.1       bertrand   15: GPP=gpp-3.0
1.107     bertrand   16: GNUPLOT=gnuplot-5.0.0
1.23      bertrand   17: FILE=file-5.11
1.60      bertrand   18: ICONV=libiconv-1.14
1.121     bertrand   19: SQLITE=sqlite-3.8.10.2
1.118     bertrand   20: OPENSSL=openssl-1.0.2a
1.48      bertrand   21: OPENMOTIF=openmotif-2.3.4
1.1       bertrand   22: LIBXPM=libXpm-3.5.9
1.31      bertrand   23: SIGSEGV=libsigsegv-2.11
1.113     bertrand   24: ZLIB=zlib-1.2.8
1.1       bertrand   25: 
1.94      bertrand   26: GMP=gmp-6.0.0
1.64      bertrand   27: MPFR=mpfr-3.1.2
1.1       bertrand   28: NTL=ntl-5.5.2
1.29      bertrand   29: COCOA=CoCoALib-0.9950
1.73      bertrand   30: PARI=pari-2.5.4
1.110     bertrand   31: GIAC=giac-1.1.4
1.1       bertrand   32: 
1.33      bertrand   33: dnl 32 bits ABI
                     34: AC_ARG_WITH(gcc_version,
                     35: [  --with-gcc-version      force gcc version],[
                     36: CC=gcc-$with_gcc_version
                     37: CXX=g++-$with_gcc_version
                     38: CF=gfortran-$with_gcc_version
                     39: F77=gfortran-$with_gcc_version
1.43      bertrand   40: AC_SUBST(CC)
                     41: AC_SUBST(CXX)
                     42: AC_SUBST(CF)
                     43: AC_SUBST(F77)
1.33      bertrand   44: ],[])
                     45: 
1.37      bertrand   46: dnl Checks for Bash
1.100     bertrand   47: BASH_PATH=$(which bash)
1.37      bertrand   48: BASH=$(which bash | sed 's/\//\\\//g')
                     49: 
                     50: if test x$BASH = x; then
                     51:    AC_MSG_ERROR([Cannot find bash! You have to install it.])
                     52: fi
                     53: 
                     54: AC_SUBST(BASH)
1.100     bertrand   55: AC_SUBST(BASH_PATH)
1.37      bertrand   56: 
1.1       bertrand   57: dnl Checks for C compiler
                     58: AC_PROG_CC(gcc)
                     59: 
                     60: EXT_SQL=
                     61: 
                     62: AM_PROG_CC_C_O
                     63: 
                     64: if test "$GCC" != yes; then
                     65:    AC_MSG_ERROR([Cannot find gcc! You have to install it.])
                     66: fi
                     67: 
                     68: dnl Checks for C++ compiler
                     69: AC_PROG_CXX(g++)
                     70: 
1.2       bertrand   71: if test "$GXX" != yes; then
1.1       bertrand   72:    AC_MSG_ERROR([Cannot find g++! You have to install it.])
                     73: fi
                     74: 
                     75: dnl Checks for Fortran 77 compiler
                     76: AC_PROG_F77(gfortran)
                     77: 
1.3       bertrand   78: dnl Check for Fortran 9* compiler
                     79: AC_PROG_FC(gfortran)
                     80: 
1.92      bertrand   81: if test x"$F77" = x; then
1.1       bertrand   82:    AC_MSG_ERROR([Cannot find gfortran! You have to install it.])
                     83: fi
                     84: 
1.92      bertrand   85: if test x"$FC" = x; then
1.1       bertrand   86:    AC_MSG_ERROR([Cannot find gfortran! You have to install it.])
                     87: fi
                     88: 
1.33      bertrand   89: OPTIMISATION_C=-O3
                     90: OPTIMISATION_CXX=-O3
                     91: OPTIMISATION_F=-O3
1.1       bertrand   92: 
                     93: dnl X paths
                     94: AC_PATH_X
                     95: AC_PATH_XTRA
                     96: 
                     97: if test "$ac_x_includes" != "no"; then
                     98:    if test x"$ac_x_includes" != x; then
                     99:        X_CFLAGS="$X_CFLAGS -I$ac_x_includes"
                    100:        includeX="-I$ac_x_includes"
                    101:    fi
                    102: fi
                    103: if test "$ac_x_libraries" != "no"; then
                    104:    if test x"$ac_x_libraries" != x; then
                    105:        X_LIBS="$X_LIBS -L$ac_x_libraries"
                    106:    fi
                    107: fi
                    108: 
                    109: dnl 32 bits ABI
                    110: AC_ARG_WITH(32bits-abi,
                    111: [  --with-32bits-abi       force 32bits ABI (multilib)],[
1.23      bertrand  112: if test "$with_32bits_abi" = "no"; then
1.1       bertrand  113:    ABI=
                    114: else
                    115:    ABI=-m32
                    116: fi],[
                    117:    ABI=
                    118:    ]
                    119: )
                    120: 
                    121: if test x$ABI = x; then
                    122: AC_ARG_WITH(64bits-abi,
                    123: [  --with-64bits-abi       force 64bits ABI (multilib)],[
1.23      bertrand  124: if test "$with_64bits_abi" = "no"; then
1.1       bertrand  125:    ABI=
                    126: else
                    127:    ABI=-m64
                    128: fi],[
                    129:    ABI=
                    130:    ]
                    131: )
                    132: fi
                    133: 
                    134: LDFLAGS="$LDFLAGS $ABI"
                    135: 
1.23      bertrand  136: AC_ARG_WITH(sysroot,
                    137: [  --with-sysroot          sysroot for cross compilation],[
                    138: if test "$with_sysroot" = "no" -o "$with_rpltools" = "yes"; then
                    139:    AC_MSG_ERROR([You have to specify sysroot path !])
                    140: else
1.24      bertrand  141:    SYSROOT="-I$with_sysroot/usr/include"
1.25      bertrand  142:    SYSROOT2=$with_sysroot
1.23      bertrand  143: fi],[
                    144:    SYSROOT=
1.25      bertrand  145:    SYSROOT2=
1.23      bertrand  146:    ]
                    147: )
                    148: 
1.6       bertrand  149: AC_ARG_ENABLE(recursive,
                    150: [  --enable-recursive      recursive configuration (default=yes)],[
                    151: if test "$enableval" = "yes"; then
                    152:    RECURSIVE=yes
                    153: else
                    154:    RECURSIVE=no
                    155: fi],[
                    156:    RECURSIVE=yes
                    157:    ]
                    158: )
                    159: 
1.3       bertrand  160: AC_ARG_WITH(rpltools,
                    161: [  --with-rpltools         specify rpltools path used for cross compilation],[
1.23      bertrand  162: if test "$with_rpltools" = "no" -o "$with_rpltools" = "yes"; then
1.3       bertrand  163:    AC_MSG_ERROR([You have to specify rpltools path !])
                    164: else
                    165:    RPLTOOLS=$with_rpltools
                    166: fi],[
                    167:    RPLTOOLS=\$\(top_builddir\)
                    168:    ]
                    169: )
                    170: 
                    171: AC_SUBST(RPLTOOLS)
                    172: 
1.1       bertrand  173: dnl RPL/CAS support
1.3       bertrand  174: AC_ARG_ENABLE(rplcas,
                    175: [  --enable-rplcas         compile rplcas (default=no)],[
                    176: if test "$enableval" = "no"; then
1.1       bertrand  177:    RPLCAS=-URPLCAS
                    178:    LIBRPLCAS=
1.95      bertrand  179:    INCRPLCAS=
1.1       bertrand  180: else
                    181:    RPLCAS=-DRPLCAS
                    182:    LIBRPLCAS=\$\(top_builddir\)/rplcas/lib/librplcas.a
1.95      bertrand  183:    INCRPLCAS="-I\$(top_builddir)/rplcas/include/giac \
                    184:            -I\$(top_builddir)/rplcas/include"
1.1       bertrand  185: fi],[
                    186:    RPLCAS=-URPLCAS
                    187:    LIBRPLCAS=
1.95      bertrand  188:    INCRPLCAS=
1.1       bertrand  189:    ]
                    190: )
                    191: 
                    192: AC_SUBST(ABI)
                    193: AC_SUBST(RPLCAS)
                    194: AC_SUBST(LIBRPLCAS)
1.95      bertrand  195: AC_SUBST(INCRPLCAS)
1.1       bertrand  196: 
                    197: dnl Options
                    198: AC_ARG_ENABLE(optimization,
                    199: [  --enable-optimization   set compiler flags [[default=environment variables -O3]]], [
                    200: if test "$enableval" = "no"; then
                    201:    CFLAGS=$ABI
                    202:    FFLAGS=$ABI
                    203:    CXXFLAGS=$ABI
                    204:    FCFLAGS=$ABI
                    205: else
                    206:    CFLAGS="$CFLAGS $ABI $enable_optimization"
                    207:    FFLAGS="$FFLAGS $ABI $enable_optimization"
                    208:    CXXFLAGS="$CXXFLAGS $ABI $enable_optimization"
                    209:    FCFLAGS="$FCFLAGS $ABI $enable_optimization"
                    210: fi],[
1.93      bertrand  211:    CFLAGS="$CFLAGS $ABI $OPTIMISATION_C" 
1.1       bertrand  212:    FFLAGS="$FFLAGS $ABI $OPTIMISATION_F"
                    213:    CXXFLAGS="$CXXFLAGS $ABI $OPTIMISATION_CXX"
                    214:    FCFLAGS="$FCFLAGS $ABI $OPTIMISATION_F"
                    215:    ]
                    216: )
                    217: 
1.93      bertrand  218: CFLAGS="$CFLAGS -fno-strict-overflow"
                    219: 
1.6       bertrand  220: AC_MSG_CHECKING([for usable shared memory])
                    221: AC_COMPILE_IFELSE(
                    222:    [AC_LANG_PROGRAM([#include <sys/shm.h>
                    223:     ],
                    224:    [ return(0); ])],
                    225: [SHARED_MEMORY=-DSHARED_MEMORY; AC_MSG_RESULT(yes)],
                    226: [SHARED_MEMORY=-USHARED_MEMORY; AC_MSG_RESULT(no)]
                    227:    )
                    228: AC_SUBST(SHARED_MEMORY)
                    229: 
1.116     bertrand  230: AC_C_INLINE
                    231: 
                    232: if test "$ac_cv_c_inline" != no ; then
                    233:    AC_DEFINE(HAVE_INLINE,1,[inline keywork or macro available])
                    234:     AC_SUBST(HAVE_INLINE)
                    235: fi
                    236: 
1.6       bertrand  237: AC_MSG_CHECKING([for pselect])
1.7       bertrand  238: AC_COMPILE_IFELSE(
1.6       bertrand  239:    [AC_LANG_PROGRAM([#include <sys/select.h>
                    240:     #include <unistd.h>
                    241:     #include <sys/time.h>
                    242:     #include <sys/types.h>
                    243:     ],
                    244:    [
                    245:     struct timespec tv;
                    246:     fd_set s1, s2, s3;
                    247:     tv.tv_sec=1;
                    248:     tv.tv_nsec=0;
                    249:     FD_SET(1, &s1); FD_SET(2, &s2); FD_SET(3, &s3);
                    250:     pselect(5, &s1, &s2, &s3, &tv, NULL);
                    251:     return(0);
                    252:    ])],
                    253: [PSELECT=-DPSELECT; AC_MSG_RESULT(yes)],
                    254: [PSELECT=-UPSELECT; AC_MSG_RESULT(no)]
                    255:    )
                    256: AC_SUBST(PSELECT)
                    257: 
1.2       bertrand  258: AC_ARG_ENABLE(sysv-ipcs,
1.1       bertrand  259: [  --enable-sysv-ipcs      use SystemV IPC functions [[default=guessed]]], [
                    260: if test "$enableval" = "no"; then
1.3       bertrand  261:    IPCS_SYSV=-UIPCS_SYSV
                    262:    POSIX_IPCS=no
1.1       bertrand  263: else
1.3       bertrand  264:    IPCS_SYSV=-DIPCS_SYSV
                    265:    POSIX_IPCS=yes
1.1       bertrand  266: fi],
1.91      bertrand  267: REG=$LIBS
1.3       bertrand  268: POSIX_IPCS=guessed
1.91      bertrand  269: LIBS="-lrt -lpthread"
1.1       bertrand  270: [AC_MSG_CHECKING([for POSIX semaphores and shared objects])
1.23      bertrand  271: AC_LINK_IFELSE(
1.1       bertrand  272: [AC_LANG_PROGRAM([#include <sys/mman.h>
                    273: #include <sys/stat.h>
                    274: #include <fcntl.h>
                    275:  ],
                    276: [ int fd; char *sem = "/test";
                    277: fd = shm_open(sem , O_CREAT | O_RDWR, S_IRUSR | S_IWUSR);
                    278:   close(fd);
                    279:   shm_unlink(sem);
                    280:   fd = sem_open(sem, O_CREAT | O_RDWR, S_IRUSR | S_IWUSR, 0);
                    281:   close(fd);
                    282:   sem_unlink(sem);
                    283:   return(0);
                    284: ])],
                    285: [IPCS_SYSV=-UIPCS_SYSV; AC_MSG_RESULT(yes)],
                    286: [IPCS_SYSV=-DIPCS_SYSV; AC_MSG_RESULT(no)]
                    287:    )]
1.91      bertrand  288: LIBS=$REG
1.1       bertrand  289: )
                    290: 
1.3       bertrand  291: if test "$IPCS_SYSV" = "-UIPCS_SYSV" -a "$POSIX_IPCS" = "guessed"; then
1.91      bertrand  292: REG=$LIBS
                    293: LIBS=-pthread
1.1       bertrand  294: AC_MSG_CHECKING([for POSIX anonymous semaphores])
1.23      bertrand  295: AC_LINK_IFELSE(
1.1       bertrand  296: [AC_LANG_PROGRAM([#include <semaphore.h>
                    297:  ],
                    298: [ sem_t sem;
                    299:  if (sem_init(&sem, 1, 0) != 0) return(1);
                    300:  sem_destroy(&sem);
                    301:   return(0);
                    302: ])],
                    303: [SEMAPHORES_NOMMES=-USEMAPHORES_NOMMES; AC_MSG_RESULT(yes)],
                    304: [SEMAPHORES_NOMMES=-DSEMAPHORES_NOMMES; AC_MSG_RESULT(no)]
                    305:    )
1.91      bertrand  306: LDFLAGS=$LIBS
1.1       bertrand  307: REG=""
                    308: else
                    309:    SEMAPHORES_NOMMES=-USEMAPHORES_NOMMES
                    310: fi
                    311: 
                    312: AC_ARG_ENABLE(full-static,
                    313: [  --enable-full-static    build static RPL/2 engine [[default=shared]]], [
                    314: if test "$enableval" = "no"; then
                    315:    STATIC=no
                    316: else
                    317:    STATIC=yes
                    318: fi],
                    319: STATIC=no)
                    320: 
                    321: AC_ARG_ENABLE(final-encoding,
                    322: [  --enable-final-encoding force final encoding [[default=guessed]]], [
                    323: if test "$enableval" = "no"; then
                    324:    FINAL_ENCODING="\$(shell locale charmap | \
                    325:        \$(AWK) '/\=/ { print \$\$3;} !/\=/ { print \$\$1;}')"
                    326:    FORCED_FINAL_ENCODING=0
                    327: else
                    328:    FINAL_ENCODING="$enable_final_encoding"
                    329:    FORCED_FINAL_ENCODING=1
                    330: fi], [
                    331: FORCED_FINAL_ENCODING=0
                    332: FINAL_ENCODING="\$(shell locale charmap | \
                    333:    \$(AWK) '/\=/ { print \$\$3;} !/\=/ { print \$\$1;}')"])
                    334: 
                    335: AC_ARG_ENABLE(tex,
                    336: [  --enable-tex            provide the TeX support [[default=guessed]]], [
                    337: if test "$enableval" = "no"; then
                    338:    TEX_SUPPORT=no
                    339: else
                    340:    TEX_SUPPORT=yes
                    341: fi],
                    342: TEX_SUPPORT=guessed)
                    343: 
                    344: AC_ARG_ENABLE(vim,
                    345: [  --enable-vim            provide the vim support [[default=guessed]]], [
                    346: if test "$enableval" = "no"; then
                    347:    VIM_SUPPORT=no
1.16      bertrand  348:    DEBVIM=
1.1       bertrand  349: else
                    350:    VIM_SUPPORT=yes
1.17      bertrand  351:    DEBVIM=", vim"
1.1       bertrand  352: fi],
                    353: VIM_SUPPORT=guessed)
                    354: 
                    355: AC_ARG_ENABLE(embedded-gnuplot,
                    356: [  --enable-embedded-gnuplot build gnuplot provided by this package [[default=yes]]], [
                    357: if test "$enableval" = "no"; then
                    358:    MYGNUPLOT=no
                    359: else
                    360:    MYGNUPLOT=yes
                    361: fi], [
                    362: MYGNUPLOT=yes])
                    363: 
                    364: AC_ARG_ENABLE(gnuplot,
                    365: [  --enable-gnuplot        provide the GnuPlot support [[default=guessed]]],
                    366: [
                    367: if test "$enableval" = "no"; then
                    368:    GNUPLOT_SUPPORT=no
                    369:    MYGNUPLOT=no
                    370:    FORCE_GNUPLOT_PATH=-UFORCE_GNUPLOT_PATH
                    371: else
                    372:    GNUPLOT_SUPPORT=yes
                    373:    FORCE_GNUPLOT_PATH=-DFORCE_GNUPLOT_PATH
                    374: fi], [
                    375: if test "$MYGNUPLOT" = "yes"; then
                    376:    GNUPLOT_SUPPORT=yes
                    377:    FORCE_GNUPLOT_PATH=-DFORCE_GNUPLOT_PATH
                    378: else
                    379:    GNUPLOT_SUPPORT=guessed
                    380:    FORCE_GNUPLOT_PATH=-UFORCE_GNUPLOT_PATH
                    381: fi])
                    382: 
                    383: libX=""
                    384: LIBMOTIF=""
                    385: INCMOTIF=""
                    386: BUILD_OPENMOTIF=""
                    387: 
                    388: AC_ARG_ENABLE(motif,
                    389: [  --enable-motif          provide the Motif support [[default=guessed]]], [
                    390: if test "$enableval" = "no"; then
                    391:    MOTIF_SUPPORT="-UMOTIF_SUPPORT"
                    392: else
                    393:    MOTIF_SUPPORT="-DMOTIF_SUPPORT"
                    394: fi],
1.92      bertrand  395: if test "$have_x" = "yes"; then
1.1       bertrand  396:    MOTIF_SUPPORT="-DMOTIF_SUPPORT"
                    397: else
                    398:    MOTIF_SUPPORT="-UMOTIF_SUPPORT"
                    399: fi)
                    400: 
                    401: if test "$MOTIF_SUPPORT" = "-DMOTIF_SUPPORT"; then
1.19      bertrand  402:    libX="$X_LIBS -lXt -lX11 -lXext"
1.1       bertrand  403:    LIBMOTIF="\$(top_builddir)/tools/$OPENMOTIF/lib/Xm/.libs/libXm.a \
                    404:            \$(top_builddir)/tools/$LIBXPM/src/.libs/libXpm.a"
                    405:    INCMOTIF="-I\$(top_srcdir)/tools/$OPENMOTIF/lib \
                    406:            -I\$(top_builddir)/tools/$OPENMOTIF/lib \
1.8       bertrand  407:            -I\$(top_srcdir)/tools/$LIBXPM/include"
1.1       bertrand  408:    BUILD_OPENMOTIF="$LIBXPM $OPENMOTIF"
1.6       bertrand  409: 
                    410:    if test $RECURSIVE = yes; then
                    411:        AC_CONFIG_SUBDIRS(tools/$LIBXPM)
                    412:        AC_CONFIG_SUBDIRS(tools/$OPENMOTIF)
                    413:    fi;
1.1       bertrand  414: fi
                    415: 
                    416: AC_ARG_ENABLE(experimental,
                    417: [  --enable-experimental   enable experimental code [[default=no]]], [
                    418: if test "$enableval" = "no"; then
                    419:    EXPERIMENTAL_CODE="-UEXPERIMENTAL_CODE"
                    420: else
                    421:    EXPERIMENTAL_CODE="-DEXPERIMENTAL_CODE"
                    422: fi],
                    423: EXPERIMENTAL_CODE="-UEXPERIMENTAL_CODE")
                    424: 
                    425: AC_ARG_ENABLE(debug,
                    426: [  --enable-debug          enable debug code [[default=no]]], [
                    427: if test "$enableval" = "no"; then
                    428:    DEBUG="-UDEBUG_MEMOIRE -UDEBUG_ERREURS"
                    429: else
                    430:    DEBUG="-DDEBUG_MEMOIRE -UDEBUG_ERREURS"
                    431: fi], [DEBUG="-UDEBUG_MEMOIRE -UDEBUG_ERREURS"])
                    432: 
                    433: AC_ARG_ENABLE(profile,
                    434: [  --enable-profile        enable profile code [[default=no]]], [
                    435: if test "$enableval" = "no"; then
                    436:    PROFILAGE=""
                    437: else
                    438:    PROFILAGE="-pg"
                    439: fi], [PROFILAGE=""])
                    440: 
                    441: AC_SUBST(PROFILAGE)
                    442: 
1.48      bertrand  443: dnl Checks for uuencode
                    444: AC_CHECK_PROG(UUENCODE, uuencode, yes, no)
                    445: if test "$UUENCODE" = no; then
                    446:    AC_MSG_ERROR([Can not find uuencode !])
                    447: fi
                    448: 
1.1       bertrand  449: if test ! -d tools; then
                    450:    mkdir tools
                    451: fi
                    452: if test ! -d "$srcdir"/tools/$NCURSES; then
                    453:    gunzip -c "$srcdir"/tools/$NCURSES.tar.gz | \
                    454:            (cd "$srcdir/tools" && tar -xf -)
                    455:    (cd "$srcdir/tools/"$NCURSES && \
1.13      bertrand  456:            for i in ../$NCURSES*.sh.gz;
1.15      bertrand  457:            do TMP=$i; gunzip -c $i > ${TMP%.*};
1.13      bertrand  458:            done;
                    459:            for i in ../$NCURSES*.sh;
1.24      bertrand  460:            do echo Applying script $i && chmod 775 $i && ./$i;
1.13      bertrand  461:            done;
1.1       bertrand  462:            for i in ../$NCURSES*.patch.gz;
1.98      bertrand  463:            do echo Applying patch $i && \
                    464:                    if test $i = "../ncurses-5.9-20140607.patch.gz" ; then \
                    465:                        rm -f Ada95/src/library.gpr; \
1.122     bertrand  466:                    elif test $i = "../ncurses-5.9-20150516.patch.gz"; then \
                    467:                        rm -f doc/html/man/adacurses-config.1.html;
1.98      bertrand  468:                    fi && \
                    469:                gunzip -c $i | patch -p1;
1.1       bertrand  470:            done);
                    471: fi
                    472: if test ! -d "$srcdir"/tools/$READLINE; then
                    473:    gunzip -c "$srcdir"/tools/$READLINE.tar.gz | \
                    474:            (cd "$srcdir/tools" && tar -xf -)
                    475: fi
                    476: if test ! -d "$srcdir"/tools/$UNITS; then
                    477:    gunzip -c "$srcdir"/tools/$UNITS.tar.gz | \
                    478:            (cd "$srcdir/tools" && tar -xf -)
                    479: fi
                    480: if test ! -d "$srcdir"/tools/$GSL; then
                    481:    gunzip -c "$srcdir"/tools/$GSL.tar.gz | \
                    482:            (cd "$srcdir/tools" && tar -xf -)
                    483:    if test $(uname) = "OS/2"; then
                    484:        (cd "$srcdir"/tools/$GSL; \
                    485:                TMP=$(mktemp tmp.XXXXXXXXXX); \
                    486:                sed -e '1,$s/\${1+"\$@"}/"\$@"/g' ltmain.sh > $TMP; \
                    487:                \mv -f $TMP ltmain.sh)
                    488:    fi
                    489: fi
                    490: if test ! -d "$srcdir"/tools/$GPP; then
                    491:    gunzip -c "$srcdir"/tools/$GPP.tar.gz | \
                    492:            (cd "$srcdir/tools" && tar -xf -)
                    493: fi
                    494: if test ! -d "$srcdir"/tools/$FILE; then
                    495:    gunzip -c "$srcdir"/tools/$FILE.tar.gz | \
                    496:            (cd "$srcdir/tools" && tar -xf - )
1.23      bertrand  497:    (cd "$srcdir/tools"/$FILE && gunzip -c ../$FILE.diff.gz | patch -p1 && \
                    498:            autoreconf)
1.1       bertrand  499: fi
                    500: if test ! -d "$srcdir"/tools/$SQLITE; then
                    501:    gunzip -c "$srcdir"/tools/$SQLITE.tar.gz | \
                    502:            (cd "$srcdir/tools" && tar -xf -)
                    503: fi
                    504: if test ! -d "$srcdir"/tools/$SIGSEGV; then
                    505:    gunzip -c "$srcdir"/tools/$SIGSEGV.tar.gz | \
                    506:            (cd "$srcdir/tools" && tar -xf -)
1.32      bertrand  507:    (cd "$srcdir/tools/$SIGSEGV" && ./autogen.sh --skip-gnulib)
1.1       bertrand  508: fi
1.36      bertrand  509: if test ! -d "$srcdir"/tools/$ICONV; then
                    510:    gunzip -c "$srcdir"/tools/$ICONV.tar.gz | \
                    511:            (cd "$srcdir/tools" && tar -xf -)
1.38      bertrand  512:    (cd "$srcdir"/tools/$ICONV && ln -sf ../$SIGSEGV/gnulib gnulib)
1.36      bertrand  513: fi
1.1       bertrand  514: if test ! -d "$srcdir"/tools/$OPENMOTIF; then
                    515:    gunzip -c "$srcdir"/tools/$OPENMOTIF.tar.gz | \
                    516:            (cd "$srcdir/tools" && tar -xf -)
                    517: fi
                    518: if test ! -d "$srcdir"/tools/$LIBXPM; then
                    519:    gunzip -c "$srcdir"/tools/$LIBXPM.tar.gz | \
                    520:            (cd "$srcdir/tools" && tar -xf -)
                    521: fi
                    522: if test ! -d tools/$OPENSSL; then
                    523:    gunzip -c "$srcdir"/tools/$OPENSSL.tar.gz | \
                    524:            (cd tools && tar -xf -)
                    525: fi
1.62      bertrand  526: if test ! -d tools/$ZLIB; then
                    527:    gunzip -c "$srcdir"/tools/$ZLIB.tar.gz | \
                    528:            (cd tools && tar -xf - && cd $ZLIB && ./configure --static)
                    529: fi
1.1       bertrand  530: if test ! -d rplcas; then
                    531:    mkdir rplcas
                    532: fi
                    533: if test ! -d "$srcdir"/rplcas/$GMP; then
                    534:    gunzip -c "$srcdir"/rplcas/$GMP.tar.gz | \
                    535:            (cd "$srcdir/rplcas" && tar -xf -)
                    536: fi
                    537: if test ! -d "$srcdir"/rplcas/$MPFR; then
                    538:    gunzip -c "$srcdir"/rplcas/$MPFR.tar.gz | \
                    539:            (cd "$srcdir/rplcas" && tar -xf -)
                    540: fi
                    541: if test ! -d rplcas/$NTL; then
                    542:    gunzip -c "$srcdir"/rplcas/$NTL.tar.gz | \
                    543:            (cd rplcas && tar -xf -)
                    544: fi
                    545: if test ! -d rplcas/$COCOA; then
                    546:    gunzip -c "$srcdir"/rplcas/$COCOA.tar.gz | \
                    547:            (cd rplcas && tar -xf -)
                    548: fi
                    549: if test ! -d rplcas/$PARI; then
                    550:    gunzip -c "$srcdir"/rplcas/$PARI.tar.gz | \
                    551:            (cd rplcas && tar -xf -)
                    552: fi
                    553: if test ! -d "$srcdir"/rplcas/$GIAC; then
                    554:    gunzip -c "$srcdir"/rplcas/$GIAC.tar.gz | \
                    555:            (cd "$srcdir/rplcas" && tar -xf -)
                    556: fi
                    557: 
                    558: touch tools/openmotif.lib
                    559: 
                    560: dnl Default installation directory
                    561: AC_PREFIX_DEFAULT(/usr/local)
                    562: 
                    563: dnl Set final install path
                    564: AC_ARG_ENABLE(final-run-path,
                    565:              [  --enable-final-run-path=PATH enable another final run path than PREFIX], [
                    566:    if test "x$enable_final_run_path" = "x"; then
                    567:        AC_MSG_NOTICE("No path with --enable-final-run-path.")
                    568:        AC_MSG_ERROR("You should specify final path !")
                    569:    else
                    570:        RUNPATH="$enable_final_run_path"
                    571:    fi
                    572: ],
                    573: RUNPATH="\${prefix}"
                    574: )
                    575: AC_SUBST(RUNPATH)
                    576: 
                    577: dnl Checks for programs
                    578: AC_PROG_INSTALL
                    579: AC_PROG_LN_S
                    580: AC_PROG_MAKE_SET
                    581: AC_PROG_RANLIB
                    582: 
                    583: dnl Checks for nawk
                    584: AC_CHECK_PROG(AWK, nawk, yes, no)
                    585: if test "$AWK" = no; then
                    586:    AC_CHECK_PROG(AWK, gawk, yes, no)
                    587:    if test "$AWK" = no; then
                    588:        AC_MSG_ERROR([Can not find nawk !])
                    589:    fi
                    590: fi
                    591: 
                    592: dnl Checks for sed
                    593: AC_CHECK_PROG(SED, sed, yes, no)
                    594: if test "$SED" = no; then
                    595:    AC_MSG_ERROR([Can not find sed !])
                    596: fi
                    597: 
1.48      bertrand  598: dnl Checks for yacc
                    599: AC_CHECK_PROG(YACC, yacc, yes, no)
                    600: if test "$YACC" = no; then
                    601:    AC_MSG_ERROR([Can not find yacc !])
                    602: fi
                    603: 
1.1       bertrand  604: dnl Checks for TeX, LaTeX, dvips, gs, gv, vim and gnuplot
                    605: if test "$TEX_SUPPORT" = guessed; then
                    606:    POSTSCRIPT_SUPPORT="-DPOSTSCRIPT_SUPPORT"
                    607: 
                    608:    AC_CHECK_PROG(TEX, tex, yes, no)
                    609:    if test "$TEX" = no; then
                    610:        AC_MSG_WARN([Cannot find TeX! You may install it.
                    611: Download at http://tex.loria.fr/
                    612: ])
                    613:        POSTSCRIPT_SUPPORT="-UPOSTSCRIPT_SUPPORT"
                    614:    fi
                    615: 
                    616:    AC_CHECK_PROG(LATEX, latex, yes, no)
                    617:    if test "$LATEX" = no; then
                    618:        AC_MSG_WARN([Cannot find LaTeX! You may install it.
                    619: Download at http://tex.loria.fr/
                    620: ])
                    621:        POSTSCRIPT_SUPPORT="-UPOSTSCRIPT_SUPPORT"
                    622:    fi
                    623: 
                    624:    AC_CHECK_PROG(DVIPS, dvips, yes, no)
                    625:    if test "$DVIPS" = no; then
                    626:        AC_MSG_WARN([Cannot find dvips! You may install it.
                    627: Download at http://tex.loria.fr/
                    628: ])
                    629:        POSTSCRIPT_SUPPORT="-UPOSTSCRIPT_SUPPORT"
                    630:    fi
                    631: 
                    632:    AC_CHECK_PROG(GS, gs, yes, no)
                    633:    if test "$GS" = no; then
                    634:        AC_MSG_WARN([Cannot find gs! You may install it.
                    635: Download at http://ftp.lip6.fr/
                    636: ])
                    637:        POSTSCRIPT_SUPPORT="-UPOSTSCRIPT_SUPPORT"
                    638:    fi
                    639: 
                    640:    AC_CHECK_PROG(GV, gv, yes, no)
                    641:    if test "$GV" = no; then
                    642:        AC_MSG_WARN([Cannot find gv! You may install it.
                    643: Download at http://ftp.lip6.fr/
                    644: ])
                    645:        POSTSCRIPT_SUPPORT="-UPOSTSCRIPT_SUPPORT"
                    646:    fi
                    647: else
                    648:    if test "$TEX_SUPPORT" = no; then
                    649:        POSTSCRIPT_SUPPORT="-UPOSTSCRIPT_SUPPORT"
                    650:    else
                    651:        POSTSCRIPT_SUPPORT="-DPOSTSCRIPT_SUPPORT"
                    652:    fi
                    653: fi
                    654: 
                    655: if test "$GNUPLOT_SUPPORT" = guessed; then
                    656:    AC_CHECK_PROG(GNUPLOT_P, gnuplot, yes, no)
                    657:    if test "$GNUPLOT_P" = no; then
                    658:        AC_MSG_WARN([Cannot find gnuplot! You may install it.
                    659: Download at http://www.gnuplot.vt.edu/
                    660: ])
                    661:        GNUPLOT_SUPPORT="-UGNUPLOT_SUPPORT"
                    662:    else
                    663:        GNUPLOT_SUPPORT="-DGNUPLOT_SUPPORT"
                    664:    fi
                    665: else
                    666:    if test "$GNUPLOT_SUPPORT" = no; then
                    667:        GNUPLOT_SUPPORT="-UGNUPLOT_SUPPORT"
                    668:    else
                    669:        GNUPLOT_SUPPORT="-DGNUPLOT_SUPPORT"
                    670:    fi
                    671: fi
                    672: 
                    673: if test "$VIM_SUPPORT" = guessed; then
                    674:    AC_CHECK_PROG(VIM, vim, yes, no)
                    675:    if test "$VIM" = no; then
                    676:        AC_MSG_WARN([Cannot find vim! You may install it.
                    677: Download at http://www.vim.org/
                    678: ])
                    679:        VIM_SUPPORT="-UVIM_SUPPORT"
1.16      bertrand  680:        DEBVIM=
1.1       bertrand  681:    else
                    682:        VIM_SUPPORT="-DVIM_SUPPORT"
1.18      bertrand  683:        DEBVIM=", vim"
1.1       bertrand  684:    fi
                    685: else
                    686:    if test "$VIM_SUPPORT" = no; then
                    687:        VIM_SUPPORT="-UVIM_SUPPORT"
1.16      bertrand  688:        DEBVIM=
1.1       bertrand  689:    else
                    690:        VIM_SUPPORT="-DVIM_SUPPORT"
1.18      bertrand  691:        DEBVIM=", vim"
1.1       bertrand  692:    fi
                    693: fi
                    694: 
                    695: dnl Substitutions
                    696: AC_SUBST(GNUPLOT_SUPPORT)
                    697: AC_SUBST(FORCE_GNUPLOT_PATH)
                    698: AC_SUBST(POSTSCRIPT_SUPPORT)
                    699: AC_SUBST(VIM_SUPPORT)
                    700: AC_SUBST(EXPERIMENTAL_CODE)
                    701: AC_SUBST(DEBUG)
                    702: AC_SUBST(MOTIF_SUPPORT)
                    703: AC_SUBST(libX)
                    704: AC_SUBST(includeX)
                    705: 
                    706: dnl Date
1.124   ! bertrand  707: DATE=$(env LC_ALL=C date +"%A, %e %B %Y %T %z")
        !           708: DATE_FR=$(env LC_ALL=fr_FR date +"%A, %e %B %Y %T %z")
1.1       bertrand  709: AC_SUBST(DATE)
1.124   ! bertrand  710: AC_SUBST(DATE_FR)
1.1       bertrand  711: 
                    712: dnl Checks for libraries
                    713: AC_CHECK_LIB(m, main,, AC_MSG_ERROR([Can not find libm !]))
1.2       bertrand  714: AC_CHECK_LIB(c, pthread_mutex_init,,
                    715:             [AC_CHECK_LIB(pthread, main,,
                    716:             AC_MSG_ERROR([Can not find libpthread !]))])
1.1       bertrand  717: 
                    718: dnl Check for union semun
                    719: AC_CHECK_TYPE([union semun], SEMUN=-DUNION_SEMUN, SEMUN=-UUNION_SEMUN, [[
                    720: #include <sys/sem.h>
                    721: ]])
                    722: 
                    723: dnl Check for IPv6 support
                    724: AC_CHECK_TYPE([struct sockaddr_in6], IPV6=-DIPV6, IPV6=-UIPV6, [[
                    725: #include <sys/types.h>
                    726: #include <netinet/in.h>
                    727: ]])
                    728: 
                    729: dnl Do we need to use -ldl?
                    730: if test "$CYGWIN" != yes; then
                    731:    AC_CHECK_LIB(dl, dlopen, LIBS="$LIBS -ldl",
                    732:            AC_MSG_WARN([libdl doesn't seem to be needed on this system.]))
                    733: fi
                    734: 
                    735: dnl Do we need to use -lrt?
                    736: AC_CHECK_LIB(rt, nanosleep, LIBS="$LIBS -lrt",
                    737:        AC_MSG_WARN([librt doesn't seem to be needed on this system.]))
                    738: 
1.79      bertrand  739: AC_CHECK_LIB(rt, shm_open, LIBS="$LIBS -lrt",
                    740:        AC_MSG_WARN([librt doesn't seem to be needed on this system.]))
                    741: 
                    742: AC_CHECK_LIB(pthread, pthread_create, LIBS="$LIBS -lpthread",
                    743:        AC_MSG_WARN([libpthread doesn't seem to be needed on this system.]))
                    744: 
1.1       bertrand  745: dnl Do we need to use -lsocket?
                    746: AC_CHECK_LIB(socket, bind, LIBS="$LIBS -lsocket",
                    747:        AC_MSG_WARN([libsocket doesn't seem to be needed on this system.]))
                    748: 
                    749: dnl Check for SQL libraries
                    750: MYSQL_SUPPORT="-UMYSQL_SUPPORT"
                    751: AC_ARG_WITH(mysql,
                    752: [  --with-mysql=PATH         specify directory for installed mysql],
                    753: [], [with_mysql=check])
                    754: 
                    755: if test "x$with_mysql" = xcheck -o "x$with_mysql" = yes; then
                    756:    libMySQLinc="-I/usr/include"
                    757:    libMySQLlib="/usr/lib"
                    758: 
                    759:    AC_MSG_CHECKING(for libmysql includes in /usr/include)
                    760:    saved_CFLAGS="$CFLAGS"
                    761:    CFLAGS="$CFLAGS -L/$libMySQLinc"
                    762:    AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "mysql.h"]], [[]])],[AC_MSG_RESULT([yes]); MYSQL_SUPPORT="-DMYSQL_SUPPORT";
                    763:                    libMySQLinc=$libMySQLinc/mysql],[AC_MSG_RESULT([no]); MYSQL_SUPPORT="-UMYSQL_SUPPORT"])
                    764:    CFLAGS=$saved_CFLAGS
                    765: 
                    766:    if test "$MYSQL_SUPPORT" = "-UMYSQL_SUPPORT"; then
                    767:        AC_MSG_CHECKING(for libmysql includes in /usr/include/mysql)
                    768:        saved_CFLAGS="$CFLAGS"
                    769:        CFLAGS="$CFLAGS $libMySQLinc/mysql"
                    770:        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "mysql.h"]], [[]])],[AC_MSG_RESULT([yes]); MYSQL_SUPPORT="-DMYSQL_SUPPORT";
                    771:                        libMySQLinc=$libMySQLinc],[AC_MSG_RESULT([no]); MYSQL_SUPPORT="-UMYSQL_SUPPORT"])
                    772:        CFLAGS=$saved_CFLAGS
                    773:        libMySQLinc=$libMySQLinc/mysql
                    774:    fi
                    775: 
                    776:    if test "$MYSQL_SUPPORT" = "-UMYSQL_SUPPORT"; then
                    777:        AC_MSG_CHECKING(for libmysql includes in /usr/local/include)
                    778:        saved_CFLAGS="$CFLAGS"
                    779:        CFLAGS="$CFLAGS $libMySQLinc/../local/include"
                    780:        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "mysql.h"]], [[]])],[AC_MSG_RESULT([yes]); MYSQL_SUPPORT="-DMYSQL_SUPPORT";
                    781:                        libMySQLinc=$libMySQLinc/mysql],[AC_MSG_RESULT([no]); MYSQL_SUPPORT="-UMYSQL_SUPPORT"])
                    782:        CFLAGS=$saved_CFLAGS
                    783:        libMySQLinc=$libMySQLinc/../local/include
                    784:        libMySQLlib=$libMySQLlib/../local/lib
                    785:    fi
                    786: 
                    787:    if test "$MYSQL_SUPPORT" = "-UMYSQL_SUPPORT"; then
                    788:        AC_MSG_CHECKING(for libmysql includes in /usr/local/include/mysql)
                    789:        saved_CFLAGS="$CFLAGS"
                    790:        CFLAGS="$CFLAGS $libMySQLinc/../local/include/mysql"
                    791:        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "mysql.h"]], [[]])],[AC_MSG_RESULT([yes]); MYSQL_SUPPORT="-DMYSQL_SUPPORT";
                    792:                        libMySQLinc=$libMySQLinc/mysql],[AC_MSG_RESULT([no]); MYSQL_SUPPORT="-UMYSQL_SUPPORT"])
                    793:        CFLAGS=$saved_CFLAGS
                    794:        libMySQLinc=$libMySQLinc/../local/include/mysql
                    795:        libMySQLlib=$libMySQLlib/../local/lib
                    796:    fi
                    797: else
                    798:    if test "x$with_mysql" != xno; then
                    799:        libMySQLinc="-I$with_mysql/include"
                    800:        libMySQLlib="$with_mysql/lib"
                    801: 
                    802:        AC_MSG_CHECKING(for libmysql includes in $with_mysql)
                    803:        saved_CFLAGS="$CFLAGS"
                    804:        CFLAGS="$CFLAGS $libMySQLinc"
                    805:        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "mysql.h"]], [[]])],[AC_MSG_RESULT([yes]); MYSQL_SUPPORT="-DMYSQL_SUPPORT";
                    806:                        libMySQLinc=$libMySQLinc/mysql],[AC_MSG_RESULT([no]); MYSQL_SUPPORT="-UMYSQL_SUPPORT"])
                    807:        CFLAGS=$saved_CFLAGS
                    808: 
                    809:        if test "$MYSQL_SUPPORT" = "-UMYSQL_SUPPORT"; then
                    810:            AC_MSG_CHECKING(for libmysql includes in $with_mysql/mysql)
                    811:            saved_CFLAGS="$CFLAGS"
                    812:            CFLAGS="$CFLAGS $libMySQLinc/mysql"
                    813:            AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "mysql.h"]], [[]])],[AC_MSG_RESULT([yes]); MYSQL_SUPPORT="-DMYSQL_SUPPORT";
                    814:                            libMySQLinc=$libMySQLinc],[AC_MSG_RESULT([no]); MYSQL_SUPPORT="-UMYSQL_SUPPORT"])
                    815:            CFLAGS=$saved_CFLAGS
                    816:            libMySQLinc=$libMySQLinc/mysql
                    817:        fi
                    818:    else
                    819:        MYSQL_SUPPORT="-UMYSQL_SUPPORT"
                    820:    fi
                    821: fi
                    822: 
                    823: if test "$MYSQL_SUPPORT" = "-DMYSQL_SUPPORT"; then
                    824:    MYSQL_LIB=no
                    825: 
                    826:    if test $MYSQL_LIB = no; then
                    827:        AC_MSG_CHECKING(for libmysql libraries in $libMySQLlib)
                    828:        saved_LIBS="$LIBS"
                    829:        if test $STATIC = no; then
                    830:            LIBS="$LIBS -L/$libMySQLlib -lmysqlclient_r $libMySQLinc"
                    831:        else
1.86      bertrand  832:            LIBS="$LIBS $libMySQLlib/libmysqlclient_r.a $libMySQLinc"
1.1       bertrand  833:        fi
                    834:        AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include "mysql.h"]], [[MYSQL mysql; mysql_init(&mysql);]])],[AC_MSG_RESULT([yes]); MYSQL_LIB="yes"],[AC_MSG_RESULT([no]); MYSQL_LIB="no"])
                    835:        LIBS=$saved_LIBS;
                    836:        if test $STATIC = no; then
                    837:            libMySQLlib="-L/$libMySQLlib -lmysqlclient_r"
                    838:        else
                    839:            libMySQLlib="$libMySQLlib/libmysqlclient_r.a"
                    840:            EXT_SQL="$EXT_SQL $libMySQLlib"
                    841:        fi
                    842:    fi
                    843: 
                    844:    if test $MYSQL_LIB = no; then
                    845:        MYSQL_SUPPORT="-UMYSQL_SUPPORT"
                    846:    fi
                    847: fi
                    848: 
1.16      bertrand  849: DEBMYSQL=
                    850: 
1.1       bertrand  851: if test "$MYSQL_SUPPORT" != "-DMYSQL_SUPPORT"; then
                    852:    libMySQLinc=
                    853:    libMySQLlib=
1.16      bertrand  854: else
1.17      bertrand  855:    DEBMYSQL=", libmysqlclient18"
1.1       bertrand  856: fi
                    857: 
                    858: AC_SUBST(MYSQL_SUPPORT)
                    859: AC_SUBST(libMySQLinc)
                    860: AC_SUBST(libMySQLlib)
                    861: 
                    862: POSTGRESQL_SUPPORT=-UPOSTGRESQL_SUPPORT
                    863: AC_ARG_WITH(postgresql,
                    864: [  --with-postgresql=PATH    specify directory for installed postgresql],
                    865: [], [with_postgresql=check])
                    866: 
                    867: # with_postgresql : check [pas défini], yes [uniquement --with],
                    868: # no [--without], valeur [--with=valeur].
                    869: 
                    870: if test "x$with_postgresql" = xcheck -o "x$with_postgresql" = xyes; then
                    871:    libPgSQLinc="-I/usr/include"
                    872:    libPgSQLlib="/usr/lib"
                    873: 
                    874:    AC_MSG_CHECKING(for libpq includes in /usr/include)
                    875:    saved_CFLAGS="$CFLAGS"
                    876:    CFLAGS="$CFLAGS $libPgSQLinc"
                    877:    AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "libpq-fe.h"]], [[]])],[AC_MSG_RESULT([yes]); POSTGRESQL_SUPPORT="-DPOSTGRESQL_SUPPORT"],[AC_MSG_RESULT([no]); POSTGRESQL_SUPPORT="-UPOSTGRESQL_SUPPORT"])
                    878:    CFLAGS=$saved_CFLAGS
                    879: 
                    880:    if test "$POSTGRESQL_SUPPORT" = "-UPOSTGRESQL_SUPPORT"; then
                    881:        AC_MSG_CHECKING(for libpq includes in /usr/include/postgresql)
                    882:        saved_CFLAGS="$CFLAGS"
                    883:        CFLAGS="$CFLAGS $libPgSQLinc/postgresql"
                    884:        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "libpq-fe.h"]], [[]])],[AC_MSG_RESULT([yes]);
                    885:                POSTGRESQL_SUPPORT="-DPOSTGRESQL_SUPPORT"],[AC_MSG_RESULT([no]);
                    886:                POSTGRESQL_SUPPORT="-UPOSTGRESQL_SUPPORT"])
                    887:        CFLAGS=$saved_CFLAGS
                    888:        libPgSQLinc=$libPgSQLinc/postgresql
                    889:    fi
                    890: 
                    891:    if test "$POSTGRESQL_SUPPORT" = "-UPOSTGRESQL_SUPPORT"; then
                    892:        AC_MSG_CHECKING(for libpq includes in /usr/include/pgsql)
                    893:        saved_CFLAGS="$CFLAGS"
                    894:        CFLAGS="$CFLAGS $libPgSQLinc/pgsql"
                    895:        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "libpq-fe.h"]], [[]])],[AC_MSG_RESULT([yes]);
                    896:                POSTGRESQL_SUPPORT="-DPOSTGRESQL_SUPPORT"],[AC_MSG_RESULT([no]);
                    897:                POSTGRESQL_SUPPORT="-UPOSTGRESQL_SUPPORT"])
                    898:        CFLAGS=$saved_CFLAGS
                    899:        libPgSQLinc=$libPgSQLinc/pgsql
                    900:    fi
                    901: 
                    902:    if test "$POSTGRESQL_SUPPORT" = "-UPOSTGRESQL_SUPPORT"; then
                    903:        AC_MSG_CHECKING(for libpq includes in /usr/local/include)
                    904:        saved_CFLAGS="$CFLAGS"
                    905:        CFLAGS="$CFLAGS $libPgSQLinc/../local/include"
                    906:        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "libpq-fe.h"]], [[]])],[AC_MSG_RESULT([yes]);
                    907:                POSTGRESQL_SUPPORT="-DPOSTGRESQL_SUPPORT"],[AC_MSG_RESULT([no]);
                    908:                POSTGRESQL_SUPPORT="-UPOSTGRESQL_SUPPORT"])
                    909:        CFLAGS=$saved_CFLAGS
                    910:        libPgSQLinc=$libPgSQLinc/../local/include
                    911:        libPgSQLlib=$libPgSQLlib/../local/lib
                    912:    fi
                    913: 
                    914:    if test "$POSTGRESQL_SUPPORT" = "-UPOSTGRESQL_SUPPORT"; then
                    915:        AC_MSG_CHECKING(for libpq includes in /usr/local/include/postgresql)
                    916:        saved_CFLAGS="$CFLAGS"
                    917:        CFLAGS="$CFLAGS $libPgSQLinc/../local/include/postgresql"
                    918:        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "libpq-fe.h"]], [[]])],[AC_MSG_RESULT([yes]);
                    919:                POSTGRESQL_SUPPORT="-DPOSTGRESQL_SUPPORT"],[AC_MSG_RESULT([no]);
                    920:                POSTGRESQL_SUPPORT="-UPOSTGRESQL_SUPPORT"])
                    921:        CFLAGS=$saved_CFLAGS
                    922:        libPgSQLinc=$libPgSQLinc/../local/include/postgresql
                    923:        libPgSQLlib=$libPgSQLlib/../local/lib
                    924:    fi
                    925: 
                    926:    if test "$POSTGRESQL_SUPPORT" = "-UPOSTGRESQL_SUPPORT"; then
                    927:        AC_MSG_CHECKING(for libpq includes in /usr/local/include/pgsql)
                    928:        saved_CFLAGS="$CFLAGS"
                    929:        CFLAGS="$CFLAGS $libPgSQLinc/../local/include/pgsql"
                    930:        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "libpq-fe.h"]], [[]])],[AC_MSG_RESULT([yes]);
                    931:                POSTGRESQL_SUPPORT="-DPOSTGRESQL_SUPPORT"],[AC_MSG_RESULT([no]);
                    932:                POSTGRESQL_SUPPORT="-UPOSTGRESQL_SUPPORT"])
                    933:        CFLAGS=$saved_CFLAGS
                    934:        libPgSQLinc=$libPgSQLinc/local/include/pgsql
                    935:        libPgSQLlib=$libPgSQLlib/../local/lib
                    936:    fi
                    937: else
                    938:    if test "x$with_postgresql" != xno; then
                    939:        libPgSQLinc="-I$with_postgresql/include"
                    940:        libPgSQLlib="$with_postgresql/lib"
                    941: 
                    942:        AC_MSG_CHECKING(for libpq includes in $libPgSQLinc)
                    943:        saved_CFLAGS="$CFLAGS"
                    944:        CFLAGS="$CFLAGS $libPgSQLinc"
                    945:        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "libpq-fe.h"]], [[]])],[AC_MSG_RESULT([yes]);
                    946:                POSTGRESQL_SUPPORT="-DPOSTGRESQL_SUPPORT"],[AC_MSG_RESULT([no]);
                    947:                POSTGRESQL_SUPPORT="-UPOSTGRESQL_SUPPORT"])
                    948:        CFLAGS=$saved_CFLAGS
                    949: 
                    950:        if test "$POSTGRESQL_SUPPORT" = "-UPOSTGRESQL_SUPPORT"; then
                    951:            AC_MSG_CHECKING(for libpq includes in $libPgSQLinc/postgresql)
                    952:            saved_CFLAGS="$CFLAGS"
                    953:            CFLAGS="$CFLAGS $libPgSQLinc/postgresql"
                    954:            AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "libpq-fe.h"]], [[]])],[AC_MSG_RESULT([yes]);
                    955:                    POSTGRESQL_SUPPORT="-DPOSTGRESQL_SUPPORT"],[AC_MSG_RESULT([no]);
                    956:                    POSTGRESQL_SUPPORT="-UPOSTGRESQL_SUPPORT"])
                    957:            CFLAGS=$saved_CFLAGS
                    958:            libPgSQLinc=$libPgSQLinc/postgresql
                    959:        fi
                    960: 
                    961:        if test "$POSTGRESQL_SUPPORT" = "-UPOSTGRESQL_SUPPORT"; then
                    962:            AC_MSG_CHECKING(for libpq includes in $libPgSQLinc/pgsql)
                    963:            saved_CFLAGS="$CFLAGS"
                    964:            CFLAGS="$CFLAGS $libPgSQLinc/pgsql"
                    965:            AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include "libpq-fe.h"]], [[]])],[AC_MSG_RESULT([yes]);
                    966:                    POSTGRESQL_SUPPORT="-DPOSTGRESQL_SUPPORT"],[AC_MSG_RESULT([no]);
                    967:                    POSTGRESQL_SUPPORT="-UPOSTGRESQL_SUPPORT"])
                    968:            CFLAGS=$saved_CFLAGS
                    969:            libPgSQLinc=$libPgSQLinc/pgsql
                    970:        fi
                    971:    else
                    972:        POSTGRESQL_SUPPORT="-UPOSTGRESQL_SUPPORT"
                    973:    fi
                    974: fi
                    975: 
                    976: if test "$POSTGRESQL_SUPPORT" = "-DPOSTGRESQL_SUPPORT"; then
                    977:    POSTGRESQL_LIB=no
                    978: 
                    979:    if test $POSTGRESQL_LIB = no; then
                    980:        AC_MSG_CHECKING(for libpq libraries in $libPgSQLlib)
                    981:        saved_LIBS="$LIBS"
                    982:        if test $STATIC = no; then
                    983:            LIBS="$LIBS -L/$libPgSQLlib $libPgSQLinc -lpq"
                    984:        else
                    985:            LIBS="$LIBS $libPgSQLlib/libpq.a $libPgSQLinc"
                    986:        fi
                    987:        AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include "libpq-fe.h"]], [[PGconn *conn; const char *conninfo="dbname=postgres"; conn =
                    988:             PQconnectdb(conninfo);]])],[AC_MSG_RESULT([yes]); POSTGRESQL_LIB="yes"],[AC_MSG_RESULT([no]); POSTGRESQL_LIB="no"])
                    989:        LIBS=$saved_LIBS;
                    990:        if test $STATIC = no; then
                    991:            libPgSQLlib="-L/$libPgSQLlib -lpq"
                    992:        else
                    993:            libPgSQLlib="$libPgSQLlib/libpq.a"
                    994:            EXT_SQL="$EXT_SQL $libPgSQLlib"
                    995:        fi
                    996:    fi
                    997: fi
                    998: 
1.16      bertrand  999: DEBPQ=
                   1000: 
1.1       bertrand 1001: if test "$POSTGRESQL_SUPPORT" != "-DPOSTGRESQL_SUPPORT"; then
                   1002:    libPgSQLinc=
                   1003:    libPgSQLlib=
1.16      bertrand 1004: else
1.17      bertrand 1005:    DEBPQ=", libpq5"
1.1       bertrand 1006: fi
                   1007: 
                   1008: AC_SUBST(POSTGRESQL_SUPPORT)
                   1009: AC_SUBST(libPgSQLinc)
                   1010: AC_SUBST(libPgSQLlib)
                   1011: 
                   1012: # with_postgresql : check [pas défini], yes [uniquement --with],
                   1013: # no [--without], valeur [--with=valeur].
                   1014: AC_ARG_WITH(bourne_shell,
                   1015: [  --with-bourne-shell=PATH  specify path for OS/2 bourne shell],
                   1016: [], [with_bourne_shell=no])
                   1017: 
                   1018: if test "x$with_bourne_shell" = xyes; then
                   1019:    AC_MSG_ERROR([You have to specify a valide shell path !])
                   1020: fi
                   1021: 
                   1022: if test "x$with_bourne_shell" = xno; then
                   1023:    if test $(uname) = "OS/2"; then
                   1024:        AC_MSG_ERROR([With OS/2 or eComstation, you have to specify a valide
                   1025: shell path with --with-bourne-shell=PATH !])
                   1026:    fi
                   1027: 
                   1028:    BSH_PATH=
                   1029: else
                   1030:    if test ! -x $with_bourne_shell; then
                   1031:        AC_MSG_ERROR([$with_bourne_shell is not executable !])
                   1032:    fi
                   1033: 
                   1034:    if test $(uname) = "OS/2"; then
                   1035:        with_os2_bourne_shell=$(echo $with_bourne_shell | \
                   1036:                sed -e '1,$s/\//\\\\\\\\/g')
                   1037:        BSH_PATH=-DBOURNE_SHELL=\"\\\"$with_os2_bourne_shell\\\"\"
                   1038:    else
                   1039:        AC_MSG_WARN([--with-bourne-shell ignored])
                   1040:        BSH_PATH=
                   1041:    fi
                   1042: fi
                   1043: 
                   1044: dnl Checks for sizes
                   1045: AC_CHECK_SIZEOF(void *, 4)
                   1046: AC_CHECK_SIZEOF(char, 1)
                   1047: AC_CHECK_SIZEOF(short int, 2)
                   1048: AC_CHECK_SIZEOF(int, 4)
                   1049: AC_CHECK_SIZEOF(long int, 4)
                   1050: AC_CHECK_SIZEOF(long long int, 8)
                   1051: AC_CHECK_SIZEOF(float, 4)
                   1052: AC_CHECK_SIZEOF(double, 8)
                   1053: AC_CHECK_SIZEOF(long double, 12)
                   1054: 
                   1055: dnl Checks for header files.
                   1056: AC_HEADER_DIRENT
                   1057: AC_HEADER_STDC
                   1058: AC_HEADER_SYS_WAIT
                   1059: AC_CHECK_HEADERS(dlfcn.h fcntl.h math.h pwd.h signal.h string.h termios.h \
                   1060:        time.h unistd.h sys/resource.h sys/stat.h sys/time.h sys/timeb.h \
                   1061:        sys/types.h sys/select.h sys/wait.h stdio.h stdlib.h pthread.h)
                   1062: 
                   1063: dnl Checks for typedefs, structures, and compiler characteristics.
                   1064: AC_C_CONST
                   1065: AC_TYPE_UID_T
                   1066: AC_TYPE_PID_T
                   1067: AC_TYPE_SIZE_T
                   1068: AC_HEADER_TIME
                   1069: AC_STRUCT_TM
                   1070: 
                   1071: dnl Checks for library functions.
                   1072: AC_DIAGNOSE([obsolete],[your code may safely assume C89 semantics that RETSIGTYPE is void.
                   1073: Remove this warning and the `AC_CACHE_CHECK' when you adjust the code.])dnl
                   1074: AC_CACHE_CHECK([return type of signal handlers],[ac_cv_type_signal],[AC_COMPILE_IFELSE(
                   1075: [AC_LANG_PROGRAM([#include <sys/types.h>
                   1076: #include <signal.h>
                   1077: ],
                   1078:         [return *(signal (0, 0)) (0) == 1;])],
                   1079:           [ac_cv_type_signal=int],
                   1080:           [ac_cv_type_signal=void])])
                   1081: AC_DEFINE_UNQUOTED([RETSIGTYPE],[$ac_cv_type_signal],[Define as the return type of signal handlers
                   1082:            (`int' or `void').])
                   1083: 
                   1084: AC_FUNC_STRCOLL
                   1085: AC_FUNC_STRFTIME
                   1086: AC_FUNC_VPRINTF
                   1087: AC_CHECK_FUNCS(ftime getcwd putenv select strcspn strdup \
                   1088:        strerror strspn strstr strtod)
                   1089: 
                   1090: dnl Check for OpenSSL os/comp
                   1091: AC_ARG_WITH(openssl_arch,
                   1092: [  --with-openssl-arch=ARCH  specify os and compiler for openssl (ARCH or list)],
                   1093: [], [with_openssl_arch=none])
                   1094: 
                   1095: if test $(uname) = "OS/2"; then
                   1096:    bash -c "cd tools/$OPENSSL && os2/OS2-EMX.cmd"
                   1097: else
1.23      bertrand 1098:    if test $build = $host; then
                   1099:        OPENSSL_CROSS=
                   1100:    else
                   1101:        OPENSSL_CROSS="AR=$host-ar RANLIB=$host-ranlib CC=$host-gcc NM=$host-nm"
                   1102:    fi
                   1103:    echo $build $host
                   1104:    echo $OPENSSL_CROSS
1.1       bertrand 1105:    if test "x$with_openssl_arch" = xnone; then
1.23      bertrand 1106:        (cd tools/$OPENSSL && sh -c "$OPENSSL_CROSS ./config no-asm")
1.1       bertrand 1107:    elif test "x$with_openssl_arch" = xyes -o "x$with_openssl_arch" = xno; then
                   1108:        (cd tools/$OPENSSL && ./Configure)
                   1109:        AC_MSG_ERROR([OS/COMP informations are required!])
                   1110:    elif test "x$with_openssl_arch" = xlist; then
                   1111:        (cd tools/$OPENSSL && ./Configure)
                   1112:        AC_MSG_ERROR([Please specify OS and Architecture])
                   1113:    else
1.23      bertrand 1114:        (cd tools/$OPENSSL && sh -c "$OPENSSL_CROSS ./Configure no-asm \
                   1115:                $with_openssl_arch")
1.1       bertrand 1116:    fi
                   1117: fi
                   1118: 
                   1119: if test "$MYGNUPLOT" = "yes"; then
                   1120:    if test ! -d "$srcdir"/tools/$GNUPLOT; then
                   1121:        gunzip -c "$srcdir"/tools/$GNUPLOT.tar.gz | \
                   1122:                (cd "$srcdir/tools" && tar -xf -)
                   1123:    fi
1.6       bertrand 1124: 
                   1125:    if test $RECURSIVE = yes; then
                   1126:        AC_CONFIG_SUBDIRS(tools/$GNUPLOT)
                   1127:    fi
                   1128: 
1.1       bertrand 1129:    GNUPLOT_COMPILATION=$GNUPLOT
                   1130: else
                   1131:    GNUPLOT_COMPILATION=
                   1132: fi
                   1133: 
                   1134: AC_SUBST(GNUPLOT_COMPILATION)
                   1135: 
1.3       bertrand 1136: HOST=$target
1.1       bertrand 1137: AC_SUBST(HOST)
1.25      bertrand 1138: BUILD=$build
                   1139: AC_SUBST(BUILD)
1.1       bertrand 1140: 
1.2       bertrand 1141: my_save_cflags="$CFLAGS"
                   1142: FPCFLAGS=""
1.1       bertrand 1143: 
1.2       bertrand 1144: CFLAGS=-malign-double
                   1145: AC_MSG_CHECKING([whether CC supports -malign-double])
                   1146: AC_COMPILE_IFELSE([AC_LANG_PROGRAM([])],
                   1147:    [AC_MSG_RESULT([yes]); FPCFLAGS="$FPCFLAGS -malign-double"],
                   1148:    [AC_MSG_RESULT([no])])
                   1149: CFLAGS=-mieee-fp
                   1150: AC_MSG_CHECKING([whether CC supports -mieee-fp])
                   1151: AC_COMPILE_IFELSE([AC_LANG_PROGRAM([])],
                   1152:     [AC_MSG_RESULT([yes]); FPCFLAGS="$FPCFLAGS -mieee-fp"],
                   1153:    [AC_MSG_RESULT([no])])
                   1154: CFLAGS=-mieee
                   1155: AC_MSG_CHECKING([whether CC supports -mieee])
                   1156: AC_COMPILE_IFELSE([AC_LANG_PROGRAM([])],
                   1157:     [AC_MSG_RESULT([yes]); FPCFLAGS="$FPCFLAGS -mieee"],
                   1158:    [AC_MSG_RESULT([no])])
                   1159: CFLAGS=$my_save_cflags
                   1160: 
                   1161: CFLAGS="$CFLAGS $FPCFLAGS -Wall -funsigned-char -Wno-pointer-sign"
                   1162: FFLAGS="$FFLAGS $FPCFLAGS -Wall -fno-f2c"
                   1163: FCFLAGS="$FCFLAGS $FPCFLAGS -Wall -fno-f2c"
                   1164: CXXFLAGS="$CXXFLAGS $FPCFLAGS -Wall -funsigned-char"
1.1       bertrand 1165: 
1.2       bertrand 1166: case $target_os in
1.1       bertrand 1167: 
                   1168:    cygwin*)
                   1169:        OS=Cygwin
                   1170:    break ;;
                   1171: 
                   1172:    interix*)
                   1173:        OS=Interix
                   1174:    break ;;
                   1175: 
                   1176:    *)
                   1177:        OS=$(uname)
                   1178:    break ;;
                   1179: 
                   1180: esac
                   1181: 
                   1182: AC_SUBST(OS)
                   1183: 
                   1184: MALLOC=
                   1185: 
                   1186: case $OS in
                   1187:     Darwin)
                   1188:        EXPORT_DYNAMIC=-Wl,-flat_namespace
                   1189:        NESTED_FUNCTIONS=-fnested-functions
                   1190:        CXXFLAGS="$CXXFLAGS -D_GLIBCXX_FULLY_DYNAMIC_STRING"
                   1191:        ac_configure_args="$ac_configure_args --with-readline=builtin \
                   1192:                --disable-shared --enable-static --enable-threads \
                   1193:                CFLAGS=\"$CFLAGS\" CXXFLAGS=\"$CXXFLAGS\" \
                   1194:                FFLAGS=\"$FFLAGS\" FCFLAGS=\"$FCFLAGS\" \
                   1195:                LDFLAGS=\"$LDFLAGS\""
                   1196:        C_STANDARD=-std=gnu99
                   1197:        ELF=
                   1198:    break ;;
                   1199: 
                   1200:     Cygwin)
                   1201:        EXPORT_DYNAMIC=-Wl,--export-all-symbols
                   1202:        NESTED_FUNCTIONS=
                   1203:        ac_configure_args="$ac_configure_args --with-readline=builtin \
                   1204:                --disable-shared --enable-static --enable-threads \
                   1205:                CFLAGS=\"$CFLAGS\" CXXFLAGS=\"$CXXFLAGS\" \
                   1206:                FFLAGS=\"$FFLAGS\" FCFLAGS=\"$FCFLAGS\" \
                   1207:                LDFLAGS=\"$LDFLAGS\""
                   1208:        C_STANDARD=-std=gnu99
                   1209:        ELF=
                   1210:    break ;;
                   1211: 
                   1212:    Interix)
                   1213:        EXPORT_DYNAMIC=-Wl,--export-all-symbols
                   1214:        NESTED_FUNCTIONS=
                   1215:        ac_configure_args="$ac_configure_args --with-readline=builtin \
                   1216:                --disable-shared --enable-static --enable-threads \
                   1217:                CFLAGS=\"$CFLAGS\" CXXFLAGS=\"$CXXFLAGS\" \
                   1218:                FFLAGS=\"$FFLAGS\" FCFLAGS=\"$FCFLAGS\" \
                   1219:                LDFLAGS=\"$LDFLAGS\""
                   1220:        C_STANDARD=-std=gnu99
                   1221:        ELF=
                   1222:    break;;
                   1223: 
                   1224:     AIX)
                   1225:        EXPORT_DYNAMIC=-Wl,--export-dynamic
                   1226:        NESTED_FUNCTIONS=
                   1227:        ac_configure_args="$ac_configure_args --with-readline=builtin \
                   1228:                --disable-shared --enable-static --enable-threads \
                   1229:                CFLAGS=\"$CFLAGS\" CXXFLAGS=\"$CXXFLAGS\" \
                   1230:                FFLAGS=\"$FFLAGS\" FCFLAGS=\"$FCFLAGS\" \
                   1231:                LDFLAGS=\"$LDFLAGS\""
                   1232:        C_STANDARD=-std=gnu99
                   1233:        ELF=
                   1234:    break ;;
                   1235: 
                   1236:     OS/2)
                   1237:        if test $FORCED_FINAL_ENCODING -eq 0; then \
                   1238:            FINAL_ENCODING=CP850; \
1.47      bertrand 1239:            FORCED_FINAL_ENCODING=1;\
1.1       bertrand 1240:        fi;
                   1241:        OS=OS2
                   1242:        NESTED_FUNCTIONS=
                   1243:        EXPORT_DYNAMIC=-Zmap
                   1244:        ac_configure_args="$ac_configure_args --without-readline \
                   1245:                --without-cairo --disable-shared --enable-static \
                   1246:                --enable-threads \
                   1247:                CFLAGS=\"$CFLAGS\" CXXFLAGS=\"$CXXFLAGS\" \
                   1248:                FFLAGS=\"$FFLAGS\" FCFLAGS=\"$FCFLAGS\" \
                   1249:                LDFLAGS=\"$LDFLAGS\""
                   1250:        C_STANDARD=
                   1251:        ELF=
                   1252:    break;;
                   1253: 
                   1254:    OpenBSD)
                   1255:        if test $FORCED_FINAL_ENCODING -eq 0; then \
                   1256:            FINAL_ENCODING=UTF-8; \
1.47      bertrand 1257:            FORCED_FINAL_ENCODING=1;\
1.1       bertrand 1258:        fi;
                   1259:        EXPORT_DYNAMIC=-Wl,--export-dynamic
                   1260:        NESTED_FUNCTIONS=
                   1261:        ac_configure_args="$ac_configure_args --with-readline=builtin \
                   1262:                --disable-shared --enable-static --enable-threads \
                   1263:                CFLAGS=\"$CFLAGS\" CXXFLAGS=\"$CXXFLAGS\" \
                   1264:                FFLAGS=\"$FFLAGS\" FCFLAGS=\"$FCFLAGS\" \
                   1265:                LDFLAGS=\"$LDFLAGS\""
                   1266:        C_STANDARD=-std=gnu99
                   1267:        ELF=
                   1268:    break;;
                   1269: 
                   1270:     SunOS)
                   1271:        EXPORT_DYNAMIC=-Wl,--export-dynamic
                   1272:        NESTED_FUNCTIONS=
                   1273: 
                   1274:        ac_configure_args="$ac_configure_args --with-readline=builtin \
                   1275:                --disable-shared --enable-static --enable-threads \
                   1276:                CFLAGS=\"$CFLAGS\" CXXFLAGS=\"$CXXFLAGS\" \
                   1277:                FFLAGS=\"$FFLAGS\" FCFLAGS=\"$FCFLAGS\" \
                   1278:                LDFLAGS=\"$LDFLAGS\""
                   1279:        C_STANDARD=-std=gnu99
                   1280:        MALLOC=-lumem
                   1281:        ELF=
                   1282:    break ;;
                   1283: 
                   1284:     NetBSD)
                   1285:        EXPORT_DYNAMIC=-Wl,--export-dynamic
                   1286:        NESTED_FUNCTIONS=
                   1287: 
                   1288:        ac_configure_args="$ac_configure_args --with-readline=builtin \
                   1289:                --disable-shared --enable-static --enable-threads \
                   1290:                CFLAGS=\"$CFLAGS\" CXXFLAGS=\"$CXXFLAGS\" \
                   1291:                FFLAGS=\"$FFLAGS\" FCFLAGS=\"$FCFLAGS\" \
                   1292:                LDFLAGS=\"$LDFLAGS\""
                   1293:        C_STANDARD=-std=gnu99
                   1294:        GCCBIN=`which gcc`
                   1295:        GCCLIB=`dirname $GCCBIN`/../lib
                   1296:        ELF="-Wl,-R/usr/pkg/lib -Wl,-R$GCCLIB"
                   1297:    break ;;
                   1298: 
                   1299:     *)
                   1300:        EXPORT_DYNAMIC=-Wl,--export-dynamic
                   1301:        NESTED_FUNCTIONS=
                   1302: 
                   1303:        ac_configure_args="$ac_configure_args --with-readline=builtin \
                   1304:                --disable-shared --enable-static --enable-threads \
                   1305:                CFLAGS=\"$CFLAGS\" CXXFLAGS=\"$CXXFLAGS\" \
                   1306:                FFLAGS=\"$FFLAGS\" FCFLAGS=\"$FCFLAGS\" \
                   1307:                LDFLAGS=\"$LDFLAGS\""
                   1308:        C_STANDARD=-std=gnu99
                   1309:        ELF=
                   1310:    break ;;
1.5       bertrand 1311: esac
                   1312: 
1.109     bertrand 1313: dnl Correction d'un problème de compilation pour GNUplot 5.0.0
                   1314: ac_configure_args="$ac_configure_args --disable-wxwidgets"
                   1315: 
1.5       bertrand 1316: case $OS in
                   1317:     OS2)
                   1318:        WHOLE_LIB1=""
                   1319:        WHOLE_LIB2=""
1.6       bertrand 1320:        LIB_PREFIX=""
1.5       bertrand 1321:    break ;;
1.1       bertrand 1322: 
1.5       bertrand 1323:    *)
                   1324:        WHOLE_LIB1="-Wl,-whole-archive"
                   1325:        WHOLE_LIB2="-Wl,-no-whole-archive"
1.6       bertrand 1326:        LIB_PREFIX="lib"
1.5       bertrand 1327:    break ;;
1.1       bertrand 1328: esac
                   1329: 
1.12      bertrand 1330: case $HOST in
1.33      bertrand 1331:    x86_64-*-linux-gnu)
1.12      bertrand 1332:        ARCH=amd64
                   1333:    break ;;
                   1334: 
1.33      bertrand 1335:    i?86-*-linux-gnu)
1.12      bertrand 1336:        ARCH=i386
                   1337:    break ;;
                   1338: 
1.24      bertrand 1339:    arm-unknown-linux-gnueabi)
                   1340:        ARCH=armel
                   1341:    break;;
                   1342: 
1.58      bertrand 1343:    mips*el-unknown-linux-gnu)
1.53      bertrand 1344:        ARCH=mipsel
                   1345:    break;;
                   1346: 
1.12      bertrand 1347:    *)
1.72      bertrand 1348:        ARCH=$(echo $HOST | cut -f1 -d-)
1.12      bertrand 1349:    break ;;
                   1350: esac
                   1351: 
1.5       bertrand 1352: AC_SUBST(WHOLE_LIB1)
                   1353: AC_SUBST(WHOLE_LIB2)
1.6       bertrand 1354: AC_SUBST(LIB_PREFIX)
1.5       bertrand 1355: 
1.1       bertrand 1356: AC_SUBST(C_STANDARD)
                   1357: AC_SUBST(EXPORT_DYNAMIC)
                   1358: AC_SUBST(NESTED_FUNCTIONS)
                   1359: AC_SUBST(SEMAPHORES_NOMMES)
                   1360: AC_SUBST(IPCS_SYSV)
                   1361: AC_SUBST(SEMUN)
                   1362: AC_SUBST(IPV6)
                   1363: AC_SUBST(BSH_PATH)
                   1364: AC_SUBST(ELF)
1.12      bertrand 1365: AC_SUBST(ARCH)
1.1       bertrand 1366: 
                   1367: AC_SUBST(NCURSES)
                   1368: AC_SUBST(READLINE)
                   1369: AC_SUBST(UNITS)
                   1370: AC_SUBST(GSL)
                   1371: AC_SUBST(GPP)
                   1372: AC_SUBST(GNUPLOT)
                   1373: AC_SUBST(FILE)
                   1374: AC_SUBST(ICONV)
                   1375: AC_SUBST(SQLITE)
                   1376: AC_SUBST(OPENSSL)
                   1377: AC_SUBST(LIBXPM)
                   1378: AC_SUBST(OPENMOTIF)
                   1379: AC_SUBST(BUILD_OPENMOTIF)
                   1380: AC_SUBST(SIGSEGV)
                   1381: AC_SUBST(FINAL_ENCODING)
1.47      bertrand 1382: AC_SUBST(FORCED_FINAL_ENCODING)
1.1       bertrand 1383: AC_SUBST(DATE)
                   1384: AC_SUBST(EXT_SQL)
                   1385: AC_SUBST(MALLOC)
                   1386: AC_SUBST(GMP)
                   1387: AC_SUBST(MPFR)
                   1388: AC_SUBST(NTL)
                   1389: AC_SUBST(COCOA)
                   1390: AC_SUBST(PARI)
                   1391: AC_SUBST(GIAC)
                   1392: AC_SUBST(INCMOTIF)
                   1393: AC_SUBST(LIBMOTIF)
1.62      bertrand 1394: AC_SUBST(ZLIB)
1.1       bertrand 1395: 
                   1396: AC_SUBST(CFLAGS)
                   1397: AC_SUBST(CXXFLAGS)
                   1398: AC_SUBST(FFLAGS)
                   1399: AC_SUBST(FCFLAGS)
                   1400: AC_SUBST(LDFLAGS)
1.23      bertrand 1401: AC_SUBST(SYSROOT)
1.25      bertrand 1402: AC_SUBST(SYSROOT2)
1.1       bertrand 1403: 
1.16      bertrand 1404: AC_SUBST(DEBPQ)
                   1405: AC_SUBST(DEBMYSQL)
                   1406: AC_SUBST(DEBVIM)
                   1407: 
1.6       bertrand 1408: if test $RECURSIVE = yes; then
                   1409:    AC_CONFIG_SUBDIRS(tools/$NCURSES)
                   1410:    AC_CONFIG_SUBDIRS(tools/$READLINE)
                   1411:    AC_CONFIG_SUBDIRS(tools/$GSL)
                   1412:    AC_CONFIG_SUBDIRS(tools/$GPP)
                   1413:    AC_CONFIG_SUBDIRS(tools/$FILE)
                   1414:    AC_CONFIG_SUBDIRS(tools/$ICONV)
                   1415:    AC_CONFIG_SUBDIRS(tools/$SQLITE)
                   1416:    AC_CONFIG_SUBDIRS(tools/$UNITS)
                   1417:    AC_CONFIG_SUBDIRS(tools/$SIGSEGV)
                   1418: fi
1.1       bertrand 1419: 
                   1420: AC_CONFIG_FILES(Makefile)
1.59      bertrand 1421: AC_CONFIG_FILES(HEADER)
1.1       bertrand 1422: AC_CONFIG_FILES(tools/Makefile)
                   1423: AC_CONFIG_FILES(src/Makefile)
                   1424: AC_CONFIG_FILES(man/Makefile)
                   1425: AC_CONFIG_FILES(man/fr_FR/Makefile)
                   1426: AC_CONFIG_FILES(doc/Makefile)
                   1427: AC_CONFIG_FILES(scripts/Makefile)
                   1428: AC_CONFIG_FILES(scripts/mkrplso)
                   1429: AC_CONFIG_FILES(scripts/rplcc)
                   1430: AC_CONFIG_FILES(scripts/rpllink)
                   1431: AC_CONFIG_FILES(rpltags/Makefile)
                   1432: AC_CONFIG_FILES(rpliconv/Makefile)
                   1433: AC_CONFIG_FILES(rplsums/Makefile)
                   1434: AC_CONFIG_FILES(rplcas/Makefile)
                   1435: AC_CONFIG_FILES(rplawk/Makefile)
                   1436: AC_CONFIG_FILES(lapack/lapack/Makefile)
                   1437: AC_CONFIG_FILES(lapack/blas/Makefile)
                   1438: 
                   1439: AC_CONFIG_FILES(man/rpl.1)
                   1440: AC_CONFIG_FILES(man/rplcc.1)
                   1441: AC_CONFIG_FILES(man/rpllink.1)
                   1442: AC_CONFIG_FILES(man/rpltags.1)
                   1443: AC_CONFIG_FILES(man/mkrplso.1)
                   1444: AC_CONFIG_FILES(man/fr_FR/rpl.1)
                   1445: AC_CONFIG_FILES(man/fr_FR/rplcc.1)
                   1446: AC_CONFIG_FILES(man/fr_FR/rpllink.1)
                   1447: AC_CONFIG_FILES(man/fr_FR/rpltags.1)
                   1448: AC_CONFIG_FILES(man/fr_FR/mkrplso.1)
                   1449: 
1.12      bertrand 1450: AC_CONFIG_FILES(DEBIAN/control)
                   1451: 
1.1       bertrand 1452: AC_OUTPUT

CVSweb interface <joel.bertrand@systella.fr>