[Gdal-dev] linking problems with MrSID library

Bill Binko bill at binko.net
Tue Oct 4 00:14:41 EDT 2005


> Bill,
> 
> Yeah, it was your messages I saw about this a while back.  I wasn't  
> quite sure what to do, and didn't have time to pursue it much.
> 
> What did you do to the GDAL makefiles to get it to work for you?  Did  
> you get Frank's -XCClinker trick to work?
> 
> I just tried this: add the static libstdc++ from GCC 3.3 (that's all  
> Apple gave us for GCC 3.3, tho they gave us a dynamic version for GCC  
> 4) to LIBS in GDALmake.opt.  Now I get tons of multiple defs between  
> the 2 libstdc++ versions.
> 
> I'm, not sure what order the 2 versions are getting linked - I  
> believe GCC 4 takes care of automatically linking libstdc++ as  
> needed, so it's not in the link command that comes out of libtool.
> 
Try this:

Go back to your default build: the one that ended up with only linker 
errors.  Go ahead and build: you'll fail at link time on the applications.

Just for grins, manually run the first failed link command line adding the 
libraries into the command.  For example, if it were:

gcc .... -o gdal_warp ... -lstd++ -lm -l...etc.

change it to

gcc .... -o gdal_warp ... /usr/local/lib/libstdc++.so.4 
/usr/local/lib/libstdc++.so.5 -lm -l...etc.

And report back how it goes.  That's how I started.  If you want to take 
this offline, you can send this to me: perhaps I can help.

Bill



More information about the Gdal-dev mailing list