public inbox for libc-hacker@sourceware.org
 help / color / mirror / Atom feed
* Problem with glibc mainline and linuxthreads on x86-64
@ 2002-08-21  5:54 Andreas Jaeger
  2002-08-21  6:39 ` Andreas Jaeger
  2002-08-21  6:39 ` Andreas Schwab
  0 siblings, 2 replies; 7+ messages in thread
From: Andreas Jaeger @ 2002-08-21  5:54 UTC (permalink / raw)
  To: GNU libc hacker


Compiling glibc mainline for x86-64 I get this error:

/usr/src/aj/build-glibc-mainline/linuxthreads/libpthread_pic.a(attr.os): In function `pthread_attr_init@GLIBC_2.2.5':
itimerspec/attr.c:48: multiple definition of `pthread_attr_init@GLIBC_2.2.5'
/usr/lib64/gcc-lib/x86_64-suse-linux/3.2/../../../../x86_64-suse-linux/bin/ld: Warning: size of symbol `pthread_attr_init@GLIBC_2.2.5' changed from 83 to 40 in /usr/src/aj/build-glibc-mainline/linuxthreads/libpthread_pic.a(attr.os)
/usr/src/aj/build-glibc-mainline/linuxthreads/libpthread_pic.a(pthread.os): In function `pthread_create@GLIBC_2.2.5':
Elf32_Ehdr/pthread.c:796: multiple definition of `pthread_create@GLIBC_2.2.5'
/usr/lib64/gcc-lib/x86_64-suse-linux/3.2/../../../../x86_64-suse-linux/bin/ld: Warning: size of symbol `pthread_create@GLIBC_2.2.5' changed from 198 to 153 in /usr/src/aj/build-glibc-mainline/linuxthreads/libpthread_pic.a(pthread.os)
/usr/src/aj/build-glibc-mainline/linuxthreads/libpthread_pic.a(oldsemaphore.os):


$ nm linuxthreads/attr.os |grep pthread_attr_init
0000000000000054 T __pthread_attr_init_2_0
0000000000000000 T __pthread_attr_init_2_1
0000000000000000 T pthread_attr_init@@GLIBC_2.2.5
0000000000000054 T pthread_attr_init@GLIBC_2.2.5

One think puzzles me: Why do I get the _2_0 symbol at all?  There's no
compatibility for x86-64 for glibc 2.0 and therefore the stuff should
not get compiled in.

linuxthreads/shlib-versions contains:
x86_64-.*-linux.*	libpthread=0		GLIBC_2.2.5

Can anybody hint me in the right direction?

Thanks,
Andreas
-- 
 Andreas Jaeger
  SuSE Labs aj@suse.de
   private aj@arthur.inka.de
    http://www.suse.de/~aj

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

* Re: Problem with glibc mainline and linuxthreads on x86-64
  2002-08-21  5:54 Problem with glibc mainline and linuxthreads on x86-64 Andreas Jaeger
@ 2002-08-21  6:39 ` Andreas Jaeger
  2002-08-21  6:39 ` Andreas Schwab
  1 sibling, 0 replies; 7+ messages in thread
From: Andreas Jaeger @ 2002-08-21  6:39 UTC (permalink / raw)
  To: GNU libc hacker


Andreas Schwab will send a full analysis of the problem.

The problem can be worked around with the appended patch but I think
this is a generic problem that needs fixing in the script generating
the defines,

Andreas 

Index: Versions.def
===================================================================
RCS file: /cvs/glibc/libc/Versions.def,v
retrieving revision 1.43
diff -u -p -r1.43 Versions.def
--- Versions.def        11 Jul 2002 16:29:54 -0000      1.43
+++ Versions.def        21 Aug 2002 13:34:19 -0000
@@ -67,6 +67,7 @@ libpthread {
   GLIBC_2.1.2
   GLIBC_2.2
   GLIBC_2.2.3
+  GLIBC_2.2.5
   GLIBC_2.2.6
   GLIBC_PRIVATE
 }


-- 
 Andreas Jaeger
  SuSE Labs aj@suse.de
   private aj@arthur.inka.de
    http://www.suse.de/~aj

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

