]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
Add the ability to ignore JVMs that lack certain capabilities.
authorBruno Haible <bruno@clisp.org>
Thu, 13 Nov 2003 15:36:30 +0000 (15:36 +0000)
committerBruno Haible <bruno@clisp.org>
Tue, 23 Jun 2009 10:11:14 +0000 (12:11 +0200)
gettext-tools/m4/ChangeLog
gettext-tools/m4/javaexec.m4

index ac20ac752ff27f3dedaec55fe520eb2e795bdc78..70824af67f3237aa1d0c05bf29574c8b19ed4836 100644 (file)
@@ -1,3 +1,8 @@
+2003-11-09  Bruno Haible  <bruno@clisp.org>
+
+       * javaexec.m4 (gt_JAVAEXEC): Accept two optional arguments, denoting
+       a test class to execute.
+
 2003-11-11  Bruno Haible  <bruno@clisp.org>
 
        * size_max.m4: New file, from gnulib.
index 17cb7abf8845670a07bfc4618c76b5ec0edfb8c2..0c06e9aeb6f7ba6214bfa8c8124b4ffed6400a2c 100644 (file)
@@ -1,5 +1,5 @@
-# javaexec.m4 serial 1 (gettext-0.11)
-dnl Copyright (C) 2001-2002 Free Software Foundation, Inc.
+# javaexec.m4 serial 2 (gettext-0.12.2)
+dnl Copyright (C) 2001-2003 Free Software Foundation, Inc.
 dnl This file is free software, distributed under the terms of the GNU
 dnl General Public License.  As a special exception to the GNU General
 dnl Public License, this file may be distributed as part of a program
@@ -7,6 +7,7 @@ dnl that contains a configuration script generated by Autoconf, under
 dnl the same distribution terms as the rest of that program.
 
 # Prerequisites of javaexec.sh.
+# gt_JAVAEXEC or gt_JAVAEXEC(testclass, its-directory)
 # Sets HAVE_JAVAEXEC to nonempty if javaexec.sh will work.
 
 AC_DEFUN([gt_JAVAEXEC],
@@ -31,23 +32,32 @@ AC_DEFUN([gt_JAVAEXEC],
     popdef([AC_MSG_RESULT])dnl
     popdef([AC_CHECKING])dnl
     popdef([AC_MSG_CHECKING])dnl
+    ifelse([$1], , , [
+      save_CLASSPATH="$CLASSPATH"
+      CLASSPATH="$2"${CLASSPATH+"$CLASSPATH_SEPARATOR$CLASSPATH"}
+      ])
+    export CLASSPATH
     if test -n "$HAVE_GIJ_IN_PATH" \
-       && gij --version >/dev/null 2>/dev/null; then
+       && gij --version >/dev/null 2>/dev/null \
+       ifelse([$1], , , [&& gij $1 >/dev/null 2>/dev/null]); then
       HAVE_GIJ=1
       ac_result="gij"
     else
       if test -n "$HAVE_JAVA_IN_PATH" \
-         && java -version >/dev/null 2>/dev/null; then
+         && java -version >/dev/null 2>/dev/null \
+         ifelse([$1], , , [&& java $1 >/dev/null 2>/dev/null]); then
         HAVE_JAVA=1
         ac_result="java"
       else
         if test -n "$HAVE_JRE_IN_PATH" \
-           && (jre >/dev/null 2>/dev/null || test $? = 1); then
+           && (jre >/dev/null 2>/dev/null || test $? = 1) \
+           ifelse([$1], , , [&& jre $1 >/dev/null 2>/dev/null]); then
           HAVE_JRE=1
           ac_result="jre"
         else
           if test -n "$HAVE_JVIEW_IN_PATH" \
-             && (jview -? >/dev/null 2>/dev/null || test $? = 1); then
+             && (jview -? >/dev/null 2>/dev/null || test $? = 1) \
+             ifelse([$1], , , [&& jview $1 >/dev/null 2>/dev/null]); then
             HAVE_JVIEW=1
             ac_result="jview"
           else
@@ -57,6 +67,9 @@ AC_DEFUN([gt_JAVAEXEC],
         fi
       fi
     fi
+    ifelse([$1], , , [
+      CLASSPATH="$save_CLASSPATH"
+    ])
   fi
   AC_MSG_RESULT([$ac_result])
   AC_SUBST(JAVA)