Cleanup the Java setup m4's - orte doesn't require java, and we do all compiler checks in opal
This commit was SVN r29530.
Этот коммит содержится в:
родитель
25385590e6
Коммит
588e7ce974
@ -32,7 +32,7 @@ AC_DEFUN([OMPI_SETUP_JAVA_BINDINGS_BANNER],[
|
||||
# this macro.
|
||||
AC_DEFUN([OMPI_SETUP_JAVA_BINDINGS],[
|
||||
# must have Java setup
|
||||
AC_REQUIRE([ORTE_SETUP_JAVA])
|
||||
AC_REQUIRE([OPAL_SETUP_JAVA])
|
||||
|
||||
AC_REQUIRE([OMPI_SETUP_JAVA_BINDINGS_BANNER])
|
||||
|
||||
@ -42,14 +42,14 @@ AC_DEFUN([OMPI_SETUP_JAVA_BINDINGS],[
|
||||
[enable Java MPI bindings (default: disabled)]))
|
||||
|
||||
# check for required support
|
||||
if test "$orte_java_happy" = "no" -a "$enable_mpi_java" = "yes"; then
|
||||
if test "$opal_java_happy" = "no" -a "$enable_mpi_java" = "yes"; then
|
||||
AC_MSG_RESULT([yes])
|
||||
AC_MSG_WARN([Java bindings requested but no Java support found])
|
||||
AC_MSG_ERROR([cannot continue])
|
||||
fi
|
||||
|
||||
# Only build the Java bindings if requested
|
||||
if test "$orte_java_happy" = "yes" -a "$enable_mpi_java" = "yes"; then
|
||||
if test "$opal_java_happy" = "yes" -a "$enable_mpi_java" = "yes"; then
|
||||
AC_MSG_RESULT([yes])
|
||||
WANT_MPI_JAVA_SUPPORT=1
|
||||
AC_MSG_CHECKING([if shared libraries are enabled])
|
||||
@ -61,7 +61,7 @@ AC_DEFUN([OMPI_SETUP_JAVA_BINDINGS],[
|
||||
[AC_MSG_RESULT([yes])])
|
||||
# must have Java support
|
||||
AC_MSG_CHECKING([if Java support was found])
|
||||
AS_IF([test "$orte_java_happy" = "yes"],
|
||||
AS_IF([test "$opal_java_happy" = "yes"],
|
||||
[AC_MSG_RESULT([yes])],
|
||||
[AC_MSG_WARN([Java MPI bindings requested, but Java support was not found])
|
||||
AC_MSG_WARN([Please reconfigure the --with-jdk options to where Java])
|
||||
|
@ -14,6 +14,7 @@ dnl Copyright (c) 2006-2012 Los Alamos National Security, LLC. All rights
|
||||
dnl reserved.
|
||||
dnl Copyright (c) 2007-2012 Oracle and/or its affiliates. All rights reserved.
|
||||
dnl Copyright (c) 2008-2012 Cisco Systems, Inc. All rights reserved.
|
||||
dnl Copyright (c) 2013 Intel, Inc. All rights reserved.
|
||||
dnl $COPYRIGHT$
|
||||
dnl
|
||||
dnl Additional copyrights may follow
|
||||
@ -22,16 +23,16 @@ dnl $HEADER$
|
||||
dnl
|
||||
|
||||
# This macro is necessary to get the title to be displayed first. :-)
|
||||
AC_DEFUN([ORTE_SETUP_JAVA_BANNER],[
|
||||
AC_DEFUN([OPAL_SETUP_JAVA_BANNER],[
|
||||
ompi_show_subtitle "Java compiler"
|
||||
])
|
||||
|
||||
# ORTE_SETUP_JAVA()
|
||||
# OPAL_SETUP_JAVA()
|
||||
# ----------------
|
||||
# Do everything required to setup the Java compiler. Safe to AC_REQUIRE
|
||||
# this macro.
|
||||
AC_DEFUN([ORTE_SETUP_JAVA],[
|
||||
AC_REQUIRE([ORTE_SETUP_JAVA_BANNER])
|
||||
AC_DEFUN([OPAL_SETUP_JAVA],[
|
||||
AC_REQUIRE([OPAL_SETUP_JAVA_BANNER])
|
||||
|
||||
AC_ARG_ENABLE(java,
|
||||
AC_HELP_STRING([--enable-java],
|
||||
@ -49,7 +50,7 @@ AC_DEFUN([ORTE_SETUP_JAVA],[
|
||||
|
||||
if test "$enable_java" = "no"; then
|
||||
HAVE_JAVA_SUPPORT=0
|
||||
orte_java_happy=no
|
||||
opal_java_happy=no
|
||||
else
|
||||
# Check for bozo case: ensure a directory was specified
|
||||
AS_IF([test "$with_jdk_dir" = "yes" -o "$with_jdk_dir" = "no"],
|
||||
@ -147,7 +148,7 @@ AC_DEFUN([ORTE_SETUP_JAVA],[
|
||||
OMPI_CHECK_WITHDIR([jdk-headers], [$with_jdk_headers], [jni.h])
|
||||
|
||||
# Look for various Java-related programs
|
||||
orte_java_happy=no
|
||||
opal_java_happy=no
|
||||
PATH_save=$PATH
|
||||
AS_IF([test -n "$with_jdk_bindir" -a "$with_jdk_bindir" != "yes" -a "$with_jdk_bindir" != "no"],
|
||||
[PATH="$with_jdk_bindir:$PATH"])
|
||||
@ -158,48 +159,48 @@ AC_DEFUN([ORTE_SETUP_JAVA],[
|
||||
|
||||
# Check to see if we have all 3 programs.
|
||||
AS_IF([test -z "$JAVAC" -o -z "$JAVAH" -o -z "$JAR"],
|
||||
[orte_java_happy=no
|
||||
[opal_java_happy=no
|
||||
HAVE_JAVA_SUPPORT=0],
|
||||
[orte_java_happy=yes
|
||||
[opal_java_happy=yes
|
||||
HAVE_JAVA_SUPPORT=1])
|
||||
|
||||
# Look for jni.h
|
||||
AS_IF([test "$orte_java_happy" = "yes"],
|
||||
AS_IF([test "$opal_java_happy" = "yes"],
|
||||
[CPPFLAGS_save=$CPPFLAGS
|
||||
# silence a stupid Mac warning
|
||||
CPPFLAGS="$CPPFLAGS -DTARGET_RT_MAC_CFM=0"
|
||||
AS_IF([test -n "$with_jdk_headers" -a "$with_jdk_headers" != "yes" -a "$with_jdk_headers" != "no"],
|
||||
[ORTE_JDK_CPPFLAGS="-I$with_jdk_headers"
|
||||
[OPAL_JDK_CPPFLAGS="-I$with_jdk_headers"
|
||||
# Some flavors of JDK also require -I<blah>/linux.
|
||||
# See if that's there, and if so, add a -I for that,
|
||||
# too. Ugh.
|
||||
AS_IF([test -d "$with_jdk_headers/linux"],
|
||||
[ORTE_JDK_CPPFLAGS="$ORTE_JDK_CPPFLAGS -I$with_jdk_headers/linux"])
|
||||
[OPAL_JDK_CPPFLAGS="$OPAL_JDK_CPPFLAGS -I$with_jdk_headers/linux"])
|
||||
# Solaris JDK also require -I<blah>/solaris.
|
||||
# See if that's there, and if so, add a -I for that,
|
||||
# too. Ugh.
|
||||
AS_IF([test -d "$with_jdk_headers/solaris"],
|
||||
[ORTE_JDK_CPPFLAGS="$ORTE_JDK_CPPFLAGS -I$with_jdk_headers/solaris"])
|
||||
[OPAL_JDK_CPPFLAGS="$OPAL_JDK_CPPFLAGS -I$with_jdk_headers/solaris"])
|
||||
|
||||
CPPFLAGS="$CPPFLAGS $ORTE_JDK_CPPFLAGS"])
|
||||
CPPFLAGS="$CPPFLAGS $OPAL_JDK_CPPFLAGS"])
|
||||
AC_CHECK_HEADER([jni.h], [],
|
||||
[orte_java_happy=no])
|
||||
[opal_java_happy=no])
|
||||
CPPFLAGS=$CPPFLAGS_save
|
||||
])
|
||||
else
|
||||
orte_java_happy=no;
|
||||
opal_java_happy=no;
|
||||
HAVE_JAVA_SUPPORT=no;
|
||||
fi
|
||||
AC_SUBST(ORTE_JDK_CPPFLAGS)
|
||||
AC_SUBST(OPAL_JDK_CPPFLAGS)
|
||||
fi
|
||||
|
||||
# Are we happy?
|
||||
AC_MSG_CHECKING([Java support available])
|
||||
AS_IF([test "$orte_java_happy" = "no"],
|
||||
AS_IF([test "$opal_java_happy" = "no"],
|
||||
[AC_MSG_RESULT([no])],
|
||||
[AC_MSG_RESULT([yes])])
|
||||
|
||||
AC_DEFINE_UNQUOTED([ORTE_HAVE_JAVA_SUPPOR]T, [$HAVE_JAVA_SUPPORT], [do we have Java support])
|
||||
AM_CONDITIONAL(ORTE_HAVE_JAVA_SUPPORT, test "$orte_java_happy" = "yes")
|
||||
AC_DEFINE_UNQUOTED([OPAL_HAVE_JAVA_SUPPORT], [$HAVE_JAVA_SUPPORT], [do we have Java support])
|
||||
AM_CONDITIONAL(OPAL_HAVE_JAVA_SUPPORT, test "$opal_java_happy" = "yes")
|
||||
|
||||
])
|
@ -565,12 +565,6 @@ OPAL_CHECK_ATTRIBUTES
|
||||
OPAL_CHECK_COMPILER_VERSION_ID
|
||||
|
||||
|
||||
##################################
|
||||
# Java compiler characteristics
|
||||
##################################
|
||||
# Needed for ORTE - OMPI will AC_REQUIRE where needed
|
||||
m4_ifdef([project_orte], [ORTE_SETUP_JAVA])
|
||||
|
||||
##################################
|
||||
# Java MPI Binding request
|
||||
##################################
|
||||
|
Загрузка…
Ссылка в новой задаче
Block a user