1 |
#!/bin/bash |
2 |
############################################################################# |
3 |
# XULU Start Script - This file is part of the eXtendable Unified Land Use |
4 |
# Modelling Platform (XULU) |
5 |
############################################################################# |
6 |
# |
7 |
# This library is free software; you can redistribute it and/or modify it |
8 |
# under the terms of the GNU Lesser General Public License as published by the |
9 |
# Free Software Foundation; either version 2.1 of the License, or (at your |
10 |
# option) any later version. |
11 |
# This library is distributed in the hope that it will be useful, but |
12 |
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
13 |
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License |
14 |
# for more details. |
15 |
# You should have received a copy of the GNU Lesser General Public License |
16 |
# along with this library; if not, write to the Free Software Foundation, Inc., |
17 |
# 51 Franklin St, Fifth Floor, Boston, MA 02110, USA |
18 |
# |
19 |
# Diese Bibliothek ist freie Software; Sie dürfen sie unter den Bedingungen |
20 |
# der GNU Lesser General Public License, wie von der Free Software Foundation |
21 |
# veröffentlicht, weiterverteilen und/oder modifizieren; entweder gemäß Version |
22 |
# 2.1 der Lizenz oder (nach Ihrer Option) jeder späteren Version. |
23 |
# Diese Bibliothek wird in der Hoffnung weiterverbreitet, daß sie nützlich |
24 |
# sein wird, jedoch OHNE IRGENDEINE GARANTIE, auch ohne die implizierte Garantie |
25 |
# der MARKTREIFE oder der VERWENDBARKEIT FÜR EINEN BESTIMMTEN ZWECK. Mehr |
26 |
# Details finden Sie in der GNU Lesser General Public License. |
27 |
# Sie sollten eine Kopie der GNU Lesser General Public License zusammen mit |
28 |
# dieser Bibliothek erhalten haben; falls nicht, schreiben Sie an die Free |
29 |
# Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA. |
30 |
# |
31 |
|
32 |
#################################################################### |
33 |
############# Xulu library paths and parameters ############### |
34 |
################################################################### |
35 |
|
36 |
LIB_ROOT="../../lib" |
37 |
|
38 |
XULU_LIB=classes |
39 |
XULU_MODELS_LIB=classes_models |
40 |
if [ "$1" == "-useXuluJar" ]; then XULU_LIB=$LIB_ROOT/xulu/XuluModellingPlatform.jar ; fi |
41 |
if [ "$1" == "-useXuluJar" ]; then XULU_MODELS_LIB=$LIB_ROOT/xulu/XuluModellingPlatformModels.jar ; fi |
42 |
##if "$1"=="/useXuluClasses" set XULU_LIB=classes |
43 |
##if "$1"=="/useXuluClasses" set XULU_MODELS_LIB=classes_models |
44 |
|
45 |
XULU_REGISTRY=./registry_ProxyGrid.xif |
46 |
XULU_LANGUAGE=de |
47 |
XULU_WORK_DIR= |
48 |
XULU_START_SCRIPTS= |
49 |
XULU_RESOURCE=resource |
50 |
|
51 |
#################################################### |
52 |
############# External libraries ############### |
53 |
#################################################### |
54 |
|
55 |
##### Where to find "Java Advanced Imaging" ##### |
56 |
JAI_ROOT=$LIB_ROOT/jai-1_1_3/lib |
57 |
|
58 |
##### Where to find "GeoTools" ##### |
59 |
GT_ROOT=$LIB_ROOT/gt2-2.4.4 |
60 |
|
61 |
##### Where to find gt2-arcgrid-2.1.x.jar (from SpearfishDemo) ##### |
62 |
GT_ARCGRID_ROOT=$LIB_ROOT/geotoolsArcGrid |
63 |
|
64 |
##### Where to find "Adagios" ##### |
65 |
ADAGIOS_ROOT=$LIB_ROOT/Adagios |
66 |
|
67 |
##### Where to find "Log4j" ##### |
68 |
LOG4J_ROOT=$LIB_ROOT/log4j-1.2.14 |
69 |
|
70 |
##### Where to find "JINI" ##### |
71 |
JINI_ROOT=$LIB_ROOT/jini |
72 |
|
73 |
##### Where to find "R" ##### |
74 |
#R_ROOT=$LIB_ROOT/JavaRInterface |
75 |
|
76 |
##### Where to find "jFreeChart" ##### |
77 |
JFREECHART_ROOT=$LIB_ROOT/jFreeChart |
78 |
|
79 |
##### combine the external libs ##### |
80 |
JAI_LIB=$JAI_ROOT/* |
81 |
GT_LIB=$GT_ROOT/* |
82 |
GT_LIB=$GT_LIB:$GT_ARCGRID_ROOT/gt2-arcgrid-2.3.0-M0.jar:$GT_ARCGRID_ROOT/junit-4.4.jar |
83 |
ADAGIOS_LIB=$ADAGIOS_ROOT/AdagiosJavaLib.jar |
84 |
JINI_LIB=$JINI_ROOT/lib/*:$JINI_ROOT/lib-dl/*:$JINI_ROOT/lib-ext/* |
85 |
# set JINI_LIB=$JINI_ROOT/lib/jsk-platform.jar;$JINI_ROOT/lib/tools.jar |
86 |
LOG4J_LIB=$LOG4J_ROOT/log4j-1.2.14.jar |
87 |
#R_LIB=$R_ROOT/JRI.jar;$R_ROOT/libjri.so;$R_ROOT/libR.so |
88 |
JFREECHART_LIB=$JFREECHART_ROOT/jfreechart-1.0.6.jar:$JFREECHART_ROOT/jcommon-1.0.10.jar |
89 |
|
90 |
LIB_ALL=$XULU_LIB:$JAI_LIB:$GT_LIB:$ADAGIOS_LIB:$LOG4J_LIB:$JINI_LIB:$JFREECHART_LIB #:$R_LIB |
91 |
|
92 |
##### combine the native libs ##### |
93 |
JAI_NATIVE=$JAI_ROOT/native_linux |
94 |
|
95 |
LIB_NATIVE=$JAI_NATIVE |
96 |
|
97 |
|
98 |
##### combine Xulu starting parameters ##### |
99 |
|
100 |
XULU_PARAMS="" |
101 |
|
102 |
if test -n $XULU_LANGUAGE ; then |
103 |
XULU_PARAMS="$XULU_PARAMS -l $XULU_LANGUAGE" |
104 |
fi |
105 |
|
106 |
if test -n $XULU_REGISTRY ; then |
107 |
XULU_PARAMS="$XULU_PARAMS -rf $XULU_REGISTRY" |
108 |
fi |
109 |
|
110 |
if test -n $XULU_MODELS_LIB ;then |
111 |
XULU_PARAMS="$XULU_PARAMS -d $XULU_MODELS_LIB" |
112 |
fi |
113 |
|
114 |
if test -n $XULU_WORK_DIR; then |
115 |
XULU_PARAMS="$XULU_PARAMS -w $XULU_WORK_DIR" |
116 |
fi |
117 |
|
118 |
|
119 |
if test -n $XULU_START_SCRIPTS; then |
120 |
XULU_PARAMS="$XULU_PARAMS -s $XULU_START_SCRIPTS" |
121 |
fi |
122 |
|
123 |
##### determine java interpreter ##### |
124 |
JAVA_PRG="java" |
125 |
|
126 |
|
127 |
##### start Xulu ##### |
128 |
# -version:1.6.0_10 funktioniert unter linux nicht |
129 |
$JAVA_PRG -Xms300M -Xmx1000M -cp $XULU_RESOURCE:$LIB_ALL -Djava.library.path=$LIB_NATIVE -splash:resource/icons/xulu_start.png edu.bonn.xulu.XuluModellingPlatform $XULU_PARAMS $* |
130 |
|