[Qgis-developer] Shipping SAGA with QGIS

Victor Olaya volayaf at gmail.com
Sun Feb 24 15:52:09 PST 2013


Thanks everyone for your help.

As far as I see, the following sounds like a good solution.

- In Linux, let users install SAGA independently and assume the SAGA
folder is in PATH (That is, leave it like now)
- In Windows, the user should configure the SAGA folder, but SEXTANTE
will try to infere it by looking at the registry (or, if we ship SAGA
with QGIS, by pointing it to the folder where is can be found)
- In Mac, since there seems to be problems, I would let the user
select the folder itself, and not infere anything from the system or
assume any path. It seems that SAGA is not easy to install in Mac, so
if someone can do it, probably he can configure SEXTANTE correctly.

Anyway, since I know absolutely zero about Mac OS and do not have a
Mac to test, I would need someone to run some simple analysis in SAGA
using saga_cmd and send it to me, so I can see exactly how to do it.
That includes setting any environment variables (as it is done now for
the Windows version), or any other thing that might be needed, so I
can set it to run on Mac (or at least, try to...)

I have included a test before a SAGA algorithm is run, which actually
calls SAGA and computes voronoi polygons for a tiny layer, so it takes
almost no time, but if it passes that test, it means SAGA can work
from SEXTANTE. This way, it is now impossible to get a "Layer not
found" error due to SAGA not being installed and configured, since the
algorithm will not even launch. The test is not run everytime an
algorithm is run. Once it passes, SEXTANTE will not test for that
anymore and assume it is correctly configured from that moment.

I will add similar checks for the other algorithm providers

Thanks again for you help!

2013/2/24 Phil Hess <macpgmr at fastermac.net>:
>>>Unfortunately, Qt does put some tools in /usr/bin, oh well
>
> As do Java and Mono, but I agree: /usr/local/bin should be good enough.
>
> Perhaps SEXTANTE could just check for the existence of the saga_cmd file in
> a couple of logical places, for example, in /usr/local/bin or, if not found
> there, look in (per GDAL convention, etc.):
>
> /Library/Frameworks/SAGA.framework/programs
>
> With Windows, a peek at the registry would give the install location for
> systems where the InnoSetup installer was run to install SAGA. This would
> avoid the need for the user to configure the SAGA folder in SEXTANTE. For
> example, with 2.0.8, the InstallDir value under this registry key could be
> used:
>
> SOFTWARE\SAGA User Group Association\SAGA GIS\2.0.8
>
> Thanks.
>
> -Phil
>
>
>
>
> --
> View this message in context: http://osgeo-org.1560.n6.nabble.com/Shipping-SAGA-with-QGIS-tp5036274p5036507.html
> Sent from the Quantum GIS - Developer mailing list archive at Nabble.com.
> _______________________________________________
> Qgis-developer mailing list
> Qgis-developer at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/qgis-developer


More information about the Qgis-developer mailing list