[an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive]
 
[an error occurred while processing this directive] [an error occurred while processing this directive]
Skåne Sjælland Linux User Group - http://www.sslug.dk Home   Subscribe   Mail Archive   Forum   Calendar   Search
MhonArc Date: [Date Prev] [Date Index] [Date Next]   Thread: [Date Prev] [Thread Index] [Date Next]   MhonArc
 

Re: [CPROG] Linker problem ved brug af egen so fil



On Tue, 3 Jul 2001, Kasper Hauge wrote:

> 
> gcc -D_LINUX_ -D_ISOC99_SOURCE -g -o test test.o -L. -lmylib
> 
> ./libmylib.so: undefined reference to `pthread_create'
> ./libmylib.so: undefined reference to `pthread_cancel'
> ./libmylib.so: undefined reference to `Tcl_Sleep'
> collect2: ld returned 1 exit status
> 
> Jeg bruger andre funktioner fra pthread.h og dem kommer der ingen fejl
> på.
> 
> Hvad kan der være galt ??

I det sidste skridt her, linker du en bunke .o filer sammen til en exe
fil. Der skal oversætteren have adgang til de filer du skal linke
med. Tilføj -lpthread til ovenstående, så får du linket med pthread. Jeg
ved ikke med Tcl_Sleep, men den kommer nok fra et eller andet tcl lib.

Mads

-- 
Mads Bondo Dydensborg.                               sslug@sslug
You know you're a Linux geek when...

    You keep track of your highest uptime, and try to break your record.

                                                     - segfault



 
Home   Subscribe   Mail Archive   Index   Calendar   Search

 
 
Questions about the web-pages to <www_admin>. Last modified 2005-08-10, 20:08 CEST [an error occurred while processing this directive]
This page is maintained by [an error occurred while processing this directive]MHonArc [an error occurred while processing this directive] # [an error occurred while processing this directive] *