dnl Process this file with autoconf to produce a configure script. AC_INIT(native/java.net/javanet.c) AC_CANONICAL_HOST PACKAGE="classpath" VERSION="0.0" LIBVERSION="0:0" AC_SUBST(PACKAGE) AC_SUBST(VERSION) AC_SUBST(LIBVERSION) AM_INIT_AUTOMAKE(${PACKAGE}, ${VERSION}) AM_CONFIG_HEADER(config.h) AC_PREFIX_DEFAULT(/usr/local/classpath) dnl Initialize libtool AM_DISABLE_STATIC AM_PROG_LIBTOOL dnl required if SUBDIRS is used AC_PROG_MAKE_SET dnl Checks for programs. dnl AC_PROG_CXX AC_PROG_AWK AC_PROG_CC AC_PROG_CPP AC_PROG_INSTALL AC_PROG_LN_S AC_HEADER_STDC AC_CHECK_HEADERS(unistd.h) AC_C_CONST AC_CHECK_FUNCS(gethostname socket strerror fork pipe execve strtod atof) AC_HEADER_TIME AC_STRUCT_TM AC_STRUCT_TIMEZONE dnl guile checks - shouldn't need now that mauve exists dnl GUILE_FLAGS dnl Initialize maintainer mode dnl AM_MAINTAINER_MODE # We want warnings, lots of warnings :-) if eval "test x$GCC = xyes"; then JAPHAR_GREP_CFLAGS(-Wall, [ CFLAGS="$CFLAGS -Wall" ]) JAPHAR_GREP_CFLAGS(-Wstrict-prototypes, [ CFLAGS="$CFLAGS -Wstrict-prototypes" ]) JAPHAR_GREP_CFLAGS(-Wmissing-prototypes, [ CFLAGS="$CFLAGS -Wmissing-prototypes" ]) JAPHAR_GREP_CFLAGS(-Wmissing-declarations, [ CFLAGS="$CFLAGS -Wmissing-declarations" ]) JAPHAR_GREP_CFLAGS(-Wreturn-type, [ CFLAGS="$CFLAGS -Wreturn-type" ]) JAPHAR_GREP_CFLAGS(-Wcast-align, [ CFLAGS="$CFLAGS -Wcast-align" ]) JAPHAR_GREP_CFLAGS(-pedantic, [ CFLAGS="$CFLAGS -pedantic" ]) fi dnl Check for cthreads, w32 threads, pthreads dnl CLASSPATH_CHECK_THREADS dnl --with-japhar CLASSPATH_CHECK_JAPHAR dnl --with-kaffe CLASSPATH_CHECK_KAFFE dnl if no jvm yet defined, check for japhar if test -z "$JVM" || test "$JVM" = "no"; then CLASSPATH_INTERNAL_CHECK_JAPHAR fi AC_MSG_CHECKING(for defined vm) if test -z "$JVM" || test "$JVM" = "no"; then AC_MSG_ERROR(no: try --with-japhar) else AC_MSG_RESULT(yes) fi dnl must check our conditionals from vm checks AM_CONDITIONAL(JAPHAR, test x$conditional_with_japhar = xtrue) AC_ARG_WITH(java, [ --with-java specify path to a java-like program ], [ if test ${withval} != "" || test ${withval} != "yes" || test ${withval} != "no"; then # set javac to user input value AC_MSG_CHECKING(for java) USER_JABBA=${withval} AC_SUBST(USER_JABBA) AC_MSG_RESULT(${withval}) conditional_with_java=true fi ], [ conditional_with_java=false]) AM_CONDITIONAL(USER_SPECIFIED_JABBA, test x$conditional_with_java = xtrue) AC_ARG_WITH(javah, [ --with-javah specify path to a javah-like program ], [ if test ${withval} != "" || test ${withval} != "yes" || test ${withval} != "no"; then # set javah to user input value AC_MSG_CHECKING(for javah) USER_JAVAH=${withval} AC_SUBST(USER_JAVAH) AC_MSG_RESULT(${withval}) conditional_with_javah=true fi ], [ conditional_with_javah=false ]) AM_CONDITIONAL(USER_SPECIFIED_JAVAH, test x$conditional_with_javah = xtrue) AC_ARG_WITH(classlib, [ --with-classlib specify path to a classes.zip like file ], [ if test ${withval} != "" || test ${withval} != "yes" || test ${withval} != "no"; then # set javac to user input value AM_CONDITIONAL(USER_SPECIFIED_CLASSLIB, test x = y) AC_MSG_CHECKING(for classlib) USER_CLASSLIB=${withval} AC_SUBST(USER_CLASSLIB) AC_MSG_RESULT(${withval}) conditional_with_classlib=true fi ], [ conditional_with_classlib=false ]) AM_CONDITIONAL(USER_SPECIFIED_CLASSLIB, test x$conditional_with_classlib = xtrue) dnl Since most people won't have JavaDeps or Jikes to compute dependencies dnl on the Java source files. This mode also causes the resulting Makefiles dnl to attempt to build java classes where applicable. AC_ARG_ENABLE(maintainer-build, [ --enable-maintainer-build java dependency computation [default=no]], [case "${enableval}" in yes) conditional_maintainer_build=true ;; no) conditional_maintainer_build=false ;; *) AC_MSG_ERROR(bad value ${enableval} for --enable-maintainer-build) ;; esac], [conditional_maintainer_build=false]) dnl This build mode indicates to configure it should compile java classes dnl but not rebuild the .deps file for doing so. The default then is to dnl not build any Java classes (glibj.zip is distributed in the build using dnl the maintainer-build mode) AC_ARG_ENABLE(developer-build, [ --enable-developer-build rebuild glibj.zip [default=no]], [case "${enableval}" in yes) conditional_developer_build=true ;; no) conditional_developer_build=false ;; *) AC_MSG_ERROR(bad value ${enableval} for --enable-developer-build) ;; esac], [conditional_developer_build=false]) AM_CONDITIONAL(MAINTAINER_BUILD, test x$conditional_maintainer_build = xtrue) if test x${conditional_maintainer_build} = "xtrue"; then conditional_developer_build=false fi AM_CONDITIONAL(DEVELOPER_BUILD, test x$conditional_developer_build = xtrue) dnl java dependency creation AC_ARG_WITH(jdeps, [ --with-jdeps specify location of JavaDeps], [ if test ${withval} = "yes" || test ${withval} = ""; then AC_PATH_PROG(JAVADEPS, jdeps, "", $PATH) else AC_PATH_PROG(JAVADEPS, jdeps, "", $PATH:${withval}) fi ], [ if test x"$conditional_maintainer_build" = xtrue; then AC_PATH_PROG(JAVADEPS, jdeps, "", $PATH) fi ]) dnl This is probably useless. AC_PATH_PROG(SH, sh) dnl According to the GNU coding guide, we shouldn't require find dnl however it should be okay since it is only used in maintainer dnl build mode. AC_PATH_PROG(FIND, find) AC_PATH_PROG(ZIP, zip) AC_OUTPUT(Makefile doc/Makefile gnu/java/io/decode/Makefile gnu/java/io/Makefile gnu/java/io/encode/Makefile gnu/java/lang/reflect/Makefile gnu/java/lang/Makefile gnu/java/Makefile gnu/java/beans/editors/Makefile gnu/java/beans/info/Makefile gnu/java/beans/Makefile gnu/java/locale/Makefile gnu/java/net/content/text/Makefile gnu/java/net/content/Makefile gnu/java/net/Makefile gnu/java/net/protocol/file/Makefile gnu/java/net/protocol/http/Makefile gnu/java/net/protocol/Makefile gnu/java/security/Makefile gnu/Makefile gnu/tools/serialver/Makefile gnu/tools/Makefile java/beans/Makefile java/io/Makefile java/lang/reflect/Makefile java/lang/Makefile java/Makefile java/math/Makefile java/net/Makefile java/security/acl/Makefile java/security/interfaces/Makefile java/security/Makefile java/text/Makefile java/util/Makefile native/Makefile native/java.io/Makefile native/java.lang/Makefile native/java.lang.reflect/Makefile native/java.net/Makefile native/java.util/Makefile native/lib/Makefile native/vmi/Makefile resource/java/util/Makefile resource/java/Makefile resource/Makefile vm/reference/gnu/vm/stack/Makefile vm/reference/gnu/vm/Makefile vm/reference/gnu/Makefile vm/reference/java/lang/reflect/Makefile vm/reference/java/lang/Makefile vm/reference/java/Makefile vm/reference/Makefile vm/Makefile lib/deps.sh lib/gen-classlist.sh lib/Makefile, [ chmod 755 lib/deps.sh chmod 755 lib/gen-classlist.sh ]) #AC_OUTPUT_COMMANDS(chmod 755 lib/deps.sh) #AC_OUTPUT_COMMANDS(chmod 755 lib/gen-classlist.sh)