[M3devel] [cm3] unresolved pthread symbols during bootstrap
Daniel Alejandro Benavides D.
dabenavidesd at yahoo.es
Thu May 31 01:42:04 CEST 2007
Hi,
Looks that you haven't used the SYSTEM_LIBORDER array,
must be "PTHREAD" there in order to really link it.
Maybe this little guide can help. Can have several
omissions, but It works well in (K)ubuntu 6.06 and
6.10
http://es.geocities.com/dabenavidesd/InstallationGuidecm3-Modula-3.html#SECTION00033000000000000000
--- Ronny Forberger <ronny.forberger at elegosoft.com>
wrote:
> Dear m3-Developers,
>
> I could not successfully build the cm3 compiler when
> invoking
>
>
>
> > ./do-cm3-std.sh buildship
>
>
> from the script directory as described in the
> documentation.
>
> The build process stops by the following:
>
> > === package /root/cm3/m3-sys/m3cgcat ===
> > +++ cm3 -build -DROOT='/root/cm3' && cm3 -ship
> -DROOT='/root/cm3' +++
> > --- building in LINUXLIBC6 ---
> >
> > ignoring ../src/m3overrides
> >
> > -> linking m3cgcat
> >
>
/usr/local/cm3/pkg/m3core/LINUXLIBC6/libm3core.a(ThreadPThread.mo):
> In
> > function `ThreadPThread__InnerLockMutex':
> >
>
/root/cm3/m3-libs/m3core/LINUXLIBC6/ThreadPThread.m3:142:
> undefined
> > reference to `pthread_cond_wait'
> >
> [ some similar lines removed ]
>
> >
> >
>
/usr/local/cm3/pkg/m3core/LINUXLIBC6/libm3core.a(ThreadPThread.mo):
> In
> > function `RTHooks__PushEFrame':
> >
>
/root/cm3/m3-libs/m3core/LINUXLIBC6/ThreadPThread.m3:1429:
> undefined
> > reference to `pthread_getspecific'
> >
>
/root/cm3/m3-libs/m3core/LINUXLIBC6/ThreadPThread.m3:1430:
> undefined
> > reference to `pthread_setspecific'
> >
>
/usr/local/cm3/pkg/m3core/LINUXLIBC6/libm3core.a(ThreadPThread.mo):
> In
> > function `RTHooks__PopEFrame':
> >
>
/root/cm3/m3-libs/m3core/LINUXLIBC6/ThreadPThread.m3:1437:
> undefined
> > reference to `pthread_setspecific'
> >
>
/usr/local/cm3/pkg/m3core/LINUXLIBC6/libm3core.a(ThreadPThread.mo):
> In
> > function `ThreadPThread__InitHandlers':
> >
>
/root/cm3/m3-libs/m3core/LINUXLIBC6/ThreadPThread.m3:1442:
> undefined
> > reference to `pthread_key_create'
> >
>
/root/cm3/m3-libs/m3core/LINUXLIBC6/ThreadPThread.m3:1443:
> undefined
> > reference to `pthread_setspecific'
> >
>
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../lib/libc.a(vfork.o):
> In
> > function `vfork':
> > (.text+0x1): undefined reference to
> `pthread_create'
> > collect2: ld returned 1 exit status
> > Fatal Error: package build failed
> > *** execution of failed ***
>
>
> Looks like gcc cannot link against the pthread-lib.
>
> I have already added
>
> > "PTHREAD" : [ "-L/usr/lib", "-lpthread" ]
>
> to the SYSTEM_LIBS array in cm3.cfg.
>
> This is a Debian 4.0 'etch' system (x86) where
> libpthread.a resides in
> /usr/lib.
>
> I can build trivial C programs like gcc foo.c -L
> /usr/lib -lpthread
> arccordingly which become linked against
> libpthread.a properly.
>
>
> Do you have any glues?
>
> Best regards,
>
> Ronny
>
> --
> Ronny Forberger
> Systemadministrator
>
> elego Software Solutions GmbH
> ronny.forberger(at)elegosoft.com
> Ohmstraße 9, 10179 Berlin HRB 77719
> Tel.: +49 30 23 45 86 96 Amtsgericht
> Charlottenburg
> Fax: +49 30 23 45 86 95 Sitz der
> Gesellschaft: Berlin
> http://www.elegosoft.com
> Geschäftsführer: Olaf Wagner
>
> Bitte senden Sie Ihre technischen Support-Anfragen
> an admins(at)elego.de .
>
>
______________________________________________
LLama Gratis a cualquier PC del Mundo.
Llamadas a fijos y móviles desde 1 céntimo por minuto.
http://es.voice.yahoo.com
More information about the M3devel
mailing list