So far, the only linker flags I've used have been as per some instructions...now, however, I'm trying to use libmpg123 (for which there are no online examples beyond their own API), and when I kept getting "undefined references" to functions that are exported by the included header (mpg123.h) I thought, why not try one of those -l thingies. So -lmpg123 got my test script past the compiler, but then when I run it:
./a.out: error while loading shared libraries: libmpg123.so.0: cannot open shared object file: No such file or directory
libmpg123.so.... is there, tho, so there must be some more different flags I need.
[edit: should have tried ldconfig!]
Given that I have the header and know where to find the libraries that I built from source, how can I determine (-lmpg123 was an easy guess) what flags I need to get everything to run?
Maybe there is some reading related to this somewhere?