[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] {maint} test defs: new requirement for the default java comp
From: |
Stefano Lattarini |
Subject: |
Re: [PATCH] {maint} test defs: new requirement for the default java compiler |
Date: |
Sun, 10 Apr 2011 09:50:14 +0200 |
User-agent: |
KMail/1.13.3 (Linux/2.6.30-2-686; KDE/4.4.4; i686; ; ) |
On Sunday 10 April 2011, Ralf Wildenhues wrote:
> * Stefano Lattarini wrote on Sun, Apr 10, 2011 at 09:11:07AM CEST:
> > IMHO having a proper requirement for the java compiler in `tests/defs'
> > would be better than the current behaviour running the check for the
> > availability of javac in the generated configure script in each
> > relevant test. And it would also be faster for systems that lack
> > a java compiler (which are then to skip the test).
> >
> > The usefulness of this patch will be further increased if we add more
> > tests on java support in the future.
> >
> > Subject: [PATCH] test defs: new requirement for the default java compiler
> >
> > * tests/defs.in (for tool in $required): New requirement 'javac'.
> > * tests/java.test: Use it instead of ad-hoc configure check.
> > * tests/java-check.test: Likewise.
>
BTW, I had forgot to edit `instfail-java.test' and `instfdir-java.test'
accordingly :-( This is fixed now: I've amended the patch before
pushing to maint, and what I've squashed in is attached.
> > So, OK to apply the attached patch to maint?
>
> Of course. Please be sure to convert all instances in master too when
> you merge (IIRC there should be more than in maint).
>
Done. Attached is the diff of the merge.
> Thanks!
> Ralf
Thanks for the fast review,
Stefano
diff --git a/ChangeLog b/ChangeLog
index 366d295..a605aa8 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -4,6 +4,8 @@
* tests/defs.in (for tool in $required): New requirement 'javac'.
* tests/java.test: Use it instead of ad-hoc configure check.
* tests/java-check.test: Likewise.
+ * tests/instfail-java.test: Likewise.
+ * tests/instdir-java.test: Likewise.
2011-04-09 Stefano Lattarini <address@hidden>
diff --git a/tests/instdir-java.test b/tests/instdir-java.test
index 6adc82e..9d9a03c 100755
--- a/tests/instdir-java.test
+++ b/tests/instdir-java.test
@@ -16,13 +16,12 @@
# If $(javadir) is the empty string, then nothing should be installed there.
+required=javac
. ./defs || Exit 1
set -e
cat >>configure.in <<'END'
-AC_CHECK_PROG([HAS_JAVAC], [javac], [:], [exit])
-($HAS_JAVAC 77); $HAS_JAVAC 77
AC_OUTPUT
END
diff --git a/tests/instfail-java.test b/tests/instfail-java.test
index 2cb8afb..8f527cf 100755
--- a/tests/instfail-java.test
+++ b/tests/instfail-java.test
@@ -19,13 +19,12 @@
# This is the java sister test of instfail.test.
+required=javac
. ./defs || Exit 1
set -e
cat >>configure.in <<'END'
-AC_CHECK_PROG([HAS_JAVAC], [javac], [:], [exit])
-($HAS_JAVAC 77); $HAS_JAVAC 77
AC_OUTPUT
END
diff --git a/ChangeLog b/ChangeLog
index 96969a8..45688e3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,14 @@
+2011-04-10 Stefano Lattarini <address@hidden>
+
+ test defs: new requirement for the default java compiler
+ * tests/defs.in (for tool in $required): New requirement 'javac'.
+ * tests/java.test: Use it instead of ad-hoc configure check.
+ * tests/java-check.test: Likewise.
+ * tests/java-extra.test: Likewise.
+ * tests/java-noinst.test: Likewise.
+ * tests/instfail-java.test: Likewise.
+ * tests/instdir-java.test: Likewise.
+
2011-04-09 Stefano Lattarini <address@hidden>
java: check_JAVA does not cause compilation by "make all" anymore
diff --git a/tests/defs b/tests/defs
index e994a40..77bb534 100644
--- a/tests/defs
+++ b/tests/defs
@@ -286,6 +286,10 @@ do
echo "$me: running $CC -V -help"
$CC -V -help || exit 77
;;
+ javac)
+ echo "$me: running javac -version"
+ javac -version || exit 77
+ ;;
makedepend)
echo "$me: running makedepend -f-"
makedepend -f- || exit 77
diff --git a/tests/instdir-java.test b/tests/instdir-java.test
index 5831f27..8cad153 100755
--- a/tests/instdir-java.test
+++ b/tests/instdir-java.test
@@ -16,11 +16,10 @@
# If $(javadir) is the empty string, then nothing should be installed there.
+required=javac
. ./defs || Exit 1
cat >>configure.in <<'END'
-AC_CHECK_PROG([HAS_JAVAC], [javac], [:], [exit])
-($HAS_JAVAC 77); $HAS_JAVAC 77
AC_OUTPUT
END
diff --git a/tests/instfail-java.test b/tests/instfail-java.test
index 4ebc2c3..a570297 100755
--- a/tests/instfail-java.test
+++ b/tests/instfail-java.test
@@ -19,11 +19,10 @@
# This is the java sister test of instfail.test.
+required=javac
. ./defs || Exit 1
cat >>configure.in <<'END'
-AC_CHECK_PROG([HAS_JAVAC], [javac], [:], [exit])
-($HAS_JAVAC 77); $HAS_JAVAC 77
AC_OUTPUT
END
diff --git a/tests/java-check.test b/tests/java-check.test
index fd3fc96..a67b4e8 100755
--- a/tests/java-check.test
+++ b/tests/java-check.test
@@ -18,13 +18,12 @@
# "make check", and not also with "make all".
# See automake bug#8234.
+required=javac
. ./defs || Exit 1
set -e
cat >> configure.in << 'END'
-AC_CHECK_PROG([HAS_JAVAC], [javac], [:], [exit])
-($HAS_JAVAC 77); $HAS_JAVAC 77
AC_OUTPUT
END
diff --git a/tests/java-extra.test b/tests/java-extra.test
index 5309964..9837d75 100755
--- a/tests/java-extra.test
+++ b/tests/java-extra.test
@@ -19,13 +19,12 @@
# EXTRA_JAVA exists mostly for ensuring interoperation with Automake
# conditionals).
+required=javac
. ./defs || Exit 1
set -e
cat >> configure.in << 'END'
-AC_CHECK_PROG([HAS_JAVAC], [javac], [:], [exit])
-($HAS_JAVAC 77); $HAS_JAVAC 77
AM_CONDITIONAL([COND], [test x"$cond" = x"yes"])
AC_OUTPUT
END
diff --git a/tests/java-noinst.test b/tests/java-noinst.test
index 130ea63..6babc27 100755
--- a/tests/java-noinst.test
+++ b/tests/java-noinst.test
@@ -14,15 +14,15 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-# Make sure that noinst_JAVA causes generated *.class files not to be
installed.
+# Make sure that noinst_JAVA causes generated *.class files not to be
+# installed.
+required=javac
. ./defs || Exit 1
set -e
cat >> configure.in << 'END'
-AC_CHECK_PROG([HAS_JAVAC], [javac], [:], [exit])
-($HAS_JAVAC 77); $HAS_JAVAC 77
AC_OUTPUT
END
diff --git a/tests/java.test b/tests/java.test
index f4259d4..671d2fd 100755
--- a/tests/java.test
+++ b/tests/java.test
@@ -17,11 +17,10 @@
# Minimal test of Java functionality.
+required=javac
. ./defs || Exit 1
cat >>configure.in <<'EOF'
-AC_CHECK_PROG([HAS_JAVAC], [javac], [:], [exit])
-($HAS_JAVAC 77); $HAS_JAVAC 77
AC_OUTPUT
EOF
- [PATCH] {maint} test defs: new requirement for the default java compiler, Stefano Lattarini, 2011/04/10
- Re: [PATCH] {maint} test defs: new requirement for the default java compiler, Ralf Wildenhues, 2011/04/10
- Re: [PATCH] {maint} test defs: new requirement for the default java compiler,
Stefano Lattarini <=
- Re: [PATCH] {maint} test defs: new requirement for the default java compiler, Ralf Wildenhues, 2011/04/10
- Re: [PATCH] {maint} test defs: new requirement for the default java compiler, Stefano Lattarini, 2011/04/10
- Re: [PATCH] {maint} test defs: new requirement for the default java compiler, Ralf Wildenhues, 2011/04/10
- Re: [PATCH] {maint} test defs: new requirement for the default java compiler, Stefano Lattarini, 2011/04/10
- Re: [PATCH] {maint} test defs: new requirement for the default java compiler, Stefano Lattarini, 2011/04/10