Opened 14 years ago

Last modified 13 years ago

#3170 new bug

many GDAL Tools don't work in OS X standalone

Reported by: kyngchaos Owned by: brushtyler
Priority: major: does not work as expected Milestone: Version 1.7.0
Component: GDALTools Version: 1.5.0
Keywords: gdal python Cc:
Must Fix for Release: No Platform: OS X
Platform Version: Awaiting user input: no

Description

On OS X standalone Qgis, the GDAL python extension is in the Qgis python folder in the application, but this is not passed on to any of the GDAL python tools when run (they don't use the qgis builtin python interpreter).

Either GdalTools needs to automatically do this (or Qgis needs to do this), or the disable "GDAL pymod path" option in the GdalTools settings dialog needs to be enabled and programmed so the user can set the path.

Or Qgis needs to provide a general environment settings for common variables - see #3097.

Change History (5)

comment:1 by borysiasty, 13 years ago

Isn't there any way to set a fixed path on the build level?

comment:2 by pcav, 13 years ago

Component: Python plugins and bindingsGDALTools
Owner: changed from borysiasty to brushtyler

comment:3 by kyngchaos, 13 years ago

Must Fix for Release: YesNo

Not a blocker for general release, just for standalone.

As mentioned, there is a GdalTools setting to set the pymod path, but it is disabled (it doesn't look like the feature is programmed yet). This is really all that is needed for those cases where GDAL is not where expected, like bundled in a standalone package. No need to hardwire the path at compile time.

comment:4 by brushtyler, 13 years ago

python path setting is disabled because not implemented yet. I think would be better to hide it. However, you can use GDAL binaries setting instead of python path setting. Maybe are there some issues using it?

comment:5 by kyngchaos, 13 years ago

I didn't know the GDAL executable path is also used for the Python module path. Doesn't make sense, they're different things.

Another possibility - add the QGIS python path to the environment PYTHONPATH before running external python scripts. Even better would be to add the QGIS bin folder the the environment PATH before running external programs. This takes care of the standalone case, AND the user doesn't need to fuss with configuring the GDAL path (the standalone should be zero-config so the user can start using QGIS immediately).

Note: See TracTickets for help on using tickets.