Index: /main/trunk/release-kits/bin/rk.bat
===================================================================
--- /main/trunk/release-kits/bin/rk.bat	(revision 21521)
+++ /main/trunk/release-kits/bin/rk.bat	(revision 21521)
@@ -0,0 +1,15 @@
+@echo off
+set RELEASE_DIR=%CD%
+echo RELEASE_DIR:%RELEASE_DIR%
+pushd "%CD%"
+CD /D "%~dp0\.."
+
+
+::set PIPETO="%CD%\shared\windows\utils\tee.exe" "%RELEASE_DIR%\rk3.out"
+
+@echo on
+cmd.exe /c ant -f "%CD%\kits\%RK_NAME%\ant-scripts\build.xml" "-Drk.home=%CD%" "-Drk.name=%RK_NAME%" "-Dbasedir=%RELEASE_DIR%" -lib "%RELEASE_DIR%/installer/classes" %*
+
+:end
+
+popd
Index: /main/trunk/release-kits/bin/rk2.bat
===================================================================
--- /main/trunk/release-kits/bin/rk2.bat	(revision 21521)
+++ /main/trunk/release-kits/bin/rk2.bat	(revision 21521)
@@ -0,0 +1,3 @@
+@echo off
+set RK_NAME=%0
+%~dp0\rk.bat %*
Index: /main/trunk/release-kits/bin/rk3.bat
===================================================================
--- /main/trunk/release-kits/bin/rk3.bat	(revision 21521)
+++ /main/trunk/release-kits/bin/rk3.bat	(revision 21521)
@@ -0,0 +1,3 @@
+@echo off
+set RK_NAME=%0
+%~dp0\rk.bat %*
Index: /main/trunk/release-kits/kits/rk2/ant-scripts/compile.xml
===================================================================
--- /main/trunk/release-kits/kits/rk2/ant-scripts/compile.xml	(revision 21520)
+++ /main/trunk/release-kits/kits/rk2/ant-scripts/compile.xml	(revision 21521)
@@ -194,5 +194,4 @@
 
 	<target name="compile-c-code">
-		<copy file="${rk.home}/kits/rk2/resources/compile.bat" todir="${basedir}/compiled" overwrite="true"/>
 		<exec dir="${basedir}/compiled" executable="nmake"><arg value="/f"/><arg value="win32.mak"/><arg value="clean"/></exec>
 		<exec dir="${basedir}/compiled" executable="nmake"><arg value="/f"/><arg value="win32.mak"/><arg value="APACHE_HTTPD=1"/></exec>
Index: /main/trunk/release-kits/kits/rk2/ant-scripts/create-cdrom-components.xml
===================================================================
--- /main/trunk/release-kits/kits/rk2/ant-scripts/create-cdrom-components.xml	(revision 21520)
+++ /main/trunk/release-kits/kits/rk2/ant-scripts/create-cdrom-components.xml	(revision 21521)
@@ -8,5 +8,5 @@
 	-->
 
-	<target name="create-cdrom-components">
+	<target name="create-cdrom-components" depends="init,gs2-init">
 		<antcall target="compile-cdrom-installer"/> <!-- from init -->
 		<antcall target="prepare-cdrom-components"/>
@@ -32,7 +32,5 @@
 		<!-- core linux -->
 		<if><bool><equals arg1="${rk.os}" arg2="linux"/></bool>
-			<copy todir="cdrom/dist/Software/core/all" overwrite="true">
-				<fileset dir="components/tmp/core"/>
-			</copy>
+			<unzip src="components/core.comp" dest="cdrom/dist/Software/core/all" overwrite="true"/>
 			<move todir="cdrom/dist/Software/core/linux" overwrite="true">
 				<fileset dir="cdrom/dist/Software/core/all">
@@ -54,6 +52,6 @@
 		<!-- core windows -->
 		<else><if><bool><equals arg1="${rk.os}" arg2="windows"/></bool>
-			<copy todir="cdrom/dist/Software/core/windows" overwrite="true">
-				<fileset dir="components/tmp/core">
+			<unzip src="components/core.comp" dest="cdrom/dist/Software/core/windows" overwrite="true">
+				<patternset>
 					<include name="bin/windows"/>
 					<include name="server.exe"/>
@@ -63,11 +61,11 @@
 					<include name="*.bat"/>
 					<include name="gli/*.bat"/>
-				</fileset>
-			</copy>
+				</patternset>
+			</unzip>
 
 		<!-- core mac -->
 		<else><if><bool><equals arg1="${rk.os}" arg2="mac"/></bool>
-			<copy todir="cdrom/dist/Software/core/mac" overwrite="true">
-				<fileset dir="components/tmp/core">
+			<unzip src="components/core.comp" dest="cdrom/dist/Software/core/mac" overwrite="true">
+				<patternset>
 					<include name="bin/darwin"/>
 					<include name="bin/darwin/**/*"/>
