changeset 35:b32c3bd9eb89

removed the javabuilder jar (not necessary - should be copied either from the MCR or the MATLAB folder; removed some dependency checking from the build file; added some instructions file.
author luisf <luis.figueira@eecs.qmul.ac.uk>
date Tue, 10 Dec 2013 22:05:19 +0000
parents 3fead3e53b4a
children 32592582ffd1
files INSTALL.txt WebContent/WEB-INF/lib/javabuilder.jar build.xml
diffstat 3 files changed, 26 insertions(+), 17 deletions(-) [+]
line wrap: on
line diff
--- a/INSTALL.txt	Tue Dec 10 18:43:20 2013 +0000
+++ b/INSTALL.txt	Tue Dec 10 22:05:19 2013 +0000
@@ -9,32 +9,48 @@
 To install MCR, please proceed to:
     http://www.mathworks.co.uk/products/compiler/mcr/
 
-You need to install MATLAB MCR 2013b (8.2).
+And follow the installer's instructions.  You need to install MATLAB MCR 2013b (8.2).
+
+Attention: take a note of the enviornment variable DYLD_LIBRARY_PATH which the MCR installer will show - if this is not correctly set tyhe webapp will not run.
 
 = System variables =
 
-On OSX you need to
+On OSX you need to do the following (if you installed MCR to the /Applications/MATLAB/MATLAB_Compiler_Runtime/ folder):
 
-    export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:/Applications/MATLAB_R2013b.app/sys/os/maci64/:/Applications/MATLAB_R2013b.app/runtime/maci64/:/Applications/MATLAB_R2013b.app/bin/maci64/
+        export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:/Applications/MATLAB/MATLAB_Compiler_Runtime/v82/runtime/maci64:/Applications/MATLAB/MATLAB_Compiler_Runtime/v82/sys/os/maci64:/Applications/MATLAB/MATLAB_Compiler_Runtime/v82/bin/maci64
 
+        (Please not that only the above paths are necessary.)
+
+If you have Matlab installed instead, the path is probably:
+
+        export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:/Applications/MATLAB_R2013b.app/sys/os/maci64/:/Applications/MATLAB_R2013b.app/runtime/maci64/:/Applications/MATLAB_R2013b.app/bin/maci64/
 
 = Other jar files =
 
-1. Copy your web servers servlet-api.jar file into this directory.
+1. Copy your web server's servlet-api.jar file into this directory:
 
-2. Copy the javabuilder.jar file from your MATLAB or MCR install root in the directory /toolbox/javabuilder/jar/javabuilder.jar to the web applications lib folder ./WebContent/WEB-INF/lib
+        cp $CATALINA_BASE/libs/servlet-api.jar .
+
+2. Copy the javabuilder.jar file from your MATLAB or MCR install root the webapp lib folder:
+
+        (if you installed the MATLAB MCR to /Applications/MATLAB/MATLAB_Compiler_Runtime/)
+
+        cp /Applications/MATLAB/MATLAB_Compiler_Runtime/v82/toolbox/javabuilder/jar/javabuilder.jar ./WebContent/WEB-INF/lib/
 
 
 == Building the Web Application (echoapp.war) ==
 
-3. Run 'ant build.xml'. This should create the echoapp.war file. In case this fails, follow "Compiling and Generating the echoapp.war file" instructions below (points 3.1 to 3.4).
+3. Run 'ant build.xml'. This should create the echoapp.war file. In case this fails, follow "Compiling and Generating the echoapp.war file" instructions below.
 
-4. Copy the echoapp.war file to your web server's webapps folder (usually $CATALINA_BASE/webapps);
+4. Copy the echoapp.war file to your web server's webapps folder:
+
+        cp echoapp.war $CATALINA_BASE/webapps
 
 5. Start/Restart Tomcat, making sure the webapp is correctly deployed;
 
-6. Start the web server and navigate in a browser to the following url: http://localhost:8080/echoapp/
+6. Start the web server and navigate in a browser to the following url:
 
+        http://localhost:8080/echoapp/
 
 
 == Compiling and Generating the echoapp.war file ==
Binary file WebContent/WEB-INF/lib/javabuilder.jar has changed
--- a/build.xml	Tue Dec 10 18:43:20 2013 +0000
+++ b/build.xml	Tue Dec 10 22:05:19 2013 +0000
@@ -10,14 +10,6 @@
   <property name="web.dir" location="WebContent"/>
   <property name="war.file"  location="echoapp.war"/>
 
-  <uptodate property="warBuild.notRequired" targetfile="${war.file}" >
-    <srcfiles dir= "${classes}" includes="*.class"/>
-    <srcfiles dir= "${src}" includes="*.java" />
-    <srcfiles dir= "${web.dir}" includes="*.jsp"/>
-    <srcfiles dir= "${web.dir}" includes="*.css"/>
-    <srcfiles dir= "${web.dir}" includes="*.xml" />
-  </uptodate>
-
   <target name="init">
     <!-- Create the time stamp -->
     <tstamp/>
@@ -28,7 +20,7 @@
   </target>
 
   <target name="build-war" depends="build"
-        description="generate the WAR file" unless="warBuild.notRequired">
+        description="generate the WAR file" >
     <war destfile="${war.file}" webxml="${web.dir}/WEB-INF/web.xml">
       <fileset dir="${web.dir}">
         <exclude name="${web.dir}/WEB-INF/web.xml" />
@@ -39,5 +31,6 @@
   <target name="clean" description="clean up" >
     <!-- Delete the ${build} and ${dist} directory trees -->
     <delete dir="${build}"/>
+    <delete file="${war.file}"/>
   </target>
 </project>