I hit this same issue a while back. Bottom line is that gnu tools won't always "search back" in the library list to resolve missing symbols. Easy fixes are any of the following:
Just specify the libs and objs in the dependency order (as you have discovered above)
OR if you have a circular dependency (where libA references a function in libB, but libB reference a function in libA), then just specify the libs on the command line twice. This is what the manual page suggests as well. E.g.
gcc foo.c -lfoo -lbar -lfoo
Use the -( and -) params to specify a group of archives that have such circular dependencies. Look at the GNU linker manual for --start-group and --end-group. See here for more details.
When you use option 2 or 3, you're likely introducing a performance cost for linking. If your don't have that much to link, it may not matter.