Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sourceware DOT cygnus DOT com Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com Message-ID: <20000322151807.B12281@white.hole.org> Date: Wed, 22 Mar 2000 15:18:07 +0000 From: Kirth To: Kirth , earnie_boyd AT yahoo DOT com, cygwin AT sourceware DOT cygnus DOT com Subject: Re: ld problems References: <20000322134420 DOT 1595 DOT qmail AT web110 DOT yahoomail DOT com> <20000322150226 DOT A12281 AT white DOT hole DOT org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.93.2 In-Reply-To: <20000322150226.A12281@white.hole.org>; from Kirth on Wed, Mar 22, 2000 at 03:02:26PM +0000 X-Mailer: Mutt http://www.mutt.org/ X-Editor: Vim http://www.vim.org/ X-Info: http://black.hole.org/ the error's are: sql.o: In function `_tf22_IO_istream_withassign': /mnt/cygwin/ffind/src/sql.cpp(.text+0xe): undefined reference to `mysql_init' /mnt/cygwin/ffind/src/sql.cpp(.text+0x2e): undefined reference to `mysql_real_co nnect' sql.o: In function `sql_disconnect(st_mysql *, st_mysql_res *)': /mnt/cygwin/ffind/src/sql.cpp:34: undefined reference to `mysql_free_result' /mnt/cygwin/ffind/src/sql.cpp:35: undefined reference to `mysql_close' sql.o: In function `sql_do_query(char *, st_mysql *)': /mnt/cygwin/ffind/src/sql.cpp:43: undefined reference to `mysql_query' /mnt/cygwin/ffind/src/sql.cpp:49: undefined reference to `mysql_use_result' query.o: In function `Query::Do(st_mysql *)': /mnt/cygwin/ffind/src/query.cpp:222: undefined reference to `mysql_fetch_row' /mnt/cygwin/ffind/src/query.cpp:225: undefined reference to `mysql_fetch_lengths ' make: *** [ffind] Error 1 *sigh* one step forward, two back .. at least thats what this is feeling like thanks again * Kirth (kirth AT hole DOT org) [000322 15:02]: > ahh right that fixed it, mind you im not getting undefined reference's > to thinks like mysql_init .. theres are definitly part of the mysqlclient > lib. I had thought to compilie mysql myself, however it gives a few hundred > errors, so that was no go. > > Any suggestions ? ive tried the library that comes with mysql for windows, > the one from the extra mysqlclients package, and even copying across > my linux library, all give roughly the same undefined reference's. > > sorry if thats a bit OT, mysql doesnt seem to have a mailing list > for compiling under cygwin with it. > > Regards > > * Earnie Boyd (earnie_boyd AT yahoo DOT com) [000322 13:41]: > > --- Kirth wrote: > > > unfortuanlty the same thing > > > > > > g++ -o ffind config.o sql.o query.o parseword.o ffind.o > > > -L/usr/local/lib/mysql > > > -lmysqlclient > > > > > /cygnus/CYGWIN~1/H-I586~1/bin/../lib/gcc-lib/i586-cygwin32/2.95.2/../../../../i5 > > > 86-cygwin32/bin/ld: cannot open -lmysqlclient: No such file or directory > > > collect2: ld returned 1 exit status > > > make: *** [ffind] Error 1 > > > > > > ive even tried with -L./ and put the file in the same dir > > > ive renamed it mysqlclient, mysqlclient.so, mysqlclient.a ... all > > > fail. > > > > > > The library file name must be libmysqlclient.a for the -l switch to work. > > Another option is to just list the library file on the command line like this: > > > > g++ -o ffind config.o sql.o query.o parseword.o ffind.o \ > > /usr/local/lib/mysql/libmysqlclient.a > > > > The GCC will recognize the library and use it properly. > > > > > > i read something in the mailing list about removing collect2 > > > so that ld gets run directly, but i dont have a collect2 file (at all) > > > > > > > The collect2 problem isn't your problem here. That has to do with seeing the > > output from ld which you're seeing. And yes you have it, you'll find it under > > the lib/gcc-lib subdirectories. To get the exact location you can gcc > > --print-file-name=specs and the directory in which the specs file is the same > > directory that the collect2 program is located. > > > > > > ===== > > --- > > Earnie Boyd: > > __Cygwin: POSIX on Windows__ > > Cygwin Newbies: > > __Minimalist GNU for Windows__ > > Mingw32 List: > > Mingw Home: > > > > __________________________________________________ > > Do You Yahoo!? > > Talk to your friends online with Yahoo! Messenger. > > http://im.yahoo.com > > > > -- > > Want to unsubscribe from this list? > > Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com > > > > -- > Kirth > i-docs.org - interactive Documentation (i-D) kirth AT i-docs DOT org > www.oal.co.uk - Octopus Associates Ltd (OAL) kirth AT oal DOT co DOT uk > www.cu3ed.net - Cubed kirth AT cu3ed DOT net > www.worldpop.com - WorldPop Ltd (Consultant) kirth AT worldpop DOT com > black.hole.org - Personal Pages kirth AT hole DOT org -- Kirth i-docs.org - interactive Documentation (i-D) kirth AT i-docs DOT org www.oal.co.uk - Octopus Associates Ltd (OAL) kirth AT oal DOT co DOT uk www.cu3ed.net - Cubed kirth AT cu3ed DOT net www.worldpop.com - WorldPop Ltd (Consultant) kirth AT worldpop DOT com black.hole.org - Personal Pages kirth AT hole DOT org -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com