Skip to content

Commit

Permalink
Python detection added
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@7131 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
what_nick committed Aug 10, 2007
1 parent a778e1d commit 2a21091
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
6 changes: 4 additions & 2 deletions win_build/python.nsh
Expand Up @@ -7,10 +7,12 @@
# Read handler for python files from registry
ReadRegStr $9 HKEY_LOCAL_MACHINE "SOFTWARE\Python\PythonCore\2.5\InstallPath" ""

IfFileExists $9 ok ng
# The point pythonskip needs to be defined
IfFileExists $9\python.exe ok ng

ng:
MessageBox MB_OK "Python is not installed on this system.$\nPlease install Python2.5 first."
Quit
goto pythonskip
ok:
MessageBox MB_OK "Python located $9"

Expand Down
11 changes: 6 additions & 5 deletions win_build/qgis.nsi
Expand Up @@ -149,14 +149,15 @@ Section "Quantum GIS Application" SEC01
SectionEnd

Section "Development headers" SEC02
!insertmacro CHECK_PYTHON
SetOutPath "$INSTDIR\python"
File /r "C:\Program Files\qgis${PRODUCT_VERSION_NUMBER}\python"
SetOutPath "$INSTDIR\include"
File "C:\Program Files\qgis${PRODUCT_VERSION_NUMBER}\include\*.h"
SectionEnd

Section "Python Extension" SEC03
SetOutPath "$INSTDIR\python"
File "C:\Program Files\qgis${PRODUCT_VERSION_NUMBER}\include\*.h"
!insertmacro CHECK_PYTHON
SetOutPath "$INSTDIR"
File /r "C:\Program Files\qgis${PRODUCT_VERSION_NUMBER}\python"
pythonskip:
SectionEnd

; /o means unchecked by default
Expand Down

0 comments on commit 2a21091

Please sign in to comment.