forked from gmp/jni
Make find_linux_jnih more robust.
This commit is contained in:
parent
15a239885b
commit
3310c43bcf
|
@ -1,8 +1,14 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
if [ -z ${JAVA_HOME+x} ]
|
||||||
|
then
|
||||||
|
# JAVA_HOME not set. Figure out what to use for it.
|
||||||
JAVA_HOME=$(dirname $(readlink -f $(which java) | sed 's^jre/bin/^^'))
|
JAVA_HOME=$(dirname $(readlink -f $(which java) | sed 's^jre/bin/^^'))
|
||||||
|
# Handle the case where java is being run from the jdk itself, not from within the jre
|
||||||
|
JAVA_HOME=$(echo $JAVA_HOME | sed 's^bin/^^')
|
||||||
|
fi
|
||||||
|
|
||||||
echo // +build linux > jni_linux.tmp
|
echo // +build linux,!android > jni_linux.tmp
|
||||||
echo //Generated by scripts/find_linux_jnih >> jni_linux.tmp
|
echo //Generated by scripts/find_linux_jnih >> jni_linux.tmp
|
||||||
echo >> jni_linux.tmp
|
echo >> jni_linux.tmp
|
||||||
echo package jni >> jni_linux.tmp
|
echo package jni >> jni_linux.tmp
|
||||||
|
|
Loading…
Reference in New Issue
Block a user