[GRASS-SVN] r50850 - grass-addons/tools/wingrass-packager

svn_grass at osgeo.org svn_grass at osgeo.org
Fri Feb 17 16:11:01 EST 2012


Author: martinl
Date: 2012-02-17 13:11:01 -0800 (Fri, 17 Feb 2012)
New Revision: 50850

Added:
   grass-addons/tools/wingrass-packager/grass_packager_release.bat
Modified:
   grass-addons/tools/wingrass-packager/grass_addons.sh
   grass-addons/tools/wingrass-packager/grass_compile.sh
   grass-addons/tools/wingrass-packager/grass_md5sum.sh
   grass-addons/tools/wingrass-packager/grass_osgeo4w.sh
   grass-addons/tools/wingrass-packager/grass_packager.bat
   grass-addons/tools/wingrass-packager/grass_svn_info.sh
Log:
wingrass-packager: update script for dev/release

Modified: grass-addons/tools/wingrass-packager/grass_addons.sh
===================================================================
--- grass-addons/tools/wingrass-packager/grass_addons.sh	2012-02-17 21:06:04 UTC (rev 50849)
+++ grass-addons/tools/wingrass-packager/grass_addons.sh	2012-02-17 21:11:01 UTC (rev 50850)
@@ -35,8 +35,13 @@
 export PATH=/c/OSGeo4W/apps/msys/bin:/c/OSGeo4W/bin:$PATH
 export PYTHONHOME=/c/OSGeo4W/apps/Python27
 
-compile $SVN_PATH/grass6 $GISBASE_PREFIX/grass64_release $ADDON_PREFIX/grass64/addons
-compile $SVN_PATH/grass6 $GISBASE_PREFIX/grass6_devel    $ADDON_PREFIX/grass65/addons
-compile $SVN_PATH/grass7 $GISBASE_PREFIX/grass_trunk     $ADDON_PREFIX/grass70/addons
+if test -z $1 ; then
+    # dev packages
+    compile $SVN_PATH/grass6 $GISBASE_PREFIX/grass64_release $ADDON_PREFIX/grass64/addons
+    compile $SVN_PATH/grass6 $GISBASE_PREFIX/grass6_devel    $ADDON_PREFIX/grass65/addons
+    compile $SVN_PATH/grass7 $GISBASE_PREFIX/grass_trunk     $ADDON_PREFIX/grass70/addons
+else
+    compile $SVN_PATH/grass6 $GISBASE_PREFIX/grass$1         $ADDON_PREFIX/grass$1/addons
+fi
 
 exit 0

Modified: grass-addons/tools/wingrass-packager/grass_compile.sh
===================================================================
--- grass-addons/tools/wingrass-packager/grass_compile.sh	2012-02-17 21:06:04 UTC (rev 50849)
+++ grass-addons/tools/wingrass-packager/grass_compile.sh	2012-02-17 21:11:01 UTC (rev 50850)
@@ -31,8 +31,13 @@
 
 export PATH=$PATH:/c/OSGeo4W/apps/msys/bin
 
-compile grass64_release 64-dev
-compile grass6_devel 65-dev
-compile grass_trunk 70-dev
+if test -z $1 ; then
+    # dev packages
+    compile grass64_release 64-dev
+    compile grass6_devel 65-dev
+    compile grass_trunk 70-dev
+else
+    compile grass$1 $1
+fi
 
 exit 0

Modified: grass-addons/tools/wingrass-packager/grass_md5sum.sh
===================================================================
--- grass-addons/tools/wingrass-packager/grass_md5sum.sh	2012-02-17 21:06:04 UTC (rev 50849)
+++ grass-addons/tools/wingrass-packager/grass_md5sum.sh	2012-02-17 21:11:01 UTC (rev 50850)
@@ -12,8 +12,13 @@
 
 export PATH=$PATH:/c/OSGeo4W/apps/msys/bin
 
-create_md5sum grass64
-create_md5sum grass65
-create_md5sum grass70
+if test -z $1 ; then
+    # dev packages
+    create_md5sum grass64
+    create_md5sum grass65
+    create_md5sum grass70
+else
+    create_md5sum grass$1
+fi
 
 exit 0

Modified: grass-addons/tools/wingrass-packager/grass_osgeo4w.sh
===================================================================
--- grass-addons/tools/wingrass-packager/grass_osgeo4w.sh	2012-02-17 21:06:04 UTC (rev 50849)
+++ grass-addons/tools/wingrass-packager/grass_osgeo4w.sh	2012-02-17 21:11:01 UTC (rev 50850)
@@ -12,13 +12,22 @@
 	package=1
     fi
 
-    cp $dir/grass*-$package*.tar.bz2 $HOME/grass$1
+    if test -z $2; then
+	cp $dir/grass*-$package*.tar.bz2 $HOME/grass$1
+    else
+	cp $dir/grass*-$package*.tar.bz2 $HOME/grass$1/grass-$2-$3.tar.bz2
+    fi
 }
 
 export PATH=$PATH:/c/OSGeo4W/apps/msys/bin
 
-rsync_package 64
-rsync_package 65
-rsync_package 70
+if test -z $1 ; then
+    # dev packages
+    rsync_package 64
+    rsync_package 65
+    rsync_package 70
+else
+    rsync_package $1 $2 $3
+fi
 
 exit 0

