* Updated to new classpath configure options.
[cacao.git] / configure.in
1 dnl Process this file with autoconf to produce a configure script.
2
3 AC_INIT(cacao, 0.93+cvs, cacao@cacaojvm.org)
4 AC_CONFIG_SRCDIR(src/cacao/cacao.c)
5 AC_CANONICAL_HOST
6 AC_PREREQ(2.59)
7 AM_INIT_AUTOMAKE([1.9.0])
8 AM_MAINTAINER_MODE
9
10 AM_CONFIG_HEADER([config.h])
11
12 AC_PREFIX_DEFAULT(/usr/local/cacao)
13
14
15 dnl set optimization and debugging for all architectures and systems
16 if test x"$CFLAGS" = "x"; then
17         CFLAGS="-O0 -g3"
18 fi
19
20 dnl system type
21 case "$host_cpu" in
22 alpha | alphaev56 | alphapca56 )
23         ARCH_DIR="alpha"
24         CFLAGS="$CFLAGS -mieee -D__ALPHA__"
25         ;;
26
27 arm | armv4tl | armv5b )
28         ARCH_DIR="arm"
29         CFLAGS="$CFLAGS -D__ARM__"
30         ;;
31
32 i386 | i486 | i586 | i686 )
33         ARCH_DIR="i386"
34         CFLAGS="$CFLAGS -D__I386__"
35         ;;
36
37 mips )
38         ARCH_DIR="mips"
39         CFLAGS="$CFLAGS -D__MIPS__"
40         ;;
41
42 powerpc )
43         ARCH_DIR="powerpc"
44         CFLAGS="$CFLAGS -D__POWERPC__"
45         ;;
46
47 powerpc64 )
48         ARCH_DIR="powerpc64"
49         CFLAGS="$CFLAGS -D__POWERPC64__"
50         ;;
51
52 x86_64 )
53         ARCH_DIR="x86_64"
54         CFLAGS="$CFLAGS -D__X86_64__"
55         ;;
56
57 xdspcore )
58         ARCH_DIR="xdspcore"
59         ENABLE_STATICVM="yes"
60         CFLAGS="$CFLAGS -D__XDSPCORE__"
61         USE_SCHEDULER="1"
62         ;;
63 * )
64         AC_MSG_ERROR($host_cpu systems are not supported at this time)
65         ;;
66 esac
67
68 dnl host type
69 case "$host_os" in
70 *linux* | *Linux* )
71         OS_DIR="linux"
72         CFLAGS="$CFLAGS -D__LINUX__ -ansi -pedantic -Wall -Wno-long-long -D_POSIX_C_SOURCE=199506L -D_XOPEN_SOURCE=500 -D_XOPEN_SOURCE_EXTENDED -D_BSD_SOURCE"
73         ;;
74 *darwin* )
75         OS_DIR="darwin"
76         CFLAGS="$CFLAGS -D__DARWIN__ -ansi -pedantic -Wall -Wno-long-long"
77         ;;
78 *freebsd* )
79         OS_DIR="freebsd"
80         CFLAGS="$CFLAGS -D__FREEBSD__ -ansi -pedantic -Wall -Wno-long-long -D_XOPEN_SOURCE_EXTENDED"
81         ;;
82 *irix* )
83         OS_DIR="irix"
84         CFLAGS="$CFLAGS -D__IRIX__"
85         ;;
86 * )
87         ;;
88 esac
89
90
91 dnl define and substitute some architecture specific variables
92 AC_DEFINE_UNQUOTED([ARCH_DIR], "${ARCH_DIR}", [architecture directory])
93 AC_SUBST(ARCH_DIR)
94 AC_SUBST(OS_DIR)
95 AC_SUBST(USE_SCHEDULER)
96
97
98 dnl Checks for programs.
99 AC_PROG_CC
100 AM_PROG_AS
101 AC_PROG_LD
102 AC_PROG_LD_GNU
103 AC_PROG_RANLIB
104 AC_DISABLE_SHARED
105 AC_PROG_LN_S
106 AC_PROG_MAKE_SET
107 AM_PROG_MKDIR_P
108
109 dnl libtool stuff
110 AC_LIBTOOL_DLOPEN
111 AC_PROG_LIBTOOL
112
113 dnl Checks for header files.
114 AC_HEADER_DIRENT
115 AC_HEADER_STDC
116 AC_CHECK_HEADERS([fcntl.h])
117 AC_CHECK_HEADERS([sys/time.h])
118 AC_CHECK_HEADERS([unistd.h])
119 AC_CHECK_HEADERS([sys/ioctl.h])
120
121 dnl this is for fdlibm
122 AC_CHECK_HEADERS([stdint.h])
123 AC_CHECK_HEADERS([inttypes.h])
124 AC_CHECK_HEADERS([sys/config.h])
125 AC_CHECK_HEADERS([sys/types.h])
126 AC_EGREP_HEADER(uint32_t, stdint.h, AC_DEFINE(HAVE_INT32_DEFINED, 1, [Define to 1 if you have uint32_t]))
127 AC_EGREP_HEADER(uint32_t, inttypes.h, AC_DEFINE(HAVE_INT32_DEFINED, 1, [Define to 1 if you have uint32_t]))
128 AC_EGREP_HEADER(u_int32_t, sys/types.h, AC_DEFINE(HAVE_BSD_INT32_DEFINED, 1, [Define to 1 if you have BSD u_int32_t]))
129 AC_EGREP_HEADER(u_int32_t, sys/config.h, AC_DEFINE(HAVE_BSD_INT32_DEFINED, 1, [Define to 1 if you have BSD u_int32_t]))
130
131 dnl Checks for typedefs, structures, and compiler characteristics.
132 AC_C_CONST
133 AC_C_INLINE
134 AC_C_ATTRIBUTE
135 AC_TYPE_OFF_T
136 AC_TYPE_SIZE_T
137 AC_HEADER_TIME
138 AC_STRUCT_TM
139
140 dnl Checks for library functions.
141 AC_PROG_GCC_TRADITIONAL
142 AC_TYPE_SIGNAL
143 AC_FUNC_MEMCMP
144 AC_CHECK_FUNCS([calloc mprotect getpagesize free])
145 AC_CHECK_FUNCS([getcwd gettimeofday])
146 AC_CHECK_FUNCS([scandir])
147 AC_CHECK_FUNCS([mmap])
148 AC_CHECK_FUNCS([isnan])
149
150 dnl Checks for libraries.
151
152 dnl Checking sizeof void *
153 AC_CHECK_SIZEOF(void *)
154 AC_C_BIGENDIAN
155
156
157 dnl check which ld flags are required to export symbols
158 if test x"$with_gnu_ld" = "xyes"; then
159     EXPORT_SYMBOLS_FLAGS="-Wl,--export-dynamic"
160 else
161     EXPORT_SYMBOLS_FLAGS=""
162 fi
163 AC_SUBST(EXPORT_SYMBOLS_FLAGS)
164
165
166 dnl define install prefix
167 if test "x$prefix" = "xNONE"; then
168     CACAO_PREFIX=$ac_default_prefix
169 else
170     CACAO_PREFIX=$prefix
171 fi
172 AC_DEFINE_UNQUOTED([CACAO_PREFIX], "${CACAO_PREFIX}", [installation prefix])
173 AC_SUBST(CACAO_PREFIX)
174
175
176 dnl Features
177
178 dnl check arguments
179
180 dnl check for JIT compiler
181 AC_MSG_CHECKING(whether JIT compiler should be compiled)
182 AC_ARG_ENABLE([jit],
183               [AS_HELP_STRING(--disable-jit,disable JIT compiler [[default=yes]])],
184               [case "${enableval}" in
185                    no) ENABLE_JIT=no;;
186                    *) ENABLE_JIT=yes;;
187                esac],
188               [ENABLE_JIT=yes])
189 AC_MSG_RESULT(${ENABLE_JIT})
190 AM_CONDITIONAL([ENABLE_JIT], test x"${ENABLE_JIT}" = "xyes")
191
192 if test x"${ENABLE_JIT}" = "xyes"; then
193     AC_DEFINE([ENABLE_JIT], 1, [enable JIT compiler])
194 fi
195
196
197 dnl check for interpreter
198 AC_ARG_ENABLE([intrp], [AS_HELP_STRING(--enable-intrp,enable interpreter [[default=no]])])
199
200 AC_MSG_CHECKING(whether interpreter should be compiled)
201 if test x"$enable_intrp" = "xyes"; then
202     AC_MSG_RESULT(yes)
203     AC_DEFINE([ENABLE_INTRP], 1, [enable interpreter])
204     AM_CONDITIONAL([ENABLE_INTRP], [true])
205     ENABLE_INTRP=yes
206
207     AC_ASM_SKIP16
208
209     dnl check for libffi
210     AC_ARG_WITH([ffi],
211                 [AS_HELP_STRING(--with-ffi,use libffi to call native functions)],
212                 [WITH_FFI=yes
213                  AC_CHECK_HEADERS([ffi.h],, [AC_MSG_ERROR(cannot find ffi.h)])
214                  AC_CHECK_LIB(ffi, ffi_call,, [AC_MSG_ERROR(cannot find libffi)])
215                  AC_DEFINE([WITH_FFI], 1, [use libffi])],
216                 [WITH_FFI=no])
217
218     dnl check for libffcall
219     AC_ARG_WITH([ffcall],
220                 [AS_HELP_STRING(--with-ffcall,use libffcall to call native functions)],
221                 [WITH_FFCALL=yes
222                  AC_CHECK_HEADERS([avcall.h],, [AC_MSG_ERROR(cannot find avcall.h)])
223                  AC_CHECK_LIB(avcall, __builtin_avcall,, [AC_MSG_ERROR(cannot find libavcall (from libffcall))])
224                  AC_DEFINE([WITH_FFCALL], 1, [use libffcall])],
225                 [WITH_FFCALL=no])
226
227     dnl check for libffi or libffcall
228     if test x"${WITH_FFI}" = "xyes" -a x"${WITH_FFCALL}" = "xyes"; then
229         AC_ERROR(Enable only libffi or libffcall.)
230     fi
231     if test x"${WITH_FFI}" = "xno" -a x"${WITH_FFCALL}" = "xno"; then
232         AC_ERROR(Enable one of libffi or libffcall.)
233     fi
234
235 else
236     AC_MSG_RESULT(no)
237     AM_CONDITIONAL([ENABLE_INTRP], [false])
238     ENABLE_INTRP="no"
239 fi
240
241 if test x"${ENABLE_JIT}" = "xno" -a x"${ENABLE_INTRP}" = "xno"; then
242     AC_ERROR(You have to enable at least the JIT or the interpreter.)
243 fi
244
245
246 dnl check for garbage collector usage
247 AC_MSG_CHECKING(whether GC should be disabled)
248 AC_ARG_ENABLE([gc],
249               [AS_HELP_STRING(--disable-gc,disable garbage collector (for debugging only!) [[default=yes]])],
250               [case "${enableval}" in
251                    no) DISABLE_GC=yes
252                        AC_DEFINE([DISABLE_GC], 1, [disable garbage collector])
253                        ;;
254                    *) DISABLE_GC=no;;
255                esac],
256               [DISABLE_GC=no])
257 AC_MSG_RESULT(${DISABLE_GC})
258 AM_CONDITIONAL([DISABLE_GC], test x"${DISABLE_GC}" = "xyes")
259
260
261 dnl check for dump memory usage
262 AC_MSG_CHECKING(whether dump memory should be disabled)
263 AC_ARG_ENABLE([dump],
264               [AS_HELP_STRING(--disable-dump,disable dump memory (for debugging only!) [[default=yes]])],
265               [case "${enableval}" in
266                    no)
267                        DISABLE_DUMP=yes
268                        AC_DEFINE([DISABLE_DUMP], 1, [disable dump memory])
269                        ;;
270                    *) DISABLE_DUMP=no;;
271                esac],
272                [DISABLE_DUMP=no])
273 AC_MSG_RESULT(${DISABLE_DUMP})
274
275
276 dnl check for debug
277 AC_MSG_CHECKING(whether debug code generation should be enabled)
278 AC_ARG_ENABLE([debug],
279               [AS_HELP_STRING(--disable-debug,disable debug code generation [[default=yes]])],
280               [case "${enableval}" in
281                    no) NDEBUG=yes
282                        AC_DEFINE([NDEBUG], 1, [disable debug code])
283                        ;;
284                    *) NDEBUG=no;;
285                esac],
286               [NDEBUG=no])
287
288 if test x"${NDEBUG}" = "xno"; then
289     AC_MSG_RESULT(yes)
290
291     dnl check for binutils headers and libraries on some architectures for the
292     dnl disassembler
293     case "${ARCH_DIR}" in
294         arm | i386 | powerpc | x86_64 )
295             AC_CHECK_HEADER([dis-asm.h],, [AC_MSG_ERROR(cannot find dis-asm.h)])
296
297             case "${OS_DIR}" in
298                 cygwin | darwin )
299                      AC_CHECK_LIB(intl, dcgettext,, [AC_MSG_ERROR(cannot find libintl (from bintuils))])
300                      ;;
301             esac
302
303             AC_CHECK_LIB(iberty, xstrerror,, [AC_MSG_ERROR(cannot find libiberty (from bintuils))])
304             AC_CHECK_LIB(bfd, bfd_get_arch,, [AC_MSG_ERROR(cannot find libbfd (from bintuils))])
305             AC_CHECK_LIB(opcodes, init_disassemble_info,, [AC_MSG_ERROR(cannot find libopcodes (from bintuils))])
306             AC_DEFINE([WITH_BINUTILS_DISASSEMBLER], 1, [use binutils disassembler])
307             AM_CONDITIONAL([WITH_BINUTILS_DISASSEMBLER], [true])
308             ;;
309         * )
310             AM_CONDITIONAL([WITH_BINUTILS_DISASSEMBLER], [false])
311             ;;
312     esac
313
314 else
315     AC_MSG_RESULT(no)
316 fi
317 AM_CONDITIONAL([NDEBUG], test x"${NDEBUG}" = "xno")
318
319
320 dnl check for statistics
321 AC_MSG_CHECKING(whether statistics generation should be enabled)
322 AC_ARG_ENABLE([statistics],
323               [AS_HELP_STRING(--disable-statistics,disable statistics generation [[default=yes]])],
324               [case "${enableval}" in
325                    no) ENABLE_STATISTICS=no;;
326                    *) ENABLE_STATISTICS=yes;;
327                esac],
328               [ENABLE_STATISTICS=yes])
329 AC_MSG_RESULT(${ENABLE_STATISTICS})
330 AM_CONDITIONAL([ENABLE_STATISTICS], test x"${ENABLE_STATISTICS}" = "xyes")
331
332 if test x"${ENABLE_STATISTICS}" = "xyes"; then
333     AC_DEFINE([ENABLE_STATISTICS], 1, [enable statistics])
334 fi
335
336
337 dnl check for JVMTI
338 AC_MSG_CHECKING(whether to compile JVMTI support)
339 AC_ARG_ENABLE([jvmti],
340               [AS_HELP_STRING(--enable-jvmti,enable JVMTI [[default=no]])],
341               [case "${enableval}" in
342                    yes) ENABLE_JVMTI=yes;;
343                    *) ENABLE_JVMTI=no;;
344                esac],
345               [ENABLE_JVMTI=no])
346 AC_MSG_RESULT(${ENABLE_JVMTI})
347 AM_CONDITIONAL([ENABLE_JVMTI], test x"${ENABLE_JVMTI}" = "xyes")
348
349 if test x"${ENABLE_JVMTI}" = "xyes"; then
350     AC_DEFINE([ENABLE_JVMTI], 1, [use JVMTI])
351 fi
352
353
354 dnl threads
355 AC_ARG_ENABLE([threads], [AS_HELP_STRING(--enable-threads,enable threads support (none,green,native) [[default=native]])])
356 AC_ARG_ENABLE([__thread], [AS_HELP_STRING(--enable-__thread,use TLS features)], [use__thread=$enableval], [use__thread=no])
357
358 AC_MSG_CHECKING(whether to include threads support)
359 enable_threads=${enable_threads:-native}
360 case "$enable_threads" in
361 no | none | single)
362         AC_MSG_RESULT(no)
363         dnl no threads for boehm
364         ac_configure_args="$ac_configure_args --disable-boehm-threads"
365         AM_CONDITIONAL([USE_THREADS], [false])
366         AM_CONDITIONAL([NATIVE_THREADS], [false])
367         ;;
368
369 green | native | posix | pthreads)
370         AC_DEFINE([USE_THREADS], 1, [use threads])
371
372         AM_CONDITIONAL([USE_THREADS], [true])
373
374         if test x"$enable_threads" != "xgreen"; then
375                 AC_MSG_RESULT(yes, native)
376                 AC_CHECK_LIB(pthread, main)
377                 AC_DEFINE([NATIVE_THREADS], 1, [use pthreads])
378
379                 CFLAGS="$CFLAGS -D_REENTRANT"
380
381                 dnl tell boehm to support threads as well
382                 ac_configure_args="$ac_configure_args --enable-boehm-threads=posix"
383                 AM_CONDITIONAL([NATIVE_THREADS], [true])
384
385         else
386                 AC_MSG_RESULT(yes, green)
387
388                 dnl no threads for boehm
389                 ac_configure_args="$ac_configure_args --disable-boehm-threads"
390                 AM_CONDITIONAL([NATIVE_THREADS], [false])
391         fi
392     ;;
393 *)
394     AC_MSG_ERROR($enable_threads is an unknown thread package)
395     ;;
396 esac
397
398
399 dnl Check whether the compiler supports the __thread keyword.
400 if test "x$use__thread" != xno; then
401   AC_CACHE_CHECK([for __thread], ac_cv_gcc___thread,
402   [cat > conftest.c <<\EOF
403 __thread int a = 42;
404 EOF
405   if AC_TRY_COMMAND([${CC-cc} $CFLAGS -c conftest.c >&AS_MESSAGE_LOG_FD]); then
406     ac_cv_gcc___thread=yes 
407   else
408     ac_cv_gcc___thread=no
409   fi
410   rm -f conftest*])
411   if test "$ac_cv_gcc___thread" = yes; then
412     AC_DEFINE([HAVE___THREAD], 1, [have __thread])
413   fi
414 else
415   ac_cv_gcc___thread=no
416 fi
417
418
419 dnl check if linear scan register allocator(lsra) should be used
420 AC_MSG_CHECKING(whether lsra should be supported)
421 AC_ARG_ENABLE([lsra],
422               [AS_HELP_STRING(--enable-lsra,enable linear scan register allocator [[default=yes]])],
423               [case "${enableval}" in
424                    no) ENABLE_LSRA=no;;
425                    *) ENABLE_LSRA=yes;;
426                esac],
427               [ENABLE_LSRA=yes])
428 AC_MSG_RESULT(${ENABLE_LSRA})
429 AM_CONDITIONAL([ENABLE_LSRA], test x"${ENABLE_LSRA}" = "xyes")
430    
431 if test x"${ENABLE_LSRA}" = "xyes"; then
432     AC_DEFINE([ENABLE_LSRA], 1, [enable lsra])
433 fi
434
435
436 dnl check for inlining
437 dnl AC_ARG_ENABLE([inlining], [AS_HELP_STRING(--disable-inlining,disable method inlining [[default=yes]])])
438
439 dnl AC_MSG_CHECKING(whether method inlining should be disabled)
440 dnl if test x"$enable_inlining" = "xno"; then
441 dnl     AC_MSG_RESULT(yes)
442 dnl     AM_CONDITIONAL([USE_INLINING], [false])
443 dnl else
444 dnl     AC_MSG_RESULT(no)
445         AC_DEFINE([USE_INLINING], 1, [use method inlining])
446         AM_CONDITIONAL([USE_INLINING], [true])
447 dnl fi
448
449
450 dnl check for instruction scheduler
451 AC_ARG_ENABLE([scheduler], [AS_HELP_STRING(--enable-scheduler,enable instruction scheduler [[default=no]])])
452
453 AC_MSG_CHECKING(whether instruction scheduler should be supported)
454 if test x"${USE_SCHEDULER}" = "x1" -o x"$enable_scheduler" = "xyes"; then
455         case "${ARCH_DIR}" in
456                 xdspcore )
457                         ;;
458                 * )
459                         AC_MSG_ERROR(instruction scheduler is not available for ${ARCH_DIR} code generator)
460                         ;;
461         esac
462
463         AC_MSG_RESULT(yes)
464         AC_DEFINE([USE_SCHEDULER], 1, [use scheduler])
465         AM_CONDITIONAL([USE_SCHEDULER], [true])
466 else
467         AC_MSG_RESULT(no)
468         AM_CONDITIONAL([USE_SCHEDULER], [false])
469 fi
470
471
472 dnl check if zlib should be used
473 AC_MSG_CHECKING(whether zip archives should be supported)
474 AC_ARG_ENABLE([zlib],
475               [AS_HELP_STRING(--enable-zlib,enable zip archive class storage (needs zlib) [[default=yes]])],
476               [case "${enableval}" in
477                   no) ENABLE_ZLIB=yes;;
478                   *) ENABLE_ZLIB=no;;
479                esac],
480               [ENABLE_ZLIB=yes])
481 AC_MSG_RESULT(${ENABLE_ZLIB})
482
483 if test x"${ENABLE_ZLIB}" = "xyes"; then
484     AC_CHECK_HEADERS([zlib.h],, [AC_MSG_ERROR(cannot find zlib.h)])
485     AC_CHECK_LIB(z, inflate,, [AC_MSG_ERROR(cannot find libz)])
486     AC_DEFINE([ENABLE_ZLIB], 1, [use zlib])
487 fi
488 AM_CONDITIONAL([ENABLE_ZLIB], test x"${ENABLE_ZLIB}" = "xyes")
489
490
491 dnl check if CACAO should be linked statically
492 AC_MSG_CHECKING(whether to link GNU classpath native libraries statically into CACAO)
493 AC_ARG_ENABLE([staticvm],
494               [AS_HELP_STRING(--enable-staticvm, link GNU classpath native libraries statically into CACAO [[default=no]])],
495               [case "${enableval}" in
496                   yes) ENABLE_STATICVM=yes;;
497                   *) ENABLE_STATICVM=no;;
498                esac],
499               [ENABLE_STATICVM=no])
500 AC_MSG_RESULT(${ENABLE_STATICVM})
501
502 if test x"${ENABLE_STATICVM}" = "xyes"; then
503     AC_DEFINE([ENABLE_STATICVM], 1, [link CACAO statically])
504
505     dnl check for some classpath related stuff when we link statically
506     AM_ICONV_LINK
507 else
508     AC_CHECK_HEADERS([ltdl.h],, [AC_MSG_ERROR(cannot find ltdl.h)])
509     AC_CHECK_LIB(ltdl, lt_dlopen,, [AC_MSG_ERROR(cannot find libltdl)])
510 fi
511 AM_CONDITIONAL([ENABLE_STATICVM], test x"${ENABLE_STATICVM}" = "xyes")
512 AC_SUBST(ENABLE_STATICVM)
513
514
515 dnl is GNU classpath installed somewhere different
516 AC_MSG_CHECKING(where GNU Classpath is installed)
517 AC_ARG_WITH([classpath-prefix],
518             [AS_HELP_STRING(--with-classpath-prefix=<dir>,installation directory of GNU Classpath [[default=/usr/local/classpath]])],
519             [CLASSPATH_PREFIX=${withval}],
520             [CLASSPATH_PREFIX=/usr/local/classpath])
521 AC_MSG_RESULT(${CLASSPATH_PREFIX})
522 AC_DEFINE_UNQUOTED([CLASSPATH_PREFIX], "${CLASSPATH_PREFIX}", [GNU Classpath installation directory])
523 AC_SUBST(CLASSPATH_PREFIX)
524
525 AC_MSG_CHECKING(where GNU Classpath libraries are installed)
526 AC_ARG_WITH([classpath-libdir],
527             [AS_HELP_STRING(--with-classpath-libdir=<dir>,installation directory of GNU Classpath libraries [[default=/usr/local/classpath/lib]])],
528             [CLASSPATH_LIBDIR=${withval}],
529             [CLASSPATH_LIBDIR=${CLASSPATH_PREFIX}/lib])
530 AC_MSG_RESULT(${CLASSPATH_LIBDIR})
531
532 dnl expand CLASSPATH_LIBDIR to something that is usable in C code
533 AS_AC_EXPAND([CLASSPATH_LIBDIR], ${CLASSPATH_LIBDIR})
534 AC_DEFINE_UNQUOTED([CLASSPATH_LIBDIR], "${CLASSPATH_LIBDIR}", [GNU Classpath libraries installation directory])
535
536 AC_SUBST(CLASSPATH_LIBDIR)
537
538
539
540 dnl Maybe the user has Classpath installed 'flat'.
541 AC_ARG_WITH([flat-classpath], [AS_HELP_STRING(--with-flat-classpath, GNU Classpath is not zipped in the install directory)])
542 if test x"$with_flat_classpath" = "x"; then
543         GLIBJZ=glibj.zip
544 else
545         GLIBJZ=
546 fi
547 AC_SUBST(GLIBJZ)
548 AC_DEFINE_UNQUOTED(GLIBJZ_STRING, "$GLIBJZ", [define to the string base name of the classpath zip file])
549
550
551 dnl check for some programs we need
552 AC_PROG_JAVAC
553 AC_PATH_PROG(ZIP, zip)
554 if test -z "${ZIP}"; then
555     AC_MSG_ERROR([cannot find zip])
556 fi
557
558
559 dnl now configure subpackages
560 dnl the export is not my favorite (is there another way?)
561 export CFLAGS
562 AC_CONFIG_SUBDIRS(src/boehm-gc)
563
564 AC_CONFIG_FILES([Makefile]
565                 [contrib/Makefile]
566                 [contrib/setenvinstalled]
567                 [contrib/setenvsource]
568                 [doc/Makefile]
569                 [doc/handbook/Makefile]
570                 [man/Makefile]
571                 [src/Makefile]
572                 [src/cacao/Makefile]
573                 [src/cacaoh/Makefile]
574                 [src/fdlibm/Makefile]
575                 [src/lib/Makefile]
576                 [src/mm/Makefile]
577                 [src/native/Makefile]
578                 [src/native/include/Makefile]
579                 [src/native/jvmti/Makefile]
580                 [src/native/tools/Makefile]
581                 [src/native/vm/Makefile]
582                 [src/scripts/Makefile]
583                 [src/scripts/java]
584                 [src/scripts/rmiregistry]
585                 [src/threads/Makefile]
586                 [src/threads/green/Makefile]
587                 [src/threads/native/Makefile]
588                 [src/toolbox/Makefile]
589                 [src/vm/Makefile]
590                 [src/vm/jit/Makefile]
591                 [src/vm/jit/allocator/Makefile]
592                 [src/vm/jit/alpha/Makefile]
593                 [src/vm/jit/alpha/freebsd/Makefile]
594                 [src/vm/jit/alpha/linux/Makefile]
595                 [src/vm/jit/i386/Makefile]
596                 [src/vm/jit/i386/freebsd/Makefile]
597                 [src/vm/jit/i386/linux/Makefile]
598                 [src/vm/jit/intrp/Makefile]
599                 [src/vm/jit/inline/Makefile]
600                 [src/vm/jit/loop/Makefile]
601                 [src/vm/jit/mips/Makefile]
602                 [src/vm/jit/mips/irix/Makefile]
603                 [src/vm/jit/mips/linux/Makefile]
604                 [src/vm/jit/powerpc/Makefile]
605                 [src/vm/jit/powerpc/darwin/Makefile]
606                 [src/vm/jit/powerpc/linux/Makefile]
607                 [src/vm/jit/schedule/Makefile]
608                 [src/vm/jit/tools/Makefile]
609                 [src/vm/jit/verify/Makefile]
610                 [src/vm/jit/x86_64/Makefile]
611                 [tests/Makefile]
612                 [tests/codepatching/Makefile]
613                 [tests/native/Makefile]
614                 [tests/regression/Makefile])
615
616 AC_OUTPUT
617
618
619 ## Local variables:
620 ## mode: m4
621 ## indent-tabs-mode: t
622 ## c-basic-offset: 4
623 ## tab-width: 8
624 ## compile-command: "automake --add-missing"
625 ## End: