Skip to content
Permalink
Browse files
osgeo4w: packaging updates
  • Loading branch information
jef-n committed Jan 27, 2013
1 parent fbb380d commit 74ace4ad21e17f95965016c78e0bc5b302e52143
Showing with 16 additions and 8 deletions.
  1. +8 −1 ms-windows/QGIS-Installer.nsi
  2. +5 −4 ms-windows/osgeo4w/creatensis.pl
  3. +1 −1 ms-windows/osgeo4w/package-nightly.cmd
  4. +2 −2 ms-windows/osgeo4w/package.cmd
@@ -345,6 +345,8 @@ Section "Quantum GIS" SecQGIS
GetFullPathName /SHORT $0 $INSTALL_DIR
System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("OSGEO4W_ROOT", "$0").r0'
System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("OSGEO4W_STARTMENU", "$SMPROGRAMS\${QGIS_BASE}").r0'
System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("OSGEO4W_MENU_LINKS", "1").r0'
System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("OSGEO4W_DESKTOP_LINKS", "1").r0'

ReadEnvStr $0 COMSPEC
nsExec::ExecToLog '"$0" /c "$INSTALL_DIR\postinstall.bat"'
@@ -355,11 +357,14 @@ RebootNecessary:
SetRebootFlag true

NoRebootNecessary:
Delete "$DESKTOP\Quantum GIS (${VERSION_NUMBER}).lnk"
Delete "$SMPROGRAMS\${QGIS_BASE}\Quantum GIS (${VERSION_NUMBER}).lnk"

Delete "$DESKTOP\Quantum GIS Desktop (${VERSION_NUMBER}).lnk"
CreateShortCut "$DESKTOP\Quantum GIS Desktop (${VERSION_NUMBER}).lnk" "$INSTALL_DIR\bin\nircmd.exe" 'exec hide "$INSTALL_DIR\bin\${SHORTNAME}.bat"' \
"$INSTALL_DIR\icons\QGIS.ico" "" SW_SHOWNORMAL "" "Launch ${COMPLETE_NAME}"

Delete "$SMPROGRAMS\${QGIS_BASE}\Quantum GIS (${VERSION_NUMBER}).lnk"
Delete "$SMPROGRAMS\${QGIS_BASE}\Quantum GIS Desktop (${VERSION_NUMBER}).lnk"
CreateShortCut "$SMPROGRAMS\${QGIS_BASE}\Quantum GIS Desktop (${VERSION_NUMBER}).lnk" "$INSTALL_DIR\bin\nircmd.exe" 'exec hide "$INSTALL_DIR\bin\${SHORTNAME}.bat"' \
"$INSTALL_DIR\icons\QGIS.ico" "" SW_SHOWNORMAL "" "Launch ${COMPLETE_NAME}"

@@ -487,6 +492,8 @@ Section "Uninstall"
GetFullPathName /SHORT $0 $INSTDIR
System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("OSGEO4W_ROOT", "$0").r0'
System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("OSGEO4W_STARTMENU", "$SMPROGRAMS\${QGIS_BASE}").r0'
System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("OSGEO4W_MENU_LINKS", "1").r0'
System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("OSGEO4W_DESKTOP_LINKS", "1").r0'

ReadEnvStr $0 COMSPEC
nsExec::ExecToLog '"$0" /c "$INSTALL_DIR\preremove.bat"'
@@ -26,16 +26,18 @@
my $shortname;
my $version;
my $binary;
my $ininame = "setup.ini";
my $help;

my $result = GetOptions(
"verbose+" => \$verbose,
"keep" => \$keep,
"releasename=s" => \$releasename,
"version=s" => \$version,
"binary=s" => \$binary,
"binary=i" => \$binary,
"packagename=s" => \$packagename,
"shortname=s" => \$shortname,
"ininame=s" => \$ininame,
"help" => \$help
);

@@ -62,7 +64,7 @@
my %file;
my $package;

