Skip to content

Commit b88a693

Browse files
author
jef
committedNov 19, 2010
update osgeo4w version nsis installer
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@14717 c8812cc2-4d05-0410-92ff-de0c093fc19c

File tree

2 files changed

+50
-23
lines changed

2 files changed

+50
-23
lines changed
 

‎ms-windows/QGIS-Installer.nsi

Lines changed: 35 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ RequestExecutionLevel admin
3838

3939
;NSIS Includes
4040

41-
!include "MUI2.nsh"
41+
!include "MUI.nsh"
4242
!include "LogicLib.nsh"
4343

4444
;----------------------------------------------------------------------------------------------------------------------------
@@ -89,6 +89,7 @@ RequestExecutionLevel admin
8989
!define INSTALLER_DISPLAYED_NAME "${DISPLAYED_NAME}"
9090

9191
!addplugindir osgeo4w/untgz
92+
!addplugindir osgeo4w/nsis
9293
!endif
9394

9495
;----------------------------------------------------------------------------------------------------------------------------
@@ -282,6 +283,7 @@ FunctionEnd
282283

283284
;Installer Pages
284285

286+
!define MUI_WELCOMEPAGE_TITLE_3LINES
285287
!insertmacro MUI_PAGE_WELCOME
286288
!insertmacro MUI_PAGE_LICENSE ".\Installer-Files\LICENSE.txt"
287289

@@ -290,6 +292,7 @@ FunctionEnd
290292

291293
!insertmacro MUI_PAGE_COMPONENTS
292294
!insertmacro MUI_PAGE_INSTFILES
295+
!define MUI_FINISHPAGE_TITLE_3LINES
293296
!insertmacro MUI_PAGE_FINISH
294297

295298
!insertmacro MUI_UNPAGE_WELCOME
@@ -301,6 +304,19 @@ FunctionEnd
301304

302305
; Language files
303306
!insertmacro MUI_LANGUAGE "English"
307+
!insertmacro MUI_LANGUAGE "German"
308+
!insertmacro MUI_LANGUAGE "French"
309+
!insertmacro MUI_LANGUAGE "Russian"
310+
!insertmacro MUI_LANGUAGE "Japanese"
311+
!insertmacro MUI_LANGUAGE "Italian"
312+
!insertmacro MUI_LANGUAGE "Polish"
313+
!insertmacro MUI_LANGUAGE "Spanish"
314+
!insertmacro MUI_LANGUAGE "PortugueseBR"
315+
!insertmacro MUI_LANGUAGE "Portuguese"
316+
!insertmacro MUI_LANGUAGE "Czech"
317+
!insertmacro MUI_LANGUAGE "Croatian"
318+
!insertmacro MUI_LANGUAGE "Thai"
319+
!insertmacro MUI_LANGUAGE "Dutch"
304320

305321
;----------------------------------------------------------------------------------------------------------------------------
306322

@@ -397,34 +413,34 @@ Section "Quantum GIS" SecQGIS
397413

398414
;Create the Desktop Shortcut
399415
SetShellVarContext current
400-
401-
!if ${INSTALLER_TYPE} == "OSGeo4W"
402-
CreateShortCut "$DESKTOP\${QGIS_BASE}.lnk" "$INSTALL_DIR\bin\nircmd.exe" 'exec hide "$INSTALL_DIR\bin\qgis-dev.bat"' \
403-
"$INSTALL_DIR\icons\QGIS.ico" "" SW_SHOWNORMAL "" "Launch ${COMPLETE_NAME}"
404-
!else
405-
CreateShortCut "$DESKTOP\${QGIS_BASE}.lnk" "$INSTALL_DIR\bin\qgis.exe" ""\
406-
"$INSTALL_DIR\icons\QGIS.ico" "" SW_SHOWNORMAL "" "Launch ${COMPLETE_NAME}"
407-
!endif
408416

409417
;Create the Windows Start Menu Shortcuts
410418
SetShellVarContext all
411419

412420
CreateDirectory "$SMPROGRAMS\${QGIS_BASE}"
413421

414-
!if ${INSTALLER_TYPE} == "OSGeo4W"
415-
CreateShortCut "$SMPROGRAMS\${QGIS_BASE}\${QGIS_BASE}.lnk" "$INSTALL_DIR\bin\nircmd.exe" 'exec hide "$INSTALL_DIR\bin\qgis-dev.bat"' \
416-
"$INSTALL_DIR\icons\QGIS.ico" "" SW_SHOWNORMAL "" "Launch ${COMPLETE_NAME}"
417-
!else
418-
CreateShortCut "$SMPROGRAMS\${QGIS_BASE}\${QGIS_BASE}.lnk" "$INSTALL_DIR\bin\qgis.exe" ""\
419-
"$INSTALL_DIR\icons\QGIS.ico" "" SW_SHOWNORMAL "" "Launch ${COMPLETE_NAME}"
420-
!endif
421-
422422
GetFullPathName /SHORT $0 $INSTALL_DIR
423423
System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("OSGEO4W_ROOT", "$0").r0'
424424
System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("OSGEO4W_STARTMENU", "$SMPROGRAMS\${QGIS_BASE}").r0'
425425

