freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
- From: "James K. Lowden" <jklowden AT freetds.org>
- To: TDS Development Group <freetds AT lists.ibiblio.org>
- Subject: [freetds] linking
- Date: Wed, 2 Jan 2008 18:29:30 -0500
The db-lib unit tests link to the install directories, not to the build
tree.
$ ldd t0001
t0001:
-lpthread.0 => /usr/lib/libpthread.so.0
-lsybdb.5 => /usr/local/lib/libsybdb.so.5
-lc.12 => /usr/lib/libc.so.12
$ readelf -d t0001 | grep RPATH
0x0000000f (RPATH) Library rpath:
[/usr/local/lib:/usr/pkg/lib:/usr/users/home/jklowden/freetds/build/src/d
blib/.libs]
(/usr/local/lib:/usr/pkg/lib comes from my LDFLAGS, I believe.)
That means you have to run "make install" before "make check". (Well, you
don't *have* to. But if you run "make check" first, you're running the
unit test against the installed library!) Not very nice if the user is
trying to test a new version before installing it.
I haven't figured out quite how, but ISTM the unit tests should link
statically to their libraries, so we don't have to fool with RPATH and
dynamic linker settings just for them.
What to do about apps, I don't know. I don't think they should be
statically linked (except tsql). At the same time, I think it would be
better if the user could test them before installing them.
$ readelf -d .libs/bsqldb | grep RPATH
0x0000000f (RPATH) Library rpath:
[/usr/local/lib:/usr/pkg/lib]
Suggestions, anyone?
--jkl
-
[freetds] linking,
James K. Lowden, 01/02/2008
-
Re: [freetds] linking,
Frediano Ziglio, 01/04/2008
- Re: [freetds] linking, James K. Lowden, 01/04/2008
-
Re: [freetds] linking,
Frediano Ziglio, 01/04/2008
Archive powered by MHonArc 2.6.24.