summaryrefslogtreecommitdiff
path: root/gettext-runtime
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2022-06-20 08:56:18 +0200
committerBruno Haible <bruno@clisp.org>2022-06-20 08:56:18 +0200
commit971dcbdbebb05d7ae8aa6399a0c79442fa996c5c (patch)
treea94ae13a76b79ba672ff3a21170cae7123fc1bb3 /gettext-runtime
parent3be051d736bdb9c8b7860d5e829aab2540d1dfb1 (diff)
downloadgettext-971dcbdbebb05d7ae8aa6399a0c79442fa996c5c.tar.gz
Don't check for java nor javac when --disable-java is specified.
This avoid annoying dialogs on macOS when Java has not been installed so far. Reported by Iain Sandoe <idsandoe@googlemail.com> in <https://gcc.gnu.org/pipermail/gcc/2022-June/238929.html>. * gettext-runtime/configure.ac: When JAVA_CHOICE is 'no', bypass the gt_JAVACOMP and JAR tests. * gettext-tools/configure.ac: When JAVA_CHOICE is 'no', bypass the gt_JAVAEXEC, gt_JAVACOMP, and JAR tests.
Diffstat (limited to 'gettext-runtime')
-rw-r--r--gettext-runtime/configure.ac21
1 files changed, 13 insertions, 8 deletions
diff --git a/gettext-runtime/configure.ac b/gettext-runtime/configure.ac
index 2b946c9f7..2894b33ca 100644
--- a/gettext-runtime/configure.ac
+++ b/gettext-runtime/configure.ac
@@ -1,5 +1,5 @@
dnl Configuration for the gettext-runtime directory of GNU gettext
-dnl Copyright (C) 1995-2010, 2012-2015, 2018-2021 Free Software Foundation, Inc.
+dnl Copyright (C) 1995-2010, 2012-2015, 2018-2022 Free Software Foundation, Inc.
dnl
dnl This program is free software: you can redistribute it and/or modify
dnl it under the terms of the GNU General Public License as published by
@@ -33,14 +33,19 @@ AC_PROG_CC
AC_PROG_INSTALL
gt_JAVA_CHOICE
-
-gt_JAVACOMP([1.5], [1.6])
-AC_CHECK_PROG([JAR], [jar], [jar])
-if test -n "$HAVE_JAVACOMP" && test -n "$JAR" && test "$JAVA_CHOICE" != no; then
- BUILDJAVA=yes
-else
+AS_IF([test "$JAVA_CHOICE" != no], [
+ gt_JAVACOMP([1.5], [1.6])
+ AC_CHECK_PROG([JAR], [jar], [jar])
+ if test -n "$HAVE_JAVACOMP" && test -n "$JAR"; then
+ BUILDJAVA=yes
+ else
+ BUILDJAVA=no
+ fi
+], [
+ gt_JAVACOMP_DISABLED
+ JAR=
BUILDJAVA=no
-fi
+])
AC_SUBST([BUILDJAVA])
gt_CSHARPCOMP