Reid Spencer | 820dab7 | 2004-09-04 19:48:50 +0000 | [diff] [blame] | 1 | dnl ************************************************************************** |
| 2 | dnl * Initialize |
| 3 | dnl ************************************************************************** |
| 4 | AC_INIT([[[Stacker]]],[[[1.0]]],[rspencer@x10sys.com]) |
| 5 | |
| 6 | dnl Place all of the extra autoconf files into the config subdirectory |
| 7 | AC_CONFIG_AUX_DIR([autoconf]) |
| 8 | |
Reid Spencer | 011f5ca | 2004-09-15 06:19:53 +0000 | [diff] [blame] | 9 | dnl Verify that the source directory is valid |
| 10 | AC_CONFIG_SRCDIR([Makefile.common.in]) |
Reid Spencer | 820dab7 | 2004-09-04 19:48:50 +0000 | [diff] [blame] | 11 | |
| 12 | dnl Configure Makefiles |
| 13 | dnl List every Makefile that ecists within your source tree |
| 14 | |
| 15 | AC_CONFIG_MAKEFILE(Makefile) |
| 16 | AC_CONFIG_MAKEFILE(lib/Makefile) |
| 17 | AC_CONFIG_MAKEFILE(lib/compiler/Makefile) |
| 18 | AC_CONFIG_MAKEFILE(lib/runtime/Makefile) |
Reid Spencer | e07d9aa | 2004-09-05 16:42:30 +0000 | [diff] [blame] | 19 | AC_CONFIG_MAKEFILE(test/Makefile) |
Reid Spencer | 820dab7 | 2004-09-04 19:48:50 +0000 | [diff] [blame] | 20 | AC_CONFIG_MAKEFILE(tools/Makefile) |
| 21 | AC_CONFIG_MAKEFILE(tools/stkrc/Makefile) |
| 22 | |
| 23 | dnl ************************************************************************** |
| 24 | dnl * Determine which system we are building on |
| 25 | dnl ************************************************************************** |
| 26 | |
| 27 | dnl ************************************************************************** |
| 28 | dnl * Check for programs. |
| 29 | dnl ************************************************************************** |
Reid Spencer | 011f5ca | 2004-09-15 06:19:53 +0000 | [diff] [blame] | 30 | AC_PROG_LIBTOOL |
| 31 | dnl Get libtool's idea of what the shared library suffix is. |
| 32 | dnl (This is a hack; it relies on undocumented behavior.) |
| 33 | AC_MSG_CHECKING([for shared library suffix]) |
| 34 | eval "SHLIBEXT=$shrext" |
| 35 | AC_MSG_RESULT($SHLIBEXT) |
| 36 | dnl Propagate it to the Makefiles and config.h (for gccld & bugpoint). |
| 37 | AC_SUBST(SHLIBEXT,$SHLIBEXT) |
| 38 | AC_DEFINE_UNQUOTED(SHLIBEXT,"$SHLIBEXT", |
| 39 | [Extension that shared libraries have, |
| 40 | e.g., ".so".]) |
| 41 | |
Reid Spencer | 820dab7 | 2004-09-04 19:48:50 +0000 | [diff] [blame] | 42 | |
Reid Spencer | 820dab7 | 2004-09-04 19:48:50 +0000 | [diff] [blame] | 43 | |
| 44 | dnl ************************************************************************** |
| 45 | dnl * Check for libraries. |
| 46 | dnl ************************************************************************** |
| 47 | |
| 48 | dnl ************************************************************************** |
| 49 | dnl * Checks for header files. |
| 50 | dnl ************************************************************************** |
| 51 | |
| 52 | dnl ************************************************************************** |
| 53 | dnl * Checks for typedefs, structures, and compiler characteristics. |
| 54 | dnl ************************************************************************** |
| 55 | |
| 56 | dnl ************************************************************************** |
| 57 | dnl * Checks for library functions. |
| 58 | dnl ************************************************************************** |
| 59 | |
| 60 | dnl ************************************************************************** |
| 61 | dnl * Enable various compile-time options |
| 62 | dnl ************************************************************************** |
| 63 | |
| 64 | dnl ************************************************************************** |
| 65 | dnl * Set the location of various third-party software packages |
| 66 | dnl ************************************************************************** |
| 67 | |
| 68 | dnl Location of LLVM source code |
| 69 | AC_ARG_WITH(llvmsrc,AC_HELP_STRING([--with-llvmsrc],[Location of LLVM Source Code]),AC_SUBST(LLVM_SRC,[$withval]),AC_SUBST(LLVM_SRC,[`cd ${srcdir}/../..; pwd`])) |
| 70 | |
| 71 | dnl Location of LLVM object code |
| 72 | AC_ARG_WITH(llvmobj,AC_HELP_STRING([--with-llvmobj],[Location of LLVM Object Code]),AC_SUBST(LLVM_OBJ,[$withval]),AC_SUBST(LLVM_OBJ,[`cd ../..; pwd`])) |
| 73 | |
| 74 | dnl ************************************************************************** |
| 75 | dnl * Create the output files |
| 76 | dnl ************************************************************************** |
| 77 | AC_OUTPUT(Makefile.common) |