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