This is the mail archive of the
libc-help@sourceware.org
mailing list for the glibc project.
Re: Issues in adding a new API function in pthread
- From: "Dongyoon Lee" <dongyoon at gmail dot com>
- To: libc-help at sourceware dot org
- Date: Thu, 12 Jun 2008 15:51:33 -0400
- Subject: Re: Issues in adding a new API function in pthread
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=tlfyNogw7Ho35u4nkQwCAZWvR6chwtlSmBcetOxIsws=; b=Y8G7uUjkORQKOdBS6yBq+ekeYJQCJ8LpC3VWDYDmis1ITZdViF3NgOzSN3R8ON86jC 3ckN1D92FlgI6P3/6c9/lleiGLAdFOnb5K2WcL0eRj3CgwM7sV61IPfDoeGQRalw4Dps ce1k1xwv4Il1hrmI/Ir4K7uQawktr7kwarMyI=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=tNdN3w3vfjOnNOgg/0/gUhmPwMs8ARYJi3po7OK9prNwSAcYlyQ9CpJAsSykR/O2lx XX2p2+23MHv4ESHQMPzbAX82N01a4xeVCZFpuIdcVG7vHId435DgTHqmOMZBlj/l30hE x/lAon1WIWN3L0BV0wnrewiSgYXQOP9VMsGZM=
- References: <cbefbaa0806121249g7474d4afyde4fdc82a29f619b@mail.gmail.com>
I have some questions in modifying pthread library in the glibc-2.3.4.
In order to modify and add new functions in the pthread library, I
installed glibc.xxx.src.rpm, modify sources, build glibc.xxx.rpm, and
finally reinstall them.
I checked out that the modified function works on my machine, but I
have trouble exporting API's. For example, I made
pthread_mutex_lock2.c file, and it contains pthread_mutex_lock2()
dummy function that always return 0. I modified Versions, Makefiles,
libpthread.abilist, etc, but I made a compile error in calling
pthread_mutex_lock2 function from the application that use the new
pthread library.
Error messages are like this.
> # gcc d.c -o d -lpthread
> /tmp/ccaCOjbR.o(.text+0x179): In function `main':
> : undefined reference to `pthread_mutex_lock2'
> collect2: ld returned 1 exit status
I checked whether the libpthread.so and pthread.h files are updated,
and confirmed that they are updated.
Can I get any idea or reference website?