Try this:
g++ -o bin -L. -Wl,-rpath=. -l:libtest.1.0.1
Normally, on Linux at least, with -lnamespace
, ld
will try to find a file named libnamespace.so
or libnamespace.a
to link in its library search path list, but with -l:namespace
, ld
will search for a file named namespace
in its library search path list.