r2393 - in glibc-package/branches/glibc-2.5/debian: . patches patches/hurd-i386 sysdeps
Author: mbanck
Date: 2007-07-04 17:28:07 +0000 (Wed, 04 Jul 2007)
New Revision: 2393
Added:
glibc-package/branches/glibc-2.5/debian/patches/hurd-i386/local-argp-fno-strict-aliasing.diff
glibc-package/branches/glibc-2.5/debian/patches/hurd-i386/local-gcc-4.1-init-first.diff
Modified:
glibc-package/branches/glibc-2.5/debian/changelog
glibc-package/branches/glibc-2.5/debian/patches/series
glibc-package/branches/glibc-2.5/debian/sysdeps/hurd.mk
Log:
* patches/hurd-i386/local-gcc-4.1-init-first.diff: New patch by Thomas
Schwinge to fix building with gcc-4.1.
* patches/hurd-i386/local-argp-fno-strict-aliasing.diff: New patch by Thomas
Schwinge to fix run-time errors with gcc-4.1 built glibc.
* debian/sysdeps/hurd.mk (CC, BUILD_CC): Removed.
Modified: glibc-package/branches/glibc-2.5/debian/changelog
===================================================================
--- glibc-package/branches/glibc-2.5/debian/changelog 2007-07-04 16:48:06 UTC (rev 2392)
+++ glibc-package/branches/glibc-2.5/debian/changelog 2007-07-04 17:28:07 UTC (rev 2393)
@@ -5,6 +5,13 @@
some packages that use unsigned or size_t in ioctls.
Closes: 431365.
+ [ Michael Banck ]
+ * patches/hurd-i386/local-gcc-4.1-init-first.diff: New patch by Thomas
+ Schwinge to fix building with gcc-4.1.
+ * patches/hurd-i386/local-argp-fno-strict-aliasing.diff: New patch by Thomas
+ Schwinge to fix run-time errors with gcc-4.1 built glibc.
+ * debian/sysdeps/hurd.mk (CC, BUILD_CC): Removed.
+
-- Michael Banck <mbanck@debian.org> Wed, 4 Jul 2007 18:21:11 +0200
glibc (2.5-11) unstable; urgency=low
Added: glibc-package/branches/glibc-2.5/debian/patches/hurd-i386/local-argp-fno-strict-aliasing.diff
===================================================================
--- glibc-package/branches/glibc-2.5/debian/patches/hurd-i386/local-argp-fno-strict-aliasing.diff (rev 0)
+++ glibc-package/branches/glibc-2.5/debian/patches/hurd-i386/local-argp-fno-strict-aliasing.diff 2007-07-04 17:28:07 UTC (rev 2393)
@@ -0,0 +1,13 @@
+--- argp/Makefile~ 2004-03-28 16:15:30.000000000 +0200
++++ argp/Makefile 2007-01-29 21:54:59.000000000 +0100
+@@ -30,6 +30,7 @@
+
+ CFLAGS-argp-help.c = $(uses-callbacks) -fexceptions
+ CFLAGS-argp-parse.c = $(uses-callbacks)
+-CFLAGS-argp-fmtstream.c = -fexceptions
++# The following `-fno-strict-aliasing' is of course not a proper fix.
++CFLAGS-argp-fmtstream.c = -fexceptions -fno-strict-aliasing
+
+ include ../Rules
+
+
Added: glibc-package/branches/glibc-2.5/debian/patches/hurd-i386/local-gcc-4.1-init-first.diff
===================================================================
--- glibc-package/branches/glibc-2.5/debian/patches/hurd-i386/local-gcc-4.1-init-first.diff (rev 0)
+++ glibc-package/branches/glibc-2.5/debian/patches/hurd-i386/local-gcc-4.1-init-first.diff 2007-07-04 17:28:07 UTC (rev 2393)
@@ -0,0 +1,84 @@
+Index: sysdeps/mach/hurd/i386/init-first.c
+===================================================================
+RCS file: /cvs/glibc/libc/sysdeps/mach/hurd/i386/init-first.c,v
+retrieving revision 1.43.4.1
+diff -u -p -r1.43.4.1 init-first.c
+--- sysdeps/mach/hurd/i386/init-first.c 23 Oct 2005 01:00:09 -0000 1.43.4.1
++++ sysdeps/mach/hurd/i386/init-first.c 20 Nov 2006 11:05:47 -0000
+@@ -320,11 +320,11 @@ first_init (void)
+ stack set up just as the user will see it, so it can switch stacks. */
+
+ void
+-_dl_init_first (void)
++_dl_init_first (int argc, ...)
+ {
+ first_init ();
+
+- init ((int *) __builtin_frame_address (0) + 2);
++ init (&argc);
+ }
+ #endif
+
+@@ -351,23 +351,21 @@ strong_alias (posixland_init, __libc_ini
+ This poorly-named function is called by static-start.S,
+ which should not exist at all. */
+ void
+-_hurd_stack_setup (void)
++_hurd_stack_setup (volatile int argc, ...)
+ {
+- intptr_t caller = (intptr_t) __builtin_return_address (0);
+-
+ void doinit (intptr_t *data)
+ {
+ /* This function gets called with the argument data at TOS. */
+- void doinit1 (void)
++ void doinit1 (volatile int argc, ...)
+ {
+- init ((int *) __builtin_frame_address (0) + 2);
++ init ((int *) &argc);
+ }
+
+ /* Push the user return address after the argument data, and then
+ jump to `doinit1' (above), so it is as if __libc_init_first's
+ caller had called `doinit1' with the argument data already on the
+ stack. */
+- *--data = caller;
++ *--data = (&argc)[-1];
+ asm volatile ("movl %0, %%esp\n" /* Switch to new outermost stack. */
+ "movl $0, %%ebp\n" /* Clear outermost frame pointer. */
+ "jmp *%1" : : "r" (data), "r" (&doinit1) : "sp");
+@@ -376,7 +374,7 @@ _hurd_stack_setup (void)
+
+ first_init ();
+
+- _hurd_startup ((void **) __builtin_frame_address (0) + 2, &doinit);
++ _hurd_startup ((void **) &argc, &doinit);
+ }
+ #endif
+
+Index: sysdeps/mach/hurd/i386/init-first.c
+===================================================================
+RCS file: /cvs/glibc/libc/sysdeps/mach/hurd/i386/init-first.c,v
+retrieving revision 1.43.4.1
+diff -u -p -r1.43.4.1 init-first.c
+--- sysdeps/mach/hurd/i386/init-first.c 23 Oct 2005 01:00:09 -0000 1.43.4.1
++++ sysdeps/mach/hurd/i386/init-first.c 20 Nov 2006 11:05:47 -0000
+@@ -353,6 +355,8 @@
+ void
+ _hurd_stack_setup (volatile int argc, ...)
+ {
++ intptr_t caller = (&argc)[-1];
++
+ void doinit (intptr_t *data)
+ {
+ /* This function gets called with the argument data at TOS. */
+@@ -365,7 +369,7 @@
+ jump to `doinit1' (above), so it is as if __libc_init_first's
+ caller had called `doinit1' with the argument data already on the
+ stack. */
+- *--data = (&argc)[-1];
++ *--data = caller;
+ asm volatile ("movl %0, %%esp\n" /* Switch to new outermost stack. */
+ "movl $0, %%ebp\n" /* Clear outermost frame pointer. */
+ "jmp *%1" : : "r" (data), "r" (&doinit1) : "sp");
+
Modified: glibc-package/branches/glibc-2.5/debian/patches/series
===================================================================
--- glibc-package/branches/glibc-2.5/debian/patches/series 2007-07-04 16:48:06 UTC (rev 2392)
+++ glibc-package/branches/glibc-2.5/debian/patches/series 2007-07-04 17:28:07 UTC (rev 2393)
@@ -63,8 +63,10 @@
hurd-i386/cvs-futimes.diff -p1
hurd-i386/cvs-getsid.diff -p0
+hurd-i386/local-argp-fno-strict-aliasing.diff -p0
hurd-i386/local-dl-dynamic-weak.diff -p1
hurd-i386/local-enable-ldconfig.diff -p0
+hurd-i386/local-gcc-4.1-init-first.diff -p0
hurd-i386/local-mlock.diff -p1
hurd-i386/local-msg-nosignal.diff -p0
hurd-i386/local-sigsuspend-nocancel.diff -p0
Modified: glibc-package/branches/glibc-2.5/debian/sysdeps/hurd.mk
===================================================================
--- glibc-package/branches/glibc-2.5/debian/sysdeps/hurd.mk 2007-07-04 16:48:06 UTC (rev 2392)
+++ glibc-package/branches/glibc-2.5/debian/sysdeps/hurd.mk 2007-07-04 17:28:07 UTC (rev 2393)
@@ -21,10 +21,6 @@
# ld.so is broken currently if z_relro is used.
libc_extra_config_options := $(extra_config_options) --without-__thread --without-tls libc_cv_z_relro=no
-# Build with gcc-4.1 is not yet supported.
-CC = gcc-4.0
-BUILD_CC = gcc-4.0
-
# Only use libidn as add-on.
standard-add-ons = libidn
Reply to: