freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
- From: "Mark J. Lilback" <mark AT lilback.com>
- To: freetds mailing list <freetds AT lists.ibiblio.org>
- Subject: [freetds] solutions for building on Mac OS X
- Date: Tue, 30 Sep 2003 18:05:19 -0400
A few people have emailed me about getting the current cvs version to compile, and I've spent sometime figuring out what the problems are. Unfortunately, I'm not sure I know enough to find the correct fix, but I've got a hackish one that will get it to compile.
The first, and easy, problem is that EILSEQ #defined, but not to a value. The TODO list says it needs to be fixed, but until that fix happens, freetds won't compile on a system that doesn't define EILSEQ. To get around this, I set it via CFLAGS. The following is how I ran autogen.sh.
mlilback$CFLAGS=-DEILSEQ=ENOENT ./autogen.sh --with-tdsver=7.0
The next problem is that the final commands that are generated to link the shared libraries are passing each library twice on the command line. For example, when building in src/tds, $archive_cmds is created with both $libobjs and $deplibs containing libtds_objects.al and libreplacements.al.
To solve this, after running autogen.sh or configure, edit libtool and look for "Do each of the archive commands." It was line 3179 on my generated file. Add the following line above it:
deplibs=`echo "$deplibs" | sed -d 's#\([^ ]*\)\.al##g'`
Then a make will build libtds, libdb, libct, and libodbc. It dies building tsql because gethostbyaddr_r is not found. (10.2 doesn't support the _r functions.)
I spent a few hours digging through libtool and how it is created, but couldn't figure out the process since there are so many options and nesting is almost impossible to figure out in the shell scripts. If someone has an idea, I'd love to hear it. Otherwise, I'll post a message to a darwin list and see if I can get a helpful reply.
--
__________________________________________________________________________
"They that can give up essential liberty
Mark J. Lilback to obtain a little temporary safety
<mark AT lilback.com> deserve neither liberty or safety."
http://www.lilback.com/ -- Benjamin Franklin
- [freetds] solutions for building on Mac OS X, Mark J. Lilback, 09/30/2003
Archive powered by MHonArc 2.6.24.