Skip to content

Commit 5456dd2

Browse files
committed
configury: replace javah with javac -h
javah has been removed from Java 10, so use javac -h instead (that is already usable in Java 8) Refs. #5000 Signed-off-by: Gilles Gouaillardet <[email protected]>
1 parent 44a1c78 commit 5456dd2

File tree

2 files changed

+7
-10
lines changed

2 files changed

+7
-10
lines changed

config/opal_setup_java.m4

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ dnl reserved.
1515
dnl Copyright (c) 2007-2012 Oracle and/or its affiliates. All rights reserved.
1616
dnl Copyright (c) 2008-2013 Cisco Systems, Inc. All rights reserved.
1717
dnl Copyright (c) 2013 Intel, Inc. All rights reserved.
18-
dnl Copyright (c) 2015 Research Organization for Information Science
18+
dnl Copyright (c) 2015-2018 Research Organization for Information Science
1919
dnl and Technology (RIST). All rights reserved.
2020
dnl Copyright (c) 2017 FUJITSU LIMITED. All rights reserved.
2121
dnl $COPYRIGHT$
@@ -161,13 +161,12 @@ AC_DEFUN([OPAL_SETUP_JAVA],[
161161
AS_IF([test -n "$with_jdk_bindir" && test "$with_jdk_bindir" != "yes" && test "$with_jdk_bindir" != "no"],
162162
[PATH="$with_jdk_bindir:$PATH"])
163163
AC_PATH_PROG(JAVAC, javac)
164-
AC_PATH_PROG(JAVAH, javah)
165164
AC_PATH_PROG(JAR, jar)
166165
AC_PATH_PROG(JAVADOC, javadoc)
167166
PATH=$opal_java_PATH_save
168167

169-
# Check to see if we have all 4 programs.
170-
AS_IF([test -z "$JAVAC" || test -z "$JAVAH" || test -z "$JAR" || test -z "$JAVADOC"],
168+
# Check to see if we have all 3 programs.
169+
AS_IF([test -z "$JAVAC" || test -z "$JAR" || test -z "$JAVADOC"],
171170
[opal_java_happy=no
172171
HAVE_JAVA_SUPPORT=0],
173172
[opal_java_happy=yes

ompi/mpi/java/java/Makefile.am

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
# Copyright (c) 2015 Los Alamos National Security, LLC. All rights
55
# reserved.
66
# Copyright (c) 2017 FUJITSU LIMITED. All rights reserved.
7+
# Copyright (c) 2018 Research Organization for Information Science
8+
# and Technology (RIST). All rights reserved.
79
# $COPYRIGHT$
810
#
911
# Additional copyrights may follow
@@ -102,10 +104,6 @@ OMPI_V_JAVAC = $(ompi__v_JAVAC_$V)
102104
ompi__v_JAVAC_ = $(ompi__v_JAVAC_$AM_DEFAULT_VERBOSITY)
103105
ompi__v_JAVAC_0 = @echo " JAVAC " `basename $@`;
104106

105-
OMPI_V_JAVAH = $(ompi__v_JAVAH_$V)
106-
ompi__v_JAVAH_ = $(ompi__v_JAVAH_$AM_DEFAULT_VERBOSITY)
107-
ompi__v_JAVAH_0 = @echo " JAVAH " `basename $@`;
108-
109107
OMPI_V_JAR = $(ompi__v_JAR_$V)
110108
ompi__v_JAR_ = $(ompi__v_JAR_$AM_DEFAULT_VERBOSITY)
111109
ompi__v_JAR_0 = @echo " JAR " `basename $@`;
@@ -149,10 +147,10 @@ mpi/MPI.class: $(JAVA_SRC_FILES)
149147
# token mpi/MPI.class file. Hence, all the classes will be generated
150148
# first, then we'll individually generate each of the .h files.
151149
$(JAVA_H): mpi/MPI.class
152-
$(OMPI_V_JAVAH) sourcename=mpi.`echo $@ | sed -e s/^mpi_// -e s/.h$$//`; \
150+
$(OMPI_V_JAVAC) sourcename=$(top_srcdir)/ompi/mpi/java/java/`echo $@ | sed -e s/^mpi_// -e s/.h$$//`.java; \
153151
CLASSPATH=. ; \
154152
export CLASSPATH ; \
155-
$(JAVAH) -d . -jni $$sourcename
153+
$(JAVAC) -h . $$sourcename
156154

157155
# Generate the .jar file from all the class files. List mpi/MPI.class
158156
# as a dependency so that it fires the rule above that will generate

0 commit comments

Comments
 (0)