delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2005/08/02/22:10:45

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Message-ID: <42F02793.8080109@etr-usa.com>
Date: Tue, 02 Aug 2005 20:10:27 -0600
From: Warren Young <warren AT etr-usa DOT com>
User-Agent: Mozilla Thunderbird 1.0.6 (Windows/20050716)
MIME-Version: 1.0
To: Cygwin-L <cygwin AT cygwin DOT com>
Subject: Trouble making .so (undefined symbols)
X-IsSubscribed: yes

I maintain MySQL++ (http://tangentsoft.net/mysql++/), a C++ API for 
MySQL.  It builds fine under Cygwin when we create a static library, but 
linking fails due to undefined symbols when we ask for a shared object.

The symptom is the libtool error "libtool: link: warning: undefined 
symbols not allowed in i686-pc-cygwin shared libraries" when creating 
the shared object itself.  I found some messages in the archive saying 
that this can be fixed by using the link flag -no-undefined, but that 
didn't help.

Now, libtool just warns here, doesn't return an error code.  No .so file 
is created in the .libs directory.  Also, a mere 8-byte .a file is 
created.  (It contains "!<arch>\n")

After this point in the MySQL++ build process, several example programs 
are built.  When linking the first one, we get a spate of errors.  I 
think this is secondary damage, because it tries to link to that .a 
file, but it's basically empty.  Naturally g++ can't find any of the 
symbol definitions it needs to link the program.

If you need to play with this to understand what I mean, download the 
v2.0 beta 2 source from the URL above...it's LGPL.

How do I convince libtool to create the bloody .so file?

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019