426426
ReadEnvStr $0 COMSPEC
427427
nsExec::ExecToLog '"$0" /c "$INSTALL_DIR\postinstall.bat"'
428+
429+
!if ${INSTALLER_TYPE} == "OSGeo4W"
430+
Delete "$DESKTOP\Quantum GIS (${VERSION_NUMBER}).lnk"
431+
CreateShortCut "$DESKTOP\Quantum GIS (${VERSION_NUMBER}).lnk" "$INSTALL_DIR\bin\nircmd.exe" 'exec hide "$INSTALL_DIR\bin\qgis.bat"' \
432+
"$INSTALL_DIR\icons\QGIS.ico" "" SW_SHOWNORMAL "" "Launch ${COMPLETE_NAME}"
433+
434+
Delete "$SMPROGRAMS\${QGIS_BASE}\Quantum GIS (${VERSION_NUMBER}).lnk"
435+
CreateShortCut "$SMPROGRAMS\${QGIS_BASE}\Quantum GIS (${VERSION_NUMBER}).lnk" "$INSTALL_DIR\bin\nircmd.exe" 'exec hide "$INSTALL_DIR\bin\qgis.bat"' \
436+
"$INSTALL_DIR\icons\QGIS.ico" "" SW_SHOWNORMAL "" "Launch ${COMPLETE_NAME}"
437+
!else
438+
CreateShortCut "$DESKTOP\${QGIS_BASE}.lnk" "$INSTALL_DIR\bin\qgis.exe" ""\
439+
"$INSTALL_DIR\icons\QGIS.ico" "" SW_SHOWNORMAL "" "Launch ${COMPLETE_NAME}"
440+
CreateShortCut "$SMPROGRAMS\${QGIS_BASE}\${QGIS_BASE}.lnk" "$INSTALL_DIR\bin\qgis.exe" ""\
441+
"$INSTALL_DIR\icons\QGIS.ico" "" SW_SHOWNORMAL "" "Launch ${COMPLETE_NAME}"
442+
!endif
443+
428444
SectionEnd
429445

430446
Function DownloadDataSet
@@ -554,6 +570,7 @@ Section "Uninstall"
554570
Delete "$INSTDIR\preremove.bat.done"
555571
Delete "$INSTDIR\preremove.bat"
556572
Delete "$INSTDIR\preremove.log"
573+
Delete "$INSTDIR\*.txt"
557574

558575
RMDir /r "$INSTDIR\bin"
559576
RMDir /r "$INSTDIR\apps"
@@ -562,6 +579,7 @@ Section "Uninstall"
562579
RMDir /r "$INSTDIR\lib"
563580
RMDir /r "$INSTDIR\share"
564581
RMDir /r "$INSTDIR\icons"
582+
565583
!else
566584
;remove files
567585
Delete "$INSTDIR\Uninstall-QGIS.exe"

‎ms-windows/osgeo4w/creatensis.pl

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@
1313
# Download OSGeo4W packages
1414
#
1515

16+
unless(-f "nsis/System.dll") {
17+
mkdir "nsis", 0755 unless -d "nsis";
18+
system "wget -q -Onsis/System.dll http://qgis.org/downloads/System.dll";
19+
}
20+
1621
mkdir "packages", 0755 unless -d "packages";
1722
chdir "packages";
1823

@@ -52,16 +57,16 @@ sub getDeps {
5257
}
5358
}
5459

55-
getDeps("qgis-dev");
60+
getDeps("qgis");
5661

57-
if(-f "../addons/bin/NCSEcw.dll") {
62+
if(-f "../addons/bin/NCSEcw4_RO.dll") {
5863
print "Enabling ECW support...\n";
59-
getDeps("gdal16-ecw")
64+
getDeps("gdal17-ecw")
6065
}
6166

6267
if(-f "../addons/bin/lti_dsdk_dll.dll") {
6368
print "Enabling MrSID support...\n";
64-
getDeps("gdal16-mrsid")
69+
getDeps("gdal17-mrsid")
6570
}
6671

6772

@@ -104,7 +109,7 @@ sub getDeps {
104109

105110
system "cd apps/nircmd; unzip ../../../packages/nircmd.zip && mv nircmd.exe ../../bin";
106111

107-
system "tar -C ../addons -cf . | tar -xf -" if -d "../addons";
112+
system "tar -C ../addons -cf - . | tar -xf -" if -d "../addons";
108113

109114
chdir "..";
110115
}
@@ -193,6 +198,10 @@ sub getDeps {
193198
$revision =~ s/\D+$//g;
194199
close F;
195200

201+
$revision = 14615 unless $revision =~ /^\d+$/;
202+
203+
system "unzip packages/Untgz.zip" unless -d "untgz";
204+
196205
chdir "..";
197206

198207
my $cmd = "makensis";
@@ -201,7 +210,7 @@ sub getDeps {
201210
$cmd .= " -DSVN_REVISION='$revision'";
202211
$cmd .= " -DQGIS_BASE='Quantum GIS $release'";
203212
$cmd .= " -DINSTALLER_NAME='QGIS-OSGeo4W-$major.$minor.$patch-$revision-Setup.exe'";
204-
$cmd .= " -DDISPLAYED_NAME='Quantum GIS OSGeo4W ($release)'";
213+
$cmd .= " -DDISPLAYED_NAME='Quantum GIS \'$release\' ($major.$minor.$patch)'";
205214
$cmd .= " -DBINARY_REVISION=1";
206215
$cmd .= " -DINSTALLER_TYPE=OSGeo4W";
207216
$cmd .= " -DPACKAGE_FOLDER=osgeo4w/unpacked";

0 commit comments

Comments
 (0)
Please sign in to comment.