I'm trying to use the Boost Libraries ... but to no avail. I attempted to follow the Getting Started tutorial on Boost's website (for Unix Variants), but having problems along the way.
I compiled the libraries into a directory in my Downloads folder:
/Users/myUsername/Downloads/boostCompiled
When I use the full path to the library ... The example program (given on the Boost Website) compiles and links fine.
g++ -o boostTesting boostTesting.cpp -I /Users/myUsername/Downloads/boostCompiled/include/ /Users/myUsername/Downloads/boostCompiled/lib/libboost_regex.a
However, when I attempt to link the using the -L and -l options ... it fails ...
g++ -o boostTesting boostTesting.cpp -I /Users/myUsername/Downloads/boostCompiled/include/ -L /Users/myUsername/Downloads/boostCompiled/lib/ -l boost_regex
ld: library not found for -lboost_regex
collect2: ld returned 1 exit status
g++ -o boostTesting boostTesting.cpp -I /Users/myUsername/Downloads/boostCompiled/include/ -L /Users/myUsername/Downloads/boostCompiled/lib/ -l libboost_regex
ld: library not found for -llibboost_regex
collect2: ld returned 1 exit status
g++ -o boostTesting boostTesting.cpp -I /Users/myUsername/Downloads/boostCompiled/include/ -L /Users/myUsername/Downloads/boostCompiled/lib/ -l regex
ld: library not found for -lregex
collect2: ld returned 1 exit status
My shell is bash ... and I've set my DYLD_LIBRARY_PATH to the following:
export DYLD_LIBRARY_PATH=/usr/local/cuda/lib:/Users/myUsername/Downloads/boostCompiled/lib
It appears I'm not using the correct name to link (with the -l) option. Can somebody please help! Thanks in advance!