public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libc/317] New: Link error when using linuxthreads (_res, _h_errno, _errno undefined)
@ 2004-08-10 16:36 jan dot h dot d at swipnet dot se
  2004-08-10 16:37 ` [Bug libc/317] " jan dot h dot d at swipnet dot se
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: jan dot h dot d at swipnet dot se @ 2004-08-10 16:36 UTC (permalink / raw)
  To: glibc-bugs

Glibc CVS checked out at 12:02, 10 Aug, 2004.

Configure command:
% ../glibc-2.3.3/configure --prefix=/usr --enable-add-ons=nptl --with-tls

% gcc -v
Reading specs from /usr/lib/gcc/i686-pc-linux-gnu/3.4.1/specs
Configured with: ../gcc-3.4.1/configure --prefix=/usr --enable-shared
--with-gnu-as --with-gnu-ld --enable-threads
Thread model: posix
gcc version 3.4.1

% ld -v
GNU ld version 2.15.90.0.1.1 20040303
Host type: i686-pc-linux-gnu
System: Linux gaffa 2.6.7 #11 Sat Jul 24 00:06:03 CEST 2004 i686 unknown unknown
GNU/Linux
Architecture: i686

% as -v
GNU assembler version 2.15.90.0.1.1 (i386-redhat-linux-gnu) using BFD version
2.15.90.0.1.1 20040303

% /lib/libc.so.6 
GNU C Library stable release version 2.3.2, by Roland McGrath et al.
Copyright (C) 2003 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
Compiled by GNU CC version 3.2.2.
Compiled on a Linux 2.4.19 system on 2003-03-29.
Available extensions:
        GNU libio by Per Bothner
        crypt add-on version 2.1 by Michael Glad and others
        linuxthreads-0.10 by Xavier Leroy
        BIND-8.2.3-T5B
        libthread_db work sponsored by Alpha Processor Inc
        NIS(YP)/NIS+ NSS modules 0.19 by Thorsten Kukuk
Report bugs using the `glibcbug' script to <bugs@gnu.org>.

Description:
	When compiling I get these errors:

