1 dnl Example for use of GNU gettext.
2 dnl Copyright (C) 2003 Free Software Foundation, Inc.
3 dnl This file is in the public domain.
5 dnl Configuration file - processed by autoconf.
8 AC_CONFIG_SRCDIR(Hello.java)
9 AM_INIT_AUTOMAKE(hello-java, 0)
11 dnl Check whether we can build native executable.
12 AC_ARG_ENABLE(java-exe,
13 [ --disable-java-exe compile Java to bytecode only, not to native code],
14 :, enable_java_exe=yes)
16 if test "$enable_java_exe" != no && test -n "$HAVE_GCJ"; then
21 AC_SUBST(BUILDJAVAEXE)
22 AM_CONDITIONAL([USEJEXE], [test "$BUILDJAVAEXE" = yes])
25 dnl Check whether we can build Java programs at all.
27 AC_CHECK_PROG(JAR, jar, jar)
28 if test -n "$HAVE_JAVACOMP" && test -n "$JAR"; then
35 dnl Check whether we can execute Java programs.
37 if test -n "$HAVE_JAVAEXEC" && test $BUILDJAVA = yes; then
44 dnl Checks for compiler output filename suffixes.
48 dnl Checks for needed libraries.
49 AM_PATH_PROG_WITH_TEST([GETTEXT_WITH_LIBINTL_JAR], [gettext],
50 [{ basedir=`echo "$ac_dir" | sed -e 's,/bin$,,'`; test -r "$basedir"/share/gettext/libintl.jar; }])
51 if test -z "$GETTEXT_WITH_LIBINTL_JAR"; then
52 echo "Required library libintl.jar not found." 1>&2
56 basedir=`echo "$GETTEXT_WITH_LIBINTL_JAR" | sed -e 's,/[^/]*$,,' | sed -e 's,/bin$,,'`
58 LIBINTL_JAR="$basedir"/share/gettext/libintl.jar
59 AC_SUBST([LIBINTL_JAR])
61 dnl Support for the po directory.
64 AC_CONFIG_FILES([Makefile])
65 AC_CONFIG_FILES([javacomp.sh])
66 AC_CONFIG_FILES([javaexec.sh])
67 AC_CONFIG_FILES([m4/Makefile])
68 AC_CONFIG_FILES([po/Makefile], [AM_POSTPROCESS_PO_MAKEFILE])