Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use JAVA_HOME if available #27

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 14 additions & 8 deletions ProgramExe/FlashTool
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,14 @@ then

rootandudevcheck;

if test "${system64}" = "x86_64"
if test -z "${JAVA_HOME}"
then
export JAVA_HOME=./x10flasher_lib/linjre64
else
export JAVA_HOME=./x10flasher_lib/linjre32
if test "${system64}" = "x86_64"
then
export JAVA_HOME=./x10flasher_lib/linjre64
else
export JAVA_HOME=./x10flasher_lib/linjre32
fi
fi

echo "Used java home : ${JAVA_HOME}"
Expand Down Expand Up @@ -77,11 +80,14 @@ then

else

if test "${system64}" = "x86_64"
if test -z "${JAVA_HOME}"
then
export JAVA_HOME=./x10flasher_lib/macjre64
else
export JAVA_HOME=./x10flasher_lib/macjre32
if test "${system64}" = "x86_64"
then
export JAVA_HOME=./x10flasher_lib/macjre64
else
export JAVA_HOME=./x10flasher_lib/macjre32
fi
fi

echo "Used java home : ${JAVA_HOME}"
Expand Down