gcc   -shared -static-libgcc -Wl,-O1  -Wl,-z,defs -Wl,-dynamic-linker=/lib/ld-li
nux.so.2 -B/home/jhd/build/obj-cvs/linuxthreads/ -B/home/jhd/build/obj-cvs/csu/ 
-B/home/jhd/build/obj-cvs/linuxthreads/ -Wl,--version-script=/home/jhd/build/obj
-cvs/libpthread.map -Wl,-soname=libpthread.so.0 -Wl,-z,combreloc -Wl,-z,relro -W
l,--enable-new-dtags,-z,nodelete -Wl,--enable-new-dtags,-z,initfirst -L/home/jhd
/build/obj-cvs -L/home/jhd/build/obj-cvs/math -L/home/jhd/build/obj-cvs/elf -L/h
ome/jhd/build/obj-cvs/dlfcn -L/home/jhd/build/obj-cvs/nss -L/home/jhd/build/obj-
cvs/nis -L/home/jhd/build/obj-cvs/rt -L/home/jhd/build/obj-cvs/resolv -L/home/jh
d/build/obj-cvs/crypt -L/home/jhd/build/obj-cvs/linuxthreads -Wl,-rpath-link=/ho
me/jhd/build/obj-cvs:/home/jhd/build/obj-cvs/math:/home/jhd/build/obj-cvs/elf:/h
ome/jhd/build/obj-cvs/dlfcn:/home/jhd/build/obj-cvs/nss:/home/jhd/build/obj-cvs/
nis:/home/jhd/build/obj-cvs/rt:/home/jhd/build/obj-cvs/resolv:/home/jhd/build/obj-cvs/crypt:/home/jhd/build/obj-cvs/linuxthreads
-o /home/jhd/build/obj-cvs/linu
xthreads/libpthread.so -T /home/jhd/build/obj-cvs/shlib.lds /home/jhd/build/obj-
cvs/csu/abi-note.o -Wl,--whole-archive /home/jhd/build/obj-cvs/linuxthreads/libp
thread_pic.a -Wl,--no-whole-archive /home/jhd/build/obj-cvs/elf/interp.os /home/
jhd/build/obj-cvs/libc.so /home/jhd/build/obj-cvs/libc_nonshared.a /home/jhd/bui
ld/obj-cvs/elf/ld.so 
/home/jhd/build/obj-cvs/linuxthreads/libpthread_pic.a(pthread.os)(.text+0x222): 
I funktionen "pthread_initialize":
/home/jhd/build/libc/linuxthreads/pthread.c:549: undefined reference to `_res'
/home/jhd/build/obj-cvs/linuxthreads/libpthread_pic.a(pthread.os)(.text+0xbe1): 
I funktionen "__pthread_reset_main_thread":
/home/jhd/build/libc/linuxthreads/pthread.c:1144: undefined reference to `_errno
'
/home/jhd/build/obj-cvs/linuxthreads/libpthread_pic.a(pthread.os)(.text+0xbf3):/
home/jhd/build/libc/linuxthreads/pthread.c:1145: undefined reference to `_h_errn
o'
/home/jhd/build/obj-cvs/linuxthreads/libpthread_pic.a(pthread.os)(.text+0xbff):/
home/jhd/build/libc/linuxthreads/pthread.c:1146: undefined reference to `_res'
/home/jhd/build/obj-cvs/linuxthreads/libpthread_pic.a(pthread.os)(.data.rel+0x6b
8): I funktionen "__pthread_setschedparam":
/home/jhd/build/libc/linuxthreads/pthread.c:956: undefined reference to `_errno'
/home/jhd/build/obj-cvs/linuxthreads/libpthread_pic.a(pthread.os)(.data.rel+0x6c
0):/home/jhd/build/libc/linuxthreads/pthread.c:956: undefined reference to `_h_e
rrno'
/home/jhd/build/obj-cvs/linuxthreads/libpthread_pic.a(pthread.os)(.data.rel+0x6c
8):/home/jhd/build/libc/linuxthreads/pthread.c:956: undefined reference to `_res
'
collect2: ld returned 1 exit status


It seems that USE_TLS is not defined in any header file when linuxthreads are
used.  This is because FLOATING_STACKS is not defined when
linuxthreads/sysdeps/i386/tls.h is included.  The file where FLOATING_STACKS is
defined is linuxthreads/sysdeps/i386/useldt.h but that file is not included in
i386/tls.h until after i386/tls.h has checked if FLOATING_STACKS is defined.

-- 
           Summary: Link error when using linuxthreads (_res, _h_errno,
                    _errno undefined)
           Product: glibc
           Version: unspecified
            Status: NEW
          Severity: critical
          Priority: P2
         Component: libc
        AssignedTo: gotom at debian dot or dot jp
        ReportedBy: jan dot h dot d at swipnet dot se
                CC: glibc-bugs at sources dot redhat dot com
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


http://sources.redhat.com/bugzilla/show_bug.cgi?id=317

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug libc/317] Link error when using linuxthreads (_res, _h_errno, _errno undefined)
  2004-08-10 16:36 [Bug libc/317] New: Link error when using linuxthreads (_res, _h_errno, _errno undefined) jan dot h dot d at swipnet dot se
@ 2004-08-10 16:37 ` jan dot h dot d at swipnet dot se
  2004-08-10 17:25 ` jakub at redhat dot com
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: jan dot h dot d at swipnet dot se @ 2004-08-10 16:37 UTC (permalink / raw)
  To: glibc-bugs


------- Additional Comments From jan dot h dot d at swipnet dot se  2004-08-10 16:37 -------
Sorry, copy paste error.  The configure command is of course
% ../glibc-2.3.3/configure --prefix=/usr --enable-add-ons=linuxthreads --with-tls



-- 


http://sources.redhat.com/bugzilla/show_bug.cgi?id=317

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug libc/317] Link error when using linuxthreads (_res, _h_errno, _errno undefined)
  2004-08-10 16:36 [Bug libc/317] New: Link error when using linuxthreads (_res, _h_errno, _errno undefined) jan dot h dot d at swipnet dot se
  2004-08-10 16:37 ` [Bug libc/317] " jan dot h dot d at swipnet dot se
