Index: trunk/gsdl3/dist-resources/gs3-prepare-for-dist.sh
===================================================================
--- trunk/gsdl3/dist-resources/gs3-prepare-for-dist.sh	(revision 7890)
+++ trunk/gsdl3/dist-resources/gs3-prepare-for-dist.sh	(revision 7890)
@@ -0,0 +1,108 @@
+#!/bin/sh 
+
+if [ ! -f gs3-setup.sh ]; then
+    echo "You must run this script from within the Greenstone 3 home directory"
+    exit 1
+fi
+
+#check that GSDL3HOME is set
+source gs3-setup.sh
+
+if test -z "$CVSROOT" ; then
+  echo "You need to set the environment variable CVSROOT before running"
+  echo "this script. Please use the same path that you used to check out"
+  echo "the Greentone repository. If you are not using anonymous cvs, you"
+  echo "also need to set the variable CVS_RSH to ssh."
+  exit;
+fi
+ 
+# firstly, remove unwanted directories
+cvs update -dRP
+
+# now check out extra bits
+cd packages
+cvs co -P mgpp
+cd $GSDL3HOME
+
+cvs co -P gli
+cd gli
+../makegli.sh
+cd classes
+jar cf GLI.jar org images META-INF/MANIFEST.MF *.properties
+rm -r org
+mv GLI.jar ../
+cd $GSDL3HOME
+
+# unpack tomcat and rename directory
+cd comms/jakarta/
+unzip jakarta-tomcat-4.1.30.zip
+mv jakarta-tomcat-4.1.30 tomcat
+
+#edit the tomcat setclasspath script to add our classpath
+mv ./tomcat/bin/setclasspath.sh ./tomcat/bin/setclasspath.sh.orig
+cat ./tomcat/bin/setclasspath.sh.orig | sed 's,CLASSPATH=,CLASSPATH=\"$CLASSPATH\":,' > ./tomcat/bin/setclasspath.sh
+
+#make everyone happy by giving the right permissions to the shell scripts
+chmod a+x ./tomcat/bin/*.sh
+
+#rename server.xml files
+mv ./tomcat/conf/server.xml ./tomcat/conf/server-withexamples.xml.config
+mv ./tomcat/conf/server-noexamples.xml.config ./tomcat/conf/server.xml
+cd $GSDL3HOME
+
+#extract the soap jar file
+cd comms/soap
+unzip soap-bin-2.3.1.zip 
+mv soap-2_3_1 soap
+cp soap/lib/soap.jar $GSDL3HOME/lib/java
+cd $GSDL3HOME
+
+# get mysql 
+cd packages/mysql
+unzip mysql-4.0.20-linux.zip
+    
+./bin/mysql_install_db --user=root --force
+./bin/mysqld_safe --user=root --pid_file=gsdl3.pid &
+sleep 2
+./bin/mysql --user=root --execute="GRANT SELECT,INSERT,DELETE,UPDATE,DROP,CREATE ON *.* TO gsdl3admin@localhost;"
+./bin/mysql --user=root --execute="GRANT SELECT ON *.* TO gsdl3reader@localhost;"
+    
+# set up any sample collections databases
+#gs3mgdemo
+./bin/mysql --user=root --execute="create database localsite_gs3mgdemo;"
+./bin/mysql --user=root localsite_gs3mgdemo < $gsdl3home/web/sites/localsite/collect/gs3mgdemo/mysqldatadump.sql
+
+./bin/mysqladmin --user=root shutdown
+cd  $gsdl3home
+
+
+#compile the test servlet
+source gs3-setup.sh
+cd web/WEB-INF/classes
+javac TestServlet.java
+cd $GSDL3HOME
+
+# make mg and mgpp compile statically
+cd packages/mg
+cat ./configure.in | sed 's,LDFLAGS=,LDFLAGS=-static,' > ./configure.in.tmp
+mv configure.in.tmp configure.in
+autoconf configure.in > configure
+cd $GSDL3HOME
+
+cd packages/mgpp
+cat ./configure.in | sed 's,LDFLAGS=,LDFLAGS=-static,' > ./configure.in.tmp
+mv configure.in.tmp configure.in
+autoconf configure.in > configure
+cd $GSDL3HOME
+
+
+./configure
+make
+make install
+make distclean
+
+# strip the c/c== executables
+strip bin/*
+
+
+
Index: trunk/gsdl3/gs3-prepare-for-dist.sh
===================================================================
--- trunk/gsdl3/gs3-prepare-for-dist.sh	(revision 7889)
+++ 	(revision )
@@ -1,108 +1,0 @@
-#!/bin/sh 
-
-if [ ! -f gs3-setup.sh ]; then
-    echo "You must run this script from within the Greenstone 3 home directory"
-    exit 1
-fi
-
-#check that GSDL3HOME is set
-source gs3-setup.sh
-
-if test -z "$CVSROOT" ; then
-  echo "You need to set the environment variable CVSROOT before running"
-  echo "this script. Please use the same path that you used to check out"
-  echo "the Greentone repository. If you are not using anonymous cvs, you"
-  echo "also need to set the variable CVS_RSH to ssh."
-  exit;
-fi
- 
-# firstly, remove unwanted directories
-cvs update -dRP
-
-# now check out extra bits
-cd packages
-cvs co -P mgpp
-cd $GSDL3HOME
-
-cvs co -P gli
-cd gli
-../makegli.sh
-cd classes
-jar cf GLI.jar org images META-INF/MANIFEST.MF *.properties
-rm -r org
-mv GLI.jar ../
-cd $GSDL3HOME
-
-# unpack tomcat and rename directory
-cd comms/jakarta/
-unzip jakarta-tomcat-4.1.30.zip
-mv jakarta-tomcat-4.1.30 tomcat
-
-#edit the tomcat setclasspath script to add our classpath
-mv ./tomcat/bin/setclasspath.sh ./tomcat/bin/setclasspath.sh.orig
-cat ./tomcat/bin/setclasspath.sh.orig | sed 's,CLASSPATH=,CLASSPATH=\"$CLASSPATH\":,' > ./tomcat/bin/setclasspath.sh
-
-#make everyone happy by giving the right permissions to the shell scripts
-chmod a+x ./tomcat/bin/*.sh
-
-#rename server.xml files
-mv ./tomcat/conf/server.xml ./tomcat/conf/server-withexamples.xml.config
-mv ./tomcat/conf/server-noexamples.xml.config ./tomcat/conf/server.xml
-cd $GSDL3HOME
-
-#extract the soap jar file
-cd comms/soap
-unzip soap-bin-2.3.1.zip 
-mv soap-2_3_1 soap
-cp soap/lib/soap.jar $GSDL3HOME/lib/java
-cd $GSDL3HOME
-
-# get mysql 
-cd packages/mysql
-unzip mysql-4.0.20-linux.zip
-    
-./bin/mysql_install_db --user=root --force
-./bin/mysqld_safe --user=root --pid_file=gsdl3.pid &
-sleep 2
-./bin/mysql --user=root --execute="GRANT SELECT,INSERT,DELETE,UPDATE,DROP,CREATE ON *.* TO gsdl3admin@localhost;"
-./bin/mysql --user=root --execute="GRANT SELECT ON *.* TO gsdl3reader@localhost;"
-    
-# set up any sample collections databases
-#gs3mgdemo
-./bin/mysql --user=root --execute="create database localsite_gs3mgdemo;"
-./bin/mysql --user=root localsite_gs3mgdemo < $gsdl3home/web/sites/localsite/collect/gs3mgdemo/mysqldatadump.sql
-
-./bin/mysqladmin --user=root shutdown
-cd  $gsdl3home
-
-
-#compile the test servlet
-source gs3-setup.sh
-cd web/WEB-INF/classes
-javac TestServlet.java
-cd $GSDL3HOME
-
-# make mg and mgpp compile statically
-cd packages/mg
-cat ./configure.in | sed 's,LDFLAGS=,LDFLAGS=-static,' > ./configure.in.tmp
-mv configure.in.tmp configure.in
-autoconf configure.in > configure
-cd $GSDL3HOME
-
-cd packages/mgpp
-cat ./configure.in | sed 's,LDFLAGS=,LDFLAGS=-static,' > ./configure.in.tmp
-mv configure.in.tmp configure.in
-autoconf configure.in > configure
-cd $GSDL3HOME
-
-
-./configure
-make
-make install
-make distclean
-
-# strip the c/c== executables
-strip bin/*
-
-
-
