On Tuesday, 4 August 2015 at 02:45:21 UTC, Joakim Brännström wrote:
On Tuesday, 4 August 2015 at 02:26:17 UTC, Craig Dillabaugh wrote:
So how can I force my application to link to my local copy of GDAL2 at /home/craig2/code/gdal-2.0.0/lib64. Any help is appreciated.

Hi,

I recently ran into similare problems, different lib.
Try changing:
"lflags" : ["-L/home/craig2/code/gdal-2.0.0/lib64/libgdal.so.20.0.0" ]
"libs" : ["gdal"]
to:
"lflags" : ["-L/home/craig2/code/gdal-2.0.0/lib64/" ]
"libs" : [":libgdal.so.20.0.0"]

observe the flags dub passes on to dmd by using --vverbose

//Joakim

Thanks. Everything compile perfectly, and now the correct libs are linked it seems, but I still have an issue with the executable:

ldd gdaltest
        linux-vdso.so.1 (0x00007ffe63381000)
        libgdal.so.20 => not found

I can now run it with:

LD_LIBRARY_PATH=/home/craig2/code/gdal-2.0.0/lib64 ./gdaltest

But it appears the LD_LIBRARY_PATH hack is causing havoc with other libraries, as I get errors loading other shared libraries when I do that.




Reply via email to