* Re: Problem with glibc mainline and linuxthreads on x86-64
  2002-08-21  5:54 Problem with glibc mainline and linuxthreads on x86-64 Andreas Jaeger
  2002-08-21  6:39 ` Andreas Jaeger
@ 2002-08-21  6:39 ` Andreas Schwab
  2002-08-21 23:02   ` Roland McGrath
  1 sibling, 1 reply; 7+ messages in thread
From: Andreas Schwab @ 2002-08-21  6:39 UTC (permalink / raw)
  To: Andreas Jaeger; +Cc: GNU libc hacker

Andreas Jaeger <aj@suse.de> writes:

|> Compiling glibc mainline for x86-64 I get this error:
|> 
|> /usr/src/aj/build-glibc-mainline/linuxthreads/libpthread_pic.a(attr.os): In function `pthread_attr_init@GLIBC_2.2.5':
|> itimerspec/attr.c:48: multiple definition of `pthread_attr_init@GLIBC_2.2.5'
|> /usr/lib64/gcc-lib/x86_64-suse-linux/3.2/../../../../x86_64-suse-linux/bin/ld: Warning: size of symbol `pthread_attr_init@GLIBC_2.2.5' changed from 83 to 40 in /usr/src/aj/build-glibc-mainline/linuxthreads/libpthread_pic.a(attr.os)
|> /usr/src/aj/build-glibc-mainline/linuxthreads/libpthread_pic.a(pthread.os): In function `pthread_create@GLIBC_2.2.5':
|> Elf32_Ehdr/pthread.c:796: multiple definition of `pthread_create@GLIBC_2.2.5'
|> /usr/lib64/gcc-lib/x86_64-suse-linux/3.2/../../../../x86_64-suse-linux/bin/ld: Warning: size of symbol `pthread_create@GLIBC_2.2.5' changed from 198 to 153 in /usr/src/aj/build-glibc-mainline/linuxthreads/libpthread_pic.a(pthread.os)
|> /usr/src/aj/build-glibc-mainline/linuxthreads/libpthread_pic.a(oldsemaphore.os):
|> 
|> 
|> $ nm linuxthreads/attr.os |grep pthread_attr_init
|> 0000000000000054 T __pthread_attr_init_2_0
|> 0000000000000000 T __pthread_attr_init_2_1
|> 0000000000000000 T pthread_attr_init@@GLIBC_2.2.5
|> 0000000000000054 T pthread_attr_init@GLIBC_2.2.5
|> 
|> One think puzzles me: Why do I get the _2_0 symbol at all?  There's no
|> compatibility for x86-64 for glibc 2.0 and therefore the stuff should
|> not get compiled in.
|> 
|> linuxthreads/shlib-versions contains:
|> x86_64-.*-linux.*	libpthread=0		GLIBC_2.2.5
|> 
|> Can anybody hint me in the right direction?

The problem ist that abi-versions.h does not define
ABI_libpthread_GLIBC_2_2_5, but all previous version are defined in terms
of this.  Thus ABI_libpthread_GLIBC_2_0 == 0 and the compat function is
compiled in.

Andreas.

-- 
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux AG, Deutschherrnstr. 15-19, D-90429 Nürnberg
Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."

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

* Re: Problem with glibc mainline and linuxthreads on x86-64
  2002-08-21  6:39 ` Andreas Schwab
@ 2002-08-21 23:02   ` Roland McGrath
  2002-08-21 23:28     ` Andreas Jaeger
  0 siblings, 1 reply; 7+ messages in thread
From: Roland McGrath @ 2002-08-21 23:02 UTC (permalink / raw)
  To: Andreas Schwab; +Cc: Andreas Jaeger, GNU libc hacker

Does this fix it for you?

--- firstversions.awk.~1.5.~			      Sun Apr  7 19:14:19 2002
+++ firstversions.awk	   Wed Aug 21 23:01:23 2002
@@ -37,10 +37,14 @@ $1 == "}" {
       else
         break;
     }
-    if ($1 >= v || $1 == f)
+    if ($1 == f || $1 == v)
       print;
