258 | | The instructions for creating a WinGRASS native installer (for easy installation on any windows machine) are included in the GRASS source tree at {{{mswindows/README.html}}}. |
259 | | |
260 | | * GRASS 6.4 (releasebranch_6_4) [http://trac.osgeo.org/grass/browser/grass/branches/releasebranch_6_4/mswindows/README.html?format=raw here] |
261 | | * GRASS 6.5 (develbranch_6) [http://trac.osgeo.org/grass/browser/grass/branches/develbranch_6/mswindows/README.html?format=raw here] |
262 | | * GRASS 7.0 (trunk) [http://trac.osgeo.org/grass/browser/grass/trunk/mswindows/README.html?format=raw here] |
| 258 | The instructions for creating a WinGRASS native installer (as a self-contained package installer) using the scripts contained in the {{{mswindows}}} directory. In order to avoid mistakes or misunderstandings, we highly recommend to follow each step and command exactly as they are written in this document. |
| 259 | |
| 260 | === Install OSGeo4w Tree and Compile Grass === |
| 261 | |
| 262 | First of all download the OSGeo4W installer, install the required dependencies, and build GRASS from source. Do not move on to step two until you have successfully [wiki:HowToTestGrass6 tested] your new version of Grass. |
| 263 | |
| 264 | === Create a GRASS self-contained Package === |
| 265 | |
| 266 | 1. Copy all the content of the {{{mswindows}}} directory to a temporary directory, for example {{{c:\temp}}}. |
| 267 | |
| 268 | 2. Edit lines 11-15 in the file {{{c:\temp\GRASS-Packager.bat}}} to reflect the paths to your OSGeo4W tree (eg. {{{c:\OSGeo4W}}}) and the GRASS version being packaged (eg. {{{grass-6.4.0}}}). |
| 269 | |
| 270 | 3. Launch the file {{{c:\temp\GRASS-Packager.bat}}} and select version to be packaged. |
| 271 | |
| 272 | 4. When finished, you should have a GRASS self-contained release package in {{{c:\temp\GRASS-Release-Package}}}. |
| 273 | |
| 274 | === Remove OSGeo4W Traces from Package === |
| 275 | |
| 276 | 1. Open {{{c:\temp\GRASS-Release-Package\msys\msys.bat}}} and remove lines 11-16. |
| 277 | |
| 278 | At the end of line 88 (also in {{{msys.bat}}}) change: |
| 279 | |
| 280 | {{{ |
| 281 | start %WD%rxvt -backspacekey -sl 2500 -fg %FGCOLOR% -bg %BGCOLOR% -sr -fn Courier-12 -tn msys -geometry 80x25 -e /bin/sh --login -c "%*" |
| 282 | }}} |
| 283 | |
| 284 | To: |
| 285 | |
| 286 | {{{ |
| 287 | if "x%*" == "x" start "MSYS 1.0" "%WD%rxvt" -backspacekey -sl 2500 -fg %FGCOLOR% -bg %BGCOLOR% -sr -fn Courier-12 -tn msys -geometry 80x25 -e /bin/sh --login -i |
| 288 | if NOT "x%*" == "x" start "MSYS 1.0" "%WD%rxvt" -backspacekey -sl 2500 -fg %FGCOLOR% -bg %BGCOLOR% -sr -fn Courier-12 -tn msys -geometry 80x25 -e /bin/sh --login -c "%*" |
| 289 | }}} |
| 290 | |
| 291 | === Install NSIS (2.45) === |
| 292 | |
| 293 | 1. Download the [http://prdownloads.sourceforge.net/nsis/nsis-2.45-setup.exe NSIS installer] |
| 294 | |
| 295 | 2. Install to {{{c:\DevTools}}} |
| 296 | |
| 297 | === Install NSIS: Untgz Plugin (1.0.16) === |
| 298 | |
| 299 | 1. Download the [http://www.fdos.org/win32/nsis/plugins/untgz.1.0.16.zip NSIS Untgz Plugin] |
| 300 | |
| 301 | 2. Unzip to {{{c:\DevTools\Plugins\}}} |
| 302 | |
| 303 | === Create the WinGRASS Installer === |
| 304 | |
| 305 | 1. Open the the file {{{c:\temp\GRASS-Installer.nsi}}}. |
| 306 | |
| 307 | 2. At line 13 set the DEMOLOCATION_PATH varibale to the demolocation folder in the source tree. For example, {{{c:\msys\local\src\grass-6.4.0RC4\demolocation}}} |
| 308 | |
| 309 | 3. At line 18 set the INSTALLER_TYPE variable to "Release", then, at lines 24-26, set the RELEASE_VERSION_NUMBER, the RELEASE_SVN_REVISION and the RELEASE_BINARY_REVISION variables. |
| 310 | |
| 311 | 4. Finally, right click on the file {{{c:\temp\GRASS-Installer.nsi}}} and select Compile NSIS Script. |
| 312 | |
| 313 | 5. When finished, you should have the WinGRASS release installer in {{{c:\temp}}}. |