[jboss-cvs] JBossAS SVN: r60982 - branches/Branch_4_2/system/src/bin.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Wed Feb 28 04:55:42 EST 2007


Author: dimitris at jboss.org
Date: 2007-02-28 04:55:42 -0500 (Wed, 28 Feb 2007)
New Revision: 60982

Modified:
   branches/Branch_4_2/system/src/bin/run.bat
Log:
synch with mladen changes in head. Need to re-apply Jean-Frederic's changes

Modified: branches/Branch_4_2/system/src/bin/run.bat
===================================================================
--- branches/Branch_4_2/system/src/bin/run.bat	2007-02-28 09:00:10 UTC (rev 60981)
+++ branches/Branch_4_2/system/src/bin/run.bat	2007-02-28 09:55:42 UTC (rev 60982)
@@ -13,6 +13,14 @@
 set PROGNAME=run.bat
 if "%OS%" == "Windows_NT" set PROGNAME=%~nx0%
 
+pushd %DIRNAME%..
+set JBOSS_HOME=%CD%
+popd
+
+REM Add bin/native to the PATH if present
+if exist "%JBOSS_HOME%\bin\native" set PATH=%JBOSS_HOME%\bin\native;%PATH%
+if exist "%JBOSS_HOME%\bin\native" set JAVA_OPTS=%JAVA_OPTS% -Djava.library.path=%JBOSS_HOME%\bin\native
+
 rem Read all command line arguments
 
 REM
@@ -29,7 +37,7 @@
 
 rem Find run.jar, or we can't continue
 
-set RUNJAR=%DIRNAME%\run.jar
+set RUNJAR=%JBOSS_HOME%\bin\run.jar
 if exist "%RUNJAR%" goto FOUND_RUN_JAR
 echo Could not locate %RUNJAR%. Please check that you are in the
 echo bin directory when running this script.
@@ -50,25 +58,25 @@
 set JAVA=%JAVA_HOME%\bin\java
 
 if exist "%JAVA_HOME%\lib\tools.jar" goto SKIP_TOOLS
-rem tools coud be used to replace the JDT Compiler for Jasper.
-rem javassist has its own internal compiler.
-set JAVAC_JAR=%JAVA_HOME%\lib\tools.jar
+echo Could not locate %JAVA_HOME%\lib\tools.jar. Unexpected results may occur.
+echo Make sure that JAVA_HOME points to a JDK and not a JRE.
 
 :SKIP_TOOLS
 
-rem If JBOSS_CLASSPATH/JAVAC_JAR is empty, don't include it, as this will 
+rem Include the JDK javac compiler for JSP pages. The default is for a Sun JDK
+rem compatible distribution to which JAVA_HOME points
+
+set JAVAC_JAR=%JAVA_HOME%\lib\tools.jar
+
+rem If JBOSS_CLASSPATH is empty, don't include it, as this will 
 rem result in including the local directory, which makes error tracking
 rem harder.
-if "%JAVAC_JAR%" == "" set RUNJAR=%JAVAC_JAR%;%RUNJAR%
-if "%JBOSS_CLASSPATH%" == "" (
-	set JBOSS_CLASSPATH=%RUNJAR%
-) else (
-	set JBOSS_CLASSPATH=%JBOSS_CLASSPATH%;%RUNJAR%
-)
+if "%JBOSS_CLASSPATH%" == "" set RUN_CLASSPATH=%JAVAC_JAR%;%RUNJAR%
+if "%RUN_CLASSPATH%" == "" set RUN_CLASSPATH=%JBOSS_CLASSPATH%;%JAVAC_JAR%;%RUNJAR%
+set JBOSS_CLASSPATH=%RUN_CLASSPATH%
 
 rem Setup JBoss specific properties
 set JAVA_OPTS=%JAVA_OPTS% -Dprogram.name=%PROGNAME%
-set JBOSS_HOME=%DIRNAME%\..
 
 rem Add -server to the JVM options, if supported
 "%JAVA%" -version 2>&1 | findstr /I hotspot > nul




More information about the jboss-cvs-commits mailing list