Annotation of OpenXM_contrib2/asir2000/configure.in, Revision 1.30
1.30 ! ohara 1: dnl $OpenXM: OpenXM_contrib2/asir2000/configure.in,v 1.29 2008/08/11 16:58:30 ohara Exp $
1.1 ohara 2:
1.25 ohara 3: AC_INIT
4: AC_CONFIG_SRCDIR([LICENSE])
5: AC_PREREQ(2.61)
6: AC_CANONICAL_TARGET
1.5 noro 7: AM_INIT_AUTOMAKE(asir, 20030307)
1.11 ohara 8: AM_MAINTAINER_MODE
1.1 ohara 9:
10: dnl AM_PROG_AS
11: AC_PROG_CC
12: AC_PROG_INSTALL
13: AC_PROG_LN_S
14: AC_PROG_RANLIB
15: AC_PROG_YACC
16:
17: AC_PATH_XTRA
18:
19: AC_DEFINE([HMEXT])
20:
21: AC_ARG_ENABLE([shared],
22: [ --enable-shared enable linking shared libraries. [[no]]],
23: [enable_shared=yes],[enable_shared=no])
24:
25: if test "${enable_shared:=no}" != no ; then
26: true
27: fi
1.4 noro 28:
1.6 ohara 29: if test "${ac_test_CFLAGS}" != set -a "${GCC}" = yes ; then
30: if test "${ac_cv_prog_cc_g}" = yes; then
31: CFLAGS="-g -O"
32: else
33: CFLAGS="-O"
34: fi
1.18 ohara 35: elif test `basename ./"${CC}"` = "icc" ; then
36: CFLAGS="-g -O"
1.6 ohara 37: fi
1.23 ohara 38:
1.25 ohara 39: GC=gc6.8
1.30 ! ohara 40: AC_ARG_WITH([asir-gc],
! 41: [ --with-asir-gc modify Boehm's GC [[yes]]],
! 42: [with_asir_gc=${withval}],[with_asir_gc=yes])
! 43: if test ${with_asir_gc:=yes} != no; then
! 44: ASIR_GCLIB=libasir-gc.a
! 45: GCINC='-I${top_srcdir}/${GC}/include'
! 46: else
! 47: GCLIB='-L${prefix}/lib -lgc'
! 48: GCINC='-I${prefix}/include'
! 49: AC_DEFINE([NO_ASIR_GC])
! 50: fi
1.25 ohara 51: dnl GC_CONFIGURE_ARGS=--disable-threads --enable-shared=no
52: GC_CONFIGURE_ARGS=--disable-threads
53: if [ -n "${host_alias}" ]; then
54: GC_CONFIGURE_ARGS="--host=${host_alias} ${GC_CONFIGURE_ARGS}"
55: fi
1.26 ohara 56: AC_ARG_WITH([gc7],
1.30 ! ohara 57: [ --with-gc7 use GC 7.x (if --with-asir-gc=yes) [[no]]],
1.26 ohara 58: [with_gc7=${withval}],[with_gc7=no])
59: if test ${with_gc7:=no} != no; then
60: case "${with_gc7}" in
61: [7*]) GC_VERSION=${with_gc7} ;;
62: *) GC_VERSION=7.0 ;;
63: esac
64: GC=gc-${GC_VERSION}
65: AC_DEFINE([GC7])
66: fi
1.30 ! ohara 67:
! 68: AC_SUBST([ASIR_GCLIB])
! 69: AC_SUBST([GCLIB])
! 70: AC_SUBST([GCINC])
! 71:
1.25 ohara 72: AC_SUBST([GC])
73: AC_SUBST([GC_CONFIGURE_ARGS])
1.26 ohara 74: AM_CONDITIONAL([USE_GC7],[test "$with_gc7" != no])
1.25 ohara 75:
1.23 ohara 76: AC_ARG_WITH([distdir],
77: [ --with-distdir specify the spool for fetching. [[no]]],
78: [with_distdir=${withval}],[with_distdir=no])
79: GC_DISTDIR='${prefix}/../OpenXM_dist'
80: if test ${with_distdir:=no} != no -a ${with_distdir} != yes ; then
81: GC_DISTDIR=${with_distdir}
82: fi
83: AC_SUBST([GC_DISTDIR])
1.12 ohara 84:
1.1 ohara 85: libasir_postfix=""
86: AC_ARG_WITH([pari],
87: [ --with-pari use the PARI library. [[no]]],
88: [with_pari=${withval}],[with_pari=no])
89:
90: if test ${with_pari:=no} != no ; then
1.29 ohara 91: if test "${with_pari}" = new -o "${with_pari}" = 2.3 ; then
92: AC_DEFINE([PARI23])
93: fi
1.1 ohara 94: libasir_postfix=${libasir_postfix}_pari
95: PARIINC='-I${prefix}/include/pari'
96: if test "${enable_shared}" != yes ; then
1.30 ! ohara 97: PARILIB='${libdir}/libpari.a'
1.1 ohara 98: else
1.30 ! ohara 99: PARILIB='-L${libdir} -lpari'
1.1 ohara 100: fi
101: AC_DEFINE([PARI])
102: fi
103: AC_SUBST([PARIINC])
104: AC_SUBST([PARILIB])
105:
1.7 ohara 106: AC_CHECK_TYPES([unsigned long long])
1.5 noro 107: AC_CHECK_SIZEOF(long)
1.15 noro 108: if test "${ac_cv_sizeof_long}" = 8; then
1.5 noro 109: AC_DEFINE([LONG_IS_64BIT])
110: else
111: AC_DEFINE([LONG_IS_32BIT])
112: fi
1.1 ohara 113: if test "${no_x}" != yes ; then
1.14 ohara 114: if test -f "${x_libraries}/libXpm.a" -o -f "${x_libraries}/libXpm.dll.a" ; then
1.10 ohara 115: XPMLIB="-lXpm"
116: fi
1.1 ohara 117: AC_ARG_ENABLE([plot],
118: [ --enable-plot enable plot feature. [[no]]],
119: [enable_plot=yes],[enable_plot=no])
120: fi
1.10 ohara 121: AC_SUBST([XPMLIB])
1.1 ohara 122:
123: if test ${enable_plot:=no} != no ; then
124: libasir_postfix=${libasir_postfix}_X
125: AC_DEFINE([DO_PLOT])
126: fi
127: AM_CONDITIONAL([USE_PLOT],[test "$enable_plot" = yes])
128:
129: AC_ARG_ENABLE([interval],
130: [ --enable-interval enable interval feature. [[no]]],
131: [enable_interval=${enableval}],[enable_interval=no])
132:
133: if test ${enable_interval:=no} != no ; then
134: libasir_postfix=${libasir_postfix}_itv
135: AC_DEFINE([INTERVAL])
136: if test "${enable_interval}" = debug ; then
137: AC_DEFINE([ITVDEBUG])
138: fi
139: fi
140:
141: dnl AC_ARG_ENABLE([fep],
142: dnl [ --enable-fep enable fep for human interfaces. [[no]]],
143: dnl [enable_fep=yes],[enable_fep=no])
144:
145: if test "${enable_fep:=no}" != no ; then
146: AC_DEFINE([FEP])
147: FEPLIB="-lreadline -ltermcap"
148: fi
149: AC_SUBST([FEPLIB])
150:
151: AC_ARG_ENABLE([fft-float],
152: [ --enable-fft-float enable FFT-FLOAT feature. [[no]]],
153: [enable_fft_float=yes],[enable_fft_float=no])
154:
155: if test "${enable_fft_float:=no}" != no ; then
156: AC_DEFINE([USE_FLOAT])
157: fi
158:
159: dnl AC_ARG_WITH([mpi],
160: dnl [ --with-mpi use the MPI library. [[no]]],
161: dnl [with_mpi=${withval}],[with_mpi=no])
162:
163: if test "${with_mpi:=no}" != no ; then
164: MPIINC="-I/opt/FJSVmpi2/include"
165: MPILIB="-L/opt/FJSVmpi2/lib -lmpi -L/opt/FSUNaprun/lib -lmpl -lemi -lthread"
166: AC_DEFINE([MPI])
167: fi
168: AC_SUBST([MPIINC])
169: AC_SUBST([MPILIB])
170:
171: dnl AC_ARG_WITH([lapack],
172: dnl [ --with-lapack use the LAPACK library. [[no]]],
173: dnl [with_lapack=${withval}],[with_lapack=no])
174:
175: if test "${with_lapack:=no}" != no ; then
1.22 saito 176: LAPACKLIB="-llapack -lblas -lg2c"
1.1 ohara 177: AC_DEFINE([LAPACK])
178: fi
179: AC_SUBST([LAPACKLIB])
180:
181: AC_SUBST([libasir_postfix])
182:
183: dnl Object files in assembly languages for each micro processors.
184: dnl i386_elf_obj: for FreeBSD 3.x or later and Linux 2.x
185: dnl i386_aout_obj: for FreeBSD 2.x, Linux 1.x, and Cygwin
186: dnl sparc_v8_obj: for Sparc V8 processor on Solaris 2.x
187: dnl sparc_v9_obj: for Sparc V9 processor on Solaris 2.x
188: dnl generic_obj: for 32bits/64bits generic micro processors
189:
190: i386_elf_obj=asmi_l.o
191: i386_aout_obj=asmi.o
192: sparc_v8_obj="sparc-2.o asm4-2.o edr-2.o"
1.19 noro 193: sparc_v9_obj=asmalpha.o
1.1 ohara 194: generic_obj=asmalpha.o
195:
196: case "${host}" in
1.9 ohara 197: [i[3-6]86-*-freebsd[3-9].*])
1.1 ohara 198: asm_obj="${i386_elf_obj}"
1.9 ohara 199: ;;
200: [i[3-6]86-*-linux*]|x86-*-linux*)
201: asm_obj="${i386_elf_obj}"
1.13 ohara 202: AC_DEFINE([_BSD_SOURCE])
1.1 ohara 203: ;;
204: *-*-cygwin*)
205: asm_obj="${i386_aout_obj}"
1.16 ohara 206: ;;
207: [i[3-6]86-*-interix*])
1.17 ohara 208: asm_obj="${i386_aout_obj}"
1.16 ohara 209: AC_DEFINE([_ALL_SOURCE])
1.1 ohara 210: ;;
211: sparc-sun-solaris2.*)
212: case "`uname -m`" in
213: [sun4[dm]]) asm_obj="${sparc_v8_obj}" ;;
1.20 ohara 214: sun4u*) asm_obj="${sparc_v9_obj}"
215: if test "${ac_test_CFLAGS}" != set -a "${GCC}" = yes ; then
216: CFLAGS="${CFLAGS} -m64"
217: fi
218: AC_SUBST([USE_GC_SPARC64])
219: ;;
1.1 ohara 220: *) asm_obj="${generic_obj}" ;;
221: esac
222: AC_DEFINE([SYSV])
1.2 ohara 223: ;;
1.24 ohara 224: *-apple-darwin*)
1.2 ohara 225: asm_obj="${generic_obj}"
226: AC_DEFINE([__DARWIN__])
1.8 ohara 227: ;;
228: arm*-*-linux*)
229: asm_obj="${generic_obj}"
230: if test "${ac_test_CFLAGS}" != set -a "${GCC}" = yes ; then
231: CFLAGS="${CFLAGS} -fsigned-char"
232: fi
1.1 ohara 233: ;;
234: *)
235: asm_obj="${generic_obj}"
236: ;;
237: esac
238:
239: AC_SUBST([asm_obj])
240:
241: dnl for Solaris 2.x
242: AC_CHECK_FUNC(socket, , [AC_CHECK_LIB(socket,socket)])
243: AC_CHECK_FUNC(gethostbyname, , [AC_CHECK_LIB(nsl,gethostbyname)])
244:
1.25 ohara 245: AC_CONFIG_FILES([Makefile engine/Makefile asm/Makefile builtin/Makefile fft/Makefile include/Makefile io/Makefile lib/Makefile parse/Makefile plot/Makefile])
246: AC_OUTPUT
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>