I'm trying to install GDAL so that I can try out the raster functions of PostGIS2.0. I'm having difficulty installing GDAL such that python can import it (which I assume is necessary for PostGIS2.0). I have downloaded GDAL 1.8.1 and used the following command to build it:
This produces the following summary: GDAL is now configured for i686-pc-linux-gnu
Then I run
I have also tried to install gdal for python using easy_install ( asked 07 Oct '11, 06:14 womble |
SInce you have installed GDAL locally, you need to specify the path:
Then test from your django project:
If HAS_GDAL is True then it is installed correctly. Here is more on troubleshooting GDAL. answered 07 Oct '11, 08:29 timg ♦♦ Thanks for the suggestion @timg .However I'm not using django, I just want to install GDAL with python for PostGIS/Postgresql. The line 'GDAL_LIBRARY_PATH = '/home/user23/lib/python2.7/libgdal.so'' did not work in my case.
(07 Oct '11, 12:25)
womble
|
Please try setting LD_LIBRARY_PATH in your environment when invoking Python, eg:
This will let the Python interpreter know where your custom libraries are. answered 07 Oct '11, 12:39 seanf is this done during the install process of GDAL or set thereafter?
(01 Apr '12, 20:21)
netcon
1
You'd actually want to have the When I install software, I set the following five environment variables right at the beginning before installation of anything:
Then, I make sure that the
Usually by setting this value at the bottom of my
(01 Apr '12, 20:29)
ryans ♦♦
|