The unmodified weak_alias, as shown the the weak_alias.diff patch shown below gives compilation errors on current snapshot and CVS 2.3.6 and 2.4 glibc. The unmodifed _equivalent_ forms on i[3456]x86 work fine. -weak_alias (getsockname, __getsockname) +weak_alias (__getsockname, getsockname) The modification was tested on both glibc 2.3.6 and 2.4 snapshots over several weeks now. The compilations were attempted with current gcc-4.2.0 and current snapshot binutils. The exist a more severe problem farther down in the powerpc glibc compilation subject of a forthcoming PR.
Ulrich! I am at a loss. The patch I have as diff -U worked fine on the actual tree. However I can not get accepted by bugzilla either in the comments part or in an attachement. I am going to try and edit it to if a form is acceptable.
When you say "can not get accepted by bugzilla" do you mean when you try to put it in as a comment or as an attachment? What error are you having?
My mozilla is kept indefinetely "waiting for sources.red.hat.com" When I take the patch text out it works fine.
In both cases (attachment or comment) I click on commit and it hangs as long as I have diff output build messages for you.
mail the patch to me and I'll take a look - very curious - what version of mozilla?
Well, another attempt > --- ./sysdeps/unix/sysv/linux/getsockname.S.org 2002-05-14 20:17:58.000000000 -0400 > +++ ./sysdeps/unix/sysv/linux/getsockname.S 2006-05-08 05:34:59.000000000 -0400 > @@ -2,4 +2,4 @@ > #define NARGS 3 > #define NO_WEAK_ALIAS 1 > #include <socket.S> > -weak_alias (getsockname, __getsockname) > +weak_alias (__getsockname, getsockname) > --- ./sysdeps/unix/sysv/linux/bind.S.org 2002-05-14 20:17:25.000000000 -0400 > +++ ./sysdeps/unix/sysv/linux/bind.S 2006-05-08 05:21:20.000000000 -0400 > @@ -2,4 +2,4 @@ > #define NARGS 3 > #define NO_WEAK_ALIAS 1 > #include <socket.S> > -weak_alias (bind, __bind) > +weak_alias ( __bind, bind) > --- ./sysdeps/unix/sysv/linux/listen.S.org 2002-05-14 20:18:37.000000000 -0400 > +++ ./sysdeps/unix/sysv/linux/listen.S 2006-05-08 05:37:40.000000000 -0400 > @@ -2,4 +2,4 @@ > #define NARGS 2 > #define NO_WEAK_ALIAS 1 > #include <socket.S> > -weak_alias (listen, __listen) > +weak_alias (__listen, listen) > --- ./sysdeps/unix/sysv/linux/setsockopt.S.org 2002-05-14 20:19:09.000000000 -0400 > +++ ./sysdeps/unix/sysv/linux/setsockopt.S 2006-05-08 05:40:46.000000000 -0400 > @@ -2,4 +2,4 @@ > #define NARGS 5 > #define NO_WEAK_ALIAS 1 > #include <socket.S> > -weak_alias (setsockopt, __setsockopt) > +weak_alias (__setsockopt, setsockopt)
--- ./sysdeps/unix/sysv/linux/getsockname.S.org 2002-05-14 20:17:58.000000000 -0400 +++ ./sysdeps/unix/sysv/linux/getsockname.S 2006-05-08 05:34:59.000000000 -0400 @@ -2,4 +2,4 @@ #define NARGS 3 #define NO_WEAK_ALIAS 1 #include <socket.S> -weak_alias (getsockname, __getsockname) +weak_alias (__getsockname, getsockname) --- ./sysdeps/unix/sysv/linux/bind.S.org 2002-05-14 20:17:25.000000000 -0400 +++ ./sysdeps/unix/sysv/linux/bind.S 2006-05-08 05:21:20.000000000 -0400 @@ -2,4 +2,4 @@ #define NARGS 3 #define NO_WEAK_ALIAS 1 #include <socket.S> -weak_alias (bind, __bind) +weak_alias (__bind, bind) --- ./sysdeps/unix/sysv/linux/listen.S.org 2002-05-14 20:18:37.000000000 -0400 +++ ./sysdeps/unix/sysv/linux/listen.S 2006-05-08 05:37:40.000000000 -0400 @@ -2,4 +2,4 @@ #define NARGS 2 #define NO_WEAK_ALIAS 1 #include <socket.S> -weak_alias (listen, __listen) +weak_alias (__listen, listen) --- ./sysdeps/unix/sysv/linux/setsockopt.S.org 2002-05-14 20:19:09.000000000 -0400 +++ ./sysdeps/unix/sysv/linux/setsockopt.S 2006-05-08 05:40:46.000000000 -0400 @@ -2,4 +2,4 @@ #define NARGS 5 #define NO_WEAK_ALIAS 1 #include <socket.S> -weak_alias (setsockopt, __setsockopt) +weak_alias (__setsockopt, setsockopt)
Created attachment 1033 [details] Fix weak_alias usage in socket code.
For future reference it is not very helpful to put a patch in that the patch program cannot process unmodified. Additionally you had extra spaces in front of __bind in the line +weak_alias ( __bind, bind) I was able to edit your patch and both insert it into a comment and attach it without problem. I suggest you resolve the problem on your end before you attempt to submit other patches. Do you have any testcase beyond the build issues you saw?
Well, after rebuilding most of X11R6 and reinstalling mozilla (2.7.12) that problem, apparently, misinterpretation of some character went away. Going back to the weak_alias issue. Now, after CVS updates to glibc, svn updates to gcc-4.2 (main trunk) and rebuilt binutils the order of the parameters has become irrelevant. I always thought it was really a gcc issue but after hand editing the four *.S by hand I thought it would be helpful to the glibc community to have a little patch. Again, it might be only of temporary interest to know that it is necessary to change VERSION=0605xx in the binutils bfd, gas, and gprof configure files to something like =2.17. Otherwise, the configuration of glibc will term ld and as as being too old. Finally in reading the equivalents to PR 333 (my PR 2672 was made equivalent to 333) I see that similarily to the gcc in-crowd, people from the user community are not really wellcome. At over 70 years, but as a former assembly language real-time systems programmer I can take a hint and will restrict myself to cases like ICE and segmentation errors. That issue in PR 2672 will either fade away or I will find a way to fake it out and continue building my own libcs, as I have been doing for a long time. I started with gcc-1.4.x and the Berkeley libraries; hacking both for use on SCO's Xenix.
If this patch is necessary then it's the ppc definition of socket.S which is wrong. The x86 version is the master copy, see how it handles symbols.