patches/azureus-01-startscript.diff
author jurikm
Sun, 12 Feb 2012 14:04:10 +0000
changeset 8245 383896da4129
parent 1220 4a3b1d86c696
permissions -rw-r--r--
SFEsauerbraten.spec: add IPS package name
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1220
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
     1
--- azureus.orig	Fri Jun 20 18:11:58 2008
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
     2
+++ azureus	Fri Jun 20 18:24:42 2008
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
     3
@@ -4,6 +4,7 @@
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
     4
 SCRIPT_NOT_CHANGED=0	# change this to 1 if you don't want your script overwritten!
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
     5
 JAVA_PROGRAM_DIR=""	# use full path to java bin dir, ex. "/usr/java/j2sdk1.4.2/bin/"
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
     6
 #PROGRAM_DIR="/home/username/apps/azureus"	# use full path to Azureus bin dir
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
     7
+PROGRAM_DIR="/usr/share/Azureus"
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
     8
 JAVA_ARGS="-Xmx128m"
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
     9
 
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    10
 #export MOZILLA_FIVE_HOME="/path/to/gre"	# Full path to GRE/Mozilla. When commenting out this line, also comment out the next line
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    11
@@ -118,7 +119,7 @@
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    12
 
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    13
 	${JAVA_PROGRAM_DIR}java "${JAVA_ARGS}" \
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    14
 		-cp "${CLASSPATH}" \
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    15
-		-Djava.library.path="${PROGRAM_DIR}" \
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    16
+		-Djava.library.path=/usr/lib/swt:"${PROGRAM_DIR}" \
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    17
 		-Dazureus.install.path="${PROGRAM_DIR}" \
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    18
 		-Dazureus.script="$0" \
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    19
 		$JAVA_PROPS \
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    20
@@ -161,6 +162,8 @@
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    21
 	CLASSPATH="${CLASSPATH:+${CLASSPATH}:}$FILE"
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    22
 done
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    23
 
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    24
+CLASSPATH=$CLASSPATH:/usr/lib/swt/swt.jar
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    25
+
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    26
 # setup Java System Properties (no spaces in values)
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    27
 JAVA_PROPS="-Dazureus.script.version=${SCRIPT_VERSION}"
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    28
 if [ ! "$JAVA_ISGCJ x" = " x" ] ; then
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    29
@@ -169,19 +172,19 @@
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    30
 
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    31
 # some distros symlink application level plugins into the users's plugin directory..
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    32
 # remove all symlinks in user's plugin directory
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    33
-find ~/.azureus/plugins -maxdepth 1 -type l -xtype d  -exec rm {} \;
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    34
+#find ~/.azureus/plugins -maxdepth 1 -type l -xtype d  -exec rm {} \;
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    35
 
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    36
 runJavaOutput "org.gudy.azureus2.platform.unix.ScriptBeforeStartup" "$@";
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    37
 
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    38
 echo $MSG_LOADING
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    39
 
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    40
-echo "${JAVA_PROGRAM_DIR}java ${JAVA_ARGS} -cp \"${CLASSPATH}\" -Djava.library.path=\"${PROGRAM_DIR}\" -Dazureus.install.path=\"${PROGRAM_DIR}\" -Dazureus.script=\"$0\" $JAVA_PROPS $START_CLASS $@"
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    41
+echo "${JAVA_PROGRAM_DIR}java ${JAVA_ARGS} -cp \"${CLASSPATH}\" -Djava.library.path=/usr/lib/swt:\"${PROGRAM_DIR}\" -Dazureus.install.path=\"${PROGRAM_DIR}\" -Dazureus.script=\"$0\" $JAVA_PROPS $START_CLASS $@"
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    42
 # Don't use "exec -a Azureus ..." here as exec quits this script after completion,
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    43
 # preventing ScriptAfterShutdown from running, which installs updates and does
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    44
 # restarts
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    45
 ${JAVA_PROGRAM_DIR}java "${JAVA_ARGS}" \
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    46
 	-cp "${CLASSPATH}" \
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    47
-	-Djava.library.path="${PROGRAM_DIR}" \
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    48
+	-Djava.library.path=/usr/lib/swt:"${PROGRAM_DIR}" \
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    49
 	-Dazureus.install.path="${PROGRAM_DIR}" \
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    50
 	-Dazureus.script="$0" \
4a3b1d86c696 2008-06-20 River Tarnell <[email protected]>
rtarnell
parents:
diff changeset
    51
 	$JAVA_PROPS \