home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 20 / AACD20.BIN / AACD / Programming / Jikes / Source / aclocal.m4 < prev    next >
Encoding:
M4 Source File  |  2001-02-27  |  12.4 KB  |  409 lines

  1. # aclocal.m4 generated automatically by aclocal 1.4a
  2.  
  3. # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000
  4. # Free Software Foundation, Inc.
  5. # This file is free software; the Free Software Foundation
  6. # gives unlimited permission to copy and/or distribute it,
  7. # with or without modifications, as long as this notice is preserved.
  8.  
  9. # This program is distributed in the hope that it will be useful,
  10. # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
  11. # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
  12. # PARTICULAR PURPOSE.
  13.  
  14. dnl If you want to make a new macro available for use
  15. dnl in configure.in, add the macro file to the src/m4 subdirectory
  16. dnl and add the name of the m4 macro file with a builtin().
  17. dnl For example, add a FOO macro from foo.m4 like so:
  18. dnl builtin(include,foo.m4)
  19.  
  20. dnl For lots of handy autoconf C++ macros, go to
  21. dnl http://research.cys.de/autoconf-archive/
  22.  
  23. builtin(include,src/m4/ac_cxx_bool.m4)
  24. builtin(include,src/m4/ac_cxx_exceptions.m4)
  25. builtin(include,src/m4/ac_cxx_namespaces.m4)
  26. builtin(include,src/m4/ac_cxx_have_std.m4)
  27. builtin(include,src/m4/acx_check_pathname_style.m4)
  28. builtin(include,src/m4/ac_check_mathlib.m4)
  29. builtin(include,src/m4/ac_cxx_check_set_new_handler.m4)
  30. builtin(include,src/m4/ac_check_error_discard_const.m4)
  31. builtin(include,src/m4/ac_check_wcs_funcs.m4)
  32. builtin(include,src/m4/ac_check_iconv.m4)
  33. builtin(include,src/m4/ac_cxx_member_constants.m4)
  34. builtin(include,src/m4/ac_cxx_explicit.m4)
  35. builtin(include,src/m4/ac_cxx_rtti.m4)
  36. builtin(include,src/m4/ac_cxx_const_cast.m4)
  37. builtin(include,src/m4/ac_cxx_dynamic_cast.m4)
  38. builtin(include,src/m4/ac_cxx_reinterpret_cast.m4)
  39. builtin(include,src/m4/ac_cxx_static_cast.m4)
  40.  
  41. dnl builtin(include,src/m4/)
  42.  
  43.  
  44. # Do all the work for Automake.  This macro actually does too much --
  45. # some checks are only needed if your package does certain things.
  46. # But this isn't really a big deal.
  47.  
  48. # serial 3
  49.  
  50. AC_PREREQ([2.13])
  51.  
  52. # AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED)
  53. # -----------------------------------------------------------
  54. # If MACRO-NAME is provided do IF-PROVIDED, else IF-NOT-PROVIDED.
  55. # The purpose of this macro is to provide the user with a means to
  56. # check macros which are provided without letting her know how the
  57. # information is coded.
  58. # If this macro is not defined by Autoconf, define it here.
  59. ifdef([AC_PROVIDE_IFELSE],
  60.       [],
  61.       [define([AC_PROVIDE_IFELSE],
  62.               [ifdef([AC_PROVIDE_$1],
  63.                      [$2], [$3])])])
  64.  
  65.  
  66. # AM_INIT_AUTOMAKE(PACKAGE,VERSION, [NO-DEFINE])
  67. # ----------------------------------------------
  68. AC_DEFUN([AM_INIT_AUTOMAKE],
  69. [dnl We require 2.13 because we rely on SHELL being computed by configure.
  70. AC_REQUIRE([AC_PROG_INSTALL])dnl
  71. # test to see if srcdir already configured
  72. if test "`CDPATH=:; cd $srcdir && pwd`" != "`pwd`" &&
  73.    test -f $srcdir/config.status; then
  74.   AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
  75. fi
  76.  
  77. # Define the identity of the package.
  78. PACKAGE=$1
  79. AC_SUBST(PACKAGE)dnl
  80. VERSION=$2
  81. AC_SUBST(VERSION)dnl
  82. ifelse([$3],,
  83. [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
  84. AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])
  85.  
  86. # Some tools Automake needs.
  87. AC_REQUIRE([AM_SANITY_CHECK])dnl
  88. AC_REQUIRE([AC_ARG_PROGRAM])dnl
  89. AM_MISSING_PROG(ACLOCAL, aclocal)
  90. AM_MISSING_PROG(AUTOCONF, autoconf)
  91. AM_MISSING_PROG(AUTOMAKE, automake)
  92. AM_MISSING_PROG(AUTOHEADER, autoheader)
  93. AM_MISSING_PROG(MAKEINFO, makeinfo)
  94. AM_MISSING_PROG(AMTAR, tar)
  95. AM_MISSING_INSTALL_SH
  96. # We need awk for the "check" target.  The system "awk" is bad on
  97. # some platforms.
  98. AC_REQUIRE([AC_PROG_AWK])dnl
  99. AC_REQUIRE([AC_PROG_MAKE_SET])dnl
  100. AC_REQUIRE([AM_DEP_TRACK])dnl
  101. AC_REQUIRE([AM_SET_DEPDIR])dnl
  102. AC_PROVIDE_IFELSE([AC_PROG_CC],
  103.                   [AM_DEPENDENCIES(CC)],
  104.                   [define([AC_PROG_CC],
  105.                           defn([AC_PROG_CC])[AM_DEPENDENCIES(CC)
  106. ])])dnl
  107. AC_PROVIDE_IFELSE([AC_PROG_CXX],
  108.                   [AM_DEPENDENCIES(CXX)],
  109.                   [define([AC_PROG_CXX],
  110.                           defn([AC_PROG_CXX])[AM_DEPENDENCIES(CXX)
  111. ])])dnl
  112. ])
  113.  
  114. #
  115. # Check to make sure that the build environment is sane.
  116. #
  117.  
  118. AC_DEFUN([AM_SANITY_CHECK],
  119. [AC_MSG_CHECKING([whether build environment is sane])
  120. # Just in case
  121. sleep 1
  122. echo timestamp > conftestfile
  123. # Do `set' in a subshell so we don't clobber the current shell's
  124. # arguments.  Must try -L first in case configure is actually a
  125. # symlink; some systems play weird games with the mod time of symlinks
  126. # (eg FreeBSD returns the mod time of the symlink's containing
  127. # directory).
  128. if (
  129.    set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
  130.    if test "[$]*" = "X"; then
  131.       # -L didn't work.
  132.       set X `ls -t $srcdir/configure conftestfile`
  133.    fi
  134.    if test "[$]*" != "X $srcdir/configure conftestfile" \
  135.       && test "[$]*" != "X conftestfile $srcdir/configure"; then
  136.  
  137.       # If neither matched, then we have a broken ls.  This can happen
  138.       # if, for instance, CONFIG_SHELL is bash and it inherits a
  139.       # broken ls alias from the environment.  This has actually
  140.       # happened.  Such a system could not be considered "sane".
  141.       AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
  142. alias in your environment])
  143.    fi
  144.  
  145.    test "[$]2" = conftestfile
  146.    )
  147. then
  148.    # Ok.
  149.    :
  150. else
  151.    AC_MSG_ERROR([newly created file is older than distributed files!
  152. Check your system clock])
  153. fi
  154. rm -f conftest*
  155. AC_MSG_RESULT(yes)])
  156.  
  157. # AM_MISSING_PROG(NAME, PROGRAM)
  158. AC_DEFUN([AM_MISSING_PROG], [
  159. AC_REQUIRE([AM_MISSING_HAS_RUN])
  160. $1=${$1-"${am_missing_run}$2"}
  161. AC_SUBST($1)])
  162.  
  163. # Like AM_MISSING_PROG, but only looks for install-sh.
  164. # AM_MISSING_INSTALL_SH()
  165. AC_DEFUN([AM_MISSING_INSTALL_SH], [
  166. AC_REQUIRE([AM_MISSING_HAS_RUN])
  167. if test -z "$install_sh"; then
  168.    install_sh="$ac_aux_dir/install-sh"
  169.    test -f "$install_sh" || install_sh="$ac_aux_dir/install.sh"
  170.    test -f "$install_sh" || install_sh="${am_missing_run}${ac_auxdir}/install-sh"
  171.    dnl FIXME: an evil hack: we remove the SHELL invocation from
  172.    dnl install_sh because automake adds it back in.  Sigh.
  173.    install_sh="`echo $install_sh | sed -e 's/\${SHELL}//'`"
  174. fi
  175. AC_SUBST(install_sh)])
  176.  
  177. # AM_MISSING_HAS_RUN.
  178. # Define MISSING if not defined so far and test if it supports --run.
  179. # If it does, set am_missing_run to use it, otherwise, to nothing.
  180. AC_DEFUN([AM_MISSING_HAS_RUN], [
  181. test x"${MISSING+set}" = xset || \
  182.   MISSING="\${SHELL} `CDPATH=:; cd $ac_aux_dir && pwd`/missing"
  183. # Use eval to expand $SHELL
  184. if eval "$MISSING --run :"; then
  185.   am_missing_run="$MISSING --run "
  186. else
  187.   am_missing_run=
  188.   am_backtick='`'
  189.   AC_MSG_WARN([${am_backtick}missing' script is too old or missing])
  190. fi
  191. ])
  192.  
  193. # See how the compiler implements dependency checking.
  194. # Usage:
  195. # AM_DEPENDENCIES(NAME)
  196. # NAME is "CC", "CXX" or "OBJC".
  197.  
  198. # We try a few techniques and use that to set a single cache variable.
  199.  
  200. AC_DEFUN([AM_DEPENDENCIES],[
  201. AC_REQUIRE([AM_SET_DEPDIR])
  202. AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])
  203. ifelse([$1],CC,[
  204. AC_REQUIRE([AC_PROG_CC])
  205. AC_REQUIRE([AC_PROG_CPP])
  206. depcc="$CC"
  207. depcpp="$CPP"],[$1],CXX,[
  208. AC_REQUIRE([AC_PROG_CXX])
  209. AC_REQUIRE([AC_PROG_CXXCPP])
  210. depcc="$CXX"
  211. depcpp="$CXXCPP"],[$1],OBJC,[
  212. am_cv_OBJC_dependencies_compiler_type=gcc],[
  213. AC_REQUIRE([AC_PROG_][$1])
  214. depcc="$[$1]"
  215. depcpp=""])
  216. AC_MSG_CHECKING([dependency style of $depcc])
  217. AC_CACHE_VAL(am_cv_[$1]_dependencies_compiler_type,[
  218. if test -z "$AMDEP"; then
  219.   echo '#include "conftest.h"' > conftest.c
  220.   echo 'int i;' > conftest.h
  221.  
  222.   am_cv_[$1]_dependencies_compiler_type=none
  223.   for depmode in `sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < "$am_depcomp"`; do
  224.     case "$depmode" in
  225.     nosideeffect)
  226.       # after this tag, mechanisms are not by side-effect, so they'll
  227.       # only be used when explicitly requested
  228.       if test "x$enable_dependency_tracking" = xyes; then
  229.     continue
  230.       else
  231.     break
  232.       fi
  233.       ;;
  234.     none) break ;;
  235.     esac
  236.     # We check with `-c' and `-o' for the sake of the "dashmstdout"
  237.     # mode.  It turns out that the SunPro C++ compiler does not properly
  238.     # handle `-M -o', and we need to detect this.
  239.     if depmode="$depmode" \
  240.        source=conftest.c object=conftest.o \
  241.        depfile=conftest.Po tmpdepfile=conftest.TPo \
  242.        $SHELL $am_depcomp $depcc -c conftest.c -o conftest.o >/dev/null 2>&1 &&
  243.        grep conftest.h conftest.Po > /dev/null 2>&1; then
  244.       am_cv_[$1]_dependencies_compiler_type="$depmode"
  245.       break
  246.     fi
  247.   done
  248.  
  249.   rm -f conftest.*
  250. else
  251.   am_cv_[$1]_dependencies_compiler_type=none
  252. fi
  253. ])
  254. AC_MSG_RESULT($am_cv_[$1]_dependencies_compiler_type)
  255. [$1]DEPMODE="depmode=$am_cv_[$1]_dependencies_compiler_type"
  256. AC_SUBST([$1]DEPMODE)
  257. ])
  258.  
  259. # Choose a directory name for dependency files.
  260. # This macro is AC_REQUIREd in AM_DEPENDENCIES
  261.  
  262. AC_DEFUN([AM_SET_DEPDIR],[
  263. if test -d .deps || mkdir .deps 2> /dev/null || test -d .deps; then
  264.   DEPDIR=.deps
  265. else
  266.   DEPDIR=_deps
  267. fi
  268. AC_SUBST(DEPDIR)
  269. ])
  270.  
  271. AC_DEFUN([AM_DEP_TRACK],[
  272. AC_ARG_ENABLE(dependency-tracking,
  273. [  --disable-dependency-tracking Speeds up one-time builds
  274.   --enable-dependency-tracking  Do not reject slow dependency extractors])
  275. if test "x$enable_dependency_tracking" = xno; then
  276.   AMDEP="#"
  277. else
  278.   am_depcomp="$ac_aux_dir/depcomp"
  279.   if test ! -f "$am_depcomp"; then
  280.     AMDEP="#"
  281.   else
  282.     AMDEP=
  283.   fi
  284. fi
  285. AC_SUBST(AMDEP)
  286. if test -z "$AMDEP"; then
  287.   AMDEPBACKSLASH='\'
  288. else
  289.   AMDEPBACKSLASH=
  290. fi
  291. pushdef([subst], defn([AC_SUBST]))
  292. subst(AMDEPBACKSLASH)
  293. popdef([subst])
  294. ])
  295.  
  296. # Generate code to set up dependency tracking.
  297. # This macro should only be invoked once -- use via AC_REQUIRE.
  298. # Usage:
  299. # AM_OUTPUT_DEPENDENCY_COMMANDS
  300.  
  301. #
  302. # This code is only required when automatic dependency tracking
  303. # is enabled.  FIXME.  This creates each `.P' file that we will
  304. # need in order to bootstrap the dependency handling code.
  305. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],[
  306. AC_OUTPUT_COMMANDS([
  307. test x"$AMDEP" != x"" ||
  308. for mf in $CONFIG_FILES; do
  309.   case "$mf" in
  310.   Makefile) dirpart=.;;
  311.   */Makefile) dirpart=`echo "$mf" | sed -e 's|/[^/]*$||'`;;
  312.   *) continue;;
  313.   esac
  314.   grep '^DEP_FILES *= *[^ #]' < "$mf" > /dev/null || continue
  315.   # Extract the definition of DEP_FILES from the Makefile without
  316.   # running `make'.
  317.   DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"`
  318.   test -z "$DEPDIR" && continue
  319.   # When using ansi2knr, U may be empty or an underscore; expand it
  320.   U=`sed -n -e '/^U = / s///p' < "$mf"`
  321.   test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR"
  322.   # We invoke sed twice because it is the simplest approach to
  323.   # changing $(DEPDIR) to its actual value in the expansion.
  324.   for file in `sed -n -e '
  325.     /^DEP_FILES = .*\\\\$/ {
  326.       s/^DEP_FILES = //
  327.       :loop
  328.     s/\\\\$//
  329.     p
  330.     n
  331.     /\\\\$/ b loop
  332.       p
  333.     }
  334.     /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
  335.        sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
  336.     # Make sure the directory exists.
  337.     test -f "$dirpart/$file" && continue
  338.     fdir=`echo "$file" | sed -e 's|/[^/]*$||'`
  339.     $ac_aux_dir/mkinstalldirs "$dirpart/$fdir" > /dev/null 2>&1
  340.     # echo "creating $dirpart/$file"
  341.     echo '# dummy' > "$dirpart/$file"
  342.   done
  343. done
  344. ], [AMDEP="$AMDEP"
  345. ac_aux_dir="$ac_aux_dir"])])
  346.  
  347. # Like AC_CONFIG_HEADER, but automatically create stamp file.
  348.  
  349. # serial 3
  350.  
  351. # When config.status generates a header, we must update the stamp-h file.
  352. # This file resides in the same directory as the config header
  353. # that is generated.  We must strip everything past the first ":",
  354. # and everything past the last "/".
  355.  
  356. AC_PREREQ([2.12])
  357.  
  358. AC_DEFUN([AM_CONFIG_HEADER],
  359. [AC_CONFIG_HEADER([$1])
  360.   AC_OUTPUT_COMMANDS(
  361.    ifelse(patsubst([$1], [[^ ]], []),
  362.       [],
  363.       [test -z "$CONFIG_HEADERS" || echo timestamp >dnl
  364.        patsubst([$1], [^\([^:]*/\)?.*], [\1])stamp-h]),
  365.   [am_indx=1
  366.   for am_file in $1; do
  367.     case " $CONFIG_HEADERS " in
  368.     *" $am_file "*)
  369.       echo timestamp > `echo $am_file | sed 's%:.*%%;s%[^/]*$%%'`stamp-h$am_indx
  370.       ;;
  371.     esac
  372.     am_indx=\`expr \$am_indx + 1\`
  373.   done])
  374. ])
  375.  
  376. # Add --enable-maintainer-mode option to configure.
  377. # From Jim Meyering
  378.  
  379. # serial 1
  380.  
  381. AC_DEFUN([AM_MAINTAINER_MODE],
  382. [AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
  383.   dnl maintainer-mode is disabled by default
  384.   AC_ARG_ENABLE(maintainer-mode,
  385. [  --enable-maintainer-mode enable make rules and dependencies not useful
  386.                           (and sometimes confusing) to the casual installer],
  387.       USE_MAINTAINER_MODE=$enableval,
  388.       USE_MAINTAINER_MODE=no)
  389.   AC_MSG_RESULT([$USE_MAINTAINER_MODE])
  390.   AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes])
  391.   MAINT=$MAINTAINER_MODE_TRUE
  392.   AC_SUBST(MAINT)dnl
  393. ]
  394. )
  395.  
  396. # Define a conditional.
  397.  
  398. AC_DEFUN([AM_CONDITIONAL],
  399. [AC_SUBST($1_TRUE)
  400. AC_SUBST($1_FALSE)
  401. if $2; then
  402.   $1_TRUE=
  403.   $1_FALSE='#'
  404. else
  405.   $1_TRUE='#'
  406.   $1_FALSE=
  407. fi])
  408.  
  409.