[Qgis-user] Mac OS X: QGIS 1.0 Preview 2 Crashes

Martin Dobias wonder.sk at gmail.com
Fri Nov 14 15:03:34 PST 2008


On Fri, Nov 14, 2008 at 11:11 PM, William Kyngesburye
<woklist at kyngchaos.com> wrote:
> On Nov 14, 2008, at 3:58 PM, Martin Dobias wrote:
>
>> libqgispython is meant to be loaded dynamically by QGIS application on
>> startup. All python-related implementation is in this library, the
>> rest of application is "python-free", i.e. it doesn't use any
>> functions directly from python libs.
>>
>> libqgispython is not meant to be used by anything else than QGIS
>> application itself.
>
>
> So now the question is (and something I've wondered about) - just how does
> this python support work?  Does it execute the python program (as found in
> the user's PATH)?  Does it depend on linking to the python library to find
> some python start/init symbol?

We're using only direct API function calls to python C library, python
executable is _not_ being run.

To get libqgispython working properly, it's loaded from QGIS
application with following Qt's load hints:
- ResolveAllSymbolsHint
- ExportExternalSymbolsHint
See [1] for their documentation. If they're not used, python library
doesn't work correctly. There has been also some discussion on
pykde-list [2].

Martin

[1] http://doc.trolltech.com/4.3/qlibrary.html#LoadHint-enum
[2] http://lists.kde.org/?l=pykde&m=117190116820758&w=2



More information about the Qgis-user mailing list