+    else if ($1 > v) {
+      print "  " v;
+      print "  " $1;
+    }
     else
-      print $1, "=", v;
+      print "  " $1, "=", v;
   }
   else
     print;

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

* Re: Problem with glibc mainline and linuxthreads on x86-64
  2002-08-21 23:02   ` Roland McGrath
@ 2002-08-21 23:28     ` Andreas Jaeger
  2002-08-22  0:27       ` Roland McGrath
  0 siblings, 1 reply; 7+ messages in thread
From: Andreas Jaeger @ 2002-08-21 23:28 UTC (permalink / raw)
  To: Roland McGrath; +Cc: Andreas Schwab, GNU libc hacker

Roland McGrath <roland@frob.com> writes:

> Does this fix it for you?
>
> --- firstversions.awk.~1.5.~			      Sun Apr  7 19:14:19 2002
> +++ firstversions.awk	   Wed Aug 21 23:01:23 2002
> @@ -37,10 +37,14 @@ $1 == "}" {
>        else
>          break;
>      }
> -    if ($1 >= v || $1 == f)
> +    if ($1 == f || $1 == v)
>        print;
> +    else if ($1 > v) {
> +      print "  " v;
> +      print "  " $1;
> +    }
>      else
> -      print $1, "=", v;
> +      print "  " $1, "=", v;
>    }
>    else
>      print;
>

Yes, it does:
$ nm attr.os  |grep attr_init
0000000000000000 T __pthread_attr_init_2_1
0000000000000000 T pthread_attr_init@@GLIBC_2.2.5

Thanks,
Andreas
-- 
 Andreas Jaeger
  SuSE Labs aj@suse.de
   private aj@arthur.inka.de
    http://www.suse.de/~aj

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

* Re: Problem with glibc mainline and linuxthreads on x86-64
  2002-08-21 23:28     ` Andreas Jaeger
@ 2002-08-22  0:27       ` Roland McGrath
  2002-08-22  0:38         ` Andreas Jaeger
  0 siblings, 1 reply; 7+ messages in thread
From: Roland McGrath @ 2002-08-22  0:27 UTC (permalink / raw)
  To: Andreas Jaeger; +Cc: Andreas Schwab, GNU libc hacker

I checked in a clenaed up and commented version of that fix.
Please make sure I didn't break any configuration you can try.

This bites x86-64 in the 2.2 branch as well, no?  We need to either put the
script fixes into 2.2.6 or work around it by adding the line to Versions.def.

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

* Re: Problem with glibc mainline and linuxthreads on x86-64
  2002-08-22  0:27       ` Roland McGrath
@ 2002-08-22  0:38         ` Andreas Jaeger
  0 siblings, 0 replies; 7+ messages in thread
From: Andreas Jaeger @ 2002-08-22  0:38 UTC (permalink / raw)
  To: Roland McGrath; +Cc: Andreas Schwab, GNU libc hacker

Roland McGrath <roland@frob.com> writes:

> I checked in a clenaed up and commented version of that fix.
> Please make sure I didn't break any configuration you can try.
>
> This bites x86-64 in the 2.2 branch as well, no?  We need to either put the
> script fixes into 2.2.6 or work around it by adding the line to Versions.def.

It didn't bit us *yet* since there's no 2.3 version and 2.2.5 (which is
the default) is the latest.  But with 2.2.6 it might bite us, so
please check it in.  I'll give it some more testing later today,

Thanks a lot!
Andreas
-- 
 Andreas Jaeger
  SuSE Labs aj@suse.de
   private aj@arthur.inka.de
    http://www.suse.de/~aj

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

end of thread, other threads:[~2002-08-22  7:38 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-08-21  5:54 Problem with glibc mainline and linuxthreads on x86-64 Andreas Jaeger
2002-08-21  6:39 ` Andreas Jaeger
2002-08-21  6:39 ` Andreas Schwab
2002-08-21 23:02   ` Roland McGrath
2002-08-21 23:28     ` Andreas Jaeger
2002-08-22  0:27       ` Roland McGrath
2002-08-22  0:38         ` Andreas Jaeger

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).