Re: freetds on solaris 11: symbol scope specifies local binding (same problem)

Justin T Pryzby <[email protected]>
Newsgroups gmane.comp.db.tds.freetds
Message-ID <[email protected]>
On Tue, Oct 01, 2013 at 12:05:06AM -0400, James K. Lowden wrote:
> I rather suspect the compiler, because it's what produced ct.o.  What's
> the compiler command line look like?  Anything there that deals with
> symbol visibility or that affects linkage?  

The command is here
http://lists.ibiblio.org/pipermail/freetds/2013q3/028575.html
http://lists.ibiblio.org/pipermail/freetds/2013q3/028467.html

BTW, the other 3 object files in ctlib/ have the same problem,
whichever is specified first in the link command throws the error.

(BTW, did you see my more recent message?  Just checking)
http://lists.ibiblio.org/pipermail/freetds/2013q3/028591.html

I ran gobjdump -t, and found that strlen had a "hidden" attribute; I
noticed that ctlib.h sets gcc attribute "hidden":
#pragma GCC visibility push(hidden)

I was able to compile TDS by moving the include file outside of the
hidden "stack"; not sure if that's correct, but "works for me".

$ diff -U1 freetds-0.91{.orig,}/include/ctlib.h
--- freetds-0.91.orig/include/ctlib.h   Tue Oct  5 01:36:36 2010
+++ freetds-0.91/include/ctlib.h        Tue Oct  1 08:58:01 2013
@@ -26,2 +26,4 @@
 
+#include <tds.h>
+
 #if defined(__GNUC__) && __GNUC__ >= 4 && !defined(__MINGW32__)
@@ -41,3 +43,2 @@
 
-#include <tds.h>
 /*

Justin
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.