[chronojump] improved the creation of the bundle for windows



commit bcbf19b6f8453a8b630374e192487a7e81ab37b2
Author: Xavier de Blas <xaviblas gmail com>
Date:   Wed Aug 26 20:44:05 2009 +0200

    improved the creation of the bundle for windows

 build/data/chronojump.prg                          |  Bin 3019776 -> 0 bytes
 build/data/chronojump_mini.prg                     |  Bin 39936 -> 0 bytes
 .../build/ChronoJump-0.8.9.4-win32_old.exe         |  Bin 22034923 -> 0 bytes
 build/windows_bundle/build/chronojump.prg          |    1 -
 build/windows_bundle/build/chronojump_mini.prg     |    1 -
 build/windows_bundle/build/howto_build.txt         |   19 +++++-
 build/windows_bundle/build/makeBundle.sh           |    4 +-
 create_release_windows.sh                          |   68 ++++++++++++++++++++
 src/util.cs                                        |    6 +-
 version.txt                                        |    1 -
 10 files changed, 89 insertions(+), 11 deletions(-)
---
diff --git a/build/windows_bundle/build/howto_build.txt b/build/windows_bundle/build/howto_build.txt
index 7ff2e37..2017554 100755
--- a/build/windows_bundle/build/howto_build.txt
+++ b/build/windows_bundle/build/howto_build.txt
@@ -6,13 +6,26 @@ http://sourceforge.net/projects/mingw/files/
 3: install mono in a dir without spaces
 
 go to build 
-edit mkbundle.sh change MONO_INSTALL_PATHY to where it's installed mono 
+edit mkbundle.sh change MONO_INSTALL_PATH to where it's installed mono 
 (HAS TO BE A PATH WITHOUT SPACES, like c:\mono)
 
 (there were problems with dos2unix: broken pipe. But now we don't use and there aren't problems
 
-on mingw/msys, go to build, execute:
+After creating the release with
+./create_release_windows.sh 0.8.9.6
+copy the dir to windows at c:\
+
+on mingw/msys, go to build:
+cd /c/chronojum-0.8.9.6/build/
+
+, execute:
 $sh makeBundle.sh
 this takes the last compiled prg and generates exe on bin directory
 
-then with innosetup we can create the installer that is ok because installs the driver and puts the gtk_prefs on the "start" folder
\ No newline at end of file
+then with innosetup we can create the installer that is ok because installs the driver and puts the gtk_prefs on the "start" folder:
+open chronojump_innosetup.iss on build folder
+change version AT TWO PLACES:
+-AppVerName
+-OutputBaseFilename
+
+compile
diff --git a/build/windows_bundle/build/makeBundle.sh b/build/windows_bundle/build/makeBundle.sh
index 08cbea5..0054add 100755
--- a/build/windows_bundle/build/makeBundle.sh
+++ b/build/windows_bundle/build/makeBundle.sh
@@ -3,7 +3,7 @@ export PATH=$PATH:/c/Mono-2.4.2.2/bin
 export MONO_PATH=.
 export PKG_CONFIG_PATH=$MONO_INSTALL_PATH/lib/pkgconfig/
 windres logo.rc logo.o
-$MONO_INSTALL_PATH/bin/mono.exe $MONO_INSTALL_PATH/lib/mono/2.0/mkbundle.exe ./chronojump.prg --deps -c -o temp.c -oo temp.o
+$MONO_INSTALL_PATH/bin/mono.exe $MONO_INSTALL_PATH/lib/mono/2.0/mkbundle.exe ./Chronojump.exe --deps -c -o temp.c -oo temp.o
 gcc -mno-cygwin -g -o ../bin/ChronoJump.exe -Wall temp.c `pkg-config --cflags --libs mono`  logo.o temp.o
-$MONO_INSTALL_PATH/bin/mono.exe $MONO_INSTALL_PATH/lib/mono/2.0/mkbundle.exe ./chronojump_mini.prg --deps -c -o temp.c -oo temp.o
+$MONO_INSTALL_PATH/bin/mono.exe $MONO_INSTALL_PATH/lib/mono/2.0/mkbundle.exe ./Chronojump_Mini.exe --deps -c -o temp.c -oo temp.o
 gcc -mno-cygwin -g -o ../bin/ChronoJump_mini.exe -Wall temp.c `pkg-config --cflags --libs mono`  logo.o temp.o
diff --git a/create_release_windows.sh b/create_release_windows.sh
new file mode 100755
index 0000000..cb6b4e9
--- /dev/null
+++ b/create_release_windows.sh
@@ -0,0 +1,68 @@
+#!/bin/sh
+
+#Xavier de Blas, www.xdeblas.com
+
+args=$1
+echo $args
+
+#usage info
+if [ "$1" = "" ]; then
+	echo "Usage:\n $0 x.yy\n $0 x.yy.zz.ww\n NOT things like 'svn-...'"
+	#echo "Recommended!!!: $0 `cat version.txt`"
+	exit
+fi
+
+#create release root dir if needed
+if ! test -e "releases_windows"; then
+	mkdir releases_windows
+fi
+
+#create the executable
+make
+
+#create the blank db
+cd build/data
+mono Chronojump.exe createBlankDB
+echo "Blank DB created!"
+
+cd ../..
+
+#create specific release dir
+
+release_dir="releases_windows/chronojump-$1"
+
+if test -e $release_dir; then 
+	echo "release exists. EXITING! NOTHING COPIED TO releases!!!"
+	exit
+fi
+
+mkdir $release_dir
+
+#copy files ('L' for copying de symbolic link of chronopic-tests)
+cp -rL build/windows_bundle/* $release_dir/.
+
+#copy docs, license & other text stuff (these are not on "build" dir)
+mkdir $release_dir/docs
+cp manual/chronojump_manual_es.pdf $release_dir/docs/.
+cp glossary/chronojump_glossary_for_translators.html $release_dir/docs/.
+cp AUTHORS $release_dir/docs/.
+cp COPYING $release_dir/docs/.
+cp INSTALL $release_dir/docs/.
+cp changelog.txt $release_dir/docs/.
+
+
+#create compressed files
+
+release_subdir="chronojump-$1"
+cd releases_windows
+
+#zip
+windows_zip_dir="windows_zip_releases"
+zip -r $release_subdir.zip $release_subdir -x \*.svn\* -x \*.tar.gz
+mv $release_subdir.zip $release_subdir
+cp $release_subdir/$release_subdir.zip ../$windows_zip_dir
+
+#echo "Release WINDOWS done!\n- $release_subdir.zip has been copied to $windows_zip_dir , please 'git add' from that dir" > $release_subdir/readme.txt
+#cd ..
+#echo "\nPlease read $releases/$release_subdir/readme.txt"
+echo "done"
diff --git a/src/util.cs b/src/util.cs
index c3768a5..290feba 100644
--- a/src/util.cs
+++ b/src/util.cs
@@ -677,16 +677,16 @@ public class Util
 			return System.IO.Path.Combine(runningFolder,"../../");
 	}
 
-	public static string GetDataDir(){
+	private static string getDataDir(){
 		return System.IO.Path.Combine(GetPrefixDir(),"share/chronojump");
 	}
 
 	public static string GetImagesDir(){
-		return System.IO.Path.Combine(GetDataDir(),"images");
+		return System.IO.Path.Combine(getDataDir(),"images");
 	}
 
 	public static string GetCssDir(){
-		return GetDataDir();
+		return getDataDir();
 	}
 	
 	public static void BackupDirCreateIfNeeded () {



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]