[Qgis-developer] 0.9 Python modules on windows
Aaron Racicot
aaronr at z-pulley.com
Mon Jul 30 13:55:16 EDT 2007
Hi there Jesse,
So, I am not a cmake guru but if I remember:
1) There is a variable in the ccmake setup that you can set called
"BINDINGS_GLOBAL_INSTALL" which puts the core.pyd and gui.pyd files in your
python site-packages directories... this is what I do so that there is not a
need to find the libraries with PYTHONPATH. On my machine the site-packages
area with the correct files is at: C:\Python25\Lib\site-packages\qgis. Also
just make sure the the WITH_BINDINGS:BOOL=ON is set in cmake as well... just
to build the bindings at all!
2) The path PYTHONPATH needs to be able to find the core.pyd and gui.pyd
files and in my build install they are not there... so I can locate them in
the build area (not install area) at C:\dev\cpp\qgis\build\python. I have
not tried to use them from their directly (as I have them installed in
site-packages), but that is a place to start.
Hope that helps!
A
+----------------------------------------+
Aaron Racicot - GIS Programmer
360.221.2441 - aaronr at ecotrust.org
+----------------------------------------+
e c o t r u s t
pobox 1614
langley wa 98260
www.ecotrust.org
+----------------------------------------+
-----Original Message-----
From: qgis-developer-bounces at lists.qgis.org
[mailto:qgis-developer-bounces at lists.qgis.org] On Behalf Of Jesse Ayers
Sent: Monday, July 30, 2007 10:25 AM
To: 'Luca Mandolesi'; qgis-developer at lists.qgis.org
Subject: Re: [Qgis-developer] 0.9 Python modules on windows
No, I am not actually writing a script yet, just trying things out
interactively. The problem is that Python cannot find qgis.core and
qgis.gui at all.
My QGIS installation is at d:\qgis0.9preview1
I have tried these 3 paths:
d:\qgis0.9preview1
d:\qgis0.9preview1\python
d:\qgis0.9preview1\python\qgis
In both the PATH and PYTHONPATH environment variables. Is one of these
paths or locations correct?
Thanks in advance
--Jesse
>-----Original Message-----
>From: Luca Mandolesi [mailto:mandoluca at gmail.com]
>Sent: Monday, July 30, 2007 9:49 AM
>To: Jesse Ayers
>Subject: Re: [Qgis-developer] 0.9 Python modules on windows
>
>> I get an import error, the specified module cannot be found.
>
>Had you try to add to your script:
>
>import sys
>sys.path.append("your/qgis/path")
>
_______________________________________________
Qgis-developer mailing list
Qgis-developer at lists.qgis.org
http://lists.qgis.org/cgi-bin/mailman/listinfo/qgis-developer
More information about the Qgis-developer
mailing list