g++ not finding libstdc++.so on Solaris
Peter Kurpis
pkurpis@keck.hawaii.edu
Mon Apr 2 12:08:00 GMT 2001
When I do a vanilla build of gcc 2.95.2 on Solaris 7 (with or
without --with-gnu-as and --with-gun-ld), everything apparently
works fine except...
...when I build with g++, the resulting executable can't find
libstdc++.so.2.10.0 because the path (being /usr/local/lib) is
not hardwired into the resulting executable.
I can work around this by setting LD_LIBRARY_PATH=/usr/local/lib
(which is an undesirable kludge) or by setting
CXXFLAGS += -Wl,-rpath /usr/local/lib in my master Makefile, but
is there a more graceful way to set it up right?
More information about the Gcc-help
mailing list