I've known that I should use -l option for liking objects using GCC. that is gcc -o test test.c -L./ -lmy
But I found that "gcc -o test2 test.c libmy.so" is working, too.
When I use readelf for those two executable I can't find any difference. Then why people use -l option for linking objects? Does it have any advantage?