ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/owl/trunk/scripts/make-owl.sh
Revision: 1261
Committed: Wed Oct 13 08:38:40 2010 UTC (9 years, 2 months ago) by jmduarteg
File size: 1504 byte(s)
Log Message:
Added option to compile specific revision
Line User Rev File contents
1 duarte 496 #!/bin/sh
2 duarte 971 if [ -z "$2" ]
3 duarte 496 then
4 jmduarteg 1261 echo "Usage: make-owl.sh <svn url> <tempdir> [<rev>]"
5     echo "e.g. for svn url: svn://black/aglappe/trunk or svn://bioinformatics.org/svnroot/owl/tags/owl-1.2.0"
6     echo "Optionally specify a revision to be exported instead of head"
7 duarte 496 exit
8     fi
9    
10 duarte 971 svnurl=$1
11 duarte 968 tempdir=$2
12 jmduarteg 1261 rev=""
13     if [ -n "$3" ]
14     then
15     rev=$3
16     fi
17 duarte 496
18 duarte 968 echo "Compiling with:"
19     javac -version
20     echo ""
21 duarte 496
22    
23     cd $tempdir
24    
25 duarte 971 tag=`basename $svnurl`
26 duarte 496
27 jmduarteg 1261 revStr=""
28     if [ -n "$rev" ]
29     then
30     revStr="-r $rev"
31     fi
32 duarte 971
33 duarte 496 # exporting from svn
34     echo "Exporting source from svn"
35 jmduarteg 1261 svn export $revStr $svnurl
36 duarte 971 if [ "$?" -ne "0" ]
37 duarte 496 then
38 duarte 971 echo "Couldn't export from svn. Exiting"
39     exit 1
40 duarte 496 fi
41    
42    
43     # compiling
44     echo "Compiling..."
45 duarte 968 cd $tag/src
46 duarte 971
47    
48     jarfiles=`ls ../jars/*.jar`
49     CLASSPATH="."
50     for jarfile in $jarfiles
51     do
52     CLASSPATH="$jarfile:$CLASSPATH"
53     done
54 jmduarteg 1152 jarfiles=`ls ../jars/uniprot/*.jar`
55     for jarfile in $jarfiles
56     do
57     CLASSPATH="$jarfile:$CLASSPATH"
58     done
59 duarte 971
60     echo $CLASSPATH
61    
62    
63 jmduarteg 1152 javac \
64     *.java \
65     owl/core/structure/*.java \
66 jmduarteg 1156 owl/core/structure/graphs/*.java \
67     owl/core/structure/scoring/*.java \
68 jmduarteg 1152 owl/core/sequence/*.java \
69 jmduarteg 1156 owl/core/sequence/alignment/*.java \
70 jmduarteg 1152 owl/core/util/*.java \
71 jmduarteg 1156 owl/core/util/actionTools/*.java \
72 jmduarteg 1152 owl/core/connections/*.java \
73 jmduarteg 1156 owl/core/connections/pisa/*.java \
74 jmduarteg 1152 owl/core/features/*.java \
75 jmduarteg 1156 owl/core/runners/*.java \
76     owl/core/runners/blast/*.java \
77     owl/core/runners/tinker/*.java
78 duarte 496
79     # creating jar file
80 duarte 968 echo "Creating jar file: $tag.jar ..."
81     jar -cfm ../../$tag.jar ../Manifest.txt .
82 duarte 496
83 duarte 968 # removing $tag temp directory
84     cd ../..
85 duarte 972 rm -rf $tag

Properties

Name Value
svn:executable *