system "wget $wgetopt -c $root/setup.ini";
system "wget $wgetopt -O setup.ini -c $root/$ininame";
open F, "setup.ini" || die "setup.ini not found";
while(<F>) {
chop;
@@ -246,8 +248,6 @@ sub getDeps {
} else {
$binary = 1;
}
} else {
die "given binary version not numeric" unless $package =~ /^\d+$/;
}

system "unzip packages/Untgz.zip" unless -d "untgz";
@@ -294,6 +294,7 @@ =head1 SYNOPSIS
-keep don't start with a fresh unpacked directory
-version=m.m.p package version (defaults to CMakeLists.txt setting)
-binary=b binary version of package
-ininame=filename name of the setup.ini (defaults to setup.ini)
-packagename=s name of package (defaults to 'Quantum GIS')
-shortname=s shortname used for batch file (defaults to 'qgis')
-help this help
@@ -101,6 +101,7 @@ if errorlevel 1 goto error

set LIB=%LIB%;%OSGEO4W_ROOT%\lib
set INCLUDE=%INCLUDE%;%OSGEO4W_ROOT%\include
set GRASS_PREFIX=%O4W_ROOT%/apps/grass/grass-%GRASS_VERSION%

cmake -G "Visual Studio 9 2008" ^
-D BUILDNAME="OSGeo4W-Nightly-VC9" ^
@@ -120,7 +121,6 @@ cmake -G "Visual Studio 9 2008" ^
-D PYTHON_INCLUDE_PATH=%O4W_ROOT%/apps/Python27/include ^
-D PYTHON_LIBRARY=%O4W_ROOT%/apps/Python27/libs/python27.lib ^
-D SIP_BINARY_PATH=%O4W_ROOT%/apps/Python27/sip.exe ^
-D GRASS_PREFIX=%O4W_ROOT%/apps/grass/grass-%GRASS_VERSION% ^
-D QT_BINARY_DIR=%O4W_ROOT%/bin ^
-D QT_LIBRARY_DIR=%O4W_ROOT%/lib ^
-D QT_HEADERS_DIR=%O4W_ROOT%/include/qt4 ^
@@ -27,7 +27,7 @@ set PACKAGE=%2
set PACKAGENAME=%3
if "%VERSION%"=="" goto error
if "%PACKAGE%"=="" goto error
if "%PACKAGENAME%"=="" set PACKAGENAME=qgis-dev
if "%PACKAGENAME%"=="" set PACKAGENAME=qgis

path %SYSTEMROOT%\system32;%SYSTEMROOT%;%SYSTEMROOT%\System32\Wbem;%PROGRAMFILES%\CMake 2.8\bin
set PYTHONPATH=
@@ -100,6 +100,7 @@ if errorlevel 1 goto error

set LIB=%LIB%;%OSGEO4W_ROOT%\lib
set INCLUDE=%INCLUDE%;%OSGEO4W_ROOT%\include
set GRASS_PREFIX=%O4W_ROOT%/apps/grass/grass-%GRASS_VERSION%

cmake -G "Visual Studio 9 2008" ^
-D PEDANTIC=TRUE ^
@@ -117,7 +118,6 @@ cmake -G "Visual Studio 9 2008" ^
-D PYTHON_INCLUDE_PATH=%O4W_ROOT%/apps/Python27/include ^
-D PYTHON_LIBRARY=%O4W_ROOT%/apps/Python27/libs/python27.lib ^
-D SIP_BINARY_PATH=%O4W_ROOT%/apps/Python27/sip.exe ^
-D GRASS_PREFIX=%O4W_ROOT%/apps/grass/grass-%GRASS_VERSION% ^
-D QT_BINARY_DIR=%O4W_ROOT%/bin ^
-D QT_LIBRARY_DIR=%O4W_ROOT%/lib ^
-D QT_HEADERS_DIR=%O4W_ROOT%/include/qt4 ^

0 comments on commit 74ace4a

Please sign in to comment.