You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@accumulo.apache.org by kt...@apache.org on 2019/04/16 18:53:01 UTC
[accumulo] branch master updated: Update native map makefile to
work with Java 11.
This is an automated email from the ASF dual-hosted git repository.
kturner pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/accumulo.git
The following commit(s) were added to refs/heads/master by this push:
new 9591cc2 Update native map makefile to work with Java 11.
new 75a87b5 Merge branch '1.9'
9591cc2 is described below
commit 9591cc2b4b00897894e498d7a4cf49d63edbe7fc
Author: Keith Turner <kt...@apache.org>
AuthorDate: Tue Apr 16 13:53:24 2019 -0400
Update native map makefile to work with Java 11.
The native map makefile checks to see if javah exists inorder to
determine if java is a JDK or JRE. In Java 11, javah no longer exists.
The makefile was modfied to check if javac exists, which is a JDK
command that exists in Java 8 and 11.
---
server/native/src/main/resources/Makefile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/server/native/src/main/resources/Makefile b/server/native/src/main/resources/Makefile
index 5434356..cdf1c2a 100644
--- a/server/native/src/main/resources/Makefile
+++ b/server/native/src/main/resources/Makefile
@@ -27,7 +27,7 @@ endif
ifeq ($(shell uname),Linux)
JAVA_HOME=$(shell env | grep "^JAVA_HOME=" | cut -d= -f2)
ifeq ($(strip $(JAVA_HOME)),)
- JAVA_HOME=$(shell dirname "$$(dirname "$$(readlink -e "$$(which javah)")")")
+ JAVA_HOME=$(shell dirname "$$(dirname "$$(readlink -e "$$(which javac)")")")
endif
NATIVE_LIB := libaccumulo.so
CXXFLAGS=-g -fPIC -shared -O3 -Wall -I'$(JAVA_HOME)'/include -I'$(JAVA_HOME)'/include/linux -Ijavah $(USERFLAGS)
@@ -47,7 +47,7 @@ endif
# escape space and parens in path for wildcard
JAVA_HOME_ESCAPED=$(shell echo '$(JAVA_HOME)' | sed 's/ /\\ /g' | sed 's/\([()]\)/\\\1/g')
-ifeq (,$(wildcard $(JAVA_HOME_ESCAPED)/bin/javah))
+ifeq (,$(wildcard $(JAVA_HOME_ESCAPED)/bin/javac))
$(error "JAVA_HOME does not point to a JDK. Exiting...")
endif