[Xapian-devel] 回复: 回复: A beginnerin "Posting list encoding improvements"
Olly Betts
olly at survex.com
Sat Feb 15 09:22:51 GMT 2014
On Thu, Feb 13, 2014 at 02:02:17PM +0800, Hurricane Tong wrote:
> It's amazing,
> "g++ `xapian-config --cxxflags` demo2.cpp `xapian-config --libs` " work in ubuntu.
[...]
> My Ubuntu is 12.04, 32bit.
I don't have 12.04 to hand, but I can reproduce this behaviour on 12.10.
However Ubuntu 10.04 behaves like Debian unstable (the position of
--libs doesn't matter).
I'm not sure why the behaviour is different between versions, but if you
link against multiple libraries, you usually need to list them such that
each library is before any other libraries which it uses symbols from,
so it's perhaps not totally surprising to need to list the libraries
after the objects (or in this case sources) which use them.
Cheers,
Olly
More information about the Xapian-devel
mailing list