@ 2004-08-10 17:25 ` jakub at redhat dot com
  2004-09-12  5:47 ` drepper at redhat dot com
  2004-09-12  7:48 ` jan dot h dot d at swipnet dot se
  3 siblings, 0 replies; 5+ messages in thread
From: jakub at redhat dot com @ 2004-08-10 17:25 UTC (permalink / raw)
  To: glibc-bugs


------- Additional Comments From jakub at redhat dot com  2004-08-10 17:25 -------
You should use --with-tls --without-__thread when building linuxthreads.
That's the switch combination which is tested and works, I doubt anybody
tested --with-tls --with-__thread linuxthreads in the last year or two.

-- 


http://sources.redhat.com/bugzilla/show_bug.cgi?id=317

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug libc/317] Link error when using linuxthreads (_res, _h_errno, _errno undefined)
  2004-08-10 16:36 [Bug libc/317] New: Link error when using linuxthreads (_res, _h_errno, _errno undefined) jan dot h dot d at swipnet dot se
  2004-08-10 16:37 ` [Bug libc/317] " jan dot h dot d at swipnet dot se
  2004-08-10 17:25 ` jakub at redhat dot com
@ 2004-09-12  5:47 ` drepper at redhat dot com
  2004-09-12  7:48 ` jan dot h dot d at swipnet dot se
  3 siblings, 0 replies; 5+ messages in thread
From: drepper at redhat dot com @ 2004-09-12  5:47 UTC (permalink / raw)
  To: glibc-bugs


------- Additional Comments From drepper at redhat dot com  2004-09-12 05:47 -------
And furthermore, we don't provide support for building glibc.  Do not file this
kind of "bugs".  If you think you have to build glibc, solve all the problems
yourself.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |WONTFIX


http://sources.redhat.com/bugzilla/show_bug.cgi?id=317

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug libc/317] Link error when using linuxthreads (_res, _h_errno, _errno undefined)
  2004-08-10 16:36 [Bug libc/317] New: Link error when using linuxthreads (_res, _h_errno, _errno undefined) jan dot h dot d at swipnet dot se
                   ` (2 preceding siblings ...)
  2004-09-12  5:47 ` drepper at redhat dot com
@ 2004-09-12  7:48 ` jan dot h dot d at swipnet dot se
  3 siblings, 0 replies; 5+ messages in thread
From: jan dot h dot d at swipnet dot se @ 2004-09-12  7:48 UTC (permalink / raw)
  To: glibc-bugs


------- Additional Comments From jan dot h dot d at swipnet dot se  2004-09-12 07:48 -------
I can accept that.  But it becomes a bit strange when one files a bug on a
released glibc version, and is told to use CVS, because releases are not made
anymore.  Then when the CVS version don't build one is told that build problems
are not handeled by you.

Anyway, it seems to me that this was a lack of documentation, the switch
combination needed was not documented.

-- 


http://sources.redhat.com/bugzilla/show_bug.cgi?id=317

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2004-09-12  7:48 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-08-10 16:36 [Bug libc/317] New: Link error when using linuxthreads (_res, _h_errno, _errno undefined) jan dot h dot d at swipnet dot se
2004-08-10 16:37 ` [Bug libc/317] " jan dot h dot d at swipnet dot se
2004-08-10 17:25 ` jakub at redhat dot com
2004-09-12  5:47 ` drepper at redhat dot com
2004-09-12  7:48 ` jan dot h dot d at swipnet dot se

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).