Skip to content

Commit 8d2717c

Browse files
author
timlinux
committed
Updates to installer to facililate downloading sample data. Gave teh install tasks better names and descriptions. Note unzipping the downloaded sample data is not working yet due to problems I am having with the zipdll nsis plugin.
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@6335 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 2b93758 commit 8d2717c

File tree

1 file changed

+22
-7
lines changed

1 file changed

+22
-7
lines changed

win_build/qgis.nsi

Lines changed: 22 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,15 @@
1111
!define PRODUCT_STARTMENU_REGVAL "NSIS:StartMenuDir"
1212

1313
SetCompressor zlib
14+
15+
; MUI 1.67 compatible ------
16+
!include "MUI.nsh"
1417
; Added by Tim for setting env vars (see this file on disk)
1518
!include WriteEnvStr.nsh
1619
;Added by Tim for a macro that will recursively delete the files in the install dir
1720
!include RecursiveDelete.nsh
18-
19-
; MUI 1.67 compatible ------
20-
!include "MUI.nsh"
21+
;Added by Tim to support unzipping downloaded sample data automatically
22+
!include ZipDLL.nsh
2123

2224
; MUI Settings
2325
!define MUI_ABORTWARNING
@@ -85,7 +87,7 @@ InstallDirRegKey HKLM "${PRODUCT_DIR_REGKEY}" ""
8587
ShowInstDetails show
8688
ShowUnInstDetails show
8789

88-
Section "MainSection" SEC01
90+
Section "Quantum GIS Application" SEC01
8991
;Set the reg key so we get default toolbar layout
9092
!include qgis_window_geometry.nsh
9193
SetOutPath "$INSTDIR"
@@ -126,10 +128,22 @@ Section "MainSection" SEC01
126128

127129
SectionEnd
128130

129-
Section "Sample Data" SEC02
130-
; SetOutPath "$INSTDIR\SampleData\EnvironmentLayers\2050\A1F"
131+
Section "Sample Data - Spearfish (GRASS)" SEC02
132+
SetOutPath "$INSTDIR\SampleData\"
133+
NSISdl::download http://grass.itc.it/sampledata/spearfish_grass60data-0.3.zip spearfish.zip
134+
!insertmacro ZIPDLL_EXTRACT "$INSTDIR\SampleData\spearfish.zip" "$INSTDIR\SampleData\" "<ALL>"
135+
;ZipDLL::extractall "$INSTDIR\SampleData\spearfish.zip" "$INSTDIR\SampleData\"
136+
;the next line is a hack / workaround for a problem in zipdll.nsh
137+
!endif
138+
139+
140+
SectionEnd
141+
Section "Sample Data - Alaska (Non GRASS)" SEC03
142+
SetOutPath "$INSTDIR\SampleData\Alaska\"
143+
NSISdl::download http://qgis.org/uploadfiles/qgis_sample_data.tar.gz alaska.tar.gz
131144
; File "C:\dev/cpp/qgis/\qgis-release\SampleData\EnvironmentLayers\2050\A1F\Annual_dev/cpp/qgis/erature_range.asc"
132145

146+
133147
; Shortcuts
134148
!insertmacro MUI_STARTMENU_WRITE_BEGIN Application
135149
!insertmacro MUI_STARTMENU_WRITE_END
@@ -158,7 +172,8 @@ SectionEnd
158172
; Section descriptions
159173
!insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
160174
!insertmacro MUI_DESCRIPTION_TEXT ${SEC01} "Main application files - you really need this!"
161-
!insertmacro MUI_DESCRIPTION_TEXT ${SEC02} "Sample data (not required if you have your own data already)"
175+
!insertmacro MUI_DESCRIPTION_TEXT ${SEC02} "20mb Download of sample data in GRASS format (not required if you have your own data already)"
176+
!insertmacro MUI_DESCRIPTION_TEXT ${SEC03} "20mb Download of sample shapefiles and TIFF data for Alaska (not required if you have your own data already)"
162177
!insertmacro MUI_FUNCTION_DESCRIPTION_END
163178

164179

0 commit comments

Comments
 (0)