r942 - in glibc-package/trunk/debian: . patches
Author: gotom
Date: 2005-07-14 15:26:04 +0000 (Thu, 14 Jul 2005)
New Revision: 942
Added:
glibc-package/trunk/debian/patches/glibc235-gcc4-cvs.dpatch
glibc-package/trunk/debian/patches/glibc235-gcc4-elf.dpatch
glibc-package/trunk/debian/patches/glibc235-gcc4-jis0208.dpatch
Modified:
glibc-package/trunk/debian/changelog
glibc-package/trunk/debian/patches/00list
Log:
* Make glibc-2.3.5 buidable with gcc-4.0:
- debian/patches/glibc235-gcc4-cvs.dpatch: Added to compile with
gcc-4.0 pulled from upstream for some internal defintion and so on.
- debian/patches/glibc235-gcc4-elf.dpatch: Added to compile with
gcc-4.0 pulled from Dan Kagel cross-tools, remove elf_machine_rel*
definitions.
- debian/patches/glibc235-gcc4-jis0208.dpatch: Added to compile with
gcc-4.0 pulled from proposed fix in libc-hacker.
Modified: glibc-package/trunk/debian/changelog
===================================================================
--- glibc-package/trunk/debian/changelog 2005-07-14 15:23:33 UTC (rev 941)
+++ glibc-package/trunk/debian/changelog 2005-07-14 15:26:04 UTC (rev 942)
@@ -32,6 +32,15 @@
- debian/control: Updated.
- debian/sysdeps/i386.mk: Replace depreciated "-mcpu", use "-mtune".
+ * Make glibc-2.3.5 buidable with gcc-4.0:
+ - debian/patches/glibc235-gcc4-cvs.dpatch: Added to compile with
+ gcc-4.0 pulled from upstream for some internal defintion and so on.
+ - debian/patches/glibc235-gcc4-elf.dpatch: Added to compile with
+ gcc-4.0 pulled from Dan Kagel cross-tools, remove elf_machine_rel*
+ definitions.
+ - debian/patches/glibc235-gcc4-jis0208.dpatch: Added to compile with
+ gcc-4.0 pulled from proposed fix in libc-hacker.
+
* Move /etc/locale.alias to /usr/share/locale/locale.alias.
Don't install locale.alias.5. (Closes: #144670, #185991, #298784)
- debian/local/usr_sbin/locale-gen: Use /usr/share/locale/locale.alias
Modified: glibc-package/trunk/debian/patches/00list
===================================================================
--- glibc-package/trunk/debian/patches/00list 2005-07-14 15:23:33 UTC (rev 941)
+++ glibc-package/trunk/debian/patches/00list 2005-07-14 15:26:04 UTC (rev 942)
@@ -59,3 +59,6 @@
linuxthreads-sizefix
glibc232-tls-crashfix
glibc23-mips-lazy-eval
+glibc235-gcc4-cvs
+glibc235-gcc4-elf
+glibc235-gcc4-jis0208
Added: glibc-package/trunk/debian/patches/glibc235-gcc4-cvs.dpatch
===================================================================
--- glibc-package/trunk/debian/patches/glibc235-gcc4-cvs.dpatch 2005-07-14 15:23:33 UTC (rev 941)
+++ glibc-package/trunk/debian/patches/glibc235-gcc4-cvs.dpatch 2005-07-14 15:26:04 UTC (rev 942)
@@ -0,0 +1,204 @@
+#! /bin/sh -e
+
+# All lines beginning with `# DP:' are a description of the patch.
+# DP: Description: make glibc compile with gcc-4.0 pulled from upstream cvs.
+# DP: Related bugs:
+# DP: Dpatch author: GOTO Masanori <gotom@debian.org>
+# DP: Patch author: Richard Henderson <rth@redhat.com>,
+# DP: Upstream status: In CVS
+# DP: Status Details:
+# DP: Date: 2005-07-12
+
+PATCHLEVEL=0
+
+if [ $# -ne 2 ]; then
+ echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
+ exit 1
+fi
+case "$1" in
+ -patch) patch -d "$2" -f --no-backup-if-mismatch -p$PATCHLEVEL < $0;;
+ -unpatch) patch -d "$2" -f --no-backup-if-mismatch -R -p$PATCHLEVEL < $0;;
+ *)
+ echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
+ exit 1
+esac
+exit 0
+
+# append the patch here and adjust the -p? flag in the patch calls.
+2005-03-16 Richard Henderson <rth@redhat.com>
+
+ * include/libc-symbols.h (__hidden_proto): Remove bogus declaration
+ of internal.
+ (__hidden_def1, __hidden_dot_def1): Remove.
+ (__hidden_def2, __hidden_def3): Remove.
+ (__hidden_ver1): New.
+ (hidden_ver, hidden_def, hidden_weak): Use it.
+ (hidden_data_ver, hidden_data_ver, hidden_data_weak): Use non-data
+ version of the macro.
+
+ * include/wchar.h (__wcscoll): Remove.
+ * wcsmbs/wcscoll.c: Define wcscoll directly instead of via __wcscoll.
+ * string/strcoll.c: Don't issue libc_hidden_def STRCOLL redefined.
+
+Index: include/libc-symbols.h
+===================================================================
+RCS file: /cvs/glibc/libc/include/libc-symbols.h,v
+retrieving revision 1.70
+retrieving revision 1.71
+diff -u -p -r1.70 -r1.71
+--- include/libc-symbols.h 11 Feb 2005 00:29:46 -0000 1.70
++++ include/libc-symbols.h 17 Mar 2005 21:06:27 -0000 1.71
+@@ -583,78 +583,23 @@ for linking")
+ # define hidden_proto(name, attrs...) \
+ __hidden_proto (name, __GI_##name, ##attrs)
+ # define __hidden_proto(name, internal, attrs...) \
+- extern __typeof (name) internal; \
+ extern __typeof (name) name __asm__ (__hidden_asmname (#internal)) \
+ __hidden_proto_hiddenattr (attrs);
+ # define __hidden_asmname(name) \
+ __hidden_asmname1 (__USER_LABEL_PREFIX__, name)
+ # define __hidden_asmname1(prefix, name) __hidden_asmname2(prefix, name)
+ # define __hidden_asmname2(prefix, name) #prefix name
+-# ifdef HAVE_ASM_SET_DIRECTIVE
+-# define __hidden_def1(original, alias) \
+- ASM_GLOBAL_DIRECTIVE C_SYMBOL_NAME (alias) ASM_LINE_SEP \
+- .set C_SYMBOL_NAME (alias), C_SYMBOL_NAME (original)
+-# ifdef HAVE_ASM_GLOBAL_DOT_NAME
+-# define __hidden_dot_def1(original, alias) ASM_LINE_SEP \
+- ASM_GLOBAL_DIRECTIVE C_SYMBOL_DOT_NAME (alias) ASM_LINE_SEP \
+- .set C_SYMBOL_DOT_NAME (alias), C_SYMBOL_DOT_NAME (original)
+-# else
+-# define __hidden_dot_def1(original, alias)
+-# endif
+-# else
+-# define __hidden_def1(original, alias) \
+- ASM_GLOBAL_DIRECTIVE C_SYMBOL_NAME (alias) ASM_LINE_SEP \
+- C_SYMBOL_NAME (alias) = C_SYMBOL_NAME (original)
+-# ifdef HAVE_ASM_GLOBAL_DOT_NAME
+-# define __hidden_dot_def1(original, alias) ASM_LINE_SEP \
+- ASM_GLOBAL_DIRECTIVE C_SYMBOL_DOT_NAME (alias) ASM_LINE_SEP \
+- C_SYMBOL_DOT_NAME (alias) = C_SYMBOL_DOT_NAME (original)
+-# else
+-# define __hidden_dot_def1(original, alias)
+-# endif
+-# endif
+-# define __hidden_def2(...) #__VA_ARGS__
+-# define __hidden_def3(...) __hidden_def2 (__VA_ARGS__)
+-# define hidden_def(name) \
+- __asm__ (__hidden_def3 (__hidden_def1 (__GI_##name, name) \
+- __hidden_dot_def1 (__GI_##name, name)));
+-# define hidden_data_def(name) \
+- __asm__ (__hidden_def3 (__hidden_def1 (__GI_##name, name)));
+-# define hidden_ver(local, name) \
+- __asm__ (__hidden_def3 (__hidden_def1 (local, __GI_##name) \
+- __hidden_dot_def1 (local, __GI_##name)));
+-# define hidden_data_ver(local, name) \
+- __asm__ (__hidden_def3 (__hidden_def1 (local, __GI_##name)));
+-# ifdef HAVE_WEAK_SYMBOLS
+-# ifdef HAVE_ASM_WEAKEXT_DIRECTIVE
+-# define __hidden_weak1(original, alias) \
+- .weakext C_SYMBOL_NAME (alias), C_SYMBOL_NAME (original)
+-# ifdef HAVE_ASM_GLOBAL_DOT_NAME
+-# define __hidden_dot_weak1(original, alias) ASM_LINE_SEP \
+- .weakext C_SYMBOL_DOT_NAME (alias), C_SYMBOL_DOT_NAME (original)
+-# else
+-# define __hidden_dot_weak1(original, alias)
+-# endif
+-# else /* ! HAVE_ASM_WEAKEXT_DIRECTIVE */
+-# define __hidden_weak1(original, alias) \
+- .weak C_SYMBOL_NAME (alias) ASM_LINE_SEP \
+- C_SYMBOL_NAME (alias) = C_SYMBOL_NAME (original)
+-# ifdef HAVE_ASM_GLOBAL_DOT_NAME
+-# define __hidden_dot_weak1(original, alias) ASM_LINE_SEP \
+- .weak C_SYMBOL_DOT_NAME (alias) ASM_LINE_SEP \
+- C_SYMBOL_DOT_NAME (alias) = C_SYMBOL_DOT_NAME (original)
+-# else
+-# define __hidden_dot_weak1(original, alias)
+-# endif
+-# endif
+-# define hidden_weak(name) \
+- __asm__ (__hidden_def3 (__hidden_weak1 (__GI_##name, name) \
+- __hidden_dot_weak1 (__GI_##name, name)));
+-# define hidden_data_weak(name) \
+- __asm__ (__hidden_def3 (__hidden_weak1 (__GI_##name, name)));
+-# else
+-# define hidden_weak(name) hidden_def (name)
+-# endif
++# define __hidden_ver1(local, internal, name) \
++ extern __typeof (name) __EI_##name __asm__(__hidden_asmname (#internal)); \
++ extern __typeof (name) __EI_##name \
++ __attribute__((alias (__hidden_asmname (#local))))
++# define hidden_ver(local, name) __hidden_ver1(local, __GI_##name, name);
++# define hidden_data_ver(local, name) hidden_ver(local, name)
++# define hidden_def(name) __hidden_ver1(__GI_##name, name, name);
++# define hidden_data_def(name) hidden_def(name)
++# define hidden_weak(name) \
++ __hidden_ver1(__GI_##name, name, name) __attribute__((weak));
++# define hidden_data_weak(name) hidden_weak(name)
+ # else
+ /* For assembly, we need to do the opposite of what we do in C:
+ in assembly gcc __REDIRECT stuff is not in place, so functions
+Index: include/wchar.h
+===================================================================
+RCS file: /cvs/glibc/libc/include/wchar.h,v
+retrieving revision 1.26
+retrieving revision 1.27
+diff -u -p -r1.26 -r1.27
+--- include/wchar.h 14 Mar 2004 20:45:10 -0000 1.26
++++ include/wchar.h 17 Mar 2005 21:06:24 -0000 1.27
+@@ -56,7 +56,6 @@ extern int __wcscasecmp (__const wchar_t
+ extern int __wcsncasecmp (__const wchar_t *__s1, __const wchar_t *__s2,
+ size_t __n)
+ __attribute_pure__;
+-extern int __wcscoll (__const wchar_t *__s1, __const wchar_t *__s2);
+ extern size_t __wcslen (__const wchar_t *__s) __attribute_pure__;
+ extern size_t __wcsnlen (__const wchar_t *__s, size_t __maxlen)
+ __attribute_pure__;
+Index: wcsmbs/wcscoll.c
+===================================================================
+RCS file: /cvs/glibc/libc/wcsmbs/wcscoll.c,v
+retrieving revision 1.13
+retrieving revision 1.14
+diff -u -p -r1.13 -r1.14
+--- wcsmbs/wcscoll.c 14 Mar 2004 21:05:48 -0000 1.13
++++ wcsmbs/wcscoll.c 17 Mar 2005 21:06:24 -0000 1.14
+@@ -22,12 +22,11 @@
+
+ #define STRING_TYPE wchar_t
+ #define USTRING_TYPE wint_t
+-#define STRCOLL __wcscoll
++#define STRCOLL wcscoll
+ #define STRCOLL_L __wcscoll_l
+
+ #include "../string/strcoll.c"
+
+ #ifndef USE_IN_EXTENDED_LOCALE_MODEL
+-weak_alias (__wcscoll, wcscoll)
+ libc_hidden_weak (wcscoll)
+ #endif
+Index: string/strcoll.c
+===================================================================
+RCS file: /cvs/glibc/libc/string/strcoll.c,v
+retrieving revision 1.33
+retrieving revision 1.34
+diff -u -p -r1.33 -r1.34
+--- string/strcoll.c 14 Mar 2004 20:51:30 -0000 1.33
++++ string/strcoll.c 17 Mar 2005 21:06:24 -0000 1.34
+@@ -23,6 +23,7 @@
+ # define STRING_TYPE char
+ # define STRCOLL strcoll
+ # define STRCOLL_L __strcoll_l
++# define USE_HIDDEN_DEF
+ #endif
+
+ #include "../locale/localeinfo.h"
+@@ -35,6 +36,7 @@ STRCOLL (s1, s2)
+ {
+ return STRCOLL_L (s1, s2, _NL_CURRENT_LOCALE);
+ }
+-#if !defined WIDE_CHAR_VERSION
+-libc_hidden_def (strcoll)
++
++#ifdef USE_HIDDEN_DEF
++libc_hidden_def (STRCOLL)
+ #endif
Added: glibc-package/trunk/debian/patches/glibc235-gcc4-elf.dpatch
===================================================================
--- glibc-package/trunk/debian/patches/glibc235-gcc4-elf.dpatch 2005-07-14 15:23:33 UTC (rev 941)
+++ glibc-package/trunk/debian/patches/glibc235-gcc4-elf.dpatch 2005-07-14 15:26:04 UTC (rev 942)
@@ -0,0 +1,75 @@
+#! /bin/sh -e
+
+# All lines beginning with `# DP:' are a description of the patch.
+# DP: Description: Remove definition elf_machine_rel* to compile with gcc-4.0.
+# DP: Related bugs:
+# DP: Dpatch author: GOTO Masanori <gotom@debian.org>
+# DP: Patch author: Dan Kagel
+# DP: Upstream status: Debian-Specific
+# DP: Status Details:
+# DP: Date: 2005-07-12
+
+PATCHLEVEL=1
+
+if [ $# -ne 2 ]; then
+ echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
+ exit 1
+fi
+case "$1" in
+ -patch) patch -d "$2" -f --no-backup-if-mismatch -p$PATCHLEVEL < $0;;
+ -unpatch) patch -d "$2" -f --no-backup-if-mismatch -R -p$PATCHLEVEL < $0;;
+ *)
+ echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
+ exit 1
+esac
+exit 0
+
+# append the patch here and adjust the -p? flag in the patch calls.
+http://kegel.com/crosstool/crosstool-0.35/patches/glibc-2.3.4/glibc-2.3.4-allow-gcc-4.0-elf.patch
+
+--- glibc-2.3-20050307/elf/dynamic-link.h.old 2005-03-12 18:12:37.000000000 -0800
++++ glibc-2.3-20050307/elf/dynamic-link.h 2005-03-12 18:12:59.777820848 -0800
+@@ -19,43 +19,6 @@
+
+ #include <elf.h>
+ #include <assert.h>
+-
+-#ifdef RESOLVE
+-/* We pass reloc_addr as a pointer to void, as opposed to a pointer to
+- ElfW(Addr), because not all architectures can assume that the
+- relocated address is properly aligned, whereas the compiler is
+- entitled to assume that a pointer to a type is properly aligned for
+- the type. Even if we cast the pointer back to some other type with
+- less strict alignment requirements, the compiler might still
+- remember that the pointer was originally more aligned, thereby
+- optimizing away alignment tests or using word instructions for
+- copying memory, breaking the very code written to handle the
+- unaligned cases. */
+-auto void __attribute__((always_inline))
+-elf_machine_rel (struct link_map *map, const ElfW(Rel) *reloc,
+- const ElfW(Sym) *sym, const struct r_found_version *version,
+- void *const reloc_addr);
+-auto void __attribute__((always_inline))
+-elf_machine_rela (struct link_map *map, const ElfW(Rela) *reloc,
+- const ElfW(Sym) *sym, const struct r_found_version *version,
+- void *const reloc_addr);
+-auto void __attribute__((always_inline))
+-elf_machine_rel_relative (ElfW(Addr) l_addr, const ElfW(Rel) *reloc,
+- void *const reloc_addr);
+-auto void __attribute__((always_inline))
+-elf_machine_rela_relative (ElfW(Addr) l_addr, const ElfW(Rela) *reloc,
+- void *const reloc_addr);
+-# if ELF_MACHINE_NO_RELA || defined ELF_MACHINE_PLT_REL
+-auto void __attribute__((always_inline))
+-elf_machine_lazy_rel (struct link_map *map,
+- ElfW(Addr) l_addr, const ElfW(Rel) *reloc);
+-# else
+-auto void __attribute__((always_inline))
+-elf_machine_lazy_rel (struct link_map *map,
+- ElfW(Addr) l_addr, const ElfW(Rela) *reloc);
+-# endif
+-#endif
+-
+ #include <dl-machine.h>
+
+ #ifndef VERSYMIDX
Added: glibc-package/trunk/debian/patches/glibc235-gcc4-jis0208.dpatch
===================================================================
--- glibc-package/trunk/debian/patches/glibc235-gcc4-jis0208.dpatch 2005-07-14 15:23:33 UTC (rev 941)
+++ glibc-package/trunk/debian/patches/glibc235-gcc4-jis0208.dpatch 2005-07-14 15:26:04 UTC (rev 942)
@@ -0,0 +1,64 @@
+#! /bin/sh -e
+
+# All lines beginning with `# DP:' are a description of the patch.
+# DP: Description: Make glibc-2.3.5 compile with gcc-4.0.
+# DP: Related bugs:
+# DP: Dpatch author: GOTO Masanori <gotom@debian.org>
+# DP: Patch author: Alexandre Oliva <aoliva@redhat.com>
+# DP: Upstream status: Debian-Specific
+# DP: Status Details:
+# DP: Date: 2005-07-12
+
+PATCHLEVEL=0
+
+if [ $# -ne 2 ]; then
+ echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
+ exit 1
+fi
+case "$1" in
+ -patch) patch -d "$2" -f --no-backup-if-mismatch -p$PATCHLEVEL < $0;;
+ -unpatch) patch -d "$2" -f --no-backup-if-mismatch -R -p$PATCHLEVEL < $0;;
+ *)
+ echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
+ exit 1
+esac
+exit 0
+
+# append the patch here and adjust the -p? flag in the patch calls.
+http://sources.redhat.com/ml/libc-hacker/2005-02/msg00000.html
+
+2005-02-02 Alexandre Oliva <aoliva@redhat.com>
+
+ * iconvdata/jis0208.h (struct jisx0208_ucs_idx): Move declaration
+ before use. Fix typo in comment.
+
+Index: iconvdata/jis0208.h
+--- iconvdata/jis0208.h 2003-06-11 18:40:42.000000000 -0300
++++ iconvdata/jis0208.h 2005-02-02 05:57:39.000000000 -0200
+@@ -27,13 +27,7 @@
+ /* Conversion table. */
+ extern const uint16_t __jis0208_to_ucs[];
+
+-extern const char __jisx0208_from_ucs4_lat1[256][2];
+-extern const char __jisx0208_from_ucs4_greek[0xc1][2];
+-extern const struct jisx0208_ucs_idx __jisx0208_from_ucs_idx[];
+-extern const char __jisx0208_from_ucs_tab[][2];
+-
+-
+-/* Struct for table with indeces in UCS mapping table. */
++/* Struct for table with indexes in UCS mapping table. */
+ struct jisx0208_ucs_idx
+ {
+ uint16_t start;
+@@ -41,6 +35,11 @@
+ uint16_t idx;
+ };
+
++extern const char __jisx0208_from_ucs4_lat1[256][2];
++extern const char __jisx0208_from_ucs4_greek[0xc1][2];
++extern const struct jisx0208_ucs_idx __jisx0208_from_ucs_idx[];
++extern const char __jisx0208_from_ucs_tab[][2];
++
+
+ static inline uint32_t
+ __attribute ((always_inline))
Reply to: