summaryrefslogtreecommitdiff
path: root/m4
diff options
context:
space:
mode:
authorAndrew John Hughes <gnu_andrew@member.fsf.org>2010-05-04 17:31:18 +0000
committerAndrew John Hughes <gnu_andrew@member.fsf.org>2010-05-04 17:31:18 +0000
commita1878e0b67b5f23bbcbe1e1850785239148e8d90 (patch)
treeb877af0ac26c29054504974fc2b0575220a65496 /m4
parent4d2215111c0a8c84fc2d472c95c12d4747e5e144 (diff)
downloadclasspath-a1878e0b67b5f23bbcbe1e1850785239148e8d90.tar.gz
Cleanup output of javac is gcj test.
2010-05-04 Andrew John Hughes <ahughes@redhat.com> * m4/ac_prog_javac.m4: Capture all output from javac --version to avoid excess output. Make sure no appears when javac is not gcj.
Diffstat (limited to 'm4')
-rw-r--r--m4/ac_prog_javac.m47
1 files changed, 5 insertions, 2 deletions
diff --git a/m4/ac_prog_javac.m4 b/m4/ac_prog_javac.m4
index baf518600..84a72206a 100644
--- a/m4/ac_prog_javac.m4
+++ b/m4/ac_prog_javac.m4
@@ -46,10 +46,13 @@ else
fi
test "x$JAVAC" = x && AC_MSG_ERROR([no acceptable Java compiler found in \$PATH])
AC_CACHE_CHECK([if $JAVAC is a version of gcj], ac_cv_prog_javac_is_gcj, [
-if $JAVAC --version | grep gcj > /dev/null; then
+if $JAVAC --version 2>&1 | grep gcj >&AS_MESSAGE_LOG_FD ; then
ac_cv_prog_javac_is_gcj=yes;
JAVAC="$JAVAC $GCJ_OPTS";
-fi])
+else
+ ac_cv_prog_javac_is_gcj=no;
+fi
+])
AC_SUBST(JAVAC_IS_GCJ, $ac_cv_prog_javac_is_gcj)
AM_CONDITIONAL(GCJ_JAVAC, test x"${JAVAC_IS_GCJ}" = xyes)
AC_PROG_JAVAC_WORKS