Changeset 23359

Show
Ignore:
Timestamp:
30.11.2010 14:25:11 (9 years ago)
Author:
sjm84
Message:

makegli.sh will now use the JAVAC and JAVACFLAGS environment variables if they are set. JAVACFLAGS will default to "-target 1.4 and -source 1.4" by default

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/gli/makegli.sh

    r17946 r23359  
    3535if [ "x$javacpath" = "x" ]; then 
    3636 
     37    # If the JAVAC environment variable is set then use it 
     38    if [ "x$JAVAC" != "x" ] ; then 
     39    javacpath=$JAVAC 
    3740    # If it is set, use the JAVA_HOME environment variable 
    38     if [ "x$JAVA_HOME" != "x" ]; then 
     41    elif [ "x$JAVA_HOME" != "x" ]; then 
    3942    javacpath="$JAVA_HOME/bin/javac" 
    40  
    4143    # Check if Javac is on the search path 
    4244    else 
    4345    javacpath=`which javac 2> /dev/null` 
    4446    fi 
     47fi 
     48 
     49if [ "xJAVACFLAGS" = "x" ] ; then 
     50    JAVACFLAGS="-source 1.4 -target 1.4" 
    4551fi 
    4652 
     
    9399    fi 
    94100 
    95     $javacpath -deprecation -d classes/ -sourcepath src/ -classpath classes/:lib/apache.jar:lib/qfslib.jar $* 
     101    $javacpath $JAVACFLAGS -deprecation -d classes/ -sourcepath src/ -classpath classes/:lib/apache.jar:lib/qfslib.jar $* 
    96102 
    97103    if [ "$glilang" = "es" ]; then 
     
    123129 
    124130# Compile the GLI 
    125 $javacpath -deprecation -d classes/ -sourcepath src/ -classpath classes/:lib/apache.jar:lib/qfslib.jar src/org/greenstone/gatherer/GathererProg.java 
    126 $javacpath -deprecation -d classes/ -sourcepath src/ -classpath classes/:lib/apache.jar:lib/qfslib.jar src/org/greenstone/gatherer/GathererApplet.java 
     131$javacpath $JAVACFLAGS -deprecation -d classes/ -sourcepath src/ -classpath classes/:lib/apache.jar:lib/qfslib.jar src/org/greenstone/gatherer/GathererProg.java 
     132$javacpath $JAVACFLAGS -deprecation -d classes/ -sourcepath src/ -classpath classes/:lib/apache.jar:lib/qfslib.jar src/org/greenstone/gatherer/GathererApplet.java 
    127133#$javacpath -deprecation -d classes/ -sourcepath src/ -classpath classes/:lib/apache.jar:lib/qfslib.jar src/org/greenstone/gatherer/GathererApplet4gs3.java 
    128134# Compile the GEMS 
     
    130136 
    131137# Compile the standalone programs needed on the server for remote building 
    132 $javacpath -deprecation -d classes/ -sourcepath src/ -classpath classes/ src/org/greenstone/gatherer/remote/Zip*.java 
    133 $javacpath -deprecation -d classes/ -sourcepath src/ -classpath classes/ src/org/greenstone/gatherer/remote/Unzip.java 
     138$javacpath $JAVACFLAGS -deprecation -d classes/ -sourcepath src/ -classpath classes/ src/org/greenstone/gatherer/remote/Zip*.java 
     139$javacpath $JAVACFLAGS -deprecation -d classes/ -sourcepath src/ -classpath classes/ src/org/greenstone/gatherer/remote/Unzip.java 
    134140 
    135141if [ "$glilang" = "es" ]; then