Skip to content

Commit

Permalink
MONDRIAN: PPP-2542, changing dir to the current dir for win7 issue, B…
Browse files Browse the repository at this point in the history
…ISERVER-4632, added check to see if the jre folder provided exists

[git-p4: depot-paths = "//open/mondrian-release/3.2/": change = 13864]
  • Loading branch information
Will Gorman committed Oct 6, 2010
1 parent 6908dd5 commit dd0d0e7
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
7 changes: 2 additions & 5 deletions workbench/set-pentaho-env.bat
Expand Up @@ -51,7 +51,8 @@ if exist "%~dp0..\..\jre" goto gotJreTwoFolderUp
if exist "%~dp0..\..\java" goto gotJavaTwoFolderUp
if not "%JAVA_HOME%" == "" goto gotJdkHome
if not "%JRE_HOME%" == "" goto gotJreHome
goto tryValueFromCaller
if exist "%~1" goto gotValueFromCaller
goto gotPath

:gotPentahoJavaHome
echo DEBUG: Using PENTAHO_JAVA_HOME
Expand Down Expand Up @@ -107,10 +108,6 @@ set _PENTAHO_JAVA_HOME=%JRE_HOME%
set _PENTAHO_JAVA=%_PENTAHO_JAVA_HOME%\bin\%__LAUNCHER%
goto end

:tryValueFromCaller
if not !%1!==!! goto gotValueFromCaller
goto :gotPath

:gotValueFromCaller
echo DEBUG: Using value (%~1) from calling script
set _PENTAHO_JAVA_HOME=%~1
Expand Down
4 changes: 2 additions & 2 deletions workbench/set-pentaho-env.sh
Expand Up @@ -38,7 +38,7 @@ setPentahoEnv() {
cd $DIR_REL
DIR=`pwd`
cd -
if [ -n "$PENTAHO_JAVA" ]; then
__LAUNCHER="$PENTAHO_JAVA"
else
Expand Down Expand Up @@ -80,7 +80,7 @@ setPentahoEnv() {
echo "DEBUG: Using JRE_HOME"
_PENTAHO_JAVA_HOME="$JRE_HOME"
_PENTAHO_JAVA="$_PENTAHO_JAVA_HOME"/bin/$__LAUNCHER
elif [ -n "$1" ] && [ -x "$1"/bin/$__LAUNCHER ]; then
elif [ -n "$1" ] && [ -d "$1" ] && [ -x "$1"/bin/$__LAUNCHER ]; then
echo "DEBUG: Using value ($1) from calling script"
_PENTAHO_JAVA_HOME="$1"
_PENTAHO_JAVA="$_PENTAHO_JAVA_HOME"/bin/$__LAUNCHER
Expand Down
2 changes: 2 additions & 0 deletions workbench/workbench.bat
@@ -1,5 +1,7 @@
@echo off

cd /D %~dp0

rem Schema Workbench launch script

rem base Mondrian JARs need to be included
Expand Down

0 comments on commit dd0d0e7

Please sign in to comment.