@@ -81,6 +79,6 @@
 					<include name="*.csh"/>
 					<include name="*.bash"/>
-				</fileset>
-			</copy>
+				</patternset>
+			</unzip>
 			<!-- delete the httpd manual to save space -->
 			<delete dir="cdrom/dist/Software/core/mac/apache-httpd/darwin/manual"/>
@@ -90,14 +88,10 @@
 		<!-- imagemagick -->
 		<mkdir dir="cdrom/dist/Software/imagemagick/${rk.os}"/>
-		<copy todir="cdrom/dist/Software/imagemagick/${rk.os}" overwrite="true">
-			<fileset dir="components/tmp/imagemagick"/>
-		</copy>
+		<unzip src="components/imagemagick.comp" dest="cdrom/dist/Software/imagemagick/${rk.os}" overwrite="true"/>
 
 		<!-- ghostscript: windows and mac only -->
 		<if><bool><or><equals arg1="${rk.os}" arg2="windows"/><equals arg1="${rk.os}" arg2="mac"/></or></bool>
 			<mkdir dir="cdrom/dist/Software/ghostscript/${rk.os}"/>
-			<copy todir="cdrom/dist/Software/ghostscript/${rk.os}" overwrite="true">
-				<fileset dir="components/tmp/ghostscript"/>
-			</copy>
+			<unzip src="components/ghostscript.comp" dest="cdrom/dist/Software/ghostscript/${rk.os}" overwrite="true"/>
 		</if>
 
@@ -133,5 +127,10 @@
 		<!-- windows -->
 		<if><bool><equals arg1="${rk.os}" arg2="windows"/></bool>
-			<antcall target="get-copy-of-wrapper-source"><param name="todir" value="cdrom/build"/></antcall>
+			<copy todir="cdrom/build" overwrite="true">
+				<fileset dir="${rk.home}/shared/windows/wrapper"/>
+				<fileset dir="${rk.home}/shared/greenstone2/wrapper" includes="*.bmp"/>
+				<fileset dir="${rk.home}/shared/greenstone2/icon" includes="icon.ico"/>
+				<fileset dir="${rk.home}/shared/core/search4j" includes="libsearch4j.cpp,libsearch4j.h"/>
+			</copy>
 			<exec executable="rc" dir="cdrom/build">
 				<arg line="wrapper.rc"/>
Index: /main/trunk/release-kits/kits/rk2/ant-scripts/create-distribution.xml
===================================================================
--- /main/trunk/release-kits/kits/rk2/ant-scripts/create-distribution.xml	(revision 21520)
+++ /main/trunk/release-kits/kits/rk2/ant-scripts/create-distribution.xml	(revision 21521)
@@ -59,4 +59,8 @@
 
 	</target>
+	
+	<target name="copy-server">
+		<copy file="distributions/web/bin/windows/server.exe" tofile="distributions/web/server.exe"/>
+	</target>
 
 	<target name="export-imagemagick-linux-binaries">
Index: /main/trunk/release-kits/shared/core/ant-scripts/init.xml
===================================================================
--- /main/trunk/release-kits/shared/core/ant-scripts/init.xml	(revision 21520)
+++ /main/trunk/release-kits/shared/core/ant-scripts/init.xml	(revision 21521)
@@ -24,4 +24,7 @@
 		<property name="basedir.local" refid="basedir.path"/>
 
+		<!-- size of resource chunks (wrapper) -->
+		<property name="resources.chunksize" value="8388608"/>
+		
 		<!-- current date and time -->
 		<tstamp>
@@ -232,5 +235,5 @@
 			installConfig="installer/antinstall-config-cdrom.xml"
 			buildFile="installer/build-cdrom.xml"
-			antInstallLib="${rk.home}/core/ant-installer/lib"
+			antInstallLib="${rk.home}/shared/core/ant-installer/lib"
 			antLib="${ant.home}/lib"
 			validateConfig="true"
@@ -373,5 +376,5 @@
 		<mkdir dir="${todir}"/>
 		<delete dir="${todir}/perl"/>
-		<unzip src="${rk.home}/windows/perl.zip" dest="${todir}"/>
+		<unzip src="${rk.home}/shared/windows/perl.zip" dest="${todir}"/>
 	</target>
 
@@ -497,5 +500,5 @@
 		<!-- windows -->
 		<if><bool><equals arg1="${rk.os}" arg2="windows"/></bool>
-			<exec executable="${rk.home}/windows/7za/7za.exe" dir="components"><arg line="a -t7z -mx=9 ${component}.lzma ${component}.comp"/></exec>
+			<exec executable="${rk.home}/shared/windows/7za/7za.exe" dir="components"><arg line="a -t7z -mx=9 ${component}.lzma ${component}.comp"/></exec>
 		
 		<!-- linux, mac -->
