[X-Unix] Re: [PB] Compiling on MacOS X (source was written for winblow...) [moved from PB]

Eric F Crist ecrist at secure-computing.net
Sun Nov 26 06:44:27 PST 2006


On Nov 25, 2006, at 11:38 PM, Philip J Robar wrote:

>
> On Nov 25, 2006, at 6:48 PM, Eric F Crist wrote:
>
>>
>> On Nov 25, 2006, at 3:25 PM, Philip J Robar wrote:
>>
>>>
>>> On Nov 25, 2006, at 1:09 PM, Eric F Crist wrote:
>>>
>>>> Please help me understand the following output:
>>>>
>>>> root# gcc *.c -o test
>>>> /usr/bin/ld: Undefined symbols:
>>>>
>>>> How do I fix this?
>
> Oops, sorry I didn't notice that you have moved this to the list I  
> suggested. Hopefully I or someone else can help you get this working.
>
> Phil

Ok,

So I installed mysql on my Mac from fink, and I have the following  
files under /sw/lib/mysql:

Swordfish:/sw/lib/mysql ecrist$ ls
libmysqlclient.15.0.0.dylib     libmysqlclient_r.15.0.0.dylib
libmysqlclient.15.dylib         libmysqlclient_r.15.dylib

When I run the compile with the options people suggest, here's what I  
get:

gcc *.c -o test -L/sw/lib/mysql -lmysqlclient
/usr/bin/ld: can't locate file for: -lmysqlclient
collect2: ld returned 1 exit status


-----
Eric F Crist
Secure Computing Networks




More information about the X-Unix mailing list