Skip to Content.
Sympa Menu

freetds - Re: [freetds] linker and Darwin (Mac OS X)

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "James K. Lowden" <jklowden AT schemamania.org>
  • To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] linker and Darwin (Mac OS X)
  • Date: Sun, 13 Jun 2004 14:28:47 -0400

On Sun, 13 Jun 2004 17:32:53 +0200, Frediano Ziglio <freddyz77 AT tin.it>
wrote:
> I did change in linker settings:
> - check for -Bsymbolic link flag and use it to reduce size and loading
> time. This should work now on all platforms (tested on Linux, Solaris,
> Mac OS X with GNU tools)

The symbol-reduction effort is still causing problems for me on NetBSD:

gcc -shared .libs/ct.o .libs/cs.o .libs/blk.o .libs/ctutil.o
-Wl,--whole-archive ../tds/.libs/libtds_objects.a
../replacements/.libs/libreplacements.a -Wl,--no-whole-archive
-Wl,-Bsymbolic -Wl,-soname -Wl,libct.so.3 -Wl,-retain-symbols-file
-Wl,.libs/libct.exp -o .libs/libct.so.3.0
.libs/ct.o: In function `_ct_get_msgstr':
/usr/local/website/DocumentRoot/projects/freetds/build/src/ctlib/../../..
/src/ctlib/ct.c:159: undefined reference to `asprintf'
.libs/ct.o: In function `_ctclient_msg':
/usr/local/website/DocumentRoot/projects/freetds/build/src/ctlib/../../..
/src/ctlib/ct.c:186: undefined reference to `free'
.libs/ct.o: In function `ct_con_alloc':
/usr/local/website/DocumentRoot/projects/freetds/build/src/ctlib/../../..
/src/ctlib/ct.c:226: undefined reference to `malloc'
[...]

I get around this with:

for T in src/*/Makefile
do
sed 's/-export-symbols-regex.*$//' $T | diff -u $T - | patch
done

I haven't looked into it further to understand exactly what's wrong.

--jkl




Archive powered by MHonArc 2.6.24.

Top of Page