Modified: grass-addons/tools/wingrass-packager/grass_packager.bat
===================================================================
--- grass-addons/tools/wingrass-packager/grass_packager.bat	2012-02-17 21:06:04 UTC (rev 50849)
+++ grass-addons/tools/wingrass-packager/grass_packager.bat	2012-02-17 21:11:01 UTC (rev 50850)
@@ -27,10 +27,6 @@
 call .\GRASS-Packager.bat
 cd ..
 
-copy .\msys.bat .\grass64\GRASS-64-Package\msys\
-copy .\msys.bat .\grass65\GRASS-65-Package\msys\
-copy .\msys.bat .\grass70\GRASS-70-Package\msys\
-
 C:\OSGeo4W\apps\msys\bin\sh.exe .\grass_osgeo4w.sh
 C:\OSGeo4W\apps\msys\bin\sh.exe .\grass_svn_info.sh
 

Added: grass-addons/tools/wingrass-packager/grass_packager_release.bat
===================================================================
--- grass-addons/tools/wingrass-packager/grass_packager_release.bat	                        (rev 0)
+++ grass-addons/tools/wingrass-packager/grass_packager_release.bat	2012-02-17 21:11:01 UTC (rev 50850)
@@ -0,0 +1,34 @@
+ at echo off
+
+cd C:\Users\landa\grass_packager
+
+set MAJOR=6
+set MINOR=4
+set PATCH=2
+set REV=1
+
+rem Compile GRASS versions
+rmdir /s /q C:\OSGeo4W\apps\grass\grass-%MAJOR%.%MINOR%.%PATCH%
+rem native & osgeo4w
+C:\OSGeo4W\apps\msys\bin\bash.exe C:\Users\landa\grass_packager\grass_compile.sh %MAJOR%%MINOR%%PATCH%
+
+rem Preparation
+if exist .\grass%MAJOR%%MINOR%%PATCH% rmdir /S/Q .\grass%MAJOR%%MINOR%%PATCH%
+xcopy C:\OSGeo4W\usr\src\grass%MAJOR%%MINOR%%PATCH%\mswindows\* .\grass%MAJOR%%MINOR%%PATCH% /S/V/F/I
+
+cd .\grass%MAJOR%%MINOR%%PATCH%
+call .\GRASS-Packager.bat
+cd ..
+
+C:\OSGeo4W\apps\msys\bin\sh.exe .\grass_osgeo4w.sh %MAJOR%%MINOR%%PATCH% %MAJOR%.%MINOR%.%PATCH% %REV%
+C:\OSGeo4W\apps\msys\bin\sh.exe .\grass_svn_info.sh %MAJOR%%MINOR%%PATCH%
+
+C:\DevTools\makensis.exe .\grass%MAJOR%%MINOR%%PATCH%\GRASS-Installer.nsi
+
+C:\OSGeo4W\apps\msys\bin\sh.exe .\grass_md5sum.sh %MAJOR%%MINOR%%PATCH%
+
+C:\OSGeo4W\apps\msys\bin\sh.exe .\grass_addons.sh %MAJOR%%MINOR%%PATCH%
+
+pscp.exe -r -i .\ssh\id_dsa.ppk .\grass%MAJOR%%MINOR%%PATCH%\addons\*.zip    landa at geo102:/work/wingrass/grass%MAJOR%%MINOR%/addons%MAJOR%%MINOR%%PATCH%
+pscp.exe -r -i .\ssh\id_dsa.ppk .\grass%MAJOR%%MINOR%%PATCH%\addons\*.md5sum landa at geo102:/work/wingrass/grass%MAJOR%%MINOR%/addons%MAJOR%%MINOR%%PATCH%
+pscp.exe -r -i .\ssh\id_dsa.ppk .\grass%MAJOR%%MINOR%%PATCH%\addons\logs     landa at geo102:/work/wingrass/grass%MAJOR%%MINOR%/addons%MAJOR%%MINOR%%PATCH%

Modified: grass-addons/tools/wingrass-packager/grass_svn_info.sh
===================================================================
--- grass-addons/tools/wingrass-packager/grass_svn_info.sh	2012-02-17 21:06:04 UTC (rev 50849)
+++ grass-addons/tools/wingrass-packager/grass_svn_info.sh	2012-02-17 21:11:01 UTC (rev 50850)
@@ -9,7 +9,10 @@
     cd $SRC/$1
     REV=`svn info | grep 'Last Changed Rev:' | cut -d':' -f2 | tr -d ' '`
     NUM=`ls -t $PACKAGEDIR/ 2>/dev/null | head -n1 | cut -d'-' -f5 | cut -d'.' -f1`
-
+    if [ "x$NUM" = "x" ]; then
+	NUM=1
+    fi
+    
     exec 3<include/VERSION 
     read MAJOR <&3 
     read MINOR <&3 
@@ -41,8 +44,13 @@
 
 export PATH=$PATH:/c/OSGeo4W/apps/msys/bin
 
-update grass64_release grass64
-update grass6_devel grass65
-update grass_trunk grass70
+if test -z $1 ; then
+    # dev packages
+    update grass64_release grass64
+    update grass6_devel grass65
+    update grass_trunk grass70
+else
+    update grass$1 grass$1
+fi
 
 exit 0



More information about the grass-commit mailing list