瀏覽代碼

merge -r 1302719:1302720 from branch-1 onto branch-1.0. Fixes HADOOP-6924.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-1.0@1302721 13f79535-47bb-0310-9956-ffa450edef68
Devaraj Das 13 年之前
父節點
當前提交
7a540b23b9
共有 3 個文件被更改,包括 9 次插入0 次删除
  1. 5 0
      CHANGES.txt
  2. 2 0
      src/native/configure
  3. 2 0
      src/native/configure.ac

+ 5 - 0
CHANGES.txt

@@ -1,5 +1,10 @@
 Hadoop Change Log
 
+    HADOOP-6924. Adds a directory to the list of directories to search for the libjvm.so file. 
+    The new directory is found by running a 'find' command and the first output is taken. 
+    This was done to handle the build of Hadoop with IBM's JDK. (Stephen Watt, 
+    Guillermo Cabrera and ddas) 
+
 Release 1.0.2 - 2012.03.18
 
   NEW FEATURES

+ 2 - 0
src/native/configure

@@ -19777,6 +19777,8 @@ JNI_LDFLAGS=""
 if test $JAVA_HOME != ""
 then
   JNI_LDFLAGS="-L$JAVA_HOME/jre/lib/$OS_ARCH/server"
+  JVMSOPATH=`find $JAVA_HOME/jre/ -name libjvm.so | head -n 1`
+  JNI_LDFLAGS="$JNI_LDFLAGS -L`dirname $JVMSOPATH`"
 fi
 ldflags_bak=$LDFLAGS
 LDFLAGS="$LDFLAGS $JNI_LDFLAGS"

+ 2 - 0
src/native/configure.ac

@@ -55,6 +55,8 @@ JNI_LDFLAGS=""
 if test $JAVA_HOME != ""
 then
   JNI_LDFLAGS="-L$JAVA_HOME/jre/lib/$OS_ARCH/server"
+  JVMSOPATH=`find $JAVA_HOME/jre/ -name libjvm.so | head -n 1`
+  JNI_LDFLAGS="$JNI_LDFLAGS -L`dirname $JVMSOPATH`"
 fi
 ldflags_bak=$LDFLAGS
 LDFLAGS="$LDFLAGS $JNI_LDFLAGS"