From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17321 invoked by alias); 2 Sep 2002 17:06:37 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 17314 invoked from network); 2 Sep 2002 17:06:37 -0000 Received: from unknown (HELO anora.org) (12.227.4.60) by sources.redhat.com with SMTP; 2 Sep 2002 17:06:37 -0000 Received: (qmail 1932 invoked from network); 2 Sep 2002 17:06:19 -0000 Received: from unknown (HELO vaghn.anora.org) (root@192.168.1.177) by 12-227-4-60.client.attbi.com with SMTP; 2 Sep 2002 17:06:19 -0000 Date: Mon, 02 Sep 2002 10:06:00 -0000 From: GRE Spam Mail To: "Rupert Wood" Cc: gcc-help@gcc.gnu.org Subject: Re: undefined reference to `__errno_location(void)' Message-Id: <20020902130644.34af2db7.gre_spam@anora.org> In-Reply-To: <616BE6A276E3714788D2AC35C40CD18D561765@whale.softwire.co.uk> References: <616BE6A276E3714788D2AC35C40CD18D7D2511@whale.softwire.co.uk> <616BE6A276E3714788D2AC35C40CD18D561765@whale.softwire.co.uk> Organization: Anora Computer Services Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-SW-Source: 2002-09/txt/msg00012.txt.bz2 On Mon, 2 Sep 2002 07:38:48 +0100 "Rupert Wood" wrote: > Gordon Ellsworth wrote: > > > /home/muvie/muvie/src/socket_class.c:211: undefined reference to > > `__errno_location(void)' > : > > And when you link make sure to add -lpthread, > > since the symbol for errno_location is defined > > in the libpthread library on Linux. > : > > I tried this, but it did not get rid of the problem. > > Can I confirm that you tried the '-lpthread' in addition to the #include > in the PR comment? Which #include would that be? I think I missed it. > If so, can you confirm that you've got a libpthread.a > or libpthread.so in /lib or /usr/lib Here's what I have: ./usr/lib/libpthread.a ./usr/lib/libpthread_p.a ./lib/libpthread-0.9.so ./usr/lib/libpthread.so > and that it contains the symbol > __errno_location? > How do I check for the symbol? I tried this to see if the symbol was there, I don't know if this is the right way to check: [root@vaghn (/)] 01:02:53 $ grep "__errno_location" /usr/lib/libpthread.a Binary file /usr/lib/libpthread.a matches [root@vaghn (/)] 01:02:56 $ grep "__errno_location" /usr/lib/libpthread.so Binary file /usr/lib/libpthread.so matches > As you said you haven't upgraded, the system *ought* to work as shipped. > But it's possible (albeit unlikely) that your C library was not build > with threading support or that you're missing the ptherad library - > maybe you need to install it as a separate package? I installed every package that comes with Slackware 8.1 (I did a full install from the Slackware CD) so there should be nothing missing. > > Good luck, > Rup. Thank you for your help. Sincerely, Gordon R. Ellsworth, Jr.