summaryrefslogtreecommitdiff
path: root/packages/glibc
diff options
context:
space:
mode:
authorAlexey Neyman <stilor@att.net>2017-12-02 20:44:39 (GMT)
committerAlexey Neyman <stilor@att.net>2017-12-02 20:44:39 (GMT)
commit98bc4decdeab1361bdc585c86591718fb08c8ffb (patch)
tree4e048ed57988306696efa3c5b81a80d48030e913 /packages/glibc
parent2a1935f3ad41d360dd3d96a1b0486083293651dd (diff)
Run all patches through renumbering and update
Signed-off-by: Alexey Neyman <stilor@att.net>
Diffstat (limited to 'packages/glibc')
-rw-r--r--packages/glibc/2.12.1/0000-respect-env-CPPFLAGS.patch (renamed from packages/glibc/2.12.1/100-respect-env-CPPFLAGS.patch)15
-rw-r--r--packages/glibc/2.12.1/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch (renamed from packages/glibc/2.13/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch)31
-rw-r--r--packages/glibc/2.12.1/0002-fix-signed-shift-overlow.patch (renamed from packages/glibc/2.13/102-fix-signed-shift-overlow.patch)23
-rw-r--r--packages/glibc/2.12.1/0003-unused-variables.patch (renamed from packages/glibc/2.13/104-unused-variables.patch)62
-rw-r--r--packages/glibc/2.12.1/0004-misleading-indentation.patch (renamed from packages/glibc/2.14.1/105-misleading-indentation.patch)8
-rw-r--r--packages/glibc/2.12.1/0005-dl-open-array-bounds.patch (renamed from packages/glibc/2.14.1/106-dl-open-array-bounds.patch)8
-rw-r--r--packages/glibc/2.12.1/0006-i386-x86_64-revert-clone-cfi.patch (renamed from packages/glibc/2.16.0/120-i386-x86_64-revert-clone-cfi.patch)20
-rw-r--r--packages/glibc/2.12.1/0007-disable-ldconfig.patch (renamed from packages/glibc/2.13/140-disable-ldconfig.patch)9
-rw-r--r--packages/glibc/2.12.1/0008-Fix-combreloc-test-BSD-grep.patch (renamed from packages/glibc/2.12.1/140-Fix-combreloc-test-BSD-grep.patch)21
-rw-r--r--packages/glibc/2.12.1/0009-queue-header-updates.patch (renamed from packages/glibc/2.13/150-queue-header-updates.patch)9
-rw-r--r--packages/glibc/2.12.1/0010-manual-no-perl.patch (renamed from packages/glibc/2.13/160-manual-no-perl.patch)9
-rw-r--r--packages/glibc/2.12.1/0011-localedef-fix-trampoline.patch (renamed from packages/glibc/2.14.1/170-localedef-fix-trampoline.patch)9
-rw-r--r--packages/glibc/2.12.1/0012-resolv-dynamic.patch (renamed from packages/glibc/2.14.1/180-resolv-dynamic.patch)9
-rw-r--r--packages/glibc/2.12.1/0013-localedef-mmap.patch (renamed from packages/glibc/2.14.1/190-localedef-mmap.patch)9
-rw-r--r--packages/glibc/2.12.1/0014-fadvise64_64.patch (renamed from packages/glibc/2.13/200-fadvise64_64.patch)5
-rw-r--r--packages/glibc/2.12.1/0015-section-comments.patch (renamed from packages/glibc/2.13/220-section-comments.patch)9
-rw-r--r--packages/glibc/2.12.1/0016-no-inline-gmon.patch (renamed from packages/glibc/2.15/230-no-inline-gmon.patch)10
-rw-r--r--packages/glibc/2.12.1/0017-check_native-headers.patch (renamed from packages/glibc/2.13/240-check_native-headers.patch)9
-rw-r--r--packages/glibc/2.12.1/0018-fix-pr631.patch (renamed from packages/glibc/2.13/250-fix-pr631.patch)15
-rw-r--r--packages/glibc/2.12.1/0019-assume-pipe2.patch (renamed from packages/glibc/2.14.1/260-assume-pipe2.patch)9
-rw-r--r--packages/glibc/2.12.1/0020-china.patch (renamed from packages/glibc/2.14.1/270-china.patch)9
-rw-r--r--packages/glibc/2.12.1/0021-new-valencian-locale.patch (renamed from packages/glibc/2.14.1/280-new-valencian-locale.patch)15
-rw-r--r--packages/glibc/2.12.1/0022-macos-cross-rpcgen.patch (renamed from packages/glibc/2.13/300-macos-cross-rpcgen.patch)8
-rw-r--r--packages/glibc/2.12.1/0023-nscd-one-fork.patch (renamed from packages/glibc/2.13/300-nscd-one-fork.patch)9
-rw-r--r--packages/glibc/2.12.1/0024-hppa-nptl-carlos.patch (renamed from packages/glibc/2.12.1/310-hppa-nptl-carlos.patch)45
-rw-r--r--packages/glibc/2.12.1/0025-dl_execstack-PaX-support.patch (renamed from packages/glibc/2.16.0/340-dl_execstack-PaX-support.patch)15
-rw-r--r--packages/glibc/2.12.1/0026-pre20040117-pt_pax.patch (renamed from packages/glibc/2.14.1/350-pre20040117-pt_pax.patch)9
-rw-r--r--packages/glibc/2.12.1/0027-tests-sandbox-libdl-paths.patch (renamed from packages/glibc/2.14.1/360-tests-sandbox-libdl-paths.patch)75
-rw-r--r--packages/glibc/2.12.1/0028-fnmatch.patch (renamed from packages/glibc/2.12.1/370-fnmatch.patch)10
-rw-r--r--packages/glibc/2.12.1/0029-dont-build-timezone.patch (renamed from packages/glibc/2.13/380-dont-build-timezone.patch)9
-rw-r--r--packages/glibc/2.12.1/0030-alpha-xstat.patch (renamed from packages/glibc/2.13/400-alpha-xstat.patch)9
-rw-r--r--packages/glibc/2.12.1/0031-alpha-creat.patch17
-rw-r--r--packages/glibc/2.12.1/0032-alpha_alpha-add-fdatasync-support.patch (renamed from packages/glibc/2.12.1/490-alpha_alpha-add-fdatasync-support.patch)20
-rw-r--r--packages/glibc/2.12.1/0033-ppc-atomic.patch (renamed from packages/glibc/2.13/560-ppc-atomic.patch)25
-rw-r--r--packages/glibc/2.12.1/0034-mips_shn_undef-hack.patch (renamed from packages/glibc/2.14.1/630-mips_shn_undef-hack.patch)11
-rw-r--r--packages/glibc/2.12.1/0035-alpha-atfcts.patch (renamed from packages/glibc/2.14.1/640-alpha-atfcts.patch)8
-rw-r--r--packages/glibc/2.12.1/0036-syslog.patch (renamed from packages/glibc/2.14.1/650-syslog.patch)9
-rw-r--r--packages/glibc/2.12.1/0037-debug-readlink_chk-readklinkat_chk.patch27
-rw-r--r--packages/glibc/2.12.1/0038-march-i686.patch (renamed from packages/glibc/2.12.2/900-march-i686.patch)15
-rw-r--r--packages/glibc/2.12.1/0039-typedef-caddr.patch (renamed from packages/glibc/2.12.2/910-typedef-caddr.patch)17
-rw-r--r--packages/glibc/2.12.1/0040-fix-rpc_parse-format.patch (renamed from packages/glibc/2.13/920-fix-rpc_parse-format.patch)8
-rw-r--r--packages/glibc/2.12.1/0041-make-382.patch (renamed from packages/glibc/2.12.1/920-make-382.patch)10
-rw-r--r--packages/glibc/2.12.1/0042-nis-bogus-conditional.patch (renamed from packages/glibc/2.12.1/940-nis-bogus-conditional.patch)8
-rw-r--r--packages/glibc/2.12.1/0043-obstack-common.patch (renamed from packages/glibc/2.13/998-obstack-common.patch)8
-rw-r--r--packages/glibc/2.12.1/0044-new-tools.patch (renamed from packages/glibc/2.12.1/999-new-tools.patch)27
-rw-r--r--packages/glibc/2.12.1/120-i386-x86_64-revert-clone-cfi.patch55
-rw-r--r--packages/glibc/2.12.1/140-disable-ldconfig.patch16
-rw-r--r--packages/glibc/2.12.1/150-queue-header-updates.patch85
-rw-r--r--packages/glibc/2.12.1/170-localedef-fix-trampoline.patch53
-rw-r--r--packages/glibc/2.12.1/180-resolv-dynamic.patch39
-rw-r--r--packages/glibc/2.12.1/200-fadvise64_64.patch28
-rw-r--r--packages/glibc/2.12.1/270-china.patch32
-rw-r--r--packages/glibc/2.12.1/280-new-valencian-locale.patch115
-rw-r--r--packages/glibc/2.12.1/340-dl_execstack-PaX-support.patch66
-rw-r--r--packages/glibc/2.12.1/350-pre20040117-pt_pax.patch32
-rw-r--r--packages/glibc/2.12.1/360-tests-sandbox-libdl-paths.patch193
-rw-r--r--packages/glibc/2.12.1/380-dont-build-timezone.patch14
-rw-r--r--packages/glibc/2.12.1/400-alpha-xstat.patch15
-rw-r--r--packages/glibc/2.12.1/430-alpha-creat.patch14
-rw-r--r--packages/glibc/2.12.1/560-ppc-atomic.patch415
-rw-r--r--packages/glibc/2.12.1/630-mips_shn_undef-hack.patch16
-rw-r--r--packages/glibc/2.12.1/660-debug-readlink_chk-readklinkat_chk.patch24
-rw-r--r--packages/glibc/2.12.1/910-typedef-caddr.patch28
-rw-r--r--packages/glibc/2.12.2/0000-Fix-combreloc-test-BSD-grep.patch (renamed from packages/glibc/2.12.2/140-Fix-combreloc-test-BSD-grep.patch)21
-rw-r--r--packages/glibc/2.12.2/0001-macos-cross-rpcgen.patch (renamed from packages/glibc/2.14.1/300-macos-cross-rpcgen.patch)8
-rw-r--r--packages/glibc/2.12.2/0002-march-i686.patch (renamed from packages/glibc/2.12.1/900-march-i686.patch)15
-rw-r--r--packages/glibc/2.12.2/0003-typedef-caddr.patch (renamed from packages/glibc/2.13/910-typedef-caddr.patch)17
-rw-r--r--packages/glibc/2.12.2/0004-fix-rpc_parse-format.patch (renamed from packages/glibc/2.14.1/920-fix-rpc_parse-format.patch)8
-rw-r--r--packages/glibc/2.12.2/0005-nis-bogus-conditional.patch (renamed from packages/glibc/2.12.2/940-nis-bogus-conditional.patch)8
-rw-r--r--packages/glibc/2.12.2/0006-obstack-common.patch (renamed from packages/glibc/2.14.1/998-obstack-common.patch)8
-rw-r--r--packages/glibc/2.12.2/0007-new-tools.patch (renamed from packages/glibc/2.12.2/999-new-tools.patch)27
-rw-r--r--packages/glibc/2.13/0000-respect-env-CPPFLAGS.patch (renamed from packages/glibc/2.13/100-respect-env-CPPFLAGS.patch)9
-rw-r--r--packages/glibc/2.13/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch (renamed from packages/glibc/2.12.1/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch)31
-rw-r--r--packages/glibc/2.13/0002-fix-signed-shift-overlow.patch (renamed from packages/glibc/2.14.1/102-fix-signed-shift-overlow.patch)23
-rw-r--r--packages/glibc/2.13/0003-unused-variables.patch (renamed from packages/glibc/2.14.1/104-unused-variables.patch)62
-rw-r--r--packages/glibc/2.13/0004-misleading-indentation.patch (renamed from packages/glibc/2.12.1/105-misleading-indentation.patch)8
-rw-r--r--packages/glibc/2.13/0005-dl-open-array-bounds.patch (renamed from packages/glibc/2.13/106-dl-open-array-bounds.patch)8
-rw-r--r--packages/glibc/2.13/0006-i386-x86_64-revert-clone-cfi.patch (renamed from packages/glibc/2.13/120-i386-x86_64-revert-clone-cfi.patch)20
-rw-r--r--packages/glibc/2.13/0007-disable-ldconfig.patch (renamed from packages/glibc/2.15/140-disable-ldconfig.patch)9
-rw-r--r--packages/glibc/2.13/0008-Fix-combreloc-test-BSD-grep.patch (renamed from packages/glibc/2.13/140-Fix-combreloc-test-BSD-grep.patch)21
-rw-r--r--packages/glibc/2.13/0009-queue-header-updates.patch (renamed from packages/glibc/2.14.1/150-queue-header-updates.patch)9
-rw-r--r--packages/glibc/2.13/0010-manual-no-perl.patch (renamed from packages/glibc/2.14.1/160-manual-no-perl.patch)9
-rw-r--r--packages/glibc/2.13/0011-localedef-fix-trampoline.patch (renamed from packages/glibc/2.13/170-localedef-fix-trampoline.patch)9
-rw-r--r--packages/glibc/2.13/0012-resolv-dynamic.patch (renamed from packages/glibc/2.13/180-resolv-dynamic.patch)9
-rw-r--r--packages/glibc/2.13/0013-localedef-mmap.patch (renamed from packages/glibc/2.13/190-localedef-mmap.patch)9
-rw-r--r--packages/glibc/2.13/0014-fadvise64_64.patch (renamed from packages/glibc/2.14.1/200-fadvise64_64.patch)5
-rw-r--r--packages/glibc/2.13/0015-section-comments.patch (renamed from packages/glibc/2.14.1/220-section-comments.patch)9
-rw-r--r--packages/glibc/2.13/0016-no-inline-gmon.patch (renamed from packages/glibc/2.14.1/230-no-inline-gmon.patch)10
-rw-r--r--packages/glibc/2.13/0017-check_native-headers.patch (renamed from packages/glibc/2.12.1/240-check_native-headers.patch)9
-rw-r--r--packages/glibc/2.13/0018-fix-pr631.patch (renamed from packages/glibc/2.12.1/250-fix-pr631.patch)15
-rw-r--r--packages/glibc/2.13/0019-assume-pipe2.patch (renamed from packages/glibc/2.15/260-assume-pipe2.patch)9
-rw-r--r--packages/glibc/2.13/0020-china.patch (renamed from packages/glibc/2.13/270-china.patch)9
-rw-r--r--packages/glibc/2.13/0021-new-valencian-locale.patch (renamed from packages/glibc/2.13/280-new-valencian-locale.patch)15
-rw-r--r--packages/glibc/2.13/0022-macos-cross-rpcgen.patch (renamed from packages/glibc/2.12.2/300-macos-cross-rpcgen.patch)8
-rw-r--r--packages/glibc/2.13/0023-nscd-one-fork.patch (renamed from packages/glibc/2.14.1/300-nscd-one-fork.patch)9
-rw-r--r--packages/glibc/2.13/0024-hppa-nptl-carlos.patch (renamed from packages/glibc/2.15/310-hppa-nptl-carlos.patch)45
-rw-r--r--packages/glibc/2.13/0025-dl_execstack-PaX-support.patch (renamed from packages/glibc/2.13/340-dl_execstack-PaX-support.patch)15
-rw-r--r--packages/glibc/2.13/0026-pre20040117-pt_pax.patch (renamed from packages/glibc/2.15/350-pre20040117-pt_pax.patch)9
-rw-r--r--packages/glibc/2.13/0027-tests-sandbox-libdl-paths.patch (renamed from packages/glibc/2.16.0/360-tests-sandbox-libdl-paths.patch)75
-rw-r--r--packages/glibc/2.13/0028-dont-build-timezone.patch (renamed from packages/glibc/2.14.1/380-dont-build-timezone.patch)9
-rw-r--r--packages/glibc/2.13/0029-alpha-xstat.patch (renamed from packages/glibc/2.14.1/400-alpha-xstat.patch)9
-rw-r--r--packages/glibc/2.13/0030-alpha-creat.patch17
-rw-r--r--packages/glibc/2.13/0031-alpha_alpha-add-fdatasync-support.patch (renamed from packages/glibc/2.14.1/490-alpha_alpha-add-fdatasync-support.patch)20
-rw-r--r--packages/glibc/2.13/0032-ppc-atomic.patch (renamed from packages/glibc/2.15/560-ppc-atomic.patch)25
-rw-r--r--packages/glibc/2.13/0033-mips_shn_undef-hack.patch (renamed from packages/glibc/2.13/630-mips_shn_undef-hack.patch)11
-rw-r--r--packages/glibc/2.13/0034-alpha-atfcts.patch (renamed from packages/glibc/2.15/640-alpha-atfcts.patch)8
-rw-r--r--packages/glibc/2.13/0035-syslog.patch (renamed from packages/glibc/2.13/650-syslog.patch)9
-rw-r--r--packages/glibc/2.13/0036-debug-readlink_chk-readklinkat_chk.patch27
-rw-r--r--packages/glibc/2.13/0037-march-i686.patch (renamed from packages/glibc/2.13/900-march-i686.patch)15
-rw-r--r--packages/glibc/2.13/0038-typedef-caddr.patch (renamed from packages/glibc/2.19/910-typedef-caddr.patch)17
-rw-r--r--packages/glibc/2.13/0039-fix-rpc_parse-format.patch (renamed from packages/glibc/2.12.2/920-fix-rpc_parse-format.patch)8
-rw-r--r--packages/glibc/2.13/0040-nis-bogus-conditional.patch (renamed from packages/glibc/2.13/940-nis-bogus-conditional.patch)8
-rw-r--r--packages/glibc/2.13/0041-initfini-ppc64.patch (renamed from packages/glibc/2.13/950-initfini-ppc64.patch)10
-rw-r--r--packages/glibc/2.13/0042-obstack-common.patch (renamed from packages/glibc/2.12.1/998-obstack-common.patch)8
-rw-r--r--packages/glibc/2.13/0043-new-tools.patch (renamed from packages/glibc/2.13/999-new-tools.patch)27
-rw-r--r--packages/glibc/2.13/430-alpha-creat.patch14
-rw-r--r--packages/glibc/2.13/660-debug-readlink_chk-readklinkat_chk.patch24
-rw-r--r--packages/glibc/2.14.1/0000-respect-env-CPPFLAGS.patch (renamed from packages/glibc/2.14.1/100-respect-env-CPPFLAGS.patch)11
-rw-r--r--packages/glibc/2.14.1/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch (renamed from packages/glibc/2.14.1/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch)31
-rw-r--r--packages/glibc/2.14.1/0002-fix-signed-shift-overlow.patch (renamed from packages/glibc/2.12.1/102-fix-signed-shift-overlow.patch)23
-rw-r--r--packages/glibc/2.14.1/0003-dl-openat64-variadic.patch197
-rw-r--r--packages/glibc/2.14.1/0004-unused-variables.patch (renamed from packages/glibc/2.12.1/104-unused-variables.patch)62
-rw-r--r--packages/glibc/2.14.1/0005-misleading-indentation.patch (renamed from packages/glibc/2.15/105-misleading-indentation.patch)8
-rw-r--r--packages/glibc/2.14.1/0006-dl-open-array-bounds.patch (renamed from packages/glibc/2.15/106-dl-open-array-bounds.patch)8
-rw-r--r--packages/glibc/2.14.1/0007-i386-x86_64-revert-clone-cfi.patch (renamed from packages/glibc/2.15/120-i386-x86_64-revert-clone-cfi.patch)20
-rw-r--r--packages/glibc/2.14.1/0008-disable-ldconfig.patch (renamed from packages/glibc/2.16.0/140-disable-ldconfig.patch)9
-rw-r--r--packages/glibc/2.14.1/0009-Fix-combreloc-test-BSD-grep.patch (renamed from packages/glibc/2.14.1/140-Fix-combreloc-test-BSD-grep.patch)21
-rw-r--r--packages/glibc/2.14.1/0010-queue-header-updates.patch (renamed from packages/glibc/2.15/150-queue-header-updates.patch)9
-rw-r--r--packages/glibc/2.14.1/0011-manual-no-perl.patch (renamed from packages/glibc/2.15/160-manual-no-perl.patch)11
-rw-r--r--packages/glibc/2.14.1/0012-localedef-fix-trampoline.patch (renamed from packages/glibc/2.15/170-localedef-fix-trampoline.patch)9
-rw-r--r--packages/glibc/2.14.1/0013-resolv-dynamic.patch (renamed from packages/glibc/2.16.0/180-resolv-dynamic.patch)9
-rw-r--r--packages/glibc/2.14.1/0014-localedef-mmap.patch (renamed from packages/glibc/2.12.1/190-localedef-mmap.patch)9
-rw-r--r--packages/glibc/2.14.1/0015-fadvise64_64.patch (renamed from packages/glibc/2.16.0/200-fadvise64_64.patch)5
-rw-r--r--packages/glibc/2.14.1/0016-section-comments.patch (renamed from packages/glibc/2.15/220-section-comments.patch)11
-rw-r--r--packages/glibc/2.14.1/0017-no-inline-gmon.patch (renamed from packages/glibc/2.13/230-no-inline-gmon.patch)10
-rw-r--r--packages/glibc/2.14.1/0018-assume-pipe2.patch (renamed from packages/glibc/2.13/260-assume-pipe2.patch)9
-rw-r--r--packages/glibc/2.14.1/0019-china.patch (renamed from packages/glibc/2.15/270-china.patch)9
-rw-r--r--packages/glibc/2.14.1/0020-new-valencian-locale.patch (renamed from packages/glibc/2.15/280-new-valencian-locale.patch)17
-rw-r--r--packages/glibc/2.14.1/0021-macos-cross-rpcgen.patch (renamed from packages/glibc/2.12.1/300-macos-cross-rpcgen.patch)8
-rw-r--r--packages/glibc/2.14.1/0022-nscd-one-fork.patch (renamed from packages/glibc/2.15/300-nscd-one-fork.patch)9
-rw-r--r--packages/glibc/2.14.1/0023-hppa-nptl-carlos.patch (renamed from packages/glibc/2.13/310-hppa-nptl-carlos.patch)47
-rw-r--r--packages/glibc/2.14.1/0024-dl_execstack-PaX-support.patch (renamed from packages/glibc/2.14.1/340-dl_execstack-PaX-support.patch)17
-rw-r--r--packages/glibc/2.14.1/0025-pre20040117-pt_pax.patch (renamed from packages/glibc/2.16.0/350-pre20040117-pt_pax.patch)9
-rw-r--r--packages/glibc/2.14.1/0026-tests-sandbox-libdl-paths.patch (renamed from packages/glibc/2.13/360-tests-sandbox-libdl-paths.patch)75
-rw-r--r--packages/glibc/2.14.1/0027-dont-build-timezone.patch (renamed from packages/glibc/2.16.0/380-dont-build-timezone.patch)11
-rw-r--r--packages/glibc/2.14.1/0028-alpha-xstat.patch (renamed from packages/glibc/2.16.0/400-alpha-xstat.patch)9
-rw-r--r--packages/glibc/2.14.1/0029-alpha-creat.patch17
-rw-r--r--packages/glibc/2.14.1/0030-alpha_alpha-add-fdatasync-support.patch (renamed from packages/glibc/2.13/490-alpha_alpha-add-fdatasync-support.patch)24
-rw-r--r--packages/glibc/2.14.1/0031-ppc-atomic.patch (renamed from packages/glibc/2.16.0/560-ppc-atomic.patch)25
-rw-r--r--packages/glibc/2.14.1/0032-mips_shn_undef-hack.patch (renamed from packages/glibc/2.16.0/630-mips_shn_undef-hack.patch)13
-rw-r--r--packages/glibc/2.14.1/0033-alpha-atfcts.patch (renamed from packages/glibc/2.12.1/640-alpha-atfcts.patch)8
-rw-r--r--packages/glibc/2.14.1/0034-syslog.patch (renamed from packages/glibc/2.15/650-syslog.patch)9
-rw-r--r--packages/glibc/2.14.1/0035-debug-readlink_chk-readklinkat_chk.patch27
-rw-r--r--packages/glibc/2.14.1/0036-cpuid-include.patch (renamed from packages/glibc/2.14.1/900-cpuid-include.patch)16
-rw-r--r--packages/glibc/2.14.1/0037-asm-i686.patch (renamed from packages/glibc/2.15/910-asm-i686.patch)16
-rw-r--r--packages/glibc/2.14.1/0038-fix-rpc_parse-format.patch (renamed from packages/glibc/2.12.1/920-fix-rpc_parse-format.patch)8
-rw-r--r--packages/glibc/2.14.1/0039-nis-bogus-conditional.patch (renamed from packages/glibc/2.14.1/940-nis-bogus-conditional.patch)8
-rw-r--r--packages/glibc/2.14.1/0040-initfini-ppc64.patch (renamed from packages/glibc/2.14.1/950-initfini-ppc64.patch)8
-rw-r--r--packages/glibc/2.14.1/0041-obsolete-rpc.patch (renamed from packages/glibc/2.14.1/996-obsolete-rpc.patch)491
-rw-r--r--packages/glibc/2.14.1/0042-obstack-common.patch (renamed from packages/glibc/2.12.2/998-obstack-common.patch)8
-rw-r--r--packages/glibc/2.14.1/0043-new-tools.patch (renamed from packages/glibc/2.15/999-new-tools.patch)27
-rw-r--r--packages/glibc/2.14.1/430-alpha-creat.patch14
-rw-r--r--packages/glibc/2.14.1/660-debug-readlink_chk-readklinkat_chk.patch24
-rw-r--r--packages/glibc/2.15/0000-respect-env-CPPFLAGS.patch (renamed from packages/glibc/2.15/100-respect-env-CPPFLAGS.patch)11
-rw-r--r--packages/glibc/2.15/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch (renamed from packages/glibc/2.15/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch)31
-rw-r--r--packages/glibc/2.15/0002-fix-signed-shift-overlow.patch (renamed from packages/glibc/2.15/102-fix-signed-shift-overlow.patch)23
-rw-r--r--packages/glibc/2.15/0003-dl-openat64-variadic.patch197
-rw-r--r--packages/glibc/2.15/0004-unused-variables.patch (renamed from packages/glibc/2.15/104-unused-variables.patch)56
-rw-r--r--packages/glibc/2.15/0005-misleading-indentation.patch (renamed from packages/glibc/2.13/105-misleading-indentation.patch)8
-rw-r--r--packages/glibc/2.15/0006-dl-open-array-bounds.patch (renamed from packages/glibc/2.12.1/106-dl-open-array-bounds.patch)8
-rw-r--r--packages/glibc/2.15/0007-i386-x86_64-revert-clone-cfi.patch (renamed from packages/glibc/2.14.1/120-i386-x86_64-revert-clone-cfi.patch)20
-rw-r--r--packages/glibc/2.15/0008-disable-ldconfig.patch (renamed from packages/glibc/2.14.1/140-disable-ldconfig.patch)11
-rw-r--r--packages/glibc/2.15/0009-Fix-combreloc-test-BSD-grep.patch (renamed from packages/glibc/2.15/140-Fix-combreloc-test-BSD-grep.patch)21
-rw-r--r--packages/glibc/2.15/0010-queue-header-updates.patch (renamed from packages/glibc/2.16.0/150-queue-header-updates.patch)9
-rw-r--r--packages/glibc/2.15/0011-manual-no-perl.patch (renamed from packages/glibc/2.12.1/160-manual-no-perl.patch)11
-rw-r--r--packages/glibc/2.15/0012-localedef-fix-trampoline.patch (renamed from packages/glibc/2.16.0/170-localedef-fix-trampoline.patch)9
-rw-r--r--packages/glibc/2.15/0013-resolv-dynamic.patch (renamed from packages/glibc/2.15/180-resolv-dynamic.patch)9
-rw-r--r--packages/glibc/2.15/0014-fadvise64_64.patch (renamed from packages/glibc/2.15/200-fadvise64_64.patch)5
-rw-r--r--packages/glibc/2.15/0015-section-comments.patch (renamed from packages/glibc/2.12.1/220-section-comments.patch)11
-rw-r--r--packages/glibc/2.15/0016-no-inline-gmon.patch (renamed from packages/glibc/2.12.1/230-no-inline-gmon.patch)10
-rw-r--r--packages/glibc/2.15/0017-assume-pipe2.patch (renamed from packages/glibc/2.12.1/260-assume-pipe2.patch)9
-rw-r--r--packages/glibc/2.15/0018-china.patch (renamed from packages/glibc/2.16.0/270-china.patch)9
-rw-r--r--packages/glibc/2.15/0019-new-valencian-locale.patch (renamed from packages/glibc/2.16.0/280-new-valencian-locale.patch)17
-rw-r--r--packages/glibc/2.15/0020-macos-cross-rpcgen.patch34
-rw-r--r--packages/glibc/2.15/0021-nscd-one-fork.patch (renamed from packages/glibc/2.12.1/300-nscd-one-fork.patch)15
-rw-r--r--packages/glibc/2.15/0022-hppa-nptl-carlos.patch (renamed from packages/glibc/2.14.1/310-hppa-nptl-carlos.patch)49
-rw-r--r--packages/glibc/2.15/0023-dl_execstack-PaX-support.patch (renamed from packages/glibc/2.15/340-dl_execstack-PaX-support.patch)17
-rw-r--r--packages/glibc/2.15/0024-pre20040117-pt_pax.patch (renamed from packages/glibc/2.13/350-pre20040117-pt_pax.patch)13
-rw-r--r--packages/glibc/2.15/0025-tests-sandbox-libdl-paths.patch (renamed from packages/glibc/2.15/360-tests-sandbox-libdl-paths.patch)75
-rw-r--r--packages/glibc/2.15/0026-dont-build-timezone.patch (renamed from packages/glibc/2.15/380-dont-build-timezone.patch)11
-rw-r--r--packages/glibc/2.15/0027-alpha-xstat.patch (renamed from packages/glibc/2.15/400-alpha-xstat.patch)9
-rw-r--r--packages/glibc/2.15/0028-alpha-creat.patch17
-rw-r--r--packages/glibc/2.15/0029-alpha_alpha-add-fdatasync-support.patch (renamed from packages/glibc/2.15/490-alpha_alpha-add-fdatasync-support.patch)22
-rw-r--r--packages/glibc/2.15/0030-ppc-atomic.patch (renamed from packages/glibc/2.14.1/560-ppc-atomic.patch)25
-rw-r--r--packages/glibc/2.15/0031-mips_shn_undef-hack.patch (renamed from packages/glibc/2.15/630-mips_shn_undef-hack.patch)13
-rw-r--r--packages/glibc/2.15/0032-alpha-atfcts.patch (renamed from packages/glibc/2.13/640-alpha-atfcts.patch)8
-rw-r--r--packages/glibc/2.15/0033-syslog.patch (renamed from packages/glibc/2.12.1/650-syslog.patch)9
-rw-r--r--packages/glibc/2.15/0034-debug-readlink_chk-readklinkat_chk.patch27
-rw-r--r--packages/glibc/2.15/0035-cpuid-include.patch (renamed from packages/glibc/2.15/900-cpuid-include.patch)23
-rw-r--r--packages/glibc/2.15/0036-asm-i686.patch (renamed from packages/glibc/2.14.1/910-asm-i686.patch)16
-rw-r--r--packages/glibc/2.15/0037-fix-rpc_parse-format.patch62
-rw-r--r--packages/glibc/2.15/0038-nis-bogus-conditional.patch64
-rw-r--r--packages/glibc/2.15/0039-try-link-static.patch (renamed from packages/glibc/2.15/990-try-link-static.patch)33
-rw-r--r--packages/glibc/2.15/0040-builtin_expect.patch (renamed from packages/glibc/2.15/991-builtin_expect.patch)19
-rw-r--r--packages/glibc/2.15/0041-gcc_s-suffix.patch (renamed from packages/glibc/2.15/992-gcc_s-suffix.patch)41
-rw-r--r--packages/glibc/2.15/0042-obsolete-rpc.patch (renamed from packages/glibc/2.15/996-obsolete-rpc.patch)491
-rw-r--r--packages/glibc/2.15/0043-obstack-common.patch32
-rw-r--r--packages/glibc/2.15/0044-new-tools.patch (renamed from packages/glibc/2.14.1/999-new-tools.patch)27
-rw-r--r--packages/glibc/2.15/300-macos-cross-rpcgen.patch32
-rw-r--r--packages/glibc/2.15/430-alpha-creat.patch14
-rw-r--r--packages/glibc/2.15/660-debug-readlink_chk-readklinkat_chk.patch24
-rw-r--r--packages/glibc/2.15/920-fix-rpc_parse-format.patch60
-rw-r--r--packages/glibc/2.15/940-nis-bogus-conditional.patch62
-rw-r--r--packages/glibc/2.15/998-obstack-common.patch30
-rw-r--r--packages/glibc/2.16.0/0000-respect-env-CPPFLAGS.patch (renamed from packages/glibc/2.16.0/100-respect-env-CPPFLAGS.patch)9
-rw-r--r--packages/glibc/2.16.0/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch75
-rw-r--r--packages/glibc/2.16.0/0002-fix-signed-shift-overlow.patch97
-rw-r--r--packages/glibc/2.16.0/0003-dl-openat64-variadic.patch (renamed from packages/glibc/2.15/103-dl-openat64-variadic.patch)6
-rw-r--r--packages/glibc/2.16.0/0004-unused-variables.patch (renamed from packages/glibc/2.16.0/104-unused-variables.patch)48
-rw-r--r--packages/glibc/2.16.0/0005-misleading-indentation.patch26
-rw-r--r--packages/glibc/2.16.0/0006-dl-open-array-bounds.patch (renamed from packages/glibc/2.16.0/106-dl-open-array-bounds.patch)8
-rw-r--r--packages/glibc/2.16.0/0007-i386-x86_64-revert-clone-cfi.patch51
-rw-r--r--packages/glibc/2.16.0/0008-disable-ldconfig.patch19
-rw-r--r--packages/glibc/2.16.0/0009-Fix-combreloc-test-BSD-grep.patch (renamed from packages/glibc/2.18/140-Fix-combreloc-test-BSD-grep.patch)18
-rw-r--r--packages/glibc/2.16.0/0010-queue-header-updates.patch86
-rw-r--r--packages/glibc/2.16.0/0011-localedef-fix-trampoline.patch56
-rw-r--r--packages/glibc/2.16.0/0012-resolv-dynamic.patch42
-rw-r--r--packages/glibc/2.16.0/0013-fadvise64_64.patch27
-rw-r--r--packages/glibc/2.16.0/0014-assume-pipe2.patch (renamed from packages/glibc/2.16.0/260-assume-pipe2.patch)9
-rw-r--r--packages/glibc/2.16.0/0015-china.patch35
-rw-r--r--packages/glibc/2.16.0/0016-new-valencian-locale.patch118
-rw-r--r--packages/glibc/2.16.0/0017-macos-cross-rpcgen.patch34
-rw-r--r--packages/glibc/2.16.0/0018-nscd-one-fork.patch (renamed from packages/glibc/2.16.0/300-nscd-one-fork.patch)11
-rw-r--r--packages/glibc/2.16.0/0019-hppa-nptl-carlos.patch (renamed from packages/glibc/2.16.0/310-hppa-nptl-carlos.patch)83
-rw-r--r--packages/glibc/2.16.0/0020-dl_execstack-PaX-support.patch69
-rw-r--r--packages/glibc/2.16.0/0021-pre20040117-pt_pax.patch35
-rw-r--r--packages/glibc/2.16.0/0022-tests-sandbox-libdl-paths.patch196
-rw-r--r--packages/glibc/2.16.0/0023-dont-build-timezone.patch17
-rw-r--r--packages/glibc/2.16.0/0024-alpha-xstat.patch18
-rw-r--r--packages/glibc/2.16.0/0025-alpha-creat.patch17
-rw-r--r--packages/glibc/2.16.0/0026-alpha_alpha-add-fdatasync-support.patch (renamed from packages/glibc/2.16.0/490-alpha_alpha-add-fdatasync-support.patch)26
-rw-r--r--packages/glibc/2.16.0/0027-fix-parsing-of-numeric-hosts-in-gethostbyname_r.patch (renamed from packages/glibc/2.16.0/500-fix-parsing-of-numeric-hosts-in-gethostbyname_r.patch)22
-rw-r--r--packages/glibc/2.16.0/0028-ppc-atomic.patch412
-rw-r--r--packages/glibc/2.16.0/0029-mips_shn_undef-hack.patch19
-rw-r--r--packages/glibc/2.16.0/0030-alpha-atfcts.patch16
-rw-r--r--packages/glibc/2.16.0/0031-syslog.patch15
-rw-r--r--packages/glibc/2.16.0/0032-debug-readlink_chk-readklinkat_chk.patch27
-rw-r--r--packages/glibc/2.16.0/0033-fix-rpc_parse-format.patch62
-rw-r--r--packages/glibc/2.16.0/0034-nis-bogus-conditional.patch64
-rw-r--r--packages/glibc/2.16.0/0035-obstack-common.patch32
-rw-r--r--packages/glibc/2.16.0/0036-new-tools.patch (renamed from packages/glibc/2.16.0/999-new-tools.patch)21
-rw-r--r--packages/glibc/2.16.0/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch84
-rw-r--r--packages/glibc/2.16.0/102-fix-signed-shift-overlow.patch98
-rw-r--r--packages/glibc/2.16.0/105-misleading-indentation.patch24
-rw-r--r--packages/glibc/2.16.0/300-macos-cross-rpcgen.patch32
-rw-r--r--packages/glibc/2.16.0/430-alpha-creat.patch14
-rw-r--r--packages/glibc/2.16.0/640-alpha-atfcts.patch12
-rw-r--r--packages/glibc/2.16.0/650-syslog.patch12
-rw-r--r--packages/glibc/2.16.0/660-debug-readlink_chk-readklinkat_chk.patch24
-rw-r--r--packages/glibc/2.16.0/920-fix-rpc_parse-format.patch60
-rw-r--r--packages/glibc/2.16.0/940-nis-bogus-conditional.patch62
-rw-r--r--packages/glibc/2.16.0/998-obstack-common.patch30
-rw-r--r--packages/glibc/2.17/0000-Fix-ARM-build-with-GCC-trunk.patch (renamed from packages/glibc/2.17/100-Fix-ARM-build-with-GCC-trunk.patch)13
-rw-r--r--packages/glibc/2.17/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch75
-rw-r--r--packages/glibc/2.17/0002-fix-signed-shift-overlow.patch97
-rw-r--r--packages/glibc/2.17/0003-dl-openat64-variadic.patch (renamed from packages/glibc/2.16.0/103-dl-openat64-variadic.patch)6
-rw-r--r--packages/glibc/2.17/0004-unused-variables.patch (renamed from packages/glibc/2.17/104-unused-variables.patch)48
-rw-r--r--packages/glibc/2.17/0005-misleading-indentation.patch26
-rw-r--r--packages/glibc/2.17/0006-dl-open-array-bounds.patch (renamed from packages/glibc/2.17/106-dl-open-array-bounds.patch)8
-rw-r--r--packages/glibc/2.17/0007-support-make4.patch (renamed from packages/glibc/2.18/120-support-make4.patch)13
-rw-r--r--packages/glibc/2.17/0008-Fix-combreloc-test-BSD-grep.patch (renamed from packages/glibc/2.17/140-Fix-combreloc-test-BSD-grep.patch)18
-rw-r--r--packages/glibc/2.17/0009-macos-cross-rpcgen.patch34
-rw-r--r--packages/glibc/2.17/0010-fix-rpc_parse-format.patch62
-rw-r--r--packages/glibc/2.17/0011-nis-bogus-conditional.patch64
-rw-r--r--packages/glibc/2.17/0012-obstack-common.patch32
-rw-r--r--packages/glibc/2.17/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch84
-rw-r--r--packages/glibc/2.17/102-fix-signed-shift-overlow.patch98
-rw-r--r--packages/glibc/2.17/105-misleading-indentation.patch24
-rw-r--r--packages/glibc/2.17/300-macos-cross-rpcgen.patch32
-rw-r--r--packages/glibc/2.17/920-fix-rpc_parse-format.patch60
-rw-r--r--packages/glibc/2.17/940-nis-bogus-conditional.patch62
-rw-r--r--packages/glibc/2.17/998-obstack-common.patch30
-rw-r--r--packages/glibc/2.18/0000-4f2bcda-ARM-Fix-clone-code-when-built-for-Thumb.patch (renamed from packages/glibc/2.18/100-4f2bcda-ARM-Fix-clone-code-when-built-for-Thumb.patch)16
-rw-r--r--packages/glibc/2.18/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch75
-rw-r--r--packages/glibc/2.18/0002-fix-signed-shift-overlow.patch97
-rw-r--r--packages/glibc/2.18/0003-dl-openat64-variadic.patch (renamed from packages/glibc/2.17/103-dl-openat64-variadic.patch)6
-rw-r--r--packages/glibc/2.18/0004-unused-variables.patch (renamed from packages/glibc/2.18/104-unused-variables.patch)40
-rw-r--r--packages/glibc/2.18/0005-misleading-indentation.patch26
-rw-r--r--packages/glibc/2.18/0006-dl-open-array-bounds.patch (renamed from packages/glibc/2.20/106-dl-open-array-bounds.patch)10
-rw-r--r--packages/glibc/2.18/0007-2770d15-Fix-PI-mutex-check-in-pthread_cond_broadcast-and-pthread_cond_signal.patch (renamed from packages/glibc/2.18/110-2770d15-Fix-PI-mutex-check-in-pthread_cond_broadcast-and-pthread_cond_signal.patch)21
-rw-r--r--packages/glibc/2.18/0008-support-make4.patch (renamed from packages/glibc/2.17/120-support-make4.patch)13
-rw-r--r--packages/glibc/2.18/0009-arm-unwind.patch (renamed from packages/glibc/2.18/130-arm-unwind.patch)27
-rw-r--r--packages/glibc/2.18/0010-Fix-combreloc-test-BSD-grep.patch (renamed from packages/glibc/2.16.0/140-Fix-combreloc-test-BSD-grep.patch)18
-rw-r--r--packages/glibc/2.18/0011-macos-cross-rpcgen.patch34
-rw-r--r--packages/glibc/2.18/0012-fix-rpc_parse-format.patch62
-rw-r--r--packages/glibc/2.18/0013-nis-bogus-conditional.patch64
-rw-r--r--packages/glibc/2.18/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch84
-rw-r--r--packages/glibc/2.18/102-fix-signed-shift-overlow.patch98
-rw-r--r--packages/glibc/2.18/103-dl-openat64-variadic.patch195
-rw-r--r--packages/glibc/2.18/105-misleading-indentation.patch24
-rw-r--r--packages/glibc/2.18/300-macos-cross-rpcgen.patch32
-rw-r--r--packages/glibc/2.18/920-fix-rpc_parse-format.patch60
-rw-r--r--packages/glibc/2.18/940-nis-bogus-conditional.patch62
-rw-r--r--packages/glibc/2.19/0000-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch75
-rw-r--r--packages/glibc/2.19/0001-fix-signed-shift-overlow.patch97
-rw-r--r--packages/glibc/2.19/0002-dl-openat64-variadic.patch (renamed from packages/glibc/2.14.1/103-dl-openat64-variadic.patch)6
-rw-r--r--packages/glibc/2.19/0003-unused-variables.patch (renamed from packages/glibc/2.20/104-unused-variables.patch)45
-rw-r--r--packages/glibc/2.19/0004-misleading-indentation.patch26
-rw-r--r--packages/glibc/2.19/0005-dl-open-array-bounds.patch (renamed from packages/glibc/2.21/106-dl-open-array-bounds.patch)10
-rw-r--r--packages/glibc/2.19/0006-arm-unwind.patch (renamed from packages/glibc/2.19/130-arm-unwind.patch)27
-rw-r--r--packages/glibc/2.19/0007-Fix-combreloc-test-BSD-grep.patch (renamed from packages/glibc/2.20/140-Fix-combreloc-test-BSD-grep.patch)18
-rw-r--r--packages/glibc/2.19/0008-typedef-caddr.patch31
-rw-r--r--packages/glibc/2.19/0009-fix-rpc_parse-format.patch62
-rw-r--r--packages/glibc/2.19/0010-explicit-boolean.patch (renamed from packages/glibc/2.19/930-explicit-boolean.patch)8
-rw-r--r--packages/glibc/2.19/0011-nis-bogus-conditional.patch64
-rw-r--r--packages/glibc/2.19/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch84
-rw-r--r--packages/glibc/2.19/102-fix-signed-shift-overlow.patch98
-rw-r--r--packages/glibc/2.19/103-dl-openat64-variadic.patch195
-rw-r--r--packages/glibc/2.19/105-misleading-indentation.patch24
-rw-r--r--packages/glibc/2.19/920-fix-rpc_parse-format.patch60
-rw-r--r--packages/glibc/2.19/940-nis-bogus-conditional.patch62
-rw-r--r--packages/glibc/2.20/0000-sparc-nptl.patch (renamed from packages/glibc/2.20/100-sparc-nptl.patch)8
-rw-r--r--packages/glibc/2.20/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch75
-rw-r--r--packages/glibc/2.20/0002-fix-signed-shift-overlow.patch97
-rw-r--r--packages/glibc/2.20/0003-dl-openat64-variadic.patch197
-rw-r--r--packages/glibc/2.20/0004-unused-variables.patch (renamed from packages/glibc/2.19/104-unused-variables.patch)45
-rw-r--r--packages/glibc/2.20/0005-misleading-indentation.patch26
-rw-r--r--packages/glibc/2.20/0006-dl-open-array-bounds.patch (renamed from packages/glibc/2.18/106-dl-open-array-bounds.patch)10
-rw-r--r--packages/glibc/2.20/0007-Fix-combreloc-test-BSD-grep.patch (renamed from packages/glibc/2.19/140-Fix-combreloc-test-BSD-grep.patch)18
-rw-r--r--packages/glibc/2.20/0008-typedef-caddr.patch (renamed from packages/glibc/2.20/910-typedef-caddr.patch)12
-rw-r--r--packages/glibc/2.20/0009-fix-rpc_parse-format.patch62
-rw-r--r--packages/glibc/2.20/0010-explicit-boolean.patch (renamed from packages/glibc/2.20/930-explicit-boolean.patch)8
-rw-r--r--packages/glibc/2.20/0011-nis-bogus-conditional.patch64
-rw-r--r--packages/glibc/2.20/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch84
-rw-r--r--packages/glibc/2.20/102-fix-signed-shift-overlow.patch98
-rw-r--r--packages/glibc/2.20/103-dl-openat64-variadic.patch195
-rw-r--r--packages/glibc/2.20/105-misleading-indentation.patch24
-rw-r--r--packages/glibc/2.20/920-fix-rpc_parse-format.patch60
-rw-r--r--packages/glibc/2.20/940-nis-bogus-conditional.patch62
-rw-r--r--packages/glibc/2.21/0000-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch75
-rw-r--r--packages/glibc/2.21/0001-fix-signed-shift-overlow.patch97
-rw-r--r--packages/glibc/2.21/0002-dl-openat64-variadic.patch197
-rw-r--r--packages/glibc/2.21/0003-unused-variables.patch (renamed from packages/glibc/2.22/104-unused-variables.patch)45
-rw-r--r--packages/glibc/2.21/0004-misleading-indentation.patch26
-rw-r--r--packages/glibc/2.21/0005-dl-open-array-bounds.patch (renamed from packages/glibc/2.19/106-dl-open-array-bounds.patch)10
-rw-r--r--packages/glibc/2.21/0006-Fix-combreloc-test-BSD-grep.patch (renamed from packages/glibc/2.21/140-Fix-combreloc-test-BSD-grep.patch)18
-rw-r--r--packages/glibc/2.21/0007-typedef-caddr.patch (renamed from packages/glibc/2.21/910-typedef-caddr.patch)12
-rw-r--r--packages/glibc/2.21/0008-fix-rpc_parse-format.patch62
-rw-r--r--packages/glibc/2.21/0009-explicit-boolean.patch (renamed from packages/glibc/2.21/930-explicit-boolean.patch)8
-rw-r--r--packages/glibc/2.21/0010-nis-bogus-conditional.patch64
-rw-r--r--packages/glibc/2.21/0011-dlclose-assert.patch (renamed from packages/glibc/2.21/950-dlclose-assert.patch)10
-rw-r--r--packages/glibc/2.21/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch84
-rw-r--r--packages/glibc/2.21/102-fix-signed-shift-overlow.patch98
-rw-r--r--packages/glibc/2.21/103-dl-openat64-variadic.patch195
-rw-r--r--packages/glibc/2.21/105-misleading-indentation.patch24
-rw-r--r--packages/glibc/2.21/920-fix-rpc_parse-format.patch60
-rw-r--r--packages/glibc/2.21/940-nis-bogus-conditional.patch62
-rw-r--r--packages/glibc/2.22/0000-sparc32-sem_open-missing-include.patch (renamed from packages/glibc/2.22/100-sparc32-sem_open-missing-include.patch)6
-rw-r--r--packages/glibc/2.22/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch75
-rw-r--r--packages/glibc/2.22/0002-fix-signed-shift-overlow.patch97
-rw-r--r--packages/glibc/2.22/0003-dl-openat64-variadic.patch (renamed from packages/glibc/2.22/103-dl-openat64-variadic.patch)6
-rw-r--r--packages/glibc/2.22/0004-unused-variables.patch (renamed from packages/glibc/2.21/104-unused-variables.patch)45
-rw-r--r--packages/glibc/2.22/0005-misleading-indentation.patch26
-rw-r--r--packages/glibc/2.22/0006-cve-2105-7547-getaddrinfo-stack.patch (renamed from packages/glibc/2.22/120-cve-2105-7547-getaddrinfo-stack.patch)21
-rw-r--r--packages/glibc/2.22/0007-Fix-combreloc-test-BSD-grep.patch (renamed from packages/glibc/2.22/140-Fix-combreloc-test-BSD-grep.patch)18
-rw-r--r--packages/glibc/2.22/0008-typedef-caddr.patch (renamed from packages/glibc/2.22/910-typedef-caddr.patch)12
-rw-r--r--packages/glibc/2.22/0009-fix-rpc_parse-format.patch62
-rw-r--r--packages/glibc/2.22/0010-explicit-boolean.patch (renamed from packages/glibc/2.22/930-explicit-boolean.patch)8
-rw-r--r--packages/glibc/2.22/0011-nis-bogus-conditional.patch64
-rw-r--r--packages/glibc/2.22/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch84
-rw-r--r--packages/glibc/2.22/102-fix-signed-shift-overlow.patch98
-rw-r--r--packages/glibc/2.22/105-misleading-indentation.patch24
-rw-r--r--packages/glibc/2.22/920-fix-rpc_parse-format.patch60
-rw-r--r--packages/glibc/2.22/940-nis-bogus-conditional.patch62
-rw-r--r--packages/glibc/2.23/0000-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch75
-rw-r--r--packages/glibc/2.23/0001-Fix-build-with-enable-static-nss.patch (renamed from packages/glibc/2.23/120-Fix-build-with-enable-static-nss.patch)12
-rw-r--r--packages/glibc/2.23/0002-Fix-combreloc-test-BSD-grep.patch41
-rw-r--r--packages/glibc/2.23/0003-typedef-caddr.patch (renamed from packages/glibc/2.23/910-typedef-caddr.patch)12
-rw-r--r--packages/glibc/2.23/0004-fix-rpc_parse-format.patch62
-rw-r--r--packages/glibc/2.23/0005-explicit-boolean.patch35
-rw-r--r--packages/glibc/2.23/0006-nis-bogus-conditional.patch64
-rw-r--r--packages/glibc/2.23/0007-regexp-common.patch (renamed from packages/glibc/2.23/997-regexp-common.patch)6
-rw-r--r--packages/glibc/2.23/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch84
-rw-r--r--packages/glibc/2.23/140-Fix-combreloc-test-BSD-grep.patch49
-rw-r--r--packages/glibc/2.23/920-fix-rpc_parse-format.patch60
-rw-r--r--packages/glibc/2.23/930-explicit-boolean.patch33
-rw-r--r--packages/glibc/2.23/940-nis-bogus-conditional.patch62
-rw-r--r--packages/glibc/2.24/0000-sh-fix-gcc6.patch (renamed from packages/glibc/2.24/110-sh-fix-gcc6.patch)9
-rw-r--r--packages/glibc/2.24/0001-Fix-build-with-enable-static-nss.patch (renamed from packages/glibc/2.25/120-Fix-build-with-enable-static-nss.patch)12
-rw-r--r--packages/glibc/2.24/0002-Fix-combreloc-test-BSD-grep.patch41
-rw-r--r--packages/glibc/2.24/0003-typedef-caddr.patch17
-rw-r--r--packages/glibc/2.24/0004-fix-rpc_parse-format.patch62
-rw-r--r--packages/glibc/2.24/0005-explicit-boolean.patch35
-rw-r--r--packages/glibc/2.24/0006-nis-bogus-conditional.patch64
-rw-r--r--packages/glibc/2.24/0007-regexp-common.patch (renamed from packages/glibc/2.24/997-regexp-common.patch)6
-rw-r--r--packages/glibc/2.24/140-Fix-combreloc-test-BSD-grep.patch49
-rw-r--r--packages/glibc/2.24/910-typedef-caddr.patch15
-rw-r--r--packages/glibc/2.24/920-fix-rpc_parse-format.patch60
-rw-r--r--packages/glibc/2.24/930-explicit-boolean.patch33
-rw-r--r--packages/glibc/2.24/940-nis-bogus-conditional.patch62
-rw-r--r--packages/glibc/2.25/0000-sh-fix-gcc6.patch (renamed from packages/glibc/2.25/110-sh-fix-gcc6.patch)9
-rw-r--r--packages/glibc/2.25/0001-Fix-build-with-enable-static-nss.patch (renamed from packages/glibc/2.24/120-Fix-build-with-enable-static-nss.patch)12
-rw-r--r--packages/glibc/2.25/0002-Fix-combreloc-test-BSD-grep.patch41
-rw-r--r--packages/glibc/2.25/0003-typedef-caddr.patch17
-rw-r--r--packages/glibc/2.25/0004-sh4-trap-divdi3.patch (renamed from packages/glibc/2.25/960-sh4-trap-divdi3.patch)49
-rw-r--r--packages/glibc/2.25/0005-sparc-extra-plt-call.patch (renamed from packages/glibc/2.25/961-sparc-extra-plt-call.patch)23
-rw-r--r--packages/glibc/2.25/0006-regexp-common.patch (renamed from packages/glibc/2.25/997-regexp-common.patch)6
-rw-r--r--packages/glibc/2.25/140-Fix-combreloc-test-BSD-grep.patch49
-rw-r--r--packages/glibc/2.25/910-typedef-caddr.patch15
-rw-r--r--packages/glibc/2.26/0000-typedef-caddr.patch17
-rw-r--r--packages/glibc/2.26/910-typedef-caddr.patch15
411 files changed, 7948 insertions, 7848 deletions
diff --git a/packages/glibc/2.12.1/100-respect-env-CPPFLAGS.patch b/packages/glibc/2.12.1/0000-respect-env-CPPFLAGS.patch
index ed022be..ddeb71b 100644
--- a/packages/glibc/2.12.1/100-respect-env-CPPFLAGS.patch
+++ b/packages/glibc/2.12.1/0000-respect-env-CPPFLAGS.patch
@@ -1,9 +1,13 @@
Respect environment CPPFLAGS when we run ./configure so we can inject
random -D things without having to set CFLAGS/ASFLAGS
-diff -durN glibc-2.12.1.orig/Makeconfig glibc-2.12.1/Makeconfig
---- glibc-2.12.1.orig/Makeconfig 2009-05-09 23:57:56.000000000 +0200
-+++ glibc-2.12.1/Makeconfig 2009-11-13 00:49:41.000000000 +0100
+---
+ Makeconfig | 1 +
+ config.make.in | 1 +
+ 2 files changed, 2 insertions(+)
+
+--- a/Makeconfig
++++ b/Makeconfig
@@ -697,6 +697,7 @@
$(foreach lib,$(libof-$(basename $(@F))) \
$(libof-$(<F)) $(libof-$(@F)),$(CPPFLAGS-$(lib))) \
@@ -12,9 +16,8 @@ diff -durN glibc-2.12.1.orig/Makeconfig glibc-2.12.1/Makeconfig
override CFLAGS = -std=gnu99 $(gnu89-inline-CFLAGS) \
$(filter-out %frame-pointer,$(+cflags)) $(+gccwarn-c) \
$(sysdep-CFLAGS) $(CFLAGS-$(suffix $@)) $(CFLAGS-$(<F)) \
-diff -durN glibc-2.12.1.orig/config.make.in glibc-2.12.1/config.make.in
---- glibc-2.12.1.orig/config.make.in 2009-05-09 17:59:38.000000000 +0200
-+++ glibc-2.12.1/config.make.in 2009-11-13 00:49:41.000000000 +0100
+--- a/config.make.in
++++ b/config.make.in
@@ -107,6 +107,7 @@
CXX = @CXX@
BUILD_CC = @BUILD_CC@
diff --git a/packages/glibc/2.13/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.12.1/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
index 6fd663a..30a70a2 100644
--- a/packages/glibc/2.13/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
+++ b/packages/glibc/2.12.1/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
@@ -5,16 +5,13 @@ Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
-Wparentheses
---
- ChangeLog | 5 +++++
- nis/nis_call.c | 20 +++++++++++---------
- stdlib/setenv.c | 26 ++++++++++++++------------
- 3 files changed, 30 insertions(+), 21 deletions(-)
+ nis/nis_call.c | 20 +++++++++++---------
+ stdlib/setenv.c | 24 +++++++++++++-----------
+ 2 files changed, 24 insertions(+), 20 deletions(-)
-diff --git a/nis/nis_call.c b/nis/nis_call.c
-index 3fa37e4..cb7839a 100644
--- a/nis/nis_call.c
+++ b/nis/nis_call.c
-@@ -680,16 +680,18 @@ nis_server_cache_add (const_nis_name name, int search_parent,
+@@ -682,16 +682,18 @@
/* Choose which entry should be evicted from the cache. */
loc = &nis_server_cache[0];
if (*loc != NULL)
@@ -42,11 +39,9 @@ index 3fa37e4..cb7839a 100644
old = *loc;
*loc = new;
-diff --git a/stdlib/setenv.c b/stdlib/setenv.c
-index da61ee0..e66045f 100644
--- a/stdlib/setenv.c
+++ b/stdlib/setenv.c
-@@ -278,18 +278,20 @@ unsetenv (const char *name)
+@@ -328,18 +328,20 @@
ep = __environ;
if (ep != NULL)
while (*ep != NULL)
@@ -54,7 +49,12 @@ index da61ee0..e66045f 100644
- {
- /* Found it. Remove this pointer by moving later ones back. */
- char **dp = ep;
--
++ {
++ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
++ {
++ /* Found it. Remove this pointer by moving later ones back. */
++ char **dp = ep;
+
- do
- dp[0] = dp[1];
- while (*dp++);
@@ -62,12 +62,6 @@ index da61ee0..e66045f 100644
- }
- else
- ++ep;
-+ {
-+ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-+ {
-+ /* Found it. Remove this pointer by moving later ones back. */
-+ char **dp = ep;
-+
+ do
+ dp[0] = dp[1];
+ while (*dp++);
@@ -79,6 +73,3 @@ index da61ee0..e66045f 100644
UNLOCK;
---
-2.7.4
-
diff --git a/packages/glibc/2.13/102-fix-signed-shift-overlow.patch b/packages/glibc/2.12.1/0002-fix-signed-shift-overlow.patch
index ef49f83..5f76afe 100644
--- a/packages/glibc/2.13/102-fix-signed-shift-overlow.patch
+++ b/packages/glibc/2.12.1/0002-fix-signed-shift-overlow.patch
@@ -12,11 +12,16 @@ Date: Tue Jul 21 22:50:29 2015 -0700
* string/strchrnul.c (STRCHRNUL):
Rewrite code to avoid issues with signed shift overflow.
-diff --git a/string/memrchr.c b/string/memrchr.c
-index 0c8fd84..86cd5b9 100644
+---
+ string/memrchr.c | 11 ++---------
+ string/rawmemchr.c | 11 ++---------
+ string/strchr.c | 9 ++-------
+ string/strchrnul.c | 9 ++-------
+ 4 files changed, 8 insertions(+), 32 deletions(-)
+
--- a/string/memrchr.c
+++ b/string/memrchr.c
-@@ -96,15 +96,8 @@ MEMRCHR
+@@ -98,15 +98,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
@@ -34,11 +39,9 @@ index 0c8fd84..86cd5b9 100644
/* Set up a longword, each of whose bytes is C. */
charmask = c | (c << 8);
-diff --git a/string/rawmemchr.c b/string/rawmemchr.c
-index 05b22be..228ca9d 100644
--- a/string/rawmemchr.c
+++ b/string/rawmemchr.c
-@@ -86,15 +86,8 @@ RAWMEMCHR (s, c_in)
+@@ -90,15 +90,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
@@ -56,11 +59,9 @@ index 05b22be..228ca9d 100644
/* Set up a longword, each of whose bytes is C. */
charmask = c | (c << 8);
-diff --git a/string/strchr.c b/string/strchr.c
-index 5f90075..f13b2b3 100644
--- a/string/strchr.c
+++ b/string/strchr.c
-@@ -60,13 +60,8 @@ strchr (const char *s, int c_in)
+@@ -65,13 +65,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
@@ -76,11 +77,9 @@ index 5f90075..f13b2b3 100644
/* Set up a longword, each of whose bytes is C. */
charmask = c | (c << 8);
-diff --git a/string/strchrnul.c b/string/strchrnul.c
-index 2678f1d..daf0b3f 100644
--- a/string/strchrnul.c
+++ b/string/strchrnul.c
-@@ -66,13 +66,8 @@ STRCHRNUL (s, c_in)
+@@ -63,13 +63,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
diff --git a/packages/glibc/2.13/104-unused-variables.patch b/packages/glibc/2.12.1/0003-unused-variables.patch
index e063675..18adb17 100644
--- a/packages/glibc/2.13/104-unused-variables.patch
+++ b/packages/glibc/2.12.1/0003-unused-variables.patch
@@ -19,8 +19,18 @@ Date: Fri Sep 18 20:27:20 2015 +0100
* timezone/private.h (time_t_min): Likewise. (time_t_max):
Likewise.
-diff --git a/resolv/base64.c b/resolv/base64.c
-index ea584ed..519e5d2 100644
+---
+ resolv/base64.c | 4 ----
+ sysdeps/ieee754/dbl-64/atnat2.h | 4 ----
+ sysdeps/ieee754/dbl-64/uexp.h | 2 +-
+ sysdeps/ieee754/dbl-64/upow.h | 2 --
+ sysdeps/ieee754/flt-32/e_log10f.c | 6 ------
+ sysdeps/ieee754/flt-32/s_cosf.c | 6 ------
+ sysdeps/ieee754/ldbl-128/e_lgammal_r.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_erfl.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_log1pl.c | 1 -
+ 9 files changed, 1 insertion(+), 26 deletions(-)
+
--- a/resolv/base64.c
+++ b/resolv/base64.c
@@ -40,10 +40,6 @@
@@ -34,11 +44,9 @@ index ea584ed..519e5d2 100644
#include <sys/types.h>
#include <sys/param.h>
#include <sys/socket.h>
-diff --git a/sysdeps/ieee754/dbl-64/atnat2.h b/sysdeps/ieee754/dbl-64/atnat2.h
-index e0d65af..82943f9 100644
--- a/sysdeps/ieee754/dbl-64/atnat2.h
+++ b/sysdeps/ieee754/dbl-64/atnat2.h
-@@ -65,10 +65,8 @@
+@@ -69,10 +69,8 @@
/**/ hpi1 = {{0x3c91a626, 0x33145c07} }, /* pi/2-hpi */
/**/ mhpi = {{0xbff921fb, 0x54442d18} }, /* -pi/2 */
/**/ qpi = {{0x3fe921fb, 0x54442d18} }, /* pi/4 */
@@ -49,7 +57,7 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0xc002d97c, 0x7f3321d2} }, /* -3pi/4 */
/**/ u1 = {{0x3c314c2a, 0x00000000} }, /* 9.377e-19 */
/**/ u2 = {{0x3bf955e4, 0x00000000} }, /* 8.584e-20 */
-@@ -129,10 +127,8 @@
+@@ -139,10 +137,8 @@
/**/ hpi1 = {{0x33145c07, 0x3c91a626} }, /* pi/2-hpi */
/**/ mhpi = {{0x54442d18, 0xbff921fb} }, /* -pi/2 */
/**/ qpi = {{0x54442d18, 0x3fe921fb} }, /* pi/4 */
@@ -60,11 +68,9 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0x7f3321d2, 0xc002d97c} }, /* -3pi/4 */
/**/ u1 = {{0x00000000, 0x3c314c2a} }, /* 9.377e-19 */
/**/ u2 = {{0x00000000, 0x3bf955e4} }, /* 8.584e-20 */
-diff --git a/sysdeps/ieee754/dbl-64/uexp.h b/sysdeps/ieee754/dbl-64/uexp.h
-index 6817eaf..42b21f2 100644
--- a/sysdeps/ieee754/dbl-64/uexp.h
+++ b/sysdeps/ieee754/dbl-64/uexp.h
-@@ -29,7 +29,7 @@
+@@ -30,7 +30,7 @@
#include "mydefs.h"
@@ -73,11 +79,9 @@ index 6817eaf..42b21f2 100644
err_0 = 1.000014, err_1 = 0.000016;
const static int4 bigint = 0x40862002,
badint = 0x40876000,smallint = 0x3C8fffff;
-diff --git a/sysdeps/ieee754/dbl-64/upow.h b/sysdeps/ieee754/dbl-64/upow.h
-index c8569a9..b4911e5 100644
--- a/sysdeps/ieee754/dbl-64/upow.h
+++ b/sysdeps/ieee754/dbl-64/upow.h
-@@ -34,7 +34,6 @@
+@@ -36,7 +36,6 @@
/**/ INF = {{0x7ff00000, 0x00000000}}, /* INF */
/**/ nINF = {{0xfff00000, 0x00000000}}, /* -INF */
/**/ NaNQ = {{0x7ff80000, 0x00000000}}, /* NaNQ */
@@ -85,7 +89,7 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0x3fe62e42, 0xfefa3800}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x3d2ef357, 0x93c76730}}, /* ln(2)-ln2a */
/**/ bigu = {{0x4297ffff, 0xfffffd2c}}, /* 1.5*2**42 -724*2**-10 */
-@@ -48,7 +47,6 @@
+@@ -51,7 +50,6 @@
/**/ INF = {{0x00000000, 0x7ff00000}}, /* INF */
/**/ nINF = {{0x00000000, 0xfff00000}}, /* -INF */
/**/ NaNQ = {{0x00000000, 0x7ff80000}}, /* NaNQ */
@@ -93,45 +97,39 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0xfefa3800, 0x3fe62e42}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x93c76730, 0x3d2ef357}}, /* ln(2)-ln2a */
/**/ bigu = {{0xfffffd2c, 0x4297ffff}}, /* 1.5*2**42 -724*2**-10 */
-diff --git a/sysdeps/ieee754/flt-32/e_log10f.c b/sysdeps/ieee754/flt-32/e_log10f.c
-index 96f0e81..1daeef7 100644
--- a/sysdeps/ieee754/flt-32/e_log10f.c
+++ b/sysdeps/ieee754/flt-32/e_log10f.c
-@@ -22,12 +22,6 @@ ivln10 = 4.3429449201e-01, /* 0x3ede5bd9 */
- log10_2hi = 3.0102920532e-01, /* 0x3e9a2080 */
+@@ -31,12 +31,6 @@
log10_2lo = 7.9034151668e-07; /* 0x355427db */
--#ifdef __STDC__
+ #ifdef __STDC__
-static const float zero = 0.0;
-#else
-static float zero = 0.0;
-#endif
-
- #ifdef __STDC__
+-#ifdef __STDC__
float __ieee754_log10f(float x)
#else
-diff --git a/sysdeps/ieee754/flt-32/s_cosf.c b/sysdeps/ieee754/flt-32/s_cosf.c
-index 864ab27..0affd40 100644
+ float __ieee754_log10f(x)
--- a/sysdeps/ieee754/flt-32/s_cosf.c
+++ b/sysdeps/ieee754/flt-32/s_cosf.c
-@@ -21,12 +21,6 @@ static char rcsid[] = "$NetBSD: s_cosf.c,v 1.4 1995/05/10 20:47:03 jtc Exp $";
- #include "math.h"
+@@ -22,12 +22,6 @@
#include "math_private.h"
--#ifdef __STDC__
+ #ifdef __STDC__
-static const float one=1.0;
-#else
-static float one=1.0;
-#endif
-
- #ifdef __STDC__
+-#ifdef __STDC__
float __cosf(float x)
#else
-diff --git a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-index 500aacc..ab5a96e 100644
+ float __cosf(x)
--- a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
+++ b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-@@ -82,7 +82,6 @@ DIAG_IGNORE_NEEDS_COMMENT (4.6, "-Woverflow");
+@@ -74,7 +74,6 @@
static const long double PIL = 3.1415926535897932384626433832795028841972E0L;
static const long double MAXLGM = 1.0485738685148938358098967157129705071571E4928L;
static const long double one = 1.0L;
@@ -139,11 +137,9 @@ index 500aacc..ab5a96e 100644
static const long double huge = 1.0e4000L;
/* log gamma(x) = ( x - 0.5 ) * log(x) - x + LS2PI + 1/x P(1/x^2)
-diff --git a/sysdeps/ieee754/ldbl-128/s_erfl.c b/sysdeps/ieee754/ldbl-128/s_erfl.c
-index fa4609f..08c80a3 100644
--- a/sysdeps/ieee754/ldbl-128/s_erfl.c
+++ b/sysdeps/ieee754/ldbl-128/s_erfl.c
-@@ -140,7 +140,6 @@ deval (long double x, const long double *p, int n)
+@@ -142,7 +142,6 @@
static long double
#endif
tiny = 1e-4931L,
@@ -151,11 +147,9 @@ index fa4609f..08c80a3 100644
one = 1.0L,
two = 2.0L,
/* 2/sqrt(pi) - 1 */
-diff --git a/sysdeps/ieee754/ldbl-128/s_log1pl.c b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-index ff759bc..9609550 100644
--- a/sysdeps/ieee754/ldbl-128/s_log1pl.c
+++ b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-@@ -117,7 +117,6 @@ static const long double C2 = 1.428606820309417232121458176568075500134E-6L;
+@@ -116,7 +116,6 @@
static const long double sqrth = 0.7071067811865475244008443621048490392848L;
/* ln (2^16384 * (1 - 2^-113)) */
diff --git a/packages/glibc/2.14.1/105-misleading-indentation.patch b/packages/glibc/2.12.1/0004-misleading-indentation.patch
index 1dd8d85..35bcb1b 100644
--- a/packages/glibc/2.14.1/105-misleading-indentation.patch
+++ b/packages/glibc/2.12.1/0004-misleading-indentation.patch
@@ -7,11 +7,13 @@ Date: Fri Dec 11 09:19:37 2015 -0800
* sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
Fix indentation.
-diff --git a/sysdeps/ieee754/flt-32/k_rem_pio2f.c b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-index 0c7685c..392afdb 100644
+---
+ sysdeps/ieee754/flt-32/k_rem_pio2f.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
--- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
+++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-@@ -65,7 +65,9 @@ int __kernel_rem_pio2f(float *x, float *y, int e0, int nx, int prec, const int32
+@@ -82,7 +82,9 @@
/* compute q[0],q[1],...q[jk] */
for (i=0;i<=jk;i++) {
diff --git a/packages/glibc/2.14.1/106-dl-open-array-bounds.patch b/packages/glibc/2.12.1/0005-dl-open-array-bounds.patch
index bdb5c19..d1d3fb7 100644
--- a/packages/glibc/2.14.1/106-dl-open-array-bounds.patch
+++ b/packages/glibc/2.12.1/0005-dl-open-array-bounds.patch
@@ -4,11 +4,13 @@ Date: Fri Apr 17 12:11:58 2015 -0700
Fuller check for invalid NSID in _dl_open.
-diff --git a/elf/dl-open.c b/elf/dl-open.c
-index 0dbe07f..2d0e082 100644
+---
+ elf/dl-open.c | 10 ++++++++--
+ 1 file changed, 8 insertions(+), 2 deletions(-)
+
--- a/elf/dl-open.c
+++ b/elf/dl-open.c
-@@ -619,8 +619,14 @@ no more namespaces available for dlmopen()"));
+@@ -555,8 +555,14 @@
/* Never allow loading a DSO in a namespace which is empty. Such
direct placements is only causing problems. Also don't allow
loading into a namespace used for auditing. */
diff --git a/packages/glibc/2.16.0/120-i386-x86_64-revert-clone-cfi.patch b/packages/glibc/2.12.1/0006-i386-x86_64-revert-clone-cfi.patch
index c7f6182..f872bac 100644
--- a/packages/glibc/2.16.0/120-i386-x86_64-revert-clone-cfi.patch
+++ b/packages/glibc/2.12.1/0006-i386-x86_64-revert-clone-cfi.patch
@@ -4,16 +4,13 @@ elsewhere. this cfi code does not gain us a whole lot anyways.
http://gcc.gnu.org/ml/gcc/2006-12/msg00293.html
-Index: sysdeps/unix/sysv/linux/i386/clone.S
-===================================================================
-RCS file: /cvs/glibc/libc/sysdeps/unix/sysv/linux/i386/clone.S,v
-retrieving revision 1.27
-retrieving revision 1.26
-diff -u -p -r1.27 -r1.26
+---
+ sysdeps/unix/sysv/linux/i386/clone.S | 4 ----
+ sysdeps/unix/sysv/linux/x86_64/clone.S | 4 ----
+ 2 files changed, 8 deletions(-)
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/i386/clone.S glibc-2.13/sysdeps/unix/sysv/linux/i386/clone.S
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/i386/clone.S 2006-12-04 00:12:36.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/i386/clone.S 2009-11-13 00:49:45.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/i386/clone.S
++++ b/sysdeps/unix/sysv/linux/i386/clone.S
@@ -120,9 +120,6 @@
ret
@@ -32,9 +29,8 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/i386/clone.S glibc-2.13/sysde
cfi_startproc
PSEUDO_END (BP_SYM (__clone))
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/x86_64/clone.S glibc-2.13/sysdeps/unix/sysv/linux/x86_64/clone.S
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/x86_64/clone.S 2006-12-04 00:12:36.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/x86_64/clone.S 2009-11-13 00:49:45.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/x86_64/clone.S
++++ b/sysdeps/unix/sysv/linux/x86_64/clone.S
@@ -89,9 +89,6 @@
ret
diff --git a/packages/glibc/2.13/140-disable-ldconfig.patch b/packages/glibc/2.12.1/0007-disable-ldconfig.patch
index 378e1df..d60cb40 100644
--- a/packages/glibc/2.13/140-disable-ldconfig.patch
+++ b/packages/glibc/2.12.1/0007-disable-ldconfig.patch
@@ -3,9 +3,12 @@ file outside of the chroot. doesnt matter anyways as we wont use the cache
results (portage will rebuild cache), so running ldconfig is simply a waste
of time.
-diff -durN glibc-2.13.orig/Makefile glibc-2.13/Makefile
---- glibc-2.13.orig/Makefile 2009-04-23 20:23:03.000000000 +0200
-+++ glibc-2.13/Makefile 2009-11-13 00:49:49.000000000 +0100
+---
+ Makefile | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/Makefile
++++ b/Makefile
@@ -116,6 +116,7 @@
rm -f $(symbolic-link-list)
diff --git a/packages/glibc/2.12.1/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.12.1/0008-Fix-combreloc-test-BSD-grep.patch
index 530d4ff..35bb601 100644
--- a/packages/glibc/2.12.1/140-Fix-combreloc-test-BSD-grep.patch
+++ b/packages/glibc/2.12.1/0008-Fix-combreloc-test-BSD-grep.patch
@@ -13,15 +13,13 @@ by configure as "not found". As a result, support for "-z combreloc"
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
+ configure | 2 +-
+ configure.in | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
-diff -urpN glibc-2.12.2.orig/configure glibc-2.12.2/configure
---- glibc-2.12.2.orig/configure 2010-12-13 02:47:26.000000000 -0800
-+++ glibc-2.12.2/configure 2017-03-08 21:18:07.000000000 -0800
-@@ -6710,7 +6710,7 @@ EOF
+--- a/configure
++++ b/configure
+@@ -6732,7 +6732,7 @@
$as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }
then
@@ -30,10 +28,9 @@ diff -urpN glibc-2.12.2.orig/configure glibc-2.12.2/configure
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
-diff -urpN glibc-2.12.2.orig/configure.in glibc-2.12.2/configure.in
---- glibc-2.12.2.orig/configure.in 2010-12-13 02:47:26.000000000 -0800
-+++ glibc-2.12.2/configure.in 2017-03-08 21:18:17.000000000 -0800
-@@ -1671,7 +1671,7 @@ dnl cross-platform since the gcc used ca
+--- a/configure.in
++++ b/configure.in
+@@ -1687,7 +1687,7 @@
dnl introducing new options this is not easily doable. Instead use a tool
dnl which always is cross-platform: readelf. To detect whether -z combreloc
dnl look for a section named .rel.dyn.
diff --git a/packages/glibc/2.13/150-queue-header-updates.patch b/packages/glibc/2.12.1/0009-queue-header-updates.patch
index 7cbe70e..f6515e2 100644
--- a/packages/glibc/2.13/150-queue-header-updates.patch
+++ b/packages/glibc/2.12.1/0009-queue-header-updates.patch
@@ -2,11 +2,12 @@ grab some updates from FreeBSD
http://bugs.gentoo.org/201979
-diff -durN glibc-2.13.orig/misc/sys/queue.h glibc-2.13/misc/sys/queue.h
+---
+ misc/sys/queue.h | 36 ++++++++++++++++++++++++++++++++++++
+ 1 file changed, 36 insertions(+)
-diff -durN glibc-2.13.orig/misc/sys/queue.h glibc-2.13/misc/sys/queue.h
---- glibc-2.13.orig/misc/sys/queue.h 2008-03-05 06:50:30.000000000 +0100
-+++ glibc-2.13/misc/sys/queue.h 2009-11-13 00:49:51.000000000 +0100
+--- a/misc/sys/queue.h
++++ b/misc/sys/queue.h
@@ -136,6 +136,11 @@
(var); \
(var) = ((var)->field.le_next))
diff --git a/packages/glibc/2.13/160-manual-no-perl.patch b/packages/glibc/2.12.1/0010-manual-no-perl.patch
index 5e2b807..14ddc6d 100644
--- a/packages/glibc/2.13/160-manual-no-perl.patch
+++ b/packages/glibc/2.12.1/0010-manual-no-perl.patch
@@ -4,9 +4,12 @@ deal, so just whine a little and continue on our merry way.
http://bugs.gentoo.org/60132
-diff -durN glibc-2.13.orig/manual/Makefile glibc-2.13/manual/Makefile
---- glibc-2.13.orig/manual/Makefile 2006-01-08 07:43:47.000000000 +0100
-+++ glibc-2.13/manual/Makefile 2009-11-13 00:49:54.000000000 +0100
+---
+ manual/Makefile | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/manual/Makefile
++++ b/manual/Makefile
@@ -104,9 +104,14 @@
libm-err.texi: stamp-libm-err
stamp-libm-err: libm-err-tab.pl $(wildcard $(foreach dir,$(sysdirs),\
diff --git a/packages/glibc/2.14.1/170-localedef-fix-trampoline.patch b/packages/glibc/2.12.1/0011-localedef-fix-trampoline.patch
index 3cc6559..3b8fd6e 100644
--- a/packages/glibc/2.14.1/170-localedef-fix-trampoline.patch
+++ b/packages/glibc/2.12.1/0011-localedef-fix-trampoline.patch
@@ -5,9 +5,12 @@
# DP: Upstream status: Unknown
# DP: Status Details: Unknown
# DP: Date: 2004-03-16
-diff -durN glibc-2.13.orig/locale/programs/3level.h glibc-2.13/locale/programs/3level.h
---- glibc-2.13.orig/locale/programs/3level.h 2007-07-16 02:54:59.000000000 +0200
-+++ glibc-2.13/locale/programs/3level.h 2009-11-13 00:49:56.000000000 +0100
+---
+# locale/programs/3level.h | 36 ++++++++++++++++++++++++++++++++++++
+# 1 file changed, 36 insertions(+)
+#
+--- a/locale/programs/3level.h
++++ b/locale/programs/3level.h
@@ -203,6 +203,42 @@
}
}
diff --git a/packages/glibc/2.14.1/180-resolv-dynamic.patch b/packages/glibc/2.12.1/0012-resolv-dynamic.patch
index e916bce..fcc2f80 100644
--- a/packages/glibc/2.14.1/180-resolv-dynamic.patch
+++ b/packages/glibc/2.12.1/0012-resolv-dynamic.patch
@@ -5,9 +5,12 @@ already running get the updated information.
http://bugs.gentoo.org/177416
-diff -durN glibc-2.13.orig/resolv/res_libc.c glibc-2.13/resolv/res_libc.c
---- glibc-2.13.orig/resolv/res_libc.c 2009-02-07 05:27:42.000000000 +0100
-+++ glibc-2.13/resolv/res_libc.c 2009-11-13 00:49:59.000000000 +0100
+---
+ resolv/res_libc.c | 15 +++++++++++++++
+ 1 file changed, 15 insertions(+)
+
+--- a/resolv/res_libc.c
++++ b/resolv/res_libc.c
@@ -22,6 +22,7 @@
#include <arpa/nameser.h>
#include <resolv.h>
diff --git a/packages/glibc/2.14.1/190-localedef-mmap.patch b/packages/glibc/2.12.1/0013-localedef-mmap.patch
index f3914cd..74e586e 100644
--- a/packages/glibc/2.14.1/190-localedef-mmap.patch
+++ b/packages/glibc/2.12.1/0013-localedef-mmap.patch
@@ -7,9 +7,12 @@ http://bugs.gentoo.org/289615
used later with MMAP_FIXED | MMAP_SHARED to cope with different
alignment restrictions.
-diff -durN glibc-2.13.orig/locale/programs/locarchive.c glibc-2.13/locale/programs/locarchive.c
---- glibc-2.13.orig/locale/programs/locarchive.c 2009-04-27 16:07:47.000000000 +0200
-+++ glibc-2.13/locale/programs/locarchive.c 2009-11-13 00:50:01.000000000 +0100
+---
+ locale/programs/locarchive.c | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+--- a/locale/programs/locarchive.c
++++ b/locale/programs/locarchive.c
@@ -134,7 +134,7 @@
size_t reserved = RESERVE_MMAP_SIZE;
int xflags = 0;
diff --git a/packages/glibc/2.13/200-fadvise64_64.patch b/packages/glibc/2.12.1/0014-fadvise64_64.patch
index 71bca38..191d833 100644
--- a/packages/glibc/2.13/200-fadvise64_64.patch
+++ b/packages/glibc/2.12.1/0014-fadvise64_64.patch
@@ -3,9 +3,8 @@ ripped from Debian
sysdeps/unix/sysv/linux/posix_fadvise.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/posix_fadvise.c glibc-2.13/sysdeps/unix/sysv/linux/posix_fadvise.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/posix_fadvise.c 2003-08-17 02:36:22.000000000 +0200
-+++ glibc-2.13/sysdeps/unix/sysv/linux/posix_fadvise.c 2009-11-13 00:50:03.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/posix_fadvise.c
++++ b/sysdeps/unix/sysv/linux/posix_fadvise.c
@@ -35,6 +35,19 @@
return INTERNAL_SYSCALL_ERRNO (ret, err);
return 0;
diff --git a/packages/glibc/2.13/220-section-comments.patch b/packages/glibc/2.12.1/0015-section-comments.patch
index d717829..5960ed0 100644
--- a/packages/glibc/2.13/220-section-comments.patch
+++ b/packages/glibc/2.12.1/0015-section-comments.patch
@@ -3,9 +3,12 @@ http://sources.redhat.com/ml/binutils/2004-04/msg00665.html
fixes building on some architectures (like m68k/arm/cris/etc...) because
it does the right thing
-diff -durN glibc-2.13.orig/include/libc-symbols.h glibc-2.13/include/libc-symbols.h
---- glibc-2.13.orig/include/libc-symbols.h 2009-03-14 00:51:46.000000000 +0100
-+++ glibc-2.13/include/libc-symbols.h 2009-11-13 00:50:07.000000000 +0100
+---
+ include/libc-symbols.h | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+--- a/include/libc-symbols.h
++++ b/include/libc-symbols.h
@@ -239,12 +239,12 @@
# define __make_section_unallocated(section_string)
# endif
diff --git a/packages/glibc/2.15/230-no-inline-gmon.patch b/packages/glibc/2.12.1/0016-no-inline-gmon.patch
index fa33c2b..ed02704 100644
--- a/packages/glibc/2.15/230-no-inline-gmon.patch
+++ b/packages/glibc/2.12.1/0016-no-inline-gmon.patch
@@ -19,12 +19,12 @@ Kazu Hirata
* sysdeps/generic/initfini.c (call_gmon_start): Add
__attribute__ ((noinline)).
-Index: sysdeps/generic/initfini.c
-===================================================================
+---
+ sysdeps/generic/initfini.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
-diff -durN glibc-2.13.orig/sysdeps/generic/initfini.c glibc-2.13/sysdeps/generic/initfini.c
---- glibc-2.13.orig/sysdeps/generic/initfini.c 2007-06-17 20:02:40.000000000 +0200
-+++ glibc-2.13/sysdeps/generic/initfini.c 2009-11-13 00:50:09.000000000 +0100
+--- a/sysdeps/generic/initfini.c
++++ b/sysdeps/generic/initfini.c
@@ -70,7 +70,7 @@
/* The beginning of _init: */
asm ("\n/*@_init_PROLOG_BEGINS*/");
diff --git a/packages/glibc/2.13/240-check_native-headers.patch b/packages/glibc/2.12.1/0017-check_native-headers.patch
index c936f71..2b1b619 100644
--- a/packages/glibc/2.13/240-check_native-headers.patch
+++ b/packages/glibc/2.12.1/0017-check_native-headers.patch
@@ -4,9 +4,12 @@ many ports hit this warning:
snipped from suse
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/check_native.c glibc-2.13/sysdeps/unix/sysv/linux/check_native.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/check_native.c 2007-11-24 04:12:17.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/check_native.c 2009-11-13 00:50:11.000000000 +0100
+---
+ sysdeps/unix/sysv/linux/check_native.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/sysdeps/unix/sysv/linux/check_native.c
++++ b/sysdeps/unix/sysv/linux/check_native.c
@@ -23,6 +23,7 @@
#include <stddef.h>
#include <stdint.h>
diff --git a/packages/glibc/2.13/250-fix-pr631.patch b/packages/glibc/2.12.1/0018-fix-pr631.patch
index a48912e..636c45d 100644
--- a/packages/glibc/2.13/250-fix-pr631.patch
+++ b/packages/glibc/2.12.1/0018-fix-pr631.patch
@@ -14,9 +14,13 @@ when building glibc with --enable-static-nss.
See http://sources.redhat.com/bugzilla/show_bug.cgi?id=631
-diff -durN glibc-2.13.orig/Makeconfig glibc-2.13/Makeconfig
---- glibc-2.13.orig/Makeconfig 2009-11-13 00:49:41.000000000 +0100
-+++ glibc-2.13/Makeconfig 2009-11-13 00:50:13.000000000 +0100
+---
+ Makeconfig | 2 +-
+ elf/Makefile | 7 +++++++
+ 2 files changed, 8 insertions(+), 1 deletion(-)
+
+--- a/Makeconfig
++++ b/Makeconfig
@@ -531,7 +531,7 @@
# The static libraries.
@@ -26,9 +30,8 @@ diff -durN glibc-2.13.orig/Makeconfig glibc-2.13/Makeconfig
else
ifeq (yes,$(build-shared))
# We can try to link the programs with lib*_pic.a...
-diff -durN glibc-2.13.orig/elf/Makefile glibc-2.13/elf/Makefile
---- glibc-2.13.orig/elf/Makefile 2009-01-31 01:20:55.000000000 +0100
-+++ glibc-2.13/elf/Makefile 2009-11-13 00:50:13.000000000 +0100
+--- a/elf/Makefile
++++ b/elf/Makefile
@@ -146,6 +146,13 @@
install-bin-script = ldd
endif
diff --git a/packages/glibc/2.14.1/260-assume-pipe2.patch b/packages/glibc/2.12.1/0019-assume-pipe2.patch
index 42e8f4e..0074ea6 100644
--- a/packages/glibc/2.14.1/260-assume-pipe2.patch
+++ b/packages/glibc/2.12.1/0019-assume-pipe2.patch
@@ -20,9 +20,12 @@ __have_sock_cloexec and __have_pipe2 to true. but if glibc was built against
older kernel headers where __NR_pipe2 does not exist, glibc will have a ENOSYS
stub for it. so popen() will always fail as glibc assumes pipe2() works.
-diff -durN glibc-2.13.orig/socket/have_sock_cloexec.c glibc-2.13/socket/have_sock_cloexec.c
---- glibc-2.13.orig/socket/have_sock_cloexec.c 2008-07-25 18:46:23.000000000 +0200
-+++ glibc-2.13/socket/have_sock_cloexec.c 2009-11-13 00:50:15.000000000 +0100
+---
+ socket/have_sock_cloexec.c | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/socket/have_sock_cloexec.c
++++ b/socket/have_sock_cloexec.c
@@ -16,9 +16,14 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
diff --git a/packages/glibc/2.14.1/270-china.patch b/packages/glibc/2.12.1/0020-china.patch
index 41d7759..b323cf6 100644
--- a/packages/glibc/2.14.1/270-china.patch
+++ b/packages/glibc/2.12.1/0020-china.patch
@@ -1,8 +1,11 @@
-diff -durN glibc-2.13.orig/localedata/locales/zh_TW glibc-2.13/localedata/locales/zh_TW
---- glibc-2.13.orig/localedata/locales/zh_TW 2004-11-01 00:42:28.000000000 +0100
-+++ glibc-2.13/localedata/locales/zh_TW 2009-11-13 00:50:17.000000000 +0100
+---
+ localedata/locales/zh_TW | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+--- a/localedata/locales/zh_TW
++++ b/localedata/locales/zh_TW
@@ -1,7 +1,7 @@
comment_char %
escape_char /
diff --git a/packages/glibc/2.14.1/280-new-valencian-locale.patch b/packages/glibc/2.12.1/0021-new-valencian-locale.patch
index 4cdd108..bddc4c7 100644
--- a/packages/glibc/2.14.1/280-new-valencian-locale.patch
+++ b/packages/glibc/2.12.1/0021-new-valencian-locale.patch
@@ -1,9 +1,13 @@
http://bugs.gentoo.org/show_bug.cgi?id=131815
http://sourceware.org/bugzilla/show_bug.cgi?id=2522
-diff -durN glibc-2.13.orig/localedata/SUPPORTED glibc-2.13/localedata/SUPPORTED
---- glibc-2.13.orig/localedata/SUPPORTED 2009-04-18 10:43:52.000000000 +0200
-+++ glibc-2.13/localedata/SUPPORTED 2009-11-13 00:50:20.000000000 +0100
+---
+ localedata/SUPPORTED | 2
+ localedata/locales/ca_ES@valencia | 96 ++++++++++++++++++++++++++++++++++++++
+ 2 files changed, 98 insertions(+)
+
+--- a/localedata/SUPPORTED
++++ b/localedata/SUPPORTED
@@ -72,6 +72,8 @@
ca_ES.UTF-8/UTF-8 \
ca_ES/ISO-8859-1 \
@@ -13,9 +17,8 @@ diff -durN glibc-2.13.orig/localedata/SUPPORTED glibc-2.13/localedata/SUPPORTED
ca_FR.UTF-8/UTF-8 \
ca_FR/ISO-8859-15 \
ca_IT.UTF-8/UTF-8 \
-diff -durN glibc-2.13.orig/localedata/locales/ca_ES@valencia glibc-2.13/localedata/locales/ca_ES@valencia
---- glibc-2.13.orig/localedata/locales/ca_ES@valencia 1970-01-01 01:00:00.000000000 +0100
-+++ glibc-2.13/localedata/locales/ca_ES@valencia 2009-11-13 00:50:20.000000000 +0100
+--- /dev/null
++++ b/localedata/locales/ca_ES@valencia
@@ -0,0 +1,96 @@
+comment_char %
+escape_char /
diff --git a/packages/glibc/2.13/300-macos-cross-rpcgen.patch b/packages/glibc/2.12.1/0022-macos-cross-rpcgen.patch
index e654644..155b4f5 100644
--- a/packages/glibc/2.13/300-macos-cross-rpcgen.patch
+++ b/packages/glibc/2.12.1/0022-macos-cross-rpcgen.patch
@@ -14,11 +14,13 @@ Date: Sat Sep 7 00:01:08 2013 +0800
Signed-off-by: Jia Liu <proljc@gmail.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
-diff --git a/sunrpc/rpc/types.h b/sunrpc/rpc/types.h
-index 3dca5c4..beded52 100644
+---
+ sunrpc/rpc/types.h | 5 +++++
+ 1 file changed, 5 insertions(+)
+
--- a/sunrpc/rpc/types.h
+++ b/sunrpc/rpc/types.h
-@@ -69,6 +69,11 @@ typedef unsigned long rpcport_t;
+@@ -68,6 +68,11 @@
#include <sys/types.h>
#endif
diff --git a/packages/glibc/2.13/300-nscd-one-fork.patch b/packages/glibc/2.12.1/0023-nscd-one-fork.patch
index adc9b3f..47217b3 100644
--- a/packages/glibc/2.13/300-nscd-one-fork.patch
+++ b/packages/glibc/2.12.1/0023-nscd-one-fork.patch
@@ -2,9 +2,12 @@ only fork one to assist in stop-start-daemon assumptions about daemon behavior
http://bugs.gentoo.org/190785
-diff -durN glibc-2.13.orig/nscd/nscd.c glibc-2.13/nscd/nscd.c
---- glibc-2.13.orig/nscd/nscd.c 2009-02-06 21:10:27.000000000 +0100
-+++ glibc-2.13/nscd/nscd.c 2009-11-13 00:50:24.000000000 +0100
+---
+ nscd/nscd.c | 12 +++---------
+ 1 file changed, 3 insertions(+), 9 deletions(-)
+
+--- a/nscd/nscd.c
++++ b/nscd/nscd.c
@@ -182,6 +182,9 @@
if (pid != 0)
exit (0);
diff --git a/packages/glibc/2.12.1/310-hppa-nptl-carlos.patch b/packages/glibc/2.12.1/0024-hppa-nptl-carlos.patch
index 947bb58..a01ac9b 100644
--- a/packages/glibc/2.12.1/310-hppa-nptl-carlos.patch
+++ b/packages/glibc/2.12.1/0024-hppa-nptl-carlos.patch
@@ -1,8 +1,17 @@
-diff -durN glibc-2.12.1.orig/elf/rtld.c glibc-2.12.1/elf/rtld.c
---- glibc-2.12.1.orig/elf/rtld.c 2009-04-17 02:00:08.000000000 +0200
-+++ glibc-2.12.1/elf/rtld.c 2009-11-13 00:50:26.000000000 +0100
+---
+ elf/rtld.c | 10 +++++-----
+ include/atomic.h | 26 +++++++++++++-------------
+ nptl/Makefile | 35 ++++++++++++++++++++++++++++++++---
+ nptl/pthread_barrier_wait.c | 2 +-
+ nptl/sysdeps/pthread/Makefile | 2 ++
+ stdio-common/Makefile | 2 +-
+ sunrpc/clnt_udp.c | 2 +-
+ 7 files changed, 55 insertions(+), 24 deletions(-)
+
+--- a/elf/rtld.c
++++ b/elf/rtld.c
@@ -390,14 +390,14 @@
know it is available. We do not have to clear the memory if we
do not have to use the temporary bootstrap_map. Global variables
@@ -23,9 +32,8 @@ diff -durN glibc-2.12.1.orig/elf/rtld.c glibc-2.12.1/elf/rtld.c
# endif
# if USE___THREAD
bootstrap_map.l_tls_modid = 0;
-diff -durN glibc-2.12.1.orig/include/atomic.h glibc-2.12.1/include/atomic.h
---- glibc-2.12.1.orig/include/atomic.h 2009-02-09 00:49:53.000000000 +0100
-+++ glibc-2.12.1/include/atomic.h 2009-11-13 00:50:26.000000000 +0100
+--- a/include/atomic.h
++++ b/include/atomic.h
@@ -185,7 +185,7 @@
__typeof (*(mem)) __atg5_value = (newvalue); \
\
@@ -143,9 +151,8 @@ diff -durN glibc-2.12.1.orig/include/atomic.h glibc-2.12.1/include/atomic.h
while (__builtin_expect \
(atomic_compare_and_exchange_bool_acq (__atg19_memp, \
__atg19_old | __atg19_mask,\
-diff -durN glibc-2.12.1.orig/nptl/Makefile glibc-2.12.1/nptl/Makefile
---- glibc-2.12.1.orig/nptl/Makefile 2008-11-12 14:38:23.000000000 +0100
-+++ glibc-2.12.1/nptl/Makefile 2009-11-13 00:50:26.000000000 +0100
+--- a/nptl/Makefile
++++ b/nptl/Makefile
@@ -264,9 +264,9 @@
# Files which must not be linked with libpthread.
tests-nolibpthread = tst-unload
@@ -195,9 +202,8 @@ diff -durN glibc-2.12.1.orig/nptl/Makefile glibc-2.12.1/nptl/Makefile
CFLAGS-tst-align.c += $(stack-align-test-flags)
CFLAGS-tst-align3.c += $(stack-align-test-flags)
CFLAGS-tst-initializers1.c = -W -Wall -Werror
-diff -durN glibc-2.12.1.orig/nptl/pthread_barrier_wait.c glibc-2.12.1/nptl/pthread_barrier_wait.c
---- glibc-2.12.1.orig/nptl/pthread_barrier_wait.c 2007-08-01 06:18:50.000000000 +0200
-+++ glibc-2.12.1/nptl/pthread_barrier_wait.c 2009-11-13 00:50:26.000000000 +0100
+--- a/nptl/pthread_barrier_wait.c
++++ b/nptl/pthread_barrier_wait.c
@@ -64,7 +64,7 @@
do
lll_futex_wait (&ibarrier->curr_event, event,
@@ -207,9 +213,8 @@ diff -durN glibc-2.12.1.orig/nptl/pthread_barrier_wait.c glibc-2.12.1/nptl/pthre
}
/* Make sure the init_count is stored locally or in a register. */
-diff -durN glibc-2.12.1.orig/nptl/sysdeps/pthread/Makefile glibc-2.12.1/nptl/sysdeps/pthread/Makefile
---- glibc-2.12.1.orig/nptl/sysdeps/pthread/Makefile 2006-02-28 08:09:41.000000000 +0100
-+++ glibc-2.12.1/nptl/sysdeps/pthread/Makefile 2009-11-13 00:50:26.000000000 +0100
+--- a/nptl/sysdeps/pthread/Makefile
++++ b/nptl/sysdeps/pthread/Makefile
@@ -33,7 +33,9 @@
ifeq ($(have-forced-unwind),yes)
@@ -220,9 +225,8 @@ diff -durN glibc-2.12.1.orig/nptl/sysdeps/pthread/Makefile glibc-2.12.1/nptl/sys
endif
endif
-diff -durN glibc-2.12.1.orig/stdio-common/Makefile glibc-2.12.1/stdio-common/Makefile
---- glibc-2.12.1.orig/stdio-common/Makefile 2009-04-11 07:29:56.000000000 +0200
-+++ glibc-2.12.1/stdio-common/Makefile 2009-11-13 00:50:26.000000000 +0100
+--- a/stdio-common/Makefile
++++ b/stdio-common/Makefile
@@ -82,7 +82,7 @@
$(SHELL) -e tst-printf.sh $(common-objpfx) '$(run-program-prefix)'
endif
@@ -232,9 +236,8 @@ diff -durN glibc-2.12.1.orig/stdio-common/Makefile glibc-2.12.1/stdio-common/Mak
CFLAGS-vfwprintf.c = -Wno-uninitialized
CFLAGS-tst-printf.c = -Wno-format
CFLAGS-tstdiomisc.c = -Wno-format
-diff -durN glibc-2.12.1.orig/sunrpc/clnt_udp.c glibc-2.12.1/sunrpc/clnt_udp.c
---- glibc-2.12.1.orig/sunrpc/clnt_udp.c 2008-07-26 10:42:44.000000000 +0200
-+++ glibc-2.12.1/sunrpc/clnt_udp.c 2009-11-13 00:50:26.000000000 +0100
+--- a/sunrpc/clnt_udp.c
++++ b/sunrpc/clnt_udp.c
@@ -456,7 +456,7 @@
while (inlen < 0 && errno == EINTR);
if (inlen < 0)
diff --git a/packages/glibc/2.16.0/340-dl_execstack-PaX-support.patch b/packages/glibc/2.12.1/0025-dl_execstack-PaX-support.patch
index 2402af0..bfd7557 100644
--- a/packages/glibc/2.16.0/340-dl_execstack-PaX-support.patch
+++ b/packages/glibc/2.12.1/0025-dl_execstack-PaX-support.patch
@@ -8,9 +8,13 @@
Patch also NPTL. Bug #116086. <kevquinn@gentoo.org> (20 Dec 2005).
-diff -durN glibc-2.13.orig/nptl/allocatestack.c glibc-2.13/nptl/allocatestack.c
---- glibc-2.13.orig/nptl/allocatestack.c 2009-01-29 21:34:16.000000000 +0100
-+++ glibc-2.13/nptl/allocatestack.c 2009-11-13 00:50:33.000000000 +0100
+---
+ nptl/allocatestack.c | 3 ++-
+ sysdeps/unix/sysv/linux/dl-execstack.c | 19 ++++++++++++++++---
+ 2 files changed, 18 insertions(+), 4 deletions(-)
+
+--- a/nptl/allocatestack.c
++++ b/nptl/allocatestack.c
@@ -329,7 +329,8 @@
# error "Define either _STACK_GROWS_DOWN or _STACK_GROWS_UP"
#endif
@@ -21,9 +25,8 @@ diff -durN glibc-2.13.orig/nptl/allocatestack.c glibc-2.13/nptl/allocatestack.c
return 0;
}
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/dl-execstack.c glibc-2.13/sysdeps/unix/sysv/linux/dl-execstack.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/dl-execstack.c 2006-01-08 09:21:15.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/dl-execstack.c 2009-11-13 00:50:33.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/dl-execstack.c
++++ b/sysdeps/unix/sysv/linux/dl-execstack.c
@@ -63,7 +63,10 @@
else
# endif
diff --git a/packages/glibc/2.14.1/350-pre20040117-pt_pax.patch b/packages/glibc/2.12.1/0026-pre20040117-pt_pax.patch
index f8f6b83..ec17d24 100644
--- a/packages/glibc/2.14.1/350-pre20040117-pt_pax.patch
+++ b/packages/glibc/2.12.1/0026-pre20040117-pt_pax.patch
@@ -1,8 +1,11 @@
-diff -durN glibc-2.13.orig/elf/elf.h glibc-2.13/elf/elf.h
---- glibc-2.13.orig/elf/elf.h 2009-04-15 02:15:54.000000000 +0200
-+++ glibc-2.13/elf/elf.h 2009-11-13 00:50:35.000000000 +0100
+---
+ elf/elf.h | 13 +++++++++++++
+ 1 file changed, 13 insertions(+)
+
+--- a/elf/elf.h
++++ b/elf/elf.h
@@ -580,6 +580,7 @@
#define PT_GNU_EH_FRAME 0x6474e550 /* GCC .eh_frame_hdr segment */
#define PT_GNU_STACK 0x6474e551 /* Indicates stack executability */
diff --git a/packages/glibc/2.14.1/360-tests-sandbox-libdl-paths.patch b/packages/glibc/2.12.1/0027-tests-sandbox-libdl-paths.patch
index 9f78c52..1c4ee59 100644
--- a/packages/glibc/2.14.1/360-tests-sandbox-libdl-paths.patch
+++ b/packages/glibc/2.12.1/0027-tests-sandbox-libdl-paths.patch
@@ -15,9 +15,23 @@ Fix by Wormo
http://bugs.gentoo.org/56898
-diff -durN glibc-2.13.orig/grp/tst_fgetgrent.sh glibc-2.13/grp/tst_fgetgrent.sh
---- glibc-2.13.orig/grp/tst_fgetgrent.sh 2001-07-06 06:54:46.000000000 +0200
-+++ glibc-2.13/grp/tst_fgetgrent.sh 2009-11-13 00:50:37.000000000 +0100
+---
+ grp/tst_fgetgrent.sh | 3 ++-
+ iconvdata/run-iconv-test.sh | 2 +-
+ iconvdata/tst-table.sh | 5 ++++-
+ intl/tst-codeset.sh | 3 +++
+ intl/tst-gettext.sh | 5 ++++-
+ intl/tst-gettext2.sh | 5 ++++-
+ intl/tst-translit.sh | 5 ++++-
+ malloc/tst-mtrace.sh | 5 ++++-
+ nptl/tst-tls6.sh | 4 ++--
+ posix/globtest.sh | 2 +-
+ posix/tst-getconf.sh | 5 ++++-
+ posix/wordexp-tst.sh | 5 ++++-
+ 12 files changed, 37 insertions(+), 12 deletions(-)
+
+--- a/grp/tst_fgetgrent.sh
++++ b/grp/tst_fgetgrent.sh
@@ -24,7 +24,8 @@
rtld_installed_name=$1; shift
@@ -28,9 +42,8 @@ diff -durN glibc-2.13.orig/grp/tst_fgetgrent.sh glibc-2.13/grp/tst_fgetgrent.sh
result=0
-diff -durN glibc-2.13.orig/iconvdata/run-iconv-test.sh glibc-2.13/iconvdata/run-iconv-test.sh
---- glibc-2.13.orig/iconvdata/run-iconv-test.sh 2008-05-15 03:59:44.000000000 +0200
-+++ glibc-2.13/iconvdata/run-iconv-test.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/iconvdata/run-iconv-test.sh
++++ b/iconvdata/run-iconv-test.sh
@@ -34,7 +34,7 @@
export GCONV_PATH
@@ -40,9 +53,8 @@ diff -durN glibc-2.13.orig/iconvdata/run-iconv-test.sh glibc-2.13/iconvdata/run-
# How the start the iconv(1) program.
ICONV='$codir/elf/ld.so --library-path $LIBPATH --inhibit-rpath ${from}.so \
-diff -durN glibc-2.13.orig/iconvdata/tst-table.sh glibc-2.13/iconvdata/tst-table.sh
---- glibc-2.13.orig/iconvdata/tst-table.sh 2002-04-24 23:39:35.000000000 +0200
-+++ glibc-2.13/iconvdata/tst-table.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/iconvdata/tst-table.sh
++++ b/iconvdata/tst-table.sh
@@ -59,8 +59,11 @@
irreversible=${charset}.irreversible
fi
@@ -56,9 +68,8 @@ diff -durN glibc-2.13.orig/iconvdata/tst-table.sh glibc-2.13/iconvdata/tst-table
${objpfx}tst-table-from ${charset} \
> ${objpfx}tst-${charset}.table
-diff -durN glibc-2.13.orig/intl/tst-codeset.sh glibc-2.13/intl/tst-codeset.sh
---- glibc-2.13.orig/intl/tst-codeset.sh 2005-04-06 04:18:35.000000000 +0200
-+++ glibc-2.13/intl/tst-codeset.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-codeset.sh
++++ b/intl/tst-codeset.sh
@@ -37,6 +37,9 @@
LOCPATH=${common_objpfx}localedata
export LOCPATH
@@ -69,9 +80,8 @@ diff -durN glibc-2.13.orig/intl/tst-codeset.sh glibc-2.13/intl/tst-codeset.sh
${common_objpfx}elf/ld.so --library-path $common_objpfx \
${objpfx}tst-codeset > ${objpfx}tst-codeset.out
-diff -durN glibc-2.13.orig/intl/tst-gettext.sh glibc-2.13/intl/tst-gettext.sh
---- glibc-2.13.orig/intl/tst-gettext.sh 2004-08-15 21:28:18.000000000 +0200
-+++ glibc-2.13/intl/tst-gettext.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-gettext.sh
++++ b/intl/tst-gettext.sh
@@ -51,9 +51,12 @@
LOCPATH=${common_objpfx}localedata
export LOCPATH
@@ -86,9 +96,8 @@ diff -durN glibc-2.13.orig/intl/tst-gettext.sh glibc-2.13/intl/tst-gettext.sh
${objpfx}tst-gettext > ${objpfx}tst-gettext.out ${objpfx}domaindir
exit $?
-diff -durN glibc-2.13.orig/intl/tst-gettext2.sh glibc-2.13/intl/tst-gettext2.sh
---- glibc-2.13.orig/intl/tst-gettext2.sh 2005-05-04 19:54:48.000000000 +0200
-+++ glibc-2.13/intl/tst-gettext2.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-gettext2.sh
++++ b/intl/tst-gettext2.sh
@@ -65,8 +65,11 @@
LOCPATH=${objpfx}domaindir
export LOCPATH
@@ -102,9 +111,8 @@ diff -durN glibc-2.13.orig/intl/tst-gettext2.sh glibc-2.13/intl/tst-gettext2.sh
${objpfx}tst-gettext2 > ${objpfx}tst-gettext2.out ${objpfx}domaindir &&
cmp ${objpfx}tst-gettext2.out - <<EOF
String1 - Lang1: 1st string
-diff -durN glibc-2.13.orig/intl/tst-translit.sh glibc-2.13/intl/tst-translit.sh
---- glibc-2.13.orig/intl/tst-translit.sh 2005-05-04 19:56:10.000000000 +0200
-+++ glibc-2.13/intl/tst-translit.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-translit.sh
++++ b/intl/tst-translit.sh
@@ -36,7 +36,10 @@
LOCPATH=${common_objpfx}localedata
export LOCPATH
@@ -117,9 +125,8 @@ diff -durN glibc-2.13.orig/intl/tst-translit.sh glibc-2.13/intl/tst-translit.sh
${objpfx}tst-translit > ${objpfx}tst-translit.out ${objpfx}domaindir
exit $?
-diff -durN glibc-2.13.orig/malloc/tst-mtrace.sh glibc-2.13/malloc/tst-mtrace.sh
---- glibc-2.13.orig/malloc/tst-mtrace.sh 2005-10-15 01:40:35.000000000 +0200
-+++ glibc-2.13/malloc/tst-mtrace.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/malloc/tst-mtrace.sh
++++ b/malloc/tst-mtrace.sh
@@ -24,9 +24,12 @@
status=0
trap "rm -f ${common_objpfx}malloc/tst-mtrace.leak; exit 1" 1 2 15
@@ -134,9 +141,8 @@ diff -durN glibc-2.13.orig/malloc/tst-mtrace.sh glibc-2.13/malloc/tst-mtrace.sh
${common_objpfx}malloc/tst-mtrace || status=1
if test $status -eq 0 && test -f ${common_objpfx}malloc/mtrace; then
-diff -durN glibc-2.13.orig/nptl/tst-tls6.sh glibc-2.13/nptl/tst-tls6.sh
---- glibc-2.13.orig/nptl/tst-tls6.sh 2003-09-03 00:02:59.000000000 +0200
-+++ glibc-2.13/nptl/tst-tls6.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/nptl/tst-tls6.sh
++++ b/nptl/tst-tls6.sh
@@ -5,8 +5,8 @@
rtld_installed_name=$1; shift
logfile=$common_objpfx/nptl/tst-tls6.out
@@ -148,9 +154,8 @@ diff -durN glibc-2.13.orig/nptl/tst-tls6.sh glibc-2.13/nptl/tst-tls6.sh
tst_tls5="${elf_objpfx}${rtld_installed_name} --library-path ${library_path} \
${common_objpfx}/nptl/tst-tls5"
-diff -durN glibc-2.13.orig/posix/globtest.sh glibc-2.13/posix/globtest.sh
---- glibc-2.13.orig/posix/globtest.sh 2008-12-06 07:05:39.000000000 +0100
-+++ glibc-2.13/posix/globtest.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/posix/globtest.sh
++++ b/posix/globtest.sh
@@ -18,7 +18,7 @@
esac
@@ -160,9 +165,8 @@ diff -durN glibc-2.13.orig/posix/globtest.sh glibc-2.13/posix/globtest.sh
# Since we use `sort' we must make sure to use the same locale everywhere.
LC_ALL=C
-diff -durN glibc-2.13.orig/posix/tst-getconf.sh glibc-2.13/posix/tst-getconf.sh
---- glibc-2.13.orig/posix/tst-getconf.sh 2002-09-01 13:11:25.000000000 +0200
-+++ glibc-2.13/posix/tst-getconf.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/posix/tst-getconf.sh
++++ b/posix/tst-getconf.sh
@@ -10,7 +10,10 @@
else
rtld_installed_name=$1; shift
@@ -175,9 +179,8 @@ diff -durN glibc-2.13.orig/posix/tst-getconf.sh glibc-2.13/posix/tst-getconf.sh
}
fi
-diff -durN glibc-2.13.orig/posix/wordexp-tst.sh glibc-2.13/posix/wordexp-tst.sh
---- glibc-2.13.orig/posix/wordexp-tst.sh 2000-10-20 18:23:30.000000000 +0200
-+++ glibc-2.13/posix/wordexp-tst.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/posix/wordexp-tst.sh
++++ b/posix/wordexp-tst.sh
@@ -19,8 +19,11 @@
"
export IFS
diff --git a/packages/glibc/2.12.1/370-fnmatch.patch b/packages/glibc/2.12.1/0028-fnmatch.patch
index f345b35..992645a 100644
--- a/packages/glibc/2.12.1/370-fnmatch.patch
+++ b/packages/glibc/2.12.1/0028-fnmatch.patch
@@ -10,12 +10,12 @@ Andreas.
* posix/fnmatch.c (fnmatch): If conversion to wide character
fails fall back to single byte matching.
-Index: posix/fnmatch.c
-===================================================================
+---
+ posix/fnmatch.c | 16 ++++++++--------
+ 1 file changed, 8 insertions(+), 8 deletions(-)
-diff -durN glibc-2.12.1.orig/posix/fnmatch.c glibc-2.12.1/posix/fnmatch.c
---- glibc-2.12.1.orig/posix/fnmatch.c 2007-07-28 22:35:00.000000000 +0200
-+++ glibc-2.12.1/posix/fnmatch.c 2009-11-13 00:50:39.000000000 +0100
+--- a/posix/fnmatch.c
++++ b/posix/fnmatch.c
@@ -327,6 +327,7 @@
# if HANDLE_MULTIBYTE
if (__builtin_expect (MB_CUR_MAX, 1) != 1)
diff --git a/packages/glibc/2.13/380-dont-build-timezone.patch b/packages/glibc/2.12.1/0029-dont-build-timezone.patch
index 11c358e..b0fb8fc 100644
--- a/packages/glibc/2.13/380-dont-build-timezone.patch
+++ b/packages/glibc/2.12.1/0029-dont-build-timezone.patch
@@ -1,8 +1,11 @@
timezone data has been split into the package sys-libs/timezone-data
-diff -durN glibc-2.13.orig/Makeconfig glibc-2.13/Makeconfig
---- glibc-2.13.orig/Makeconfig 2009-11-13 00:50:13.000000000 +0100
-+++ glibc-2.13/Makeconfig 2009-11-13 00:50:41.000000000 +0100
+---
+ Makeconfig | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/Makeconfig
++++ b/Makeconfig
@@ -944,7 +944,7 @@
stdlib stdio-common libio malloc string wcsmbs time dirent \
grp pwd posix io termios resource misc socket sysvipc gmon \
diff --git a/packages/glibc/2.13/400-alpha-xstat.patch b/packages/glibc/2.12.1/0030-alpha-xstat.patch
index 6e4ab8f..4fa9517 100644
--- a/packages/glibc/2.13/400-alpha-xstat.patch
+++ b/packages/glibc/2.12.1/0030-alpha-xstat.patch
@@ -1,6 +1,9 @@
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h 2009-05-09 08:54:20.000000000 +0200
-+++ glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:50:45.000000000 +0100
+---
+ sysdeps/unix/sysv/linux/kernel-features.h | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
@@ -386,6 +386,11 @@
# define __ASSUME_GETDENTS32_D_TYPE 1
#endif
diff --git a/packages/glibc/2.12.1/0031-alpha-creat.patch b/packages/glibc/2.12.1/0031-alpha-creat.patch
new file mode 100644
index 0000000..6ef5278
--- /dev/null
+++ b/packages/glibc/2.12.1/0031-alpha-creat.patch
@@ -0,0 +1,17 @@
+alpha does not have a __NR_creat
+
+http://bugs.gentoo.org/227275
+http://sourceware.org/bugzilla/show_bug.cgi?id=6650
+
+---
+ sysdeps/unix/sysv/linux/wordsize-64/creat64.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+--- a/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
++++ b/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
+@@ -1 +1,5 @@
+ /* Defined as alias for the syscall. */
++#include <sysdep.h>
++#ifndef __NR_creat
++#include "../../../../../io/creat64.c"
++#endif
diff --git a/packages/glibc/2.12.1/490-alpha_alpha-add-fdatasync-support.patch b/packages/glibc/2.12.1/0032-alpha_alpha-add-fdatasync-support.patch
index 9d35ebd..df9f1b2 100644
--- a/packages/glibc/2.12.1/490-alpha_alpha-add-fdatasync-support.patch
+++ b/packages/glibc/2.12.1/0032-alpha_alpha-add-fdatasync-support.patch
@@ -13,9 +13,8 @@
sysdeps/unix/sysv/linux/syscalls.list | 1
4 files changed, 76 insertions(+), 1 deletion(-)
-diff -durN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/Makefile glibc-2.12.1/sysdeps/unix/sysv/linux/Makefile
---- glibc-2.12.1.orig/sysdeps/unix/sysv/linux/Makefile 2009-03-02 17:15:13.000000000 +0100
-+++ glibc-2.12.1/sysdeps/unix/sysv/linux/Makefile 2009-11-13 00:51:04.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/Makefile
++++ b/sysdeps/unix/sysv/linux/Makefile
@@ -20,6 +20,7 @@
setfsuid setfsgid makedev epoll_pwait signalfd \
eventfd eventfd_read eventfd_write
@@ -24,9 +23,8 @@ diff -durN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/Makefile glibc-2.12.1/sysde
CFLAGS-gethostid.c = -fexceptions
sysdep_headers += sys/mount.h sys/acct.h sys/sysctl.h \
-diff -durN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/fdatasync.c glibc-2.12.1/sysdeps/unix/sysv/linux/fdatasync.c
---- glibc-2.12.1.orig/sysdeps/unix/sysv/linux/fdatasync.c 1970-01-01 01:00:00.000000000 +0100
-+++ glibc-2.12.1/sysdeps/unix/sysv/linux/fdatasync.c 2009-11-13 00:51:04.000000000 +0100
+--- /dev/null
++++ b/sysdeps/unix/sysv/linux/fdatasync.c
@@ -0,0 +1,69 @@
+/* fdatasync -- synchronize at least the data part of a file with
+ the underlying media. Linux version.
@@ -97,9 +95,8 @@ diff -durN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/fdatasync.c glibc-2.12.1/sy
+
+weak_alias (__fdatasync, fdatasync)
+
-diff -durN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.12.1/sysdeps/unix/sysv/linux/kernel-features.h
---- glibc-2.12.1.orig/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:50:45.000000000 +0100
-+++ glibc-2.12.1/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:51:04.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
@@ -459,6 +459,12 @@
# define __ASSUME_FUTEX_LOCK_PI 1
#endif
@@ -113,9 +110,8 @@ diff -durN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.1
/* Support for utimensat syscall was added in 2.6.22, on SH
only after 2.6.22-rc1. */
#if __LINUX_KERNEL_VERSION >= 0x020616 \
-diff -durN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/syscalls.list glibc-2.12.1/sysdeps/unix/sysv/linux/syscalls.list
---- glibc-2.12.1.orig/sysdeps/unix/sysv/linux/syscalls.list 2008-08-02 01:29:08.000000000 +0200
-+++ glibc-2.12.1/sysdeps/unix/sysv/linux/syscalls.list 2009-11-13 00:51:04.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/syscalls.list
++++ b/sysdeps/unix/sysv/linux/syscalls.list
@@ -11,7 +11,6 @@
epoll_create1 EXTRA epoll_create1 i:i epoll_create1
epoll_ctl EXTRA epoll_ctl i:iiip epoll_ctl
diff --git a/packages/glibc/2.13/560-ppc-atomic.patch b/packages/glibc/2.12.1/0033-ppc-atomic.patch
index ee1cb90..a38c1c5 100644
--- a/packages/glibc/2.13/560-ppc-atomic.patch
+++ b/packages/glibc/2.12.1/0033-ppc-atomic.patch
@@ -1,14 +1,13 @@
sniped from suse
-Index: sysdeps/powerpc/bits/atomic.h
-===================================================================
-RCS file: /cvs/glibc/libc/sysdeps/powerpc/bits/atomic.h,v
-retrieving revision 1.17
-diff -u -a -p -r1.17 atomic.h
+---
+ sysdeps/powerpc/bits/atomic.h | 66 ++++++++++-----------
+ sysdeps/powerpc/powerpc32/bits/atomic.h | 16 ++---
+ sysdeps/powerpc/powerpc64/bits/atomic.h | 98 ++++++++++++++++----------------
+ 3 files changed, 90 insertions(+), 90 deletions(-)
-diff -durN glibc-2.13.orig/sysdeps/powerpc/bits/atomic.h glibc-2.13/sysdeps/powerpc/bits/atomic.h
---- glibc-2.13.orig/sysdeps/powerpc/bits/atomic.h 2007-03-26 22:15:28.000000000 +0200
-+++ glibc-2.13/sysdeps/powerpc/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
+--- a/sysdeps/powerpc/bits/atomic.h
++++ b/sysdeps/powerpc/bits/atomic.h
@@ -85,14 +85,14 @@
__typeof (*(mem)) __tmp; \
__typeof (mem) __memp = (mem); \
@@ -151,9 +150,8 @@ diff -durN glibc-2.13.orig/sysdeps/powerpc/bits/atomic.h glibc-2.13/sysdeps/powe
: "cr0", "memory"); \
__val; \
})
-diff -durN glibc-2.13.orig/sysdeps/powerpc/powerpc32/bits/atomic.h glibc-2.13/sysdeps/powerpc/powerpc32/bits/atomic.h
---- glibc-2.13.orig/sysdeps/powerpc/powerpc32/bits/atomic.h 2007-03-26 22:15:45.000000000 +0200
-+++ glibc-2.13/sysdeps/powerpc/powerpc32/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
+--- a/sysdeps/powerpc/powerpc32/bits/atomic.h
++++ b/sysdeps/powerpc/powerpc32/bits/atomic.h
@@ -44,14 +44,14 @@
({ \
unsigned int __tmp; \
@@ -192,9 +190,8 @@ diff -durN glibc-2.13.orig/sysdeps/powerpc/powerpc32/bits/atomic.h glibc-2.13/sy
: "cr0", "memory"); \
__tmp != 0; \
})
-diff -durN glibc-2.13.orig/sysdeps/powerpc/powerpc64/bits/atomic.h glibc-2.13/sysdeps/powerpc/powerpc64/bits/atomic.h
---- glibc-2.13.orig/sysdeps/powerpc/powerpc64/bits/atomic.h 2007-03-26 22:16:03.000000000 +0200
-+++ glibc-2.13/sysdeps/powerpc/powerpc64/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
+--- a/sysdeps/powerpc/powerpc64/bits/atomic.h
++++ b/sysdeps/powerpc/powerpc64/bits/atomic.h
@@ -44,14 +44,14 @@
({ \
unsigned int __tmp, __tmp2; \
diff --git a/packages/glibc/2.14.1/630-mips_shn_undef-hack.patch b/packages/glibc/2.12.1/0034-mips_shn_undef-hack.patch
index 791d76c..2f9d656 100644
--- a/packages/glibc/2.14.1/630-mips_shn_undef-hack.patch
+++ b/packages/glibc/2.12.1/0034-mips_shn_undef-hack.patch
@@ -1,10 +1,13 @@
-diff -durN glibc-2.13.orig/elf/dl-lookup.c glibc-2.13/elf/dl-lookup.c
---- glibc-2.13.orig/elf/dl-lookup.c 2009-03-30 23:14:32.000000000 +0200
-+++ glibc-2.13/elf/dl-lookup.c 2009-11-13 00:51:36.000000000 +0100
+---
+ elf/dl-lookup.c | 6 ++++++
+ 1 file changed, 6 insertions(+)
+
+--- a/elf/dl-lookup.c
++++ b/elf/dl-lookup.c
@@ -301,6 +301,12 @@
/* FALLTHROUGH */
case STB_GLOBAL:
- success:
+ success:
+#ifdef __mips__
+ /* HACK: MIPS marks its lazy evaluation stubs with SHN_UNDEF
+ symbols, we skip them. */
diff --git a/packages/glibc/2.14.1/640-alpha-atfcts.patch b/packages/glibc/2.12.1/0035-alpha-atfcts.patch
index 7a8a94a..2eff918 100644
--- a/packages/glibc/2.14.1/640-alpha-atfcts.patch
+++ b/packages/glibc/2.12.1/0035-alpha-atfcts.patch
@@ -1,5 +1,9 @@
---- glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h 2010-07-27 14:34:39.000000000 +0300
-+++ glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h.new 2011-03-10 18:54:37.686795979 +0200
+---
+ sysdeps/unix/sysv/linux/kernel-features.h | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
@@ -437,7 +437,8 @@
the code. On PPC they were introduced in 2.6.17-rc1,
on SH in 2.6.19-rc1. */
diff --git a/packages/glibc/2.14.1/650-syslog.patch b/packages/glibc/2.12.1/0036-syslog.patch
index c20cafc..a2d9722 100644
--- a/packages/glibc/2.14.1/650-syslog.patch
+++ b/packages/glibc/2.12.1/0036-syslog.patch
@@ -1,6 +1,9 @@
-diff -durN glibc-cvs-2.9.orig/misc/syslog.c glibc-cvs-2.9/misc/syslog.c
---- glibc-cvs-2.9.orig/misc/syslog.c 2009-06-01 10:16:50.000000000 +0200
-+++ glibc-cvs-2.9/misc/syslog.c 2009-06-01 10:17:20.000000000 +0200
+---
+ misc/syslog.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/misc/syslog.c
++++ b/misc/syslog.c
@@ -152,7 +152,7 @@
#define INTERNALLOG LOG_ERR|LOG_CONS|LOG_PERROR|LOG_PID
/* Check for invalid bits. */
diff --git a/packages/glibc/2.12.1/0037-debug-readlink_chk-readklinkat_chk.patch b/packages/glibc/2.12.1/0037-debug-readlink_chk-readklinkat_chk.patch
new file mode 100644
index 0000000..0b930f3
--- /dev/null
+++ b/packages/glibc/2.12.1/0037-debug-readlink_chk-readklinkat_chk.patch
@@ -0,0 +1,27 @@
+---
+ debug/readlink_chk.c | 2 +-
+ debug/readlinkat_chk.c | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+--- a/debug/readlink_chk.c
++++ b/debug/readlink_chk.c
+@@ -25,7 +25,7 @@
+
+
+ ssize_t
+-__readlink_chk (const char *path, void *buf, size_t len, size_t buflen)
++__readlink_chk (const char *path, char *buf, size_t len, size_t buflen)
+ {
+ if (len > buflen)
+ __chk_fail ();
+--- a/debug/readlinkat_chk.c
++++ b/debug/readlinkat_chk.c
+@@ -21,7 +21,7 @@
+
+
+ ssize_t
+-__readlinkat_chk (int fd, const char *path, void *buf, size_t len,
++__readlinkat_chk (int fd, const char *path, char *buf, size_t len,
+ size_t buflen)
+ {
+ if (len > buflen)
diff --git a/packages/glibc/2.12.2/900-march-i686.patch b/packages/glibc/2.12.1/0038-march-i686.patch
index 6030de9..e5ad2e0 100644
--- a/packages/glibc/2.12.2/900-march-i686.patch
+++ b/packages/glibc/2.12.1/0038-march-i686.patch
@@ -3,9 +3,13 @@
* sysdeps/unix/sysv/linux/i386/sysdep.h: Re-define __i686.
* nptl/sysdeps/pthread/pt-initfini.c: Ditto.
-diff -urN glibc-2.12.2.orig/nptl/sysdeps/pthread/pt-initfini.c glibc-2.12.2/nptl/sysdeps/pthread/pt-initfini.c
---- glibc-2.12.2.orig/nptl/sysdeps/pthread/pt-initfini.c 2009-10-30 18:17:08.000000000 +0100
-+++ glibc-2.12.2/nptl/sysdeps/pthread/pt-initfini.c 2010-12-30 11:36:19.858708534 +0100
+---
+ nptl/sysdeps/pthread/pt-initfini.c | 5 +++++
+ sysdeps/unix/sysv/linux/i386/sysdep.h | 4 ++++
+ 2 files changed, 9 insertions(+)
+
+--- a/nptl/sysdeps/pthread/pt-initfini.c
++++ b/nptl/sysdeps/pthread/pt-initfini.c
@@ -45,6 +45,11 @@
/* Embed an #include to pull in the alignment and .end directives. */
asm ("\n#include \"defs.h\"");
@@ -18,9 +22,8 @@ diff -urN glibc-2.12.2.orig/nptl/sysdeps/pthread/pt-initfini.c glibc-2.12.2/nptl
/* The initial common code ends here. */
asm ("\n/*@HEADER_ENDS*/");
-diff -urN glibc-2.12.2.orig/sysdeps/unix/sysv/linux/i386/sysdep.h glibc-2.12.2/sysdeps/unix/sysv/linux/i386/sysdep.h
---- glibc-2.12.2.orig/sysdeps/unix/sysv/linux/i386/sysdep.h 2009-10-30 18:17:08.000000000 +0100
-+++ glibc-2.12.2/sysdeps/unix/sysv/linux/i386/sysdep.h 2010-12-30 11:36:19.858708534 +0100
+--- a/sysdeps/unix/sysv/linux/i386/sysdep.h
++++ b/sysdeps/unix/sysv/linux/i386/sysdep.h
@@ -29,6 +29,10 @@
#include <dl-sysdep.h>
#include <tls.h>
diff --git a/packages/glibc/2.12.2/910-typedef-caddr.patch b/packages/glibc/2.12.1/0039-typedef-caddr.patch
index 4bc75cb..5139bbd 100644
--- a/packages/glibc/2.12.2/910-typedef-caddr.patch
+++ b/packages/glibc/2.12.1/0039-typedef-caddr.patch
@@ -1,6 +1,10 @@
-diff -urN glibc-2.12.2-orig/posix/sys/types.h glibc-2.12.2/posix/sys/types.h
---- glibc-2.12.2-orig/posix/sys/types.h 2010-12-13 11:47:26.000000000 +0100
-+++ glibc-2.12.2/posix/sys/types.h 2011-03-29 14:16:00.374064708 +0200
+---
+ posix/sys/types.h | 3 +++
+ sunrpc/rpc/types.h | 3 +++
+ 2 files changed, 6 insertions(+)
+
+--- a/posix/sys/types.h
++++ b/posix/sys/types.h
@@ -114,7 +114,10 @@
#ifdef __USE_BSD
# ifndef __daddr_t_defined
@@ -12,10 +16,9 @@ diff -urN glibc-2.12.2-orig/posix/sys/types.h glibc-2.12.2/posix/sys/types.h
# define __daddr_t_defined
# endif
#endif
-diff -urN glibc-2.12.2-orig/sunrpc/rpc/types.h glibc-2.12.2/sunrpc/rpc/types.h
---- glibc-2.12.2-orig/sunrpc/rpc/types.h 2010-12-13 11:47:26.000000000 +0100
-+++ glibc-2.12.2/sunrpc/rpc/types.h 2011-03-29 14:16:32.988910439 +0200
-@@ -80,7 +80,10 @@
+--- a/sunrpc/rpc/types.h
++++ b/sunrpc/rpc/types.h
+@@ -85,7 +85,10 @@
#endif
#ifndef __daddr_t_defined
typedef __daddr_t daddr_t;
diff --git a/packages/glibc/2.13/920-fix-rpc_parse-format.patch b/packages/glibc/2.12.1/0040-fix-rpc_parse-format.patch
index 37e58da..906fb70 100644
--- a/packages/glibc/2.13/920-fix-rpc_parse-format.patch
+++ b/packages/glibc/2.12.1/0040-fix-rpc_parse-format.patch
@@ -45,11 +45,13 @@ Date: Tue Nov 8 23:44:51 2016 +0000
[$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
[$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
-diff --git a/sunrpc/rpc_parse.c b/sunrpc/rpc_parse.c
-index 1a1df6d8c2..505a6554cf 100644
+---
+ sunrpc/rpc_parse.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
--- a/sunrpc/rpc_parse.c
+++ b/sunrpc/rpc_parse.c
-@@ -521,7 +521,7 @@ static void
+@@ -520,7 +520,7 @@
get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
{
token tok;
diff --git a/packages/glibc/2.12.1/920-make-382.patch b/packages/glibc/2.12.1/0041-make-382.patch
index 28be2fe..9ce2d88 100644
--- a/packages/glibc/2.12.1/920-make-382.patch
+++ b/packages/glibc/2.12.1/0041-make-382.patch
@@ -1,8 +1,12 @@
http://git.frugalware.org/gitweb/gitweb.cgi?p=frugalware-current.git;a=blob_plain;f=source/base/glibc/make-3.82-fix.patch;hb=8217c32ecc2e14962847ba3d8a272eb64a3dba4f
---- glibc-2.10.1.OLD/manual/Makefile
-+++ glibc-2.10.1.NEW/manual/Makefile
-@@ -232,7 +232,9 @@
+---
+ manual/Makefile | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+--- a/manual/Makefile
++++ b/manual/Makefile
+@@ -237,7 +237,9 @@
.PHONY: stubs
stubs: $(objpfx)stubs
endif
diff --git a/packages/glibc/2.12.1/940-nis-bogus-conditional.patch b/packages/glibc/2.12.1/0042-nis-bogus-conditional.patch
index 09b38cf..732b859 100644
--- a/packages/glibc/2.12.1/940-nis-bogus-conditional.patch
+++ b/packages/glibc/2.12.1/0042-nis-bogus-conditional.patch
@@ -47,11 +47,13 @@ Date: Wed Dec 21 23:44:01 2016 +0000
* nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
Compare name == NULL, not name != NULL.
-diff --git a/nis/nss_nisplus/nisplus-alias.c b/nis/nss_nisplus/nisplus-alias.c
-index 7f698b4e6d..cb5acce01d 100644
+---
+ nis/nss_nisplus/nisplus-alias.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
--- a/nis/nss_nisplus/nisplus-alias.c
+++ b/nis/nss_nisplus/nisplus-alias.c
-@@ -291,7 +291,7 @@ _nss_nisplus_getaliasbyname_r (const char *name, struct aliasent *alias,
+@@ -293,7 +293,7 @@
return status;
}
diff --git a/packages/glibc/2.13/998-obstack-common.patch b/packages/glibc/2.12.1/0043-obstack-common.patch
index 4b95f06..1993be2 100644
--- a/packages/glibc/2.13/998-obstack-common.patch
+++ b/packages/glibc/2.12.1/0043-obstack-common.patch
@@ -15,11 +15,13 @@ Date: Wed May 15 20:28:08 2013 +0200
* malloc/obstack.c (_obstack_compat): Add initializer.
-
-diff --git a/malloc/obstack.c b/malloc/obstack.c
-index 25a90514f7..c3c7db4a96 100644
+---
+ malloc/obstack.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
--- a/malloc/obstack.c
+++ b/malloc/obstack.c
-@@ -115,7 +115,7 @@ int obstack_exit_failure = EXIT_FAILURE;
+@@ -117,7 +117,7 @@
/* A looong time ago (before 1994, anyway; we're not sure) this global variable
was used by non-GNU-C macros to avoid multiple evaluation. The GNU C
library still exports it because somebody might use it. */
diff --git a/packages/glibc/2.12.1/999-new-tools.patch b/packages/glibc/2.12.1/0044-new-tools.patch
index d600b58..2ff427e 100644
--- a/packages/glibc/2.12.1/999-new-tools.patch
+++ b/packages/glibc/2.12.1/0044-new-tools.patch
@@ -1,7 +1,11 @@
-diff -urpN glibc-2.12.1.orig/configure glibc-2.12.1/configure
---- glibc-2.12.1.orig/configure 2010-07-27 04:34:39.000000000 -0700
-+++ glibc-2.12.1/configure 2017-02-08 00:37:58.117495908 -0800
-@@ -5079,7 +5079,7 @@ $as_echo_n "checking version of $CC... "
+---
+ configure | 8 ++++----
+ configure.in | 8 ++++----
+ 2 files changed, 8 insertions(+), 8 deletions(-)
+
+--- a/configure
++++ b/configure
+@@ -5079,7 +5079,7 @@
ac_prog_version=`$CC -v 2>&1 | sed -n 's/^.*version \([egcygnustpi-]*[0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -10,7 +14,7 @@ diff -urpN glibc-2.12.1.orig/configure glibc-2.12.1/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5142,7 +5142,7 @@ $as_echo_n "checking version of $MAKE...
+@@ -5142,7 +5142,7 @@
ac_prog_version=`$MAKE --version 2>&1 | sed -n 's/^.*GNU Make[^0-9]*\([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -19,7 +23,7 @@ diff -urpN glibc-2.12.1.orig/configure glibc-2.12.1/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5269,7 +5269,7 @@ $as_echo_n "checking version of $MAKEINF
+@@ -5269,7 +5269,7 @@
ac_prog_version=`$MAKEINFO --version 2>&1 | sed -n 's/^.*GNU texinfo.* \([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -28,7 +32,7 @@ diff -urpN glibc-2.12.1.orig/configure glibc-2.12.1/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5329,7 +5329,7 @@ else
+@@ -5329,7 +5329,7 @@
# Found it, now check the version.
{ $as_echo "$as_me:$LINENO: checking version of $SED" >&5
$as_echo_n "checking version of $SED... " >&6; }
@@ -37,10 +41,9 @@ diff -urpN glibc-2.12.1.orig/configure glibc-2.12.1/configure
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
3.0[2-9]*|3.[1-9]*|[4-9]*)
-diff -urpN glibc-2.12.1.orig/configure.in glibc-2.12.1/configure.in
---- glibc-2.12.1.orig/configure.in 2010-07-27 04:34:39.000000000 -0700
-+++ glibc-2.12.1/configure.in 2017-02-08 00:28:47.131374866 -0800
-@@ -960,11 +960,11 @@ fi
+--- a/configure.in
++++ b/configure.in
+@@ -960,11 +960,11 @@
# These programs are version sensitive.
AC_CHECK_TOOL_PREFIX
AC_CHECK_PROG_VER(CC, ${ac_tool_prefix}gcc ${ac_tool_prefix}cc, -v,
@@ -54,7 +57,7 @@ diff -urpN glibc-2.12.1.orig/configure.in glibc-2.12.1/configure.in
AC_CHECK_PROG_VER(MSGFMT, gnumsgfmt gmsgfmt msgfmt, --version,
[GNU gettext.* \([0-9]*\.[0-9.]*\)],
-@@ -972,10 +972,10 @@ AC_CHECK_PROG_VER(MSGFMT, gnumsgfmt gmsg
+@@ -972,10 +972,10 @@
MSGFMT=: aux_missing="$aux_missing msgfmt")
AC_CHECK_PROG_VER(MAKEINFO, makeinfo, --version,
[GNU texinfo.* \([0-9][0-9.]*\)],
diff --git a/packages/glibc/2.12.1/120-i386-x86_64-revert-clone-cfi.patch b/packages/glibc/2.12.1/120-i386-x86_64-revert-clone-cfi.patch
deleted file mode 100644
index 95f5ace..0000000
--- a/packages/glibc/2.12.1/120-i386-x86_64-revert-clone-cfi.patch
+++ /dev/null
@@ -1,55 +0,0 @@
-revert cfi additions to clone on i386/x86_64 to workaround problems in
-gcc's unwinder code. this is not a bug in glibc, it triggers problems
-elsewhere. this cfi code does not gain us a whole lot anyways.
-
-http://gcc.gnu.org/ml/gcc/2006-12/msg00293.html
-
-Index: sysdeps/unix/sysv/linux/i386/clone.S
-===================================================================
-RCS file: /cvs/glibc/libc/sysdeps/unix/sysv/linux/i386/clone.S,v
-retrieving revision 1.27
-retrieving revision 1.26
-diff -u -p -r1.27 -r1.26
-
-diff -durN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/i386/clone.S glibc-2.12.1/sysdeps/unix/sysv/linux/i386/clone.S
---- glibc-2.12.1.orig/sysdeps/unix/sysv/linux/i386/clone.S 2006-12-04 00:12:36.000000000 +0100
-+++ glibc-2.12.1/sysdeps/unix/sysv/linux/i386/clone.S 2009-11-13 00:49:45.000000000 +0100
-@@ -120,9 +120,6 @@
- ret
-
- L(thread_start):
-- cfi_startproc;
-- /* Clearing frame pointer is insufficient, use CFI. */
-- cfi_undefined (eip);
- /* Note: %esi is zero. */
- movl %esi,%ebp /* terminate the stack frame */
- #ifdef RESET_PID
-@@ -155,7 +152,6 @@
- jmp L(haspid)
- .previous
- #endif
-- cfi_endproc;
-
- cfi_startproc
- PSEUDO_END (BP_SYM (__clone))
-diff -durN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/x86_64/clone.S glibc-2.12.1/sysdeps/unix/sysv/linux/x86_64/clone.S
---- glibc-2.12.1.orig/sysdeps/unix/sysv/linux/x86_64/clone.S 2006-12-04 00:12:36.000000000 +0100
-+++ glibc-2.12.1/sysdeps/unix/sysv/linux/x86_64/clone.S 2009-11-13 00:49:45.000000000 +0100
-@@ -89,9 +89,6 @@
- ret
-
- L(thread_start):
-- cfi_startproc;
-- /* Clearing frame pointer is insufficient, use CFI. */
-- cfi_undefined (rip);
- /* Clear the frame pointer. The ABI suggests this be done, to mark
- the outermost frame obviously. */
- xorl %ebp, %ebp
-@@ -116,7 +113,6 @@
- /* Call exit with return value from function call. */
- movq %rax, %rdi
- call HIDDEN_JUMPTARGET (_exit)
-- cfi_endproc;
-
- cfi_startproc;
- PSEUDO_END (BP_SYM (__clone))
diff --git a/packages/glibc/2.12.1/140-disable-ldconfig.patch b/packages/glibc/2.12.1/140-disable-ldconfig.patch
deleted file mode 100644
index 43330b8..0000000
--- a/packages/glibc/2.12.1/140-disable-ldconfig.patch
+++ /dev/null
@@ -1,16 +0,0 @@
-do not bother running ldconfig on DESTDIR. it wants to write the temp cache
-file outside of the chroot. doesnt matter anyways as we wont use the cache
-results (portage will rebuild cache), so running ldconfig is simply a waste
-of time.
-
-diff -durN glibc-2.12.1.orig/Makefile glibc-2.12.1/Makefile
---- glibc-2.12.1.orig/Makefile 2009-04-23 20:23:03.000000000 +0200
-+++ glibc-2.12.1/Makefile 2009-11-13 00:49:49.000000000 +0100
-@@ -116,6 +116,7 @@
- rm -f $(symbolic-link-list)
-
- install:
-+dont-bother-with-destdir:
- -test ! -x $(common-objpfx)elf/ldconfig || LC_ALL=C LANGUAGE=C \
- $(common-objpfx)elf/ldconfig $(addprefix -r ,$(install_root)) \
- $(slibdir) $(libdir)
diff --git a/packages/glibc/2.12.1/150-queue-header-updates.patch b/packages/glibc/2.12.1/150-queue-header-updates.patch
deleted file mode 100644
index fe625e1..0000000
--- a/packages/glibc/2.12.1/150-queue-header-updates.patch
+++ /dev/null
@@ -1,85 +0,0 @@
-grab some updates from FreeBSD
-
-http://bugs.gentoo.org/201979
-
-diff -durN glibc-2.12.1.orig/misc/sys/queue.h glibc-2.12.1/misc/sys/queue.h
-
-diff -durN glibc-2.12.1.orig/misc/sys/queue.h glibc-2.12.1/misc/sys/queue.h
---- glibc-2.12.1.orig/misc/sys/queue.h 2008-03-05 06:50:30.000000000 +0100
-+++ glibc-2.12.1/misc/sys/queue.h 2009-11-13 00:49:51.000000000 +0100
-@@ -136,6 +136,11 @@
- (var); \
- (var) = ((var)->field.le_next))
-
-+#define LIST_FOREACH_SAFE(var, head, field, tvar) \
-+ for ((var) = LIST_FIRST((head)); \
-+ (var) && ((tvar) = LIST_NEXT((var), field), 1); \
-+ (var) = (tvar))
-+
- /*
- * List access methods.
- */
-@@ -197,6 +202,16 @@
- #define SLIST_FOREACH(var, head, field) \
- for((var) = (head)->slh_first; (var); (var) = (var)->field.sle_next)
-
-+#define SLIST_FOREACH_SAFE(var, head, field, tvar) \
-+ for ((var) = SLIST_FIRST((head)); \
-+ (var) && ((tvar) = SLIST_NEXT((var), field), 1); \
-+ (var) = (tvar))
-+
-+#define SLIST_FOREACH_PREVPTR(var, varp, head, field) \
-+ for ((varp) = &SLIST_FIRST((head)); \
-+ ((var) = *(varp)) != NULL; \
-+ (varp) = &SLIST_NEXT((var), field))
-+
- /*
- * Singly-linked List access methods.
- */
-@@ -242,6 +257,12 @@
- (head)->stqh_last = &(elm)->field.stqe_next; \
- } while (/*CONSTCOND*/0)
-
-+#define STAILQ_LAST(head, type, field) \
-+ (STAILQ_EMPTY((head)) ? \
-+ NULL : \
-+ ((struct type *)(void *) \
-+ ((char *)((head)->stqh_last) - __offsetof(struct type, field))))
-+
- #define STAILQ_INSERT_AFTER(head, listelm, elm, field) do { \
- if (((elm)->field.stqe_next = (listelm)->field.stqe_next) == NULL)\
- (head)->stqh_last = &(elm)->field.stqe_next; \
-@@ -271,6 +292,11 @@
- (var); \
- (var) = ((var)->field.stqe_next))
-
-+#define STAILQ_FOREACH_SAFE(var, head, field, tvar) \
-+ for ((var) = STAILQ_FIRST((head)); \
-+ (var) && ((tvar) = STAILQ_NEXT((var), field), 1); \
-+ (var) = (tvar))
-+
- #define STAILQ_CONCAT(head1, head2) do { \
- if (!STAILQ_EMPTY((head2))) { \
- *(head1)->stqh_last = (head2)->stqh_first; \
-@@ -437,11 +463,21 @@
- (var); \
- (var) = ((var)->field.tqe_next))
-
-+#define TAILQ_FOREACH_SAFE(var, head, field, tvar) \
-+ for ((var) = TAILQ_FIRST((head)); \
-+ (var) && ((tvar) = TAILQ_NEXT((var), field), 1); \
-+ (var) = (tvar))
-+
- #define TAILQ_FOREACH_REVERSE(var, head, headname, field) \
- for ((var) = (*(((struct headname *)((head)->tqh_last))->tqh_last)); \
- (var); \
- (var) = (*(((struct headname *)((var)->field.tqe_prev))->tqh_last)))
-
-+#define TAILQ_FOREACH_REVERSE_SAFE(var, head, headname, field, tvar) \
-+ for ((var) = TAILQ_LAST((head), headname); \
-+ (var) && ((tvar) = TAILQ_PREV((var), headname, field), 1); \
-+ (var) = (tvar))
-+
- #define TAILQ_CONCAT(head1, head2, field) do { \
- if (!TAILQ_EMPTY(head2)) { \
- *(head1)->tqh_last = (head2)->tqh_first; \
diff --git a/packages/glibc/2.12.1/170-localedef-fix-trampoline.patch b/packages/glibc/2.12.1/170-localedef-fix-trampoline.patch
deleted file mode 100644
index fb0881d..0000000
--- a/packages/glibc/2.12.1/170-localedef-fix-trampoline.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-# DP: Description: Fix localedef segfault when run under exec-shield,
-# PaX or similar. (#231438, #198099)
-# DP: Dpatch Author: James Troup <james@nocrew.org>
-# DP: Patch Author: (probably) Jakub Jelinek <jakub@redhat.com>
-# DP: Upstream status: Unknown
-# DP: Status Details: Unknown
-# DP: Date: 2004-03-16
-diff -durN glibc-2.12.1.orig/locale/programs/3level.h glibc-2.12.1/locale/programs/3level.h
---- glibc-2.12.1.orig/locale/programs/3level.h 2007-07-16 02:54:59.000000000 +0200
-+++ glibc-2.12.1/locale/programs/3level.h 2009-11-13 00:49:56.000000000 +0100
-@@ -203,6 +203,42 @@
- }
- }
- }
-+
-+/* GCC ATM seems to do a poor job with pointers to nested functions passed
-+ to inlined functions. Help it a little bit with this hack. */
-+#define wchead_table_iterate(tp, fn) \
-+do \
-+ { \
-+ struct wchead_table *t = (tp); \
-+ uint32_t index1; \
-+ for (index1 = 0; index1 < t->level1_size; index1++) \
-+ { \
-+ uint32_t lookup1 = t->level1[index1]; \
-+ if (lookup1 != ((uint32_t) ~0)) \
-+ { \
-+ uint32_t lookup1_shifted = lookup1 << t->q; \
-+ uint32_t index2; \
-+ for (index2 = 0; index2 < (1 << t->q); index2++) \
-+ { \
-+ uint32_t lookup2 = t->level2[index2 + lookup1_shifted]; \
-+ if (lookup2 != ((uint32_t) ~0)) \
-+ { \
-+ uint32_t lookup2_shifted = lookup2 << t->p; \
-+ uint32_t index3; \
-+ for (index3 = 0; index3 < (1 << t->p); index3++) \
-+ { \
-+ struct element_t *lookup3 \
-+ = t->level3[index3 + lookup2_shifted]; \
-+ if (lookup3 != NULL) \
-+ fn ((((index1 << t->q) + index2) << t->p) + index3, \
-+ lookup3); \
-+ } \
-+ } \
-+ } \
-+ } \
-+ } \
-+ } while (0)
-+
- #endif
-
- #ifndef NO_FINALIZE
diff --git a/packages/glibc/2.12.1/180-resolv-dynamic.patch b/packages/glibc/2.12.1/180-resolv-dynamic.patch
deleted file mode 100644
index 8f74a53..0000000
--- a/packages/glibc/2.12.1/180-resolv-dynamic.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-ripped from SuSE
-
-if /etc/resolv.conf is updated, then make sure applications
-already running get the updated information.
-
-http://bugs.gentoo.org/177416
-
-diff -durN glibc-2.12.1.orig/resolv/res_libc.c glibc-2.12.1/resolv/res_libc.c
---- glibc-2.12.1.orig/resolv/res_libc.c 2009-02-07 05:27:42.000000000 +0100
-+++ glibc-2.12.1/resolv/res_libc.c 2009-11-13 00:49:59.000000000 +0100
-@@ -22,6 +22,7 @@
- #include <arpa/nameser.h>
- #include <resolv.h>
- #include <bits/libc-lock.h>
-+#include <sys/stat.h>
-
-
- /* The following bit is copied from res_data.c (where it is #ifdef'ed
-@@ -95,6 +96,20 @@
- __res_maybe_init (res_state resp, int preinit)
- {
- if (resp->options & RES_INIT) {
-+ static time_t last_mtime, last_check;
-+ time_t now;
-+ struct stat statbuf;
-+
-+ time (&now);
-+ if (now != last_check) {
-+ last_check = now;
-+ if (stat (_PATH_RESCONF, &statbuf) == 0 && last_mtime != statbuf.st_mtime) {
-+ last_mtime = statbuf.st_mtime;
-+ atomicinclock (lock);
-+ atomicinc (__res_initstamp);
-+ atomicincunlock (lock);
-+ }
-+ }
- if (__res_initstamp != resp->_u._ext.initstamp) {
- if (resp->nscount > 0)
- __res_iclose (resp, true);
diff --git a/packages/glibc/2.12.1/200-fadvise64_64.patch b/packages/glibc/2.12.1/200-fadvise64_64.patch
deleted file mode 100644
index a9f10cd..0000000
--- a/packages/glibc/2.12.1/200-fadvise64_64.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-ripped from Debian
-
- sysdeps/unix/sysv/linux/posix_fadvise.c | 13 +++++++++++++
- 1 file changed, 13 insertions(+)
-
-diff -durN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/posix_fadvise.c glibc-2.12.1/sysdeps/unix/sysv/linux/posix_fadvise.c
---- glibc-2.12.1.orig/sysdeps/unix/sysv/linux/posix_fadvise.c 2003-08-17 02:36:22.000000000 +0200
-+++ glibc-2.12.1/sysdeps/unix/sysv/linux/posix_fadvise.c 2009-11-13 00:50:03.000000000 +0100
-@@ -35,6 +35,19 @@
- return INTERNAL_SYSCALL_ERRNO (ret, err);
- return 0;
- #else
-+# ifdef __NR_fadvise64_64
-+ INTERNAL_SYSCALL_DECL (err);
-+ int ret = INTERNAL_SYSCALL (fadvise64_64, err, 6, fd,
-+ __LONG_LONG_PAIR ((long) (offset >> 31),
-+ (long) offset),
-+ __LONG_LONG_PAIR ((long) (len >> 31),
-+ (long) len),
-+ advise);
-+ if (INTERNAL_SYSCALL_ERROR_P (ret, err))
-+ return INTERNAL_SYSCALL_ERRNO (ret, err);
-+ return 0;
-+# else
- return ENOSYS;
-+# endif
- #endif
- }
diff --git a/packages/glibc/2.12.1/270-china.patch b/packages/glibc/2.12.1/270-china.patch
deleted file mode 100644
index 4cde1cf..0000000
--- a/packages/glibc/2.12.1/270-china.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-
-
-diff -durN glibc-2.12.1.orig/localedata/locales/zh_TW glibc-2.12.1/localedata/locales/zh_TW
---- glibc-2.12.1.orig/localedata/locales/zh_TW 2004-11-01 00:42:28.000000000 +0100
-+++ glibc-2.12.1/localedata/locales/zh_TW 2009-11-13 00:50:17.000000000 +0100
-@@ -1,7 +1,7 @@
- comment_char %
- escape_char /
- %
--% Chinese language locale for Taiwan R.O.C.
-+% Chinese language locale for Taiwan
- % charmap: BIG5-CP950
- %
- % Original Author:
-@@ -17,7 +17,7 @@
- % Reference: http://wwwold.dkuug.dk/JTC1/SC22/WG20/docs/n690.pdf
-
- LC_IDENTIFICATION
--title "Chinese locale for Taiwan R.O.C."
-+title "Chinese locale for Taiwan"
- source ""
- address ""
- contact ""
-@@ -25,7 +25,7 @@
- tel ""
- fax ""
- language "Chinese"
--territory "Taiwan R.O.C."
-+territory "Taiwan"
- revision "0.2"
- date "2000-08-02"
- %
diff --git a/packages/glibc/2.12.1/280-new-valencian-locale.patch b/packages/glibc/2.12.1/280-new-valencian-locale.patch
deleted file mode 100644
index 6b46b44..0000000
--- a/packages/glibc/2.12.1/280-new-valencian-locale.patch
+++ /dev/null
@@ -1,115 +0,0 @@
-http://bugs.gentoo.org/show_bug.cgi?id=131815
-http://sourceware.org/bugzilla/show_bug.cgi?id=2522
-
-diff -durN glibc-2.12.1.orig/localedata/SUPPORTED glibc-2.12.1/localedata/SUPPORTED
---- glibc-2.12.1.orig/localedata/SUPPORTED 2009-04-18 10:43:52.000000000 +0200
-+++ glibc-2.12.1/localedata/SUPPORTED 2009-11-13 00:50:20.000000000 +0100
-@@ -72,6 +72,8 @@
- ca_ES.UTF-8/UTF-8 \
- ca_ES/ISO-8859-1 \
- ca_ES@euro/ISO-8859-15 \
-+ca_ES.UTF-8@valencia/UTF-8 \
-+ca_ES@valencia/ISO-8859-15 \
- ca_FR.UTF-8/UTF-8 \
- ca_FR/ISO-8859-15 \
- ca_IT.UTF-8/UTF-8 \
-diff -durN glibc-2.12.1.orig/localedata/locales/ca_ES@valencia glibc-2.12.1/localedata/locales/ca_ES@valencia
---- glibc-2.12.1.orig/localedata/locales/ca_ES@valencia 1970-01-01 01:00:00.000000000 +0100
-+++ glibc-2.12.1/localedata/locales/ca_ES@valencia 2009-11-13 00:50:20.000000000 +0100
-@@ -0,0 +1,96 @@
-+comment_char %
-+escape_char /
-+%
-+% Valencian (southern Catalan) locale for Spain with Euro
-+%
-+% Note that this locale is almost the same as ca_ES@euro. The point of having
-+% a separate locale is only for PO translations, which have a lot of social
-+% support and are very appreciated by the Valencian-speaking community.
-+%
-+% Contact: Jordi Mallach
-+% Email: jordi@gnu.org
-+% Tel:
-+% Fax:
-+% Language: ca
-+% Territory: ES
-+% Option: euro
-+% Revision: 1.0
-+% Date: 2006-04-06
-+% Application: general
-+% Users: general
-+% Repertoiremap: mnemonic,ds
-+% Charset: ISO-8859-15
-+% Distribution and use is free, also
-+% for commercial purposes.
-+
-+LC_IDENTIFICATION
-+title "Valencian (southern Catalan) locale for Spain with Euro"
-+source ""
-+address ""
-+contact "Jordi Mallach"
-+email "jordi@gnu.org"
-+tel ""
-+fax ""
-+language "Catalan"
-+territory "Spain"
-+revision "1.0"
-+date "2006-04-06"
-+%
-+category "ca_ES@valencia:2006";LC_IDENTIFICATION
-+category "ca_ES@valencia:2006";LC_CTYPE
-+category "ca_ES@valencia:2006";LC_COLLATE
-+category "ca_ES@valencia:2006";LC_MONETARY
-+category "ca_ES@valencia:2006";LC_NUMERIC
-+category "ca_ES@valencia:2006";LC_TIME
-+category "ca_ES@valencia:2006";LC_MESSAGES
-+category "ca_ES@valencia:2006";LC_PAPER
-+category "ca_ES@valencia:2006";LC_NAME
-+category "ca_ES@valencia:2006";LC_ADDRESS
-+category "ca_ES@valencia:2006";LC_TELEPHONE
-+category "ca_ES@valencia:2006";LC_MEASUREMENT
-+
-+END LC_IDENTIFICATION
-+
-+LC_CTYPE
-+copy "i18n"
-+END LC_CTYPE
-+
-+LC_COLLATE
-+copy "ca_ES"
-+END LC_COLLATE
-+
-+LC_MONETARY
-+copy "ca_ES"
-+END LC_MONETARY
-+
-+LC_NUMERIC
-+copy "ca_ES"
-+END LC_NUMERIC
-+
-+LC_TIME
-+copy "ca_ES"
-+END LC_TIME
-+
-+LC_MESSAGES
-+copy "ca_ES"
-+END LC_MESSAGES
-+
-+LC_PAPER
-+copy "ca_ES"
-+END LC_PAPER
-+
-+LC_NAME
-+copy "ca_ES"
-+END LC_NAME
-+
-+LC_ADDRESS
-+copy "ca_ES"
-+END LC_ADDRESS
-+
-+LC_TELEPHONE
-+copy "ca_ES"
-+END LC_TELEPHONE
-+
-+LC_MEASUREMENT
-+copy "ca_ES"
-+END LC_MEASUREMENT
diff --git a/packages/glibc/2.12.1/340-dl_execstack-PaX-support.patch b/packages/glibc/2.12.1/340-dl_execstack-PaX-support.patch
deleted file mode 100644
index afdb39c..0000000
--- a/packages/glibc/2.12.1/340-dl_execstack-PaX-support.patch
+++ /dev/null
@@ -1,66 +0,0 @@
- With latest versions of glibc, a lot of apps failed on a PaX enabled
- system with:
- cannot enable executable stack as shared object requires: Permission denied
-
- This is due to PaX 'exec-protecting' the stack, and ld.so then trying
- to make the stack executable due to some libraries not containing the
- PT_GNU_STACK section. Bug #32960. <azarah@gentoo.org> (12 Nov 2003).
-
- Patch also NPTL. Bug #116086. <kevquinn@gentoo.org> (20 Dec 2005).
-
-diff -durN glibc-2.12.1.orig/nptl/allocatestack.c glibc-2.12.1/nptl/allocatestack.c
---- glibc-2.12.1.orig/nptl/allocatestack.c 2009-01-29 21:34:16.000000000 +0100
-+++ glibc-2.12.1/nptl/allocatestack.c 2009-11-13 00:50:33.000000000 +0100
-@@ -329,7 +329,8 @@
- # error "Define either _STACK_GROWS_DOWN or _STACK_GROWS_UP"
- #endif
- if (mprotect (stack, len, PROT_READ | PROT_WRITE | PROT_EXEC) != 0)
-- return errno;
-+ if (errno != EACCES) /* PAX is enabled */
-+ return errno;
-
- return 0;
- }
-diff -durN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/dl-execstack.c glibc-2.12.1/sysdeps/unix/sysv/linux/dl-execstack.c
---- glibc-2.12.1.orig/sysdeps/unix/sysv/linux/dl-execstack.c 2006-01-08 09:21:15.000000000 +0100
-+++ glibc-2.12.1/sysdeps/unix/sysv/linux/dl-execstack.c 2009-11-13 00:50:33.000000000 +0100
-@@ -63,7 +63,10 @@
- else
- # endif
- {
-- result = errno;
-+ if (errno == EACCES) /* PAX is enabled */
-+ result = 0;
-+ else
-+ result = errno;
- goto out;
- }
- }
-@@ -89,7 +92,12 @@
- page -= size;
- else
- {
-- if (errno != ENOMEM) /* Unexpected failure mode. */
-+ if (errno == EACCES) /* PAX is enabled */
-+ {
-+ result = 0;
-+ goto out;
-+ }
-+ else if (errno != ENOMEM) /* Unexpected failure mode. */
- {
- result = errno;
- goto out;
-@@ -115,7 +123,12 @@
- page += size;
- else
- {
-- if (errno != ENOMEM) /* Unexpected failure mode. */
-+ if (errno == EACCES) /* PAX is enabled */
-+ {
-+ result = 0;
-+ goto out;
-+ }
-+ else if (errno != ENOMEM) /* Unexpected failure mode. */
- {
- result = errno;
- goto out;
diff --git a/packages/glibc/2.12.1/350-pre20040117-pt_pax.patch b/packages/glibc/2.12.1/350-pre20040117-pt_pax.patch
deleted file mode 100644
index 3f03169..0000000
--- a/packages/glibc/2.12.1/350-pre20040117-pt_pax.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-
-
-diff -durN glibc-2.12.1.orig/elf/elf.h glibc-2.12.1/elf/elf.h
---- glibc-2.12.1.orig/elf/elf.h 2009-04-15 02:15:54.000000000 +0200
-+++ glibc-2.12.1/elf/elf.h 2009-11-13 00:50:35.000000000 +0100
-@@ -580,6 +580,7 @@
- #define PT_GNU_EH_FRAME 0x6474e550 /* GCC .eh_frame_hdr segment */
- #define PT_GNU_STACK 0x6474e551 /* Indicates stack executability */
- #define PT_GNU_RELRO 0x6474e552 /* Read-only after relocation */
-+#define PT_PAX_FLAGS 0x65041580 /* Indicates PaX flag markings */
- #define PT_LOSUNW 0x6ffffffa
- #define PT_SUNWBSS 0x6ffffffa /* Sun Specific segment */
- #define PT_SUNWSTACK 0x6ffffffb /* Stack segment */
-@@ -593,6 +594,18 @@
- #define PF_X (1 << 0) /* Segment is executable */
- #define PF_W (1 << 1) /* Segment is writable */
- #define PF_R (1 << 2) /* Segment is readable */
-+#define PF_PAGEEXEC (1 << 4) /* Enable PAGEEXEC */
-+#define PF_NOPAGEEXEC (1 << 5) /* Disable PAGEEXEC */
-+#define PF_SEGMEXEC (1 << 6) /* Enable SEGMEXEC */
-+#define PF_NOSEGMEXEC (1 << 7) /* Disable SEGMEXEC */
-+#define PF_MPROTECT (1 << 8) /* Enable MPROTECT */
-+#define PF_NOMPROTECT (1 << 9) /* Disable MPROTECT */
-+#define PF_RANDEXEC (1 << 10) /* Enable RANDEXEC */
-+#define PF_NORANDEXEC (1 << 11) /* Disable RANDEXEC */
-+#define PF_EMUTRAMP (1 << 12) /* Enable EMUTRAMP */
-+#define PF_NOEMUTRAMP (1 << 13) /* Disable EMUTRAMP */
-+#define PF_RANDMMAP (1 << 14) /* Enable RANDMMAP */
-+#define PF_NORANDMMAP (1 << 15) /* Disable RANDMMAP */
- #define PF_MASKOS 0x0ff00000 /* OS-specific */
- #define PF_MASKPROC 0xf0000000 /* Processor-specific */
-
diff --git a/packages/glibc/2.12.1/360-tests-sandbox-libdl-paths.patch b/packages/glibc/2.12.1/360-tests-sandbox-libdl-paths.patch
deleted file mode 100644
index a847cdb..0000000
--- a/packages/glibc/2.12.1/360-tests-sandbox-libdl-paths.patch
+++ /dev/null
@@ -1,193 +0,0 @@
-when glibc runs its tests, it does so by invoking the local library loader.
-in Gentoo, we build/run inside of our "sandbox" which itself is linked against
-libdl (so that it can load libraries and pull out symbols). the trouble
-is that when you upgrade from an older glibc to the new one, often times
-internal symbols change name or abi. this is normally OK as you cannot use
-libc.so from say version 2.3.6 but libpthread.so from say version 2.5, so
-we always say "keep all of the glibc libraries from the same build". but
-when glibc runs its tests, it uses dynamic paths to point to its new local
-copies of libraries. if the test doesnt use libdl, then glibc doesnt add
-its path, and when sandbox triggers the loading of libdl, glibc does so
-from the host system system. this gets us into the case of all libraries
-are from the locally compiled version of glibc except for libdl.so.
-
-Fix by Wormo
-
-http://bugs.gentoo.org/56898
-
-diff -durN glibc-2.12.1.orig/grp/tst_fgetgrent.sh glibc-2.12.1/grp/tst_fgetgrent.sh
---- glibc-2.12.1.orig/grp/tst_fgetgrent.sh 2001-07-06 06:54:46.000000000 +0200
-+++ glibc-2.12.1/grp/tst_fgetgrent.sh 2009-11-13 00:50:37.000000000 +0100
-@@ -24,7 +24,8 @@
- rtld_installed_name=$1; shift
-
- testout=${common_objpfx}/grp/tst_fgetgrent.out
--library_path=${common_objpfx}
-+# make sure libdl is also in path in case sandbox is in use
-+library_path=${common_objpfx}:${common_objpfx}/dlfcn
-
- result=0
-
-diff -durN glibc-2.12.1.orig/iconvdata/run-iconv-test.sh glibc-2.12.1/iconvdata/run-iconv-test.sh
---- glibc-2.12.1.orig/iconvdata/run-iconv-test.sh 2008-05-15 03:59:44.000000000 +0200
-+++ glibc-2.12.1/iconvdata/run-iconv-test.sh 2009-11-13 00:50:37.000000000 +0100
-@@ -34,7 +34,7 @@
- export GCONV_PATH
-
- # We have to have some directories in the library path.
--LIBPATH=$codir:$codir/iconvdata
-+LIBPATH=$codir:$codir/iconvdata:$codir/dlfcn
-
- # How the start the iconv(1) program.
- ICONV='$codir/elf/ld.so --library-path $LIBPATH --inhibit-rpath ${from}.so \
-diff -durN glibc-2.12.1.orig/iconvdata/tst-table.sh glibc-2.12.1/iconvdata/tst-table.sh
---- glibc-2.12.1.orig/iconvdata/tst-table.sh 2002-04-24 23:39:35.000000000 +0200
-+++ glibc-2.12.1/iconvdata/tst-table.sh 2009-11-13 00:50:37.000000000 +0100
-@@ -59,8 +59,11 @@
- irreversible=${charset}.irreversible
- fi
-
-+# make sure libdl is also in path in case sandbox is in use
-+library_path=${common_objpfx}:${common_objpfx}/dlfcn
-+
- # iconv in one direction.
--${common_objpfx}elf/ld.so --library-path $common_objpfx \
-+${common_objpfx}elf/ld.so --library-path $library_path \
- ${objpfx}tst-table-from ${charset} \
- > ${objpfx}tst-${charset}.table
-
-diff -durN glibc-2.12.1.orig/intl/tst-codeset.sh glibc-2.12.1/intl/tst-codeset.sh
---- glibc-2.12.1.orig/intl/tst-codeset.sh 2005-04-06 04:18:35.000000000 +0200
-+++ glibc-2.12.1/intl/tst-codeset.sh 2009-11-13 00:50:37.000000000 +0100
-@@ -37,6 +37,9 @@
- LOCPATH=${common_objpfx}localedata
- export LOCPATH
-
-+# make sure libdl is also in path in case sandbox is in use
-+library_path=${common_objpfx}:${common_objpfx}/dlfcn
-+
- ${common_objpfx}elf/ld.so --library-path $common_objpfx \
- ${objpfx}tst-codeset > ${objpfx}tst-codeset.out
-
-diff -durN glibc-2.12.1.orig/intl/tst-gettext.sh glibc-2.12.1/intl/tst-gettext.sh
---- glibc-2.12.1.orig/intl/tst-gettext.sh 2004-08-15 21:28:18.000000000 +0200
-+++ glibc-2.12.1/intl/tst-gettext.sh 2009-11-13 00:50:37.000000000 +0100
-@@ -51,9 +51,12 @@
- LOCPATH=${common_objpfx}localedata
- export LOCPATH
-
-+# make sure libdl is also in path in case sandbox is in use
-+library_path=${common_objpfx}:${common_objpfx}/dlfcn
-+
- # Now run the test.
- MALLOC_TRACE=$malloc_trace LOCPATH=${objpfx}localedir:$LOCPATH \
--${common_objpfx}elf/ld.so --library-path $common_objpfx \
-+${common_objpfx}elf/ld.so --library-path $library_path \
- ${objpfx}tst-gettext > ${objpfx}tst-gettext.out ${objpfx}domaindir
-
- exit $?
-diff -durN glibc-2.12.1.orig/intl/tst-gettext2.sh glibc-2.12.1/intl/tst-gettext2.sh
---- glibc-2.12.1.orig/intl/tst-gettext2.sh 2005-05-04 19:54:48.000000000 +0200
-+++ glibc-2.12.1/intl/tst-gettext2.sh 2009-11-13 00:50:37.000000000 +0100
-@@ -65,8 +65,11 @@
- LOCPATH=${objpfx}domaindir
- export LOCPATH
-
-+# make sure libdl is also in path in case sandbox is in use
-+library_path=${common_objpfx}:${common_objpfx}/dlfcn
-+
- # Now run the test.
--${common_objpfx}elf/ld.so --library-path $common_objpfx \
-+${common_objpfx}elf/ld.so --library-path $library_path \
- ${objpfx}tst-gettext2 > ${objpfx}tst-gettext2.out ${objpfx}domaindir &&
- cmp ${objpfx}tst-gettext2.out - <<EOF
- String1 - Lang1: 1st string
-diff -durN glibc-2.12.1.orig/intl/tst-translit.sh glibc-2.12.1/intl/tst-translit.sh
---- glibc-2.12.1.orig/intl/tst-translit.sh 2005-05-04 19:56:10.000000000 +0200
-+++ glibc-2.12.1/intl/tst-translit.sh 2009-11-13 00:50:37.000000000 +0100
-@@ -36,7 +36,10 @@
- LOCPATH=${common_objpfx}localedata
- export LOCPATH
-
--${common_objpfx}elf/ld.so --library-path $common_objpfx \
-+# make sure libdl is also in path in case sandbox is in use
-+library_path=${common_objpfx}:${common_objpfx}/dlfcn
-+
-+${common_objpfx}elf/ld.so --library-path $library_path \
- ${objpfx}tst-translit > ${objpfx}tst-translit.out ${objpfx}domaindir
-
- exit $?
-diff -durN glibc-2.12.1.orig/malloc/tst-mtrace.sh glibc-2.12.1/malloc/tst-mtrace.sh
---- glibc-2.12.1.orig/malloc/tst-mtrace.sh 2005-10-15 01:40:35.000000000 +0200
-+++ glibc-2.12.1/malloc/tst-mtrace.sh 2009-11-13 00:50:37.000000000 +0100
-@@ -24,9 +24,12 @@
- status=0
- trap "rm -f ${common_objpfx}malloc/tst-mtrace.leak; exit 1" 1 2 15
-
-+# make sure libdl is also in path in case sandbox is in use
-+library_path=${common_objpfx}:${common_objpfx}/dlfcn
-+
- MALLOC_TRACE=${common_objpfx}malloc/tst-mtrace.leak \
- LOCPATH=${common_objpfx}localedata GCONV_PATH=${common_objpfx}iconvdata \
--${common_objpfx}elf/ld.so --library-path $common_objpfx \
-+${common_objpfx}elf/ld.so --library-path $library_path \
- ${common_objpfx}malloc/tst-mtrace || status=1
-
- if test $status -eq 0 && test -f ${common_objpfx}malloc/mtrace; then
-diff -durN glibc-2.12.1.orig/nptl/tst-tls6.sh glibc-2.12.1/nptl/tst-tls6.sh
---- glibc-2.12.1.orig/nptl/tst-tls6.sh 2003-09-03 00:02:59.000000000 +0200
-+++ glibc-2.12.1/nptl/tst-tls6.sh 2009-11-13 00:50:37.000000000 +0100
-@@ -5,8 +5,8 @@
- rtld_installed_name=$1; shift
- logfile=$common_objpfx/nptl/tst-tls6.out
-
--# We have to find libc and nptl
--library_path=${common_objpfx}:${common_objpfx}nptl
-+# We have to find libc and nptl (also libdl in case sandbox is in use)
-+library_path=${common_objpfx}:${common_objpfx}nptl:${common_objpfx}/dlfcn
- tst_tls5="${elf_objpfx}${rtld_installed_name} --library-path ${library_path} \
- ${common_objpfx}/nptl/tst-tls5"
-
-diff -durN glibc-2.12.1.orig/posix/globtest.sh glibc-2.12.1/posix/globtest.sh
---- glibc-2.12.1.orig/posix/globtest.sh 2008-12-06 07:05:39.000000000 +0100
-+++ glibc-2.12.1/posix/globtest.sh 2009-11-13 00:50:37.000000000 +0100
-@@ -18,7 +18,7 @@
- esac
-
- # We have to find the libc and the NSS modules.
--library_path=${common_objpfx}:${common_objpfx}nss:${common_objpfx}nis:${common_objpfx}db2:${common_objpfx}hesiod
-+library_path=${common_objpfx}:${common_objpfx}nss:${common_objpfx}nis:${common_objpfx}db2:${common_objpfx}hesiod:${common_objpfx}/dlfcn
-
- # Since we use `sort' we must make sure to use the same locale everywhere.
- LC_ALL=C
-diff -durN glibc-2.12.1.orig/posix/tst-getconf.sh glibc-2.12.1/posix/tst-getconf.sh
---- glibc-2.12.1.orig/posix/tst-getconf.sh 2002-09-01 13:11:25.000000000 +0200
-+++ glibc-2.12.1/posix/tst-getconf.sh 2009-11-13 00:50:37.000000000 +0100
-@@ -10,7 +10,10 @@
- else
- rtld_installed_name=$1; shift
- runit() {
-- ${elf_objpfx}${rtld_installed_name} --library-path ${common_objpfx} "$@"
-+
-+ # make sure libdl is also in path in case sandbox is in use
-+ library_path=${common_objpfx}:${common_objpfx}/dlfcn
-+ ${elf_objpfx}${rtld_installed_name} --library-path ${library_path} "$@"
- }
- fi
-
-diff -durN glibc-2.12.1.orig/posix/wordexp-tst.sh glibc-2.12.1/posix/wordexp-tst.sh
---- glibc-2.12.1.orig/posix/wordexp-tst.sh 2000-10-20 18:23:30.000000000 +0200
-+++ glibc-2.12.1/posix/wordexp-tst.sh 2009-11-13 00:50:37.000000000 +0100
-@@ -19,8 +19,11 @@
- "
- export IFS
-
-+# make sure libdl is also in path in case sandbox is in use
-+library_path=${common_objpfx}:${common_objpfx}/dlfcn
-+
- failed=0
--${elf_objpfx}${rtld_installed_name} --library-path ${common_objpfx} \
-+${elf_objpfx}${rtld_installed_name} --library-path ${library_path} \
- ${common_objpfx}posix/wordexp-test '$*' > ${testout}1
- cat <<"EOF" | cmp - ${testout}1 >> $logfile || failed=1
- wordexp returned 0
diff --git a/packages/glibc/2.12.1/380-dont-build-timezone.patch b/packages/glibc/2.12.1/380-dont-build-timezone.patch
deleted file mode 100644
index 0a30436..0000000
--- a/packages/glibc/2.12.1/380-dont-build-timezone.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-timezone data has been split into the package sys-libs/timezone-data
-
-diff -durN glibc-2.12.1.orig/Makeconfig glibc-2.12.1/Makeconfig
---- glibc-2.12.1.orig/Makeconfig 2009-11-13 00:50:13.000000000 +0100
-+++ glibc-2.12.1/Makeconfig 2009-11-13 00:50:41.000000000 +0100
-@@ -944,7 +944,7 @@
- stdlib stdio-common libio malloc string wcsmbs time dirent \
- grp pwd posix io termios resource misc socket sysvipc gmon \
- gnulib iconv iconvdata wctype manual shadow gshadow po argp \
-- crypt nss localedata timezone rt conform debug \
-+ crypt nss localedata rt conform debug \
- $(add-on-subdirs) $(dlfcn) $(binfmt-subdir)
-
- ifndef avoid-generated
diff --git a/packages/glibc/2.12.1/400-alpha-xstat.patch b/packages/glibc/2.12.1/400-alpha-xstat.patch
deleted file mode 100644
index 97bea98..0000000
--- a/packages/glibc/2.12.1/400-alpha-xstat.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-diff -durN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.12.1/sysdeps/unix/sysv/linux/kernel-features.h
---- glibc-2.12.1.orig/sysdeps/unix/sysv/linux/kernel-features.h 2009-05-09 08:54:20.000000000 +0200
-+++ glibc-2.12.1/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:50:45.000000000 +0100
-@@ -386,6 +386,11 @@
- # define __ASSUME_GETDENTS32_D_TYPE 1
- #endif
-
-+/* Starting with version 2.6.4, alpha stat64 syscalls are available. */
-+#if __LINUX_KERNEL_VERSION >= 0x020604 && defined __alpha__
-+# define __ASSUME_STAT64_SYSCALL 1
-+#endif
-+
- /* Starting with version 2.5.3, the initial location returned by `brk'
- after exec is always rounded up to the next page. */
- #if __LINUX_KERNEL_VERSION >= 132355
diff --git a/packages/glibc/2.12.1/430-alpha-creat.patch b/packages/glibc/2.12.1/430-alpha-creat.patch
deleted file mode 100644
index bfb72d0..0000000
--- a/packages/glibc/2.12.1/430-alpha-creat.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-alpha does not have a __NR_creat
-
-http://bugs.gentoo.org/227275
-http://sourceware.org/bugzilla/show_bug.cgi?id=6650
-
-diff -durN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/wordsize-64/creat64.c glibc-2.12.1/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
---- glibc-2.12.1.orig/sysdeps/unix/sysv/linux/wordsize-64/creat64.c 2007-11-10 20:34:26.000000000 +0100
-+++ glibc-2.12.1/sysdeps/unix/sysv/linux/wordsize-64/creat64.c 2009-11-13 00:50:51.000000000 +0100
-@@ -1 +1,5 @@
- /* Defined as alias for the syscall. */
-+#include <sysdep.h>
-+#ifndef __NR_creat
-+#include "../../../../../io/creat64.c"
-+#endif
diff --git a/packages/glibc/2.12.1/560-ppc-atomic.patch b/packages/glibc/2.12.1/560-ppc-atomic.patch
deleted file mode 100644
index 679ef18..0000000
--- a/packages/glibc/2.12.1/560-ppc-atomic.patch
+++ /dev/null
@@ -1,415 +0,0 @@
-sniped from suse
-
-Index: sysdeps/powerpc/bits/atomic.h
-===================================================================
-RCS file: /cvs/glibc/libc/sysdeps/powerpc/bits/atomic.h,v
-retrieving revision 1.17
-diff -u -a -p -r1.17 atomic.h
-
-diff -durN glibc-2.12.1.orig/sysdeps/powerpc/bits/atomic.h glibc-2.12.1/sysdeps/powerpc/bits/atomic.h
---- glibc-2.12.1.orig/sysdeps/powerpc/bits/atomic.h 2007-03-26 22:15:28.000000000 +0200
-+++ glibc-2.12.1/sysdeps/powerpc/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
-@@ -85,14 +85,14 @@
- __typeof (*(mem)) __tmp; \
- __typeof (mem) __memp = (mem); \
- __asm __volatile ( \
-- "1: lwarx %0,0,%1" MUTEX_HINT_ACQ "\n" \
-+ "1: lwarx %0,%y1" MUTEX_HINT_ACQ "\n" \
- " cmpw %0,%2\n" \
- " bne 2f\n" \
-- " stwcx. %3,0,%1\n" \
-+ " stwcx. %3,%y1\n" \
- " bne- 1b\n" \
- "2: " __ARCH_ACQ_INSTR \
-- : "=&r" (__tmp) \
-- : "b" (__memp), "r" (oldval), "r" (newval) \
-+ : "=&r" (__tmp), "+Z" (*__memp) \
-+ : "r" (oldval), "r" (newval) \
- : "cr0", "memory"); \
- __tmp; \
- })
-@@ -102,14 +102,14 @@
- __typeof (*(mem)) __tmp; \
- __typeof (mem) __memp = (mem); \
- __asm __volatile (__ARCH_REL_INSTR "\n" \
-- "1: lwarx %0,0,%1" MUTEX_HINT_REL "\n" \
-+ "1: lwarx %0,%y1" MUTEX_HINT_REL "\n" \
- " cmpw %0,%2\n" \
- " bne 2f\n" \
-- " stwcx. %3,0,%1\n" \
-+ " stwcx. %3,%y1\n" \
- " bne- 1b\n" \
- "2: " \
-- : "=&r" (__tmp) \
-- : "b" (__memp), "r" (oldval), "r" (newval) \
-+ : "=&r" (__tmp), "+Z" (__memp) \
-+ : "r" (oldval), "r" (newval) \
- : "cr0", "memory"); \
- __tmp; \
- })
-@@ -118,12 +118,12 @@
- ({ \
- __typeof (*mem) __val; \
- __asm __volatile ( \
-- "1: lwarx %0,0,%2" MUTEX_HINT_ACQ "\n" \
-- " stwcx. %3,0,%2\n" \
-+ "1: lwarx %0,%y1" MUTEX_HINT_ACQ "\n" \
-+ " stwcx. %2,%y1\n" \
- " bne- 1b\n" \
- " " __ARCH_ACQ_INSTR \
-- : "=&r" (__val), "=m" (*mem) \
-- : "b" (mem), "r" (value), "m" (*mem) \
-+ : "=&r" (__val), "+Z" (*mem) \
-+ : "r" (value) \
- : "cr0", "memory"); \
- __val; \
- })
-@@ -132,11 +132,11 @@
- ({ \
- __typeof (*mem) __val; \
- __asm __volatile (__ARCH_REL_INSTR "\n" \
-- "1: lwarx %0,0,%2" MUTEX_HINT_REL "\n" \
-- " stwcx. %3,0,%2\n" \
-+ "1: lwarx %0,%y1" MUTEX_HINT_REL "\n" \
-+ " stwcx. %2,%y1\n" \
- " bne- 1b" \
-- : "=&r" (__val), "=m" (*mem) \
-- : "b" (mem), "r" (value), "m" (*mem) \
-+ : "=&r" (__val), "+Z" (*mem) \
-+ : "r" (value) \
- : "cr0", "memory"); \
- __val; \
- })
-@@ -144,12 +144,12 @@
- #define __arch_atomic_exchange_and_add_32(mem, value) \
- ({ \
- __typeof (*mem) __val, __tmp; \
-- __asm __volatile ("1: lwarx %0,0,%3\n" \
-- " add %1,%0,%4\n" \
-- " stwcx. %1,0,%3\n" \
-+ __asm __volatile ("1: lwarx %0,%y2\n" \
-+ " add %1,%0,%3\n" \
-+ " stwcx. %1,%y2\n" \
- " bne- 1b" \
-- : "=&b" (__val), "=&r" (__tmp), "=m" (*mem) \
-- : "b" (mem), "r" (value), "m" (*mem) \
-+ : "=&b" (__val), "=&r" (__tmp), "+Z" (*mem) \
-+ : "r" (value) \
- : "cr0", "memory"); \
- __val; \
- })
-@@ -157,12 +157,12 @@
- #define __arch_atomic_increment_val_32(mem) \
- ({ \
- __typeof (*(mem)) __val; \
-- __asm __volatile ("1: lwarx %0,0,%2\n" \
-+ __asm __volatile ("1: lwarx %0,%y1\n" \
- " addi %0,%0,1\n" \
-- " stwcx. %0,0,%2\n" \
-+ " stwcx. %0,%y1\n" \
- " bne- 1b" \
-- : "=&b" (__val), "=m" (*mem) \
-- : "b" (mem), "m" (*mem) \
-+ : "=&b" (__val), "+Z" (*mem) \
-+ : \
- : "cr0", "memory"); \
- __val; \
- })
-@@ -170,27 +170,27 @@
- #define __arch_atomic_decrement_val_32(mem) \
- ({ \
- __typeof (*(mem)) __val; \
-- __asm __volatile ("1: lwarx %0,0,%2\n" \
-+ __asm __volatile ("1: lwarx %0,%y1\n" \
- " subi %0,%0,1\n" \
-- " stwcx. %0,0,%2\n" \
-+ " stwcx. %0,%y1\n" \
- " bne- 1b" \
-- : "=&b" (__val), "=m" (*mem) \
-- : "b" (mem), "m" (*mem) \
-+ : "=&b" (__val), "+Z" (*mem) \
-+ : \
- : "cr0", "memory"); \
- __val; \
- })
-
- #define __arch_atomic_decrement_if_positive_32(mem) \
- ({ int __val, __tmp; \
-- __asm __volatile ("1: lwarx %0,0,%3\n" \
-+ __asm __volatile ("1: lwarx %0,%y2\n" \
- " cmpwi 0,%0,0\n" \
- " addi %1,%0,-1\n" \
- " ble 2f\n" \
-- " stwcx. %1,0,%3\n" \
-+ " stwcx. %1,%y2\n" \
- " bne- 1b\n" \
- "2: " __ARCH_ACQ_INSTR \
-- : "=&b" (__val), "=&r" (__tmp), "=m" (*mem) \
-- : "b" (mem), "m" (*mem) \
-+ : "=&b" (__val), "=&r" (__tmp), "+Z" (*mem) \
-+ : \
- : "cr0", "memory"); \
- __val; \
- })
-diff -durN glibc-2.12.1.orig/sysdeps/powerpc/powerpc32/bits/atomic.h glibc-2.12.1/sysdeps/powerpc/powerpc32/bits/atomic.h
---- glibc-2.12.1.orig/sysdeps/powerpc/powerpc32/bits/atomic.h 2007-03-26 22:15:45.000000000 +0200
-+++ glibc-2.12.1/sysdeps/powerpc/powerpc32/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
-@@ -44,14 +44,14 @@
- ({ \
- unsigned int __tmp; \
- __asm __volatile ( \
-- "1: lwarx %0,0,%1" MUTEX_HINT_ACQ "\n" \
-+ "1: lwarx %0,%y1" MUTEX_HINT_ACQ "\n" \
- " subf. %0,%2,%0\n" \
- " bne 2f\n" \
-- " stwcx. %3,0,%1\n" \
-+ " stwcx. %3,%y1\n" \
- " bne- 1b\n" \
- "2: " __ARCH_ACQ_INSTR \
-- : "=&r" (__tmp) \
-- : "b" (mem), "r" (oldval), "r" (newval) \
-+ : "=&r" (__tmp), "+Z" (*(mem)) \
-+ : "r" (oldval), "r" (newval) \
- : "cr0", "memory"); \
- __tmp != 0; \
- })
-@@ -60,14 +60,14 @@
- ({ \
- unsigned int __tmp; \
- __asm __volatile (__ARCH_REL_INSTR "\n" \
-- "1: lwarx %0,0,%1" MUTEX_HINT_REL "\n" \
-+ "1: lwarx %0,%y1" MUTEX_HINT_REL "\n" \
- " subf. %0,%2,%0\n" \
- " bne 2f\n" \
-- " stwcx. %3,0,%1\n" \
-+ " stwcx. %3,%y1\n" \
- " bne- 1b\n" \
- "2: " \
-- : "=&r" (__tmp) \
-- : "b" (mem), "r" (oldval), "r" (newval) \
-+ : "=&r" (__tmp), "+Z" (*(mem)) \
-+ : "r" (oldval), "r" (newval) \
- : "cr0", "memory"); \
- __tmp != 0; \
- })
-diff -durN glibc-2.12.1.orig/sysdeps/powerpc/powerpc64/bits/atomic.h glibc-2.12.1/sysdeps/powerpc/powerpc64/bits/atomic.h
---- glibc-2.12.1.orig/sysdeps/powerpc/powerpc64/bits/atomic.h 2007-03-26 22:16:03.000000000 +0200
-+++ glibc-2.12.1/sysdeps/powerpc/powerpc64/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
-@@ -44,14 +44,14 @@
- ({ \
- unsigned int __tmp, __tmp2; \
- __asm __volatile (" clrldi %1,%1,32\n" \
-- "1: lwarx %0,0,%2" MUTEX_HINT_ACQ "\n" \
-+ "1: lwarx %0,%y2" MUTEX_HINT_ACQ "\n" \
- " subf. %0,%1,%0\n" \
- " bne 2f\n" \
-- " stwcx. %4,0,%2\n" \
-+ " stwcx. %4,%y2\n" \
- " bne- 1b\n" \
- "2: " __ARCH_ACQ_INSTR \
-- : "=&r" (__tmp), "=r" (__tmp2) \
-- : "b" (mem), "1" (oldval), "r" (newval) \
-+ : "=&r" (__tmp), "=r" (__tmp2), "+Z" (*(mem)) \
-+ : "1" (oldval), "r" (newval) \
- : "cr0", "memory"); \
- __tmp != 0; \
- })
-@@ -61,14 +61,14 @@
- unsigned int __tmp, __tmp2; \
- __asm __volatile (__ARCH_REL_INSTR "\n" \
- " clrldi %1,%1,32\n" \
-- "1: lwarx %0,0,%2" MUTEX_HINT_REL "\n" \
-+ "1: lwarx %0,%y2" MUTEX_HINT_REL "\n" \
- " subf. %0,%1,%0\n" \
- " bne 2f\n" \
-- " stwcx. %4,0,%2\n" \
-+ " stwcx. %4,%y2\n" \
- " bne- 1b\n" \
- "2: " \
-- : "=&r" (__tmp), "=r" (__tmp2) \
-- : "b" (mem), "1" (oldval), "r" (newval) \
-+ : "=&r" (__tmp), "=r" (__tmp2), "+Z" (*(mem)) \
-+ : "1" (oldval), "r" (newval) \
- : "cr0", "memory"); \
- __tmp != 0; \
- })
-@@ -82,14 +82,14 @@
- ({ \
- unsigned long __tmp; \
- __asm __volatile ( \
-- "1: ldarx %0,0,%1" MUTEX_HINT_ACQ "\n" \
-+ "1: ldarx %0,%y1" MUTEX_HINT_ACQ "\n" \
- " subf. %0,%2,%0\n" \
- " bne 2f\n" \
-- " stdcx. %3,0,%1\n" \
-+ " stdcx. %3,%y1\n" \
- " bne- 1b\n" \
- "2: " __ARCH_ACQ_INSTR \
-- : "=&r" (__tmp) \
-- : "b" (mem), "r" (oldval), "r" (newval) \
-+ : "=&r" (__tmp), "+Z" (*(mem)) \
-+ : "r" (oldval), "r" (newval) \
- : "cr0", "memory"); \
- __tmp != 0; \
- })
-@@ -98,14 +98,14 @@
- ({ \
- unsigned long __tmp; \
- __asm __volatile (__ARCH_REL_INSTR "\n" \
-- "1: ldarx %0,0,%2" MUTEX_HINT_REL "\n" \
-+ "1: ldarx %0,%y1" MUTEX_HINT_REL "\n" \
- " subf. %0,%2,%0\n" \
- " bne 2f\n" \
-- " stdcx. %3,0,%1\n" \
-+ " stdcx. %3,%y1\n" \
- " bne- 1b\n" \
- "2: " \
-- : "=&r" (__tmp) \
-- : "b" (mem), "r" (oldval), "r" (newval) \
-+ : "=&r" (__tmp), "+Z" (*(mem)) \
-+ : "r" (oldval), "r" (newval) \
- : "cr0", "memory"); \
- __tmp != 0; \
- })
-@@ -115,14 +115,14 @@
- __typeof (*(mem)) __tmp; \
- __typeof (mem) __memp = (mem); \
- __asm __volatile ( \
-- "1: ldarx %0,0,%1" MUTEX_HINT_ACQ "\n" \
-+ "1: ldarx %0,%y1" MUTEX_HINT_ACQ "\n" \
- " cmpd %0,%2\n" \
- " bne 2f\n" \
-- " stdcx. %3,0,%1\n" \
-+ " stdcx. %3,%y1\n" \
- " bne- 1b\n" \
- "2: " __ARCH_ACQ_INSTR \
-- : "=&r" (__tmp) \
-- : "b" (__memp), "r" (oldval), "r" (newval) \
-+ : "=&r" (__tmp), "+Z" (*__memp) \
-+ : "r" (oldval), "r" (newval) \
- : "cr0", "memory"); \
- __tmp; \
- })
-@@ -132,14 +132,14 @@
- __typeof (*(mem)) __tmp; \
- __typeof (mem) __memp = (mem); \
- __asm __volatile (__ARCH_REL_INSTR "\n" \
-- "1: ldarx %0,0,%1" MUTEX_HINT_REL "\n" \
-+ "1: ldarx %0,%y1" MUTEX_HINT_REL "\n" \
- " cmpd %0,%2\n" \
- " bne 2f\n" \
-- " stdcx. %3,0,%1\n" \
-+ " stdcx. %3,%y1\n" \
- " bne- 1b\n" \
- "2: " \
-- : "=&r" (__tmp) \
-- : "b" (__memp), "r" (oldval), "r" (newval) \
-+ : "=&r" (__tmp), "+Z" (*__memp) \
-+ : "r" (oldval), "r" (newval) \
- : "cr0", "memory"); \
- __tmp; \
- })
-@@ -148,12 +148,12 @@
- ({ \
- __typeof (*mem) __val; \
- __asm __volatile (__ARCH_REL_INSTR "\n" \
-- "1: ldarx %0,0,%2" MUTEX_HINT_ACQ "\n" \
-- " stdcx. %3,0,%2\n" \
-+ "1: ldarx %0,%y1" MUTEX_HINT_ACQ "\n" \
-+ " stdcx. %2,%y1\n" \
- " bne- 1b\n" \
- " " __ARCH_ACQ_INSTR \
-- : "=&r" (__val), "=m" (*mem) \
-- : "b" (mem), "r" (value), "m" (*mem) \
-+ : "=&r" (__val), "+Z" (*(mem)) \
-+ : "r" (value) \
- : "cr0", "memory"); \
- __val; \
- })
-@@ -162,11 +162,11 @@
- ({ \
- __typeof (*mem) __val; \
- __asm __volatile (__ARCH_REL_INSTR "\n" \
-- "1: ldarx %0,0,%2" MUTEX_HINT_REL "\n" \
-- " stdcx. %3,0,%2\n" \
-+ "1: ldarx %0,%y1" MUTEX_HINT_REL "\n" \
-+ " stdcx. %2,%y1\n" \
- " bne- 1b" \
-- : "=&r" (__val), "=m" (*mem) \
-- : "b" (mem), "r" (value), "m" (*mem) \
-+ : "=&r" (__val), "+Z" (*(mem)) \
-+ : "r" (value) \
- : "cr0", "memory"); \
- __val; \
- })
-@@ -174,12 +174,12 @@
- #define __arch_atomic_exchange_and_add_64(mem, value) \
- ({ \
- __typeof (*mem) __val, __tmp; \
-- __asm __volatile ("1: ldarx %0,0,%3\n" \
-- " add %1,%0,%4\n" \
-- " stdcx. %1,0,%3\n" \
-+ __asm __volatile ("1: ldarx %0,%y2\n" \
-+ " add %1,%0,%3\n" \
-+ " stdcx. %1,%y2\n" \
- " bne- 1b" \
-- : "=&b" (__val), "=&r" (__tmp), "=m" (*mem) \
-- : "b" (mem), "r" (value), "m" (*mem) \
-+ : "=&b" (__val), "=&r" (__tmp), "+Z" (*(mem)) \
-+ : "r" (value) \
- : "cr0", "memory"); \
- __val; \
- })
-@@ -187,12 +187,12 @@
- #define __arch_atomic_increment_val_64(mem) \
- ({ \
- __typeof (*(mem)) __val; \
-- __asm __volatile ("1: ldarx %0,0,%2\n" \
-+ __asm __volatile ("1: ldarx %0,%y1\n" \
- " addi %0,%0,1\n" \
-- " stdcx. %0,0,%2\n" \
-+ " stdcx. %0,%y1\n" \
- " bne- 1b" \
-- : "=&b" (__val), "=m" (*mem) \
-- : "b" (mem), "m" (*mem) \
-+ : "=&b" (__val), "+Z" (*(mem)) \
-+ : \
- : "cr0", "memory"); \
- __val; \
- })
-@@ -200,27 +200,27 @@
- #define __arch_atomic_decrement_val_64(mem) \
- ({ \
- __typeof (*(mem)) __val; \
-- __asm __volatile ("1: ldarx %0,0,%2\n" \
-+ __asm __volatile ("1: ldarx %0,%y1\n" \
- " subi %0,%0,1\n" \
-- " stdcx. %0,0,%2\n" \
-+ " stdcx. %0,%y1\n" \
- " bne- 1b" \
-- : "=&b" (__val), "=m" (*mem) \
-- : "b" (mem), "m" (*mem) \
-+ : "=&b" (__val), "+Z" (*(mem)) \
-+ : \
- : "cr0", "memory"); \
- __val; \
- })
-
- #define __arch_atomic_decrement_if_positive_64(mem) \
- ({ int __val, __tmp; \
-- __asm __volatile ("1: ldarx %0,0,%3\n" \
-+ __asm __volatile ("1: ldarx %0,%y2\n" \
- " cmpdi 0,%0,0\n" \
- " addi %1,%0,-1\n" \
- " ble 2f\n" \
-- " stdcx. %1,0,%3\n" \
-+ " stdcx. %1,%y2\n" \
- " bne- 1b\n" \
- "2: " __ARCH_ACQ_INSTR \
-- : "=&b" (__val), "=&r" (__tmp), "=m" (*mem) \
-- : "b" (mem), "m" (*mem) \
-+ : "=&b" (__val), "=&r" (__tmp), "+Z" (*(mem)) \
-+ : \
- : "cr0", "memory"); \
- __val; \
- })
diff --git a/packages/glibc/2.12.1/630-mips_shn_undef-hack.patch b/packages/glibc/2.12.1/630-mips_shn_undef-hack.patch
deleted file mode 100644
index f6a5eb6..0000000
--- a/packages/glibc/2.12.1/630-mips_shn_undef-hack.patch
+++ /dev/null
@@ -1,16 +0,0 @@
-diff -durN glibc-2.12.1.orig/elf/dl-lookup.c glibc-2.12.1/elf/dl-lookup.c
---- glibc-2.12.1.orig/elf/dl-lookup.c 2009-03-30 23:14:32.000000000 +0200
-+++ glibc-2.12.1/elf/dl-lookup.c 2009-11-13 00:51:36.000000000 +0100
-@@ -301,6 +301,12 @@
- /* FALLTHROUGH */
- case STB_GLOBAL:
- success:
-+#ifdef __mips__
-+ /* HACK: MIPS marks its lazy evaluation stubs with SHN_UNDEF
-+ symbols, we skip them. */
-+ if (sym->st_shndx == SHN_UNDEF)
-+ break;
-+#endif
- /* Global definition. Just what we need. */
- result->s = sym;
- result->m = (struct link_map *) map;
diff --git a/packages/glibc/2.12.1/660-debug-readlink_chk-readklinkat_chk.patch b/packages/glibc/2.12.1/660-debug-readlink_chk-readklinkat_chk.patch
deleted file mode 100644
index a5a7052..0000000
--- a/packages/glibc/2.12.1/660-debug-readlink_chk-readklinkat_chk.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-diff -dur glibc-cvs-2.9.orig/debug/readlink_chk.c glibc-cvs-2.9/debug/readlink_chk.c
---- glibc-cvs-2.9.orig/debug/readlink_chk.c 2005-03-01 01:41:15.000000000 +0100
-+++ glibc-cvs-2.9/debug/readlink_chk.c 2009-06-01 10:59:37.000000000 +0200
-@@ -25,7 +25,7 @@
-
-
- ssize_t
--__readlink_chk (const char *path, void *buf, size_t len, size_t buflen)
-+__readlink_chk (const char *path, char *buf, size_t len, size_t buflen)
- {
- if (len > buflen)
- __chk_fail ();
-diff -dur glibc-cvs-2.9.orig/debug/readlinkat_chk.c glibc-cvs-2.9/debug/readlinkat_chk.c
---- glibc-cvs-2.9.orig/debug/readlinkat_chk.c 2006-04-24 18:56:12.000000000 +0200
-+++ glibc-cvs-2.9/debug/readlinkat_chk.c 2009-06-01 11:07:26.000000000 +0200
-@@ -21,7 +21,7 @@
-
-
- ssize_t
--__readlinkat_chk (int fd, const char *path, void *buf, size_t len,
-+__readlinkat_chk (int fd, const char *path, char *buf, size_t len,
- size_t buflen)
- {
- if (len > buflen)
diff --git a/packages/glibc/2.12.1/910-typedef-caddr.patch b/packages/glibc/2.12.1/910-typedef-caddr.patch
deleted file mode 100644
index e29e810..0000000
--- a/packages/glibc/2.12.1/910-typedef-caddr.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-diff -urN glibc-2.12.1-orig/posix/sys/types.h glibc-2.12.1/posix/sys/types.h
---- glibc-2.12.1-orig/posix/sys/types.h 2010-12-13 11:47:26.000000000 +0100
-+++ glibc-2.12.1/posix/sys/types.h 2011-03-29 14:16:00.374064708 +0200
-@@ -114,7 +114,10 @@
- #ifdef __USE_BSD
- # ifndef __daddr_t_defined
- typedef __daddr_t daddr_t;
-+# if ! defined(caddr_t) && ! defined(__caddr_t_defined)
- typedef __caddr_t caddr_t;
-+# define __caddr_t_defined
-+# endif
- # define __daddr_t_defined
- # endif
- #endif
-diff -urN glibc-2.12.1-orig/sunrpc/rpc/types.h glibc-2.12.1/sunrpc/rpc/types.h
---- glibc-2.12.1-orig/sunrpc/rpc/types.h 2010-12-13 11:47:26.000000000 +0100
-+++ glibc-2.12.1/sunrpc/rpc/types.h 2011-03-29 14:16:32.988910439 +0200
-@@ -80,7 +80,10 @@
- #endif
- #ifndef __daddr_t_defined
- typedef __daddr_t daddr_t;
-+# if ! defined(caddr_t) && ! defined(__caddr_t_defined)
- typedef __caddr_t caddr_t;
-+# define __caddr_t_defined
-+# endif
- # define __daddr_t_defined
- #endif
-
diff --git a/packages/glibc/2.12.2/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.12.2/0000-Fix-combreloc-test-BSD-grep.patch
index 530d4ff..0f85a50 100644
--- a/packages/glibc/2.12.2/140-Fix-combreloc-test-BSD-grep.patch
+++ b/packages/glibc/2.12.2/0000-Fix-combreloc-test-BSD-grep.patch
@@ -13,15 +13,13 @@ by configure as "not found". As a result, support for "-z combreloc"
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
+ configure | 2 +-
+ configure.in | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
-diff -urpN glibc-2.12.2.orig/configure glibc-2.12.2/configure
---- glibc-2.12.2.orig/configure 2010-12-13 02:47:26.000000000 -0800
-+++ glibc-2.12.2/configure 2017-03-08 21:18:07.000000000 -0800
-@@ -6710,7 +6710,7 @@ EOF
+--- a/configure
++++ b/configure
+@@ -6710,7 +6710,7 @@
$as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }
then
@@ -30,10 +28,9 @@ diff -urpN glibc-2.12.2.orig/configure glibc-2.12.2/configure
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
-diff -urpN glibc-2.12.2.orig/configure.in glibc-2.12.2/configure.in
---- glibc-2.12.2.orig/configure.in 2010-12-13 02:47:26.000000000 -0800
-+++ glibc-2.12.2/configure.in 2017-03-08 21:18:17.000000000 -0800
-@@ -1671,7 +1671,7 @@ dnl cross-platform since the gcc used ca
+--- a/configure.in
++++ b/configure.in
+@@ -1671,7 +1671,7 @@
dnl introducing new options this is not easily doable. Instead use a tool
dnl which always is cross-platform: readelf. To detect whether -z combreloc
dnl look for a section named .rel.dyn.
diff --git a/packages/glibc/2.14.1/300-macos-cross-rpcgen.patch b/packages/glibc/2.12.2/0001-macos-cross-rpcgen.patch
index e654644..155b4f5 100644
--- a/packages/glibc/2.14.1/300-macos-cross-rpcgen.patch
+++ b/packages/glibc/2.12.2/0001-macos-cross-rpcgen.patch
@@ -14,11 +14,13 @@ Date: Sat Sep 7 00:01:08 2013 +0800
Signed-off-by: Jia Liu <proljc@gmail.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
-diff --git a/sunrpc/rpc/types.h b/sunrpc/rpc/types.h
-index 3dca5c4..beded52 100644
+---
+ sunrpc/rpc/types.h | 5 +++++
+ 1 file changed, 5 insertions(+)
+
--- a/sunrpc/rpc/types.h
+++ b/sunrpc/rpc/types.h
-@@ -69,6 +69,11 @@ typedef unsigned long rpcport_t;
+@@ -68,6 +68,11 @@
#include <sys/types.h>
#endif
diff --git a/packages/glibc/2.12.1/900-march-i686.patch b/packages/glibc/2.12.2/0002-march-i686.patch
index 7f5b1ce..e5ad2e0 100644
--- a/packages/glibc/2.12.1/900-march-i686.patch
+++ b/packages/glibc/2.12.2/0002-march-i686.patch
@@ -3,9 +3,13 @@
* sysdeps/unix/sysv/linux/i386/sysdep.h: Re-define __i686.
* nptl/sysdeps/pthread/pt-initfini.c: Ditto.
-diff -urN glibc-2.12.1.orig/nptl/sysdeps/pthread/pt-initfini.c glibc-2.12.1/nptl/sysdeps/pthread/pt-initfini.c
---- glibc-2.12.1.orig/nptl/sysdeps/pthread/pt-initfini.c 2009-10-30 18:17:08.000000000 +0100
-+++ glibc-2.12.1/nptl/sysdeps/pthread/pt-initfini.c 2010-12-30 11:36:19.858708534 +0100
+---
+ nptl/sysdeps/pthread/pt-initfini.c | 5 +++++
+ sysdeps/unix/sysv/linux/i386/sysdep.h | 4 ++++
+ 2 files changed, 9 insertions(+)
+
+--- a/nptl/sysdeps/pthread/pt-initfini.c
++++ b/nptl/sysdeps/pthread/pt-initfini.c
@@ -45,6 +45,11 @@
/* Embed an #include to pull in the alignment and .end directives. */
asm ("\n#include \"defs.h\"");
@@ -18,9 +22,8 @@ diff -urN glibc-2.12.1.orig/nptl/sysdeps/pthread/pt-initfini.c glibc-2.12.1/nptl
/* The initial common code ends here. */
asm ("\n/*@HEADER_ENDS*/");
-diff -urN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/i386/sysdep.h glibc-2.12.1/sysdeps/unix/sysv/linux/i386/sysdep.h
---- glibc-2.12.1.orig/sysdeps/unix/sysv/linux/i386/sysdep.h 2009-10-30 18:17:08.000000000 +0100
-+++ glibc-2.12.1/sysdeps/unix/sysv/linux/i386/sysdep.h 2010-12-30 11:36:19.858708534 +0100
+--- a/sysdeps/unix/sysv/linux/i386/sysdep.h
++++ b/sysdeps/unix/sysv/linux/i386/sysdep.h
@@ -29,6 +29,10 @@
#include <dl-sysdep.h>
#include <tls.h>
diff --git a/packages/glibc/2.13/910-typedef-caddr.patch b/packages/glibc/2.12.2/0003-typedef-caddr.patch
index e29e810..5139bbd 100644
--- a/packages/glibc/2.13/910-typedef-caddr.patch
+++ b/packages/glibc/2.12.2/0003-typedef-caddr.patch
@@ -1,6 +1,10 @@
-diff -urN glibc-2.12.1-orig/posix/sys/types.h glibc-2.12.1/posix/sys/types.h
---- glibc-2.12.1-orig/posix/sys/types.h 2010-12-13 11:47:26.000000000 +0100
-+++ glibc-2.12.1/posix/sys/types.h 2011-03-29 14:16:00.374064708 +0200
+---
+ posix/sys/types.h | 3 +++
+ sunrpc/rpc/types.h | 3 +++
+ 2 files changed, 6 insertions(+)
+
+--- a/posix/sys/types.h
++++ b/posix/sys/types.h
@@ -114,7 +114,10 @@
#ifdef __USE_BSD
# ifndef __daddr_t_defined
@@ -12,10 +16,9 @@ diff -urN glibc-2.12.1-orig/posix/sys/types.h glibc-2.12.1/posix/sys/types.h
# define __daddr_t_defined
# endif
#endif
-diff -urN glibc-2.12.1-orig/sunrpc/rpc/types.h glibc-2.12.1/sunrpc/rpc/types.h
---- glibc-2.12.1-orig/sunrpc/rpc/types.h 2010-12-13 11:47:26.000000000 +0100
-+++ glibc-2.12.1/sunrpc/rpc/types.h 2011-03-29 14:16:32.988910439 +0200
-@@ -80,7 +80,10 @@
+--- a/sunrpc/rpc/types.h
++++ b/sunrpc/rpc/types.h
+@@ -85,7 +85,10 @@
#endif
#ifndef __daddr_t_defined
typedef __daddr_t daddr_t;
diff --git a/packages/glibc/2.14.1/920-fix-rpc_parse-format.patch b/packages/glibc/2.12.2/0004-fix-rpc_parse-format.patch
index 37e58da..906fb70 100644
--- a/packages/glibc/2.14.1/920-fix-rpc_parse-format.patch
+++ b/packages/glibc/2.12.2/0004-fix-rpc_parse-format.patch
@@ -45,11 +45,13 @@ Date: Tue Nov 8 23:44:51 2016 +0000
[$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
[$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
-diff --git a/sunrpc/rpc_parse.c b/sunrpc/rpc_parse.c
-index 1a1df6d8c2..505a6554cf 100644
+---
+ sunrpc/rpc_parse.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
--- a/sunrpc/rpc_parse.c
+++ b/sunrpc/rpc_parse.c
-@@ -521,7 +521,7 @@ static void
+@@ -520,7 +520,7 @@
get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
{
token tok;
diff --git a/packages/glibc/2.12.2/940-nis-bogus-conditional.patch b/packages/glibc/2.12.2/0005-nis-bogus-conditional.patch
index 09b38cf..732b859 100644
--- a/packages/glibc/2.12.2/940-nis-bogus-conditional.patch
+++ b/packages/glibc/2.12.2/0005-nis-bogus-conditional.patch
@@ -47,11 +47,13 @@ Date: Wed Dec 21 23:44:01 2016 +0000
* nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
Compare name == NULL, not name != NULL.
-diff --git a/nis/nss_nisplus/nisplus-alias.c b/nis/nss_nisplus/nisplus-alias.c
-index 7f698b4e6d..cb5acce01d 100644
+---
+ nis/nss_nisplus/nisplus-alias.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
--- a/nis/nss_nisplus/nisplus-alias.c
+++ b/nis/nss_nisplus/nisplus-alias.c
-@@ -291,7 +291,7 @@ _nss_nisplus_getaliasbyname_r (const char *name, struct aliasent *alias,
+@@ -293,7 +293,7 @@
return status;
}
diff --git a/packages/glibc/2.14.1/998-obstack-common.patch b/packages/glibc/2.12.2/0006-obstack-common.patch
index 4b95f06..1993be2 100644
--- a/packages/glibc/2.14.1/998-obstack-common.patch
+++ b/packages/glibc/2.12.2/0006-obstack-common.patch
@@ -15,11 +15,13 @@ Date: Wed May 15 20:28:08 2013 +0200
* malloc/obstack.c (_obstack_compat): Add initializer.
-
-diff --git a/malloc/obstack.c b/malloc/obstack.c
-index 25a90514f7..c3c7db4a96 100644
+---
+ malloc/obstack.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
--- a/malloc/obstack.c
+++ b/malloc/obstack.c
-@@ -115,7 +115,7 @@ int obstack_exit_failure = EXIT_FAILURE;
+@@ -117,7 +117,7 @@
/* A looong time ago (before 1994, anyway; we're not sure) this global variable
was used by non-GNU-C macros to avoid multiple evaluation. The GNU C
library still exports it because somebody might use it. */
diff --git a/packages/glibc/2.12.2/999-new-tools.patch b/packages/glibc/2.12.2/0007-new-tools.patch
index e2f7b1d..816a01c 100644
--- a/packages/glibc/2.12.2/999-new-tools.patch
+++ b/packages/glibc/2.12.2/0007-new-tools.patch
@@ -1,7 +1,11 @@
-diff -urpN glibc-2.12.2.orig/configure glibc-2.12.2/configure
---- glibc-2.12.2.orig/configure 2010-12-13 02:47:26.000000000 -0800
-+++ glibc-2.12.2/configure 2017-02-08 00:38:10.249617723 -0800
-@@ -5189,7 +5189,7 @@ $as_echo_n "checking version of $CC... "
+---
+ configure | 8 ++++----
+ configure.in | 8 ++++----
+ 2 files changed, 8 insertions(+), 8 deletions(-)
+
+--- a/configure
++++ b/configure
+@@ -5189,7 +5189,7 @@
ac_prog_version=`$CC -v 2>&1 | sed -n 's/^.*version \([egcygnustpi-]*[0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -10,7 +14,7 @@ diff -urpN glibc-2.12.2.orig/configure glibc-2.12.2/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5252,7 +5252,7 @@ $as_echo_n "checking version of $MAKE...
+@@ -5252,7 +5252,7 @@
ac_prog_version=`$MAKE --version 2>&1 | sed -n 's/^.*GNU Make[^0-9]*\([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -19,7 +23,7 @@ diff -urpN glibc-2.12.2.orig/configure glibc-2.12.2/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5379,7 +5379,7 @@ $as_echo_n "checking version of $MAKEINF
+@@ -5379,7 +5379,7 @@
ac_prog_version=`$MAKEINFO --version 2>&1 | sed -n 's/^.*GNU texinfo.* \([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -28,7 +32,7 @@ diff -urpN glibc-2.12.2.orig/configure glibc-2.12.2/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5439,7 +5439,7 @@ else
+@@ -5439,7 +5439,7 @@
# Found it, now check the version.
{ $as_echo "$as_me:$LINENO: checking version of $SED" >&5
$as_echo_n "checking version of $SED... " >&6; }
@@ -37,10 +41,9 @@ diff -urpN glibc-2.12.2.orig/configure glibc-2.12.2/configure
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
3.0[2-9]*|3.[1-9]*|[4-9]*)
-diff -urpN glibc-2.12.2.orig/configure.in glibc-2.12.2/configure.in
---- glibc-2.12.2.orig/configure.in 2010-12-13 02:47:26.000000000 -0800
-+++ glibc-2.12.2/configure.in 2017-02-08 00:29:52.484183611 -0800
-@@ -1026,11 +1026,11 @@ fi
+--- a/configure.in
++++ b/configure.in
+@@ -1026,11 +1026,11 @@
# These programs are version sensitive.
AC_CHECK_TOOL_PREFIX
AC_CHECK_PROG_VER(CC, ${ac_tool_prefix}gcc ${ac_tool_prefix}cc, -v,
@@ -54,7 +57,7 @@ diff -urpN glibc-2.12.2.orig/configure.in glibc-2.12.2/configure.in
AC_CHECK_PROG_VER(MSGFMT, gnumsgfmt gmsgfmt msgfmt, --version,
[GNU gettext.* \([0-9]*\.[0-9.]*\)],
-@@ -1038,10 +1038,10 @@ AC_CHECK_PROG_VER(MSGFMT, gnumsgfmt gmsg
+@@ -1038,10 +1038,10 @@
MSGFMT=: aux_missing="$aux_missing msgfmt")
AC_CHECK_PROG_VER(MAKEINFO, makeinfo, --version,
[GNU texinfo.* \([0-9][0-9.]*\)],
diff --git a/packages/glibc/2.13/100-respect-env-CPPFLAGS.patch b/packages/glibc/2.13/0000-respect-env-CPPFLAGS.patch
index 3798cb2..9966a27 100644
--- a/packages/glibc/2.13/100-respect-env-CPPFLAGS.patch
+++ b/packages/glibc/2.13/0000-respect-env-CPPFLAGS.patch
@@ -1,9 +1,12 @@
Respect environment CPPFLAGS when we run ./configure so we can inject
random -D things without having to set CFLAGS/ASFLAGS
-diff -durN glibc-2.13.orig/Makeconfig glibc-2.13/Makeconfig
---- glibc-2.13.orig/Makeconfig 2009-05-09 23:57:56.000000000 +0200
-+++ glibc-2.13/Makeconfig 2009-11-13 00:49:41.000000000 +0100
+---
+ Makeconfig | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/Makeconfig
++++ b/Makeconfig
@@ -697,6 +697,7 @@
$(foreach lib,$(libof-$(basename $(@F))) \
$(libof-$(<F)) $(libof-$(@F)),$(CPPFLAGS-$(lib))) \
diff --git a/packages/glibc/2.12.1/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.13/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
index 6fd663a..30a70a2 100644
--- a/packages/glibc/2.12.1/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
+++ b/packages/glibc/2.13/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
@@ -5,16 +5,13 @@ Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
-Wparentheses
---
- ChangeLog | 5 +++++
- nis/nis_call.c | 20 +++++++++++---------
- stdlib/setenv.c | 26 ++++++++++++++------------
- 3 files changed, 30 insertions(+), 21 deletions(-)
+ nis/nis_call.c | 20 +++++++++++---------
+ stdlib/setenv.c | 24 +++++++++++++-----------
+ 2 files changed, 24 insertions(+), 20 deletions(-)
-diff --git a/nis/nis_call.c b/nis/nis_call.c
-index 3fa37e4..cb7839a 100644
--- a/nis/nis_call.c
+++ b/nis/nis_call.c
-@@ -680,16 +680,18 @@ nis_server_cache_add (const_nis_name name, int search_parent,
+@@ -682,16 +682,18 @@
/* Choose which entry should be evicted from the cache. */
loc = &nis_server_cache[0];
if (*loc != NULL)
@@ -42,11 +39,9 @@ index 3fa37e4..cb7839a 100644
old = *loc;
*loc = new;
-diff --git a/stdlib/setenv.c b/stdlib/setenv.c
-index da61ee0..e66045f 100644
--- a/stdlib/setenv.c
+++ b/stdlib/setenv.c
-@@ -278,18 +278,20 @@ unsetenv (const char *name)
+@@ -328,18 +328,20 @@
ep = __environ;
if (ep != NULL)
while (*ep != NULL)
@@ -54,7 +49,12 @@ index da61ee0..e66045f 100644
- {
- /* Found it. Remove this pointer by moving later ones back. */
- char **dp = ep;
--
++ {
++ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
++ {
++ /* Found it. Remove this pointer by moving later ones back. */
++ char **dp = ep;
+
- do
- dp[0] = dp[1];
- while (*dp++);
@@ -62,12 +62,6 @@ index da61ee0..e66045f 100644
- }
- else
- ++ep;
-+ {
-+ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-+ {
-+ /* Found it. Remove this pointer by moving later ones back. */
-+ char **dp = ep;
-+
+ do
+ dp[0] = dp[1];
+ while (*dp++);
@@ -79,6 +73,3 @@ index da61ee0..e66045f 100644
UNLOCK;
---
-2.7.4
-
diff --git a/packages/glibc/2.14.1/102-fix-signed-shift-overlow.patch b/packages/glibc/2.13/0002-fix-signed-shift-overlow.patch
index ef49f83..5f76afe 100644
--- a/packages/glibc/2.14.1/102-fix-signed-shift-overlow.patch
+++ b/packages/glibc/2.13/0002-fix-signed-shift-overlow.patch
@@ -12,11 +12,16 @@ Date: Tue Jul 21 22:50:29 2015 -0700
* string/strchrnul.c (STRCHRNUL):
Rewrite code to avoid issues with signed shift overflow.
-diff --git a/string/memrchr.c b/string/memrchr.c
-index 0c8fd84..86cd5b9 100644
+---
+ string/memrchr.c | 11 ++---------
+ string/rawmemchr.c | 11 ++---------
+ string/strchr.c | 9 ++-------
+ string/strchrnul.c | 9 ++-------
+ 4 files changed, 8 insertions(+), 32 deletions(-)
+
--- a/string/memrchr.c
+++ b/string/memrchr.c
-@@ -96,15 +96,8 @@ MEMRCHR
+@@ -98,15 +98,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
@@ -34,11 +39,9 @@ index 0c8fd84..86cd5b9 100644
/* Set up a longword, each of whose bytes is C. */
charmask = c | (c << 8);
-diff --git a/string/rawmemchr.c b/string/rawmemchr.c
-index 05b22be..228ca9d 100644
--- a/string/rawmemchr.c
+++ b/string/rawmemchr.c
-@@ -86,15 +86,8 @@ RAWMEMCHR (s, c_in)
+@@ -90,15 +90,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
@@ -56,11 +59,9 @@ index 05b22be..228ca9d 100644
/* Set up a longword, each of whose bytes is C. */
charmask = c | (c << 8);
-diff --git a/string/strchr.c b/string/strchr.c
-index 5f90075..f13b2b3 100644
--- a/string/strchr.c
+++ b/string/strchr.c
-@@ -60,13 +60,8 @@ strchr (const char *s, int c_in)
+@@ -65,13 +65,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
@@ -76,11 +77,9 @@ index 5f90075..f13b2b3 100644
/* Set up a longword, each of whose bytes is C. */
charmask = c | (c << 8);
-diff --git a/string/strchrnul.c b/string/strchrnul.c
-index 2678f1d..daf0b3f 100644
--- a/string/strchrnul.c
+++ b/string/strchrnul.c
-@@ -66,13 +66,8 @@ STRCHRNUL (s, c_in)
+@@ -63,13 +63,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
diff --git a/packages/glibc/2.14.1/104-unused-variables.patch b/packages/glibc/2.13/0003-unused-variables.patch
index e063675..18adb17 100644
--- a/packages/glibc/2.14.1/104-unused-variables.patch
+++ b/packages/glibc/2.13/0003-unused-variables.patch
@@ -19,8 +19,18 @@ Date: Fri Sep 18 20:27:20 2015 +0100
* timezone/private.h (time_t_min): Likewise. (time_t_max):
Likewise.
-diff --git a/resolv/base64.c b/resolv/base64.c
-index ea584ed..519e5d2 100644
+---
+ resolv/base64.c | 4 ----
+ sysdeps/ieee754/dbl-64/atnat2.h | 4 ----
+ sysdeps/ieee754/dbl-64/uexp.h | 2 +-
+ sysdeps/ieee754/dbl-64/upow.h | 2 --
+ sysdeps/ieee754/flt-32/e_log10f.c | 6 ------
+ sysdeps/ieee754/flt-32/s_cosf.c | 6 ------
+ sysdeps/ieee754/ldbl-128/e_lgammal_r.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_erfl.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_log1pl.c | 1 -
+ 9 files changed, 1 insertion(+), 26 deletions(-)
+
--- a/resolv/base64.c
+++ b/resolv/base64.c
@@ -40,10 +40,6 @@
@@ -34,11 +44,9 @@ index ea584ed..519e5d2 100644
#include <sys/types.h>
#include <sys/param.h>
#include <sys/socket.h>
-diff --git a/sysdeps/ieee754/dbl-64/atnat2.h b/sysdeps/ieee754/dbl-64/atnat2.h
-index e0d65af..82943f9 100644
--- a/sysdeps/ieee754/dbl-64/atnat2.h
+++ b/sysdeps/ieee754/dbl-64/atnat2.h
-@@ -65,10 +65,8 @@
+@@ -69,10 +69,8 @@
/**/ hpi1 = {{0x3c91a626, 0x33145c07} }, /* pi/2-hpi */
/**/ mhpi = {{0xbff921fb, 0x54442d18} }, /* -pi/2 */
/**/ qpi = {{0x3fe921fb, 0x54442d18} }, /* pi/4 */
@@ -49,7 +57,7 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0xc002d97c, 0x7f3321d2} }, /* -3pi/4 */
/**/ u1 = {{0x3c314c2a, 0x00000000} }, /* 9.377e-19 */
/**/ u2 = {{0x3bf955e4, 0x00000000} }, /* 8.584e-20 */
-@@ -129,10 +127,8 @@
+@@ -139,10 +137,8 @@
/**/ hpi1 = {{0x33145c07, 0x3c91a626} }, /* pi/2-hpi */
/**/ mhpi = {{0x54442d18, 0xbff921fb} }, /* -pi/2 */
/**/ qpi = {{0x54442d18, 0x3fe921fb} }, /* pi/4 */
@@ -60,11 +68,9 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0x7f3321d2, 0xc002d97c} }, /* -3pi/4 */
/**/ u1 = {{0x00000000, 0x3c314c2a} }, /* 9.377e-19 */
/**/ u2 = {{0x00000000, 0x3bf955e4} }, /* 8.584e-20 */
-diff --git a/sysdeps/ieee754/dbl-64/uexp.h b/sysdeps/ieee754/dbl-64/uexp.h
-index 6817eaf..42b21f2 100644
--- a/sysdeps/ieee754/dbl-64/uexp.h
+++ b/sysdeps/ieee754/dbl-64/uexp.h
-@@ -29,7 +29,7 @@
+@@ -30,7 +30,7 @@
#include "mydefs.h"
@@ -73,11 +79,9 @@ index 6817eaf..42b21f2 100644
err_0 = 1.000014, err_1 = 0.000016;
const static int4 bigint = 0x40862002,
badint = 0x40876000,smallint = 0x3C8fffff;
-diff --git a/sysdeps/ieee754/dbl-64/upow.h b/sysdeps/ieee754/dbl-64/upow.h
-index c8569a9..b4911e5 100644
--- a/sysdeps/ieee754/dbl-64/upow.h
+++ b/sysdeps/ieee754/dbl-64/upow.h
-@@ -34,7 +34,6 @@
+@@ -36,7 +36,6 @@
/**/ INF = {{0x7ff00000, 0x00000000}}, /* INF */
/**/ nINF = {{0xfff00000, 0x00000000}}, /* -INF */
/**/ NaNQ = {{0x7ff80000, 0x00000000}}, /* NaNQ */
@@ -85,7 +89,7 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0x3fe62e42, 0xfefa3800}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x3d2ef357, 0x93c76730}}, /* ln(2)-ln2a */
/**/ bigu = {{0x4297ffff, 0xfffffd2c}}, /* 1.5*2**42 -724*2**-10 */
-@@ -48,7 +47,6 @@
+@@ -51,7 +50,6 @@
/**/ INF = {{0x00000000, 0x7ff00000}}, /* INF */
/**/ nINF = {{0x00000000, 0xfff00000}}, /* -INF */
/**/ NaNQ = {{0x00000000, 0x7ff80000}}, /* NaNQ */
@@ -93,45 +97,39 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0xfefa3800, 0x3fe62e42}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x93c76730, 0x3d2ef357}}, /* ln(2)-ln2a */
/**/ bigu = {{0xfffffd2c, 0x4297ffff}}, /* 1.5*2**42 -724*2**-10 */
-diff --git a/sysdeps/ieee754/flt-32/e_log10f.c b/sysdeps/ieee754/flt-32/e_log10f.c
-index 96f0e81..1daeef7 100644
--- a/sysdeps/ieee754/flt-32/e_log10f.c
+++ b/sysdeps/ieee754/flt-32/e_log10f.c
-@@ -22,12 +22,6 @@ ivln10 = 4.3429449201e-01, /* 0x3ede5bd9 */
- log10_2hi = 3.0102920532e-01, /* 0x3e9a2080 */
+@@ -31,12 +31,6 @@
log10_2lo = 7.9034151668e-07; /* 0x355427db */
--#ifdef __STDC__
+ #ifdef __STDC__
-static const float zero = 0.0;
-#else
-static float zero = 0.0;
-#endif
-
- #ifdef __STDC__
+-#ifdef __STDC__
float __ieee754_log10f(float x)
#else
-diff --git a/sysdeps/ieee754/flt-32/s_cosf.c b/sysdeps/ieee754/flt-32/s_cosf.c
-index 864ab27..0affd40 100644
+ float __ieee754_log10f(x)
--- a/sysdeps/ieee754/flt-32/s_cosf.c
+++ b/sysdeps/ieee754/flt-32/s_cosf.c
-@@ -21,12 +21,6 @@ static char rcsid[] = "$NetBSD: s_cosf.c,v 1.4 1995/05/10 20:47:03 jtc Exp $";
- #include "math.h"
+@@ -22,12 +22,6 @@
#include "math_private.h"
--#ifdef __STDC__
+ #ifdef __STDC__
-static const float one=1.0;
-#else
-static float one=1.0;
-#endif
-
- #ifdef __STDC__
+-#ifdef __STDC__
float __cosf(float x)
#else
-diff --git a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-index 500aacc..ab5a96e 100644
+ float __cosf(x)
--- a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
+++ b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-@@ -82,7 +82,6 @@ DIAG_IGNORE_NEEDS_COMMENT (4.6, "-Woverflow");
+@@ -74,7 +74,6 @@
static const long double PIL = 3.1415926535897932384626433832795028841972E0L;
static const long double MAXLGM = 1.0485738685148938358098967157129705071571E4928L;
static const long double one = 1.0L;
@@ -139,11 +137,9 @@ index 500aacc..ab5a96e 100644
static const long double huge = 1.0e4000L;
/* log gamma(x) = ( x - 0.5 ) * log(x) - x + LS2PI + 1/x P(1/x^2)
-diff --git a/sysdeps/ieee754/ldbl-128/s_erfl.c b/sysdeps/ieee754/ldbl-128/s_erfl.c
-index fa4609f..08c80a3 100644
--- a/sysdeps/ieee754/ldbl-128/s_erfl.c
+++ b/sysdeps/ieee754/ldbl-128/s_erfl.c
-@@ -140,7 +140,6 @@ deval (long double x, const long double *p, int n)
+@@ -142,7 +142,6 @@
static long double
#endif
tiny = 1e-4931L,
@@ -151,11 +147,9 @@ index fa4609f..08c80a3 100644
one = 1.0L,
two = 2.0L,
/* 2/sqrt(pi) - 1 */
-diff --git a/sysdeps/ieee754/ldbl-128/s_log1pl.c b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-index ff759bc..9609550 100644
--- a/sysdeps/ieee754/ldbl-128/s_log1pl.c
+++ b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-@@ -117,7 +117,6 @@ static const long double C2 = 1.428606820309417232121458176568075500134E-6L;
+@@ -116,7 +116,6 @@
static const long double sqrth = 0.7071067811865475244008443621048490392848L;
/* ln (2^16384 * (1 - 2^-113)) */
diff --git a/packages/glibc/2.12.1/105-misleading-indentation.patch b/packages/glibc/2.13/0004-misleading-indentation.patch
index 1dd8d85..35bcb1b 100644
--- a/packages/glibc/2.12.1/105-misleading-indentation.patch
+++ b/packages/glibc/2.13/0004-misleading-indentation.patch
@@ -7,11 +7,13 @@ Date: Fri Dec 11 09:19:37 2015 -0800
* sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
Fix indentation.
-diff --git a/sysdeps/ieee754/flt-32/k_rem_pio2f.c b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-index 0c7685c..392afdb 100644
+---
+ sysdeps/ieee754/flt-32/k_rem_pio2f.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
--- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
+++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-@@ -65,7 +65,9 @@ int __kernel_rem_pio2f(float *x, float *y, int e0, int nx, int prec, const int32
+@@ -82,7 +82,9 @@
/* compute q[0],q[1],...q[jk] */
for (i=0;i<=jk;i++) {
diff --git a/packages/glibc/2.13/106-dl-open-array-bounds.patch b/packages/glibc/2.13/0005-dl-open-array-bounds.patch
index bdb5c19..0bedbc0 100644
--- a/packages/glibc/2.13/106-dl-open-array-bounds.patch
+++ b/packages/glibc/2.13/0005-dl-open-array-bounds.patch
@@ -4,11 +4,13 @@ Date: Fri Apr 17 12:11:58 2015 -0700
Fuller check for invalid NSID in _dl_open.
-diff --git a/elf/dl-open.c b/elf/dl-open.c
-index 0dbe07f..2d0e082 100644
+---
+ elf/dl-open.c | 10 ++++++++--
+ 1 file changed, 8 insertions(+), 2 deletions(-)
+
--- a/elf/dl-open.c
+++ b/elf/dl-open.c
-@@ -619,8 +619,14 @@ no more namespaces available for dlmopen()"));
+@@ -526,8 +526,14 @@
/* Never allow loading a DSO in a namespace which is empty. Such
direct placements is only causing problems. Also don't allow
loading into a namespace used for auditing. */
diff --git a/packages/glibc/2.13/120-i386-x86_64-revert-clone-cfi.patch b/packages/glibc/2.13/0006-i386-x86_64-revert-clone-cfi.patch
index c7f6182..f872bac 100644
--- a/packages/glibc/2.13/120-i386-x86_64-revert-clone-cfi.patch
+++ b/packages/glibc/2.13/0006-i386-x86_64-revert-clone-cfi.patch
@@ -4,16 +4,13 @@ elsewhere. this cfi code does not gain us a whole lot anyways.
http://gcc.gnu.org/ml/gcc/2006-12/msg00293.html
-Index: sysdeps/unix/sysv/linux/i386/clone.S
-===================================================================
-RCS file: /cvs/glibc/libc/sysdeps/unix/sysv/linux/i386/clone.S,v
-retrieving revision 1.27
-retrieving revision 1.26
-diff -u -p -r1.27 -r1.26
+---
+ sysdeps/unix/sysv/linux/i386/clone.S | 4 ----
+ sysdeps/unix/sysv/linux/x86_64/clone.S | 4 ----
+ 2 files changed, 8 deletions(-)
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/i386/clone.S glibc-2.13/sysdeps/unix/sysv/linux/i386/clone.S
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/i386/clone.S 2006-12-04 00:12:36.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/i386/clone.S 2009-11-13 00:49:45.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/i386/clone.S
++++ b/sysdeps/unix/sysv/linux/i386/clone.S
@@ -120,9 +120,6 @@
ret
@@ -32,9 +29,8 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/i386/clone.S glibc-2.13/sysde
cfi_startproc
PSEUDO_END (BP_SYM (__clone))
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/x86_64/clone.S glibc-2.13/sysdeps/unix/sysv/linux/x86_64/clone.S
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/x86_64/clone.S 2006-12-04 00:12:36.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/x86_64/clone.S 2009-11-13 00:49:45.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/x86_64/clone.S
++++ b/sysdeps/unix/sysv/linux/x86_64/clone.S
@@ -89,9 +89,6 @@
ret
diff --git a/packages/glibc/2.15/140-disable-ldconfig.patch b/packages/glibc/2.13/0007-disable-ldconfig.patch
index 378e1df..d60cb40 100644
--- a/packages/glibc/2.15/140-disable-ldconfig.patch
+++ b/packages/glibc/2.13/0007-disable-ldconfig.patch
@@ -3,9 +3,12 @@ file outside of the chroot. doesnt matter anyways as we wont use the cache
results (portage will rebuild cache), so running ldconfig is simply a waste
of time.
-diff -durN glibc-2.13.orig/Makefile glibc-2.13/Makefile
---- glibc-2.13.orig/Makefile 2009-04-23 20:23:03.000000000 +0200
-+++ glibc-2.13/Makefile 2009-11-13 00:49:49.000000000 +0100
+---
+ Makefile | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/Makefile
++++ b/Makefile
@@ -116,6 +116,7 @@
rm -f $(symbolic-link-list)
diff --git a/packages/glibc/2.13/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.13/0008-Fix-combreloc-test-BSD-grep.patch
index da21d9e..1fdd59f 100644
--- a/packages/glibc/2.13/140-Fix-combreloc-test-BSD-grep.patch
+++ b/packages/glibc/2.13/0008-Fix-combreloc-test-BSD-grep.patch
@@ -13,15 +13,13 @@ by configure as "not found". As a result, support for "-z combreloc"
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
+ configure | 2 +-
+ configure.in | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
-diff -urpN glibc-2.13.orig/configure glibc-2.13/configure
---- glibc-2.13.orig/configure 2011-01-17 20:34:07.000000000 -0800
-+++ glibc-2.13/configure 2017-03-08 21:11:09.000000000 -0800
-@@ -6504,7 +6504,7 @@ EOF
+--- a/configure
++++ b/configure
+@@ -6504,7 +6504,7 @@
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; }
then
@@ -30,10 +28,9 @@ diff -urpN glibc-2.13.orig/configure glibc-2.13/configure
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
-diff -urpN glibc-2.13.orig/configure.in glibc-2.13/configure.in
---- glibc-2.13.orig/configure.in 2011-01-17 20:34:07.000000000 -0800
-+++ glibc-2.13/configure.in 2017-03-08 21:11:22.000000000 -0800
-@@ -1673,7 +1673,7 @@ dnl cross-platform since the gcc used ca
+--- a/configure.in
++++ b/configure.in
+@@ -1673,7 +1673,7 @@
dnl introducing new options this is not easily doable. Instead use a tool
dnl which always is cross-platform: readelf. To detect whether -z combreloc
dnl look for a section named .rel.dyn.
diff --git a/packages/glibc/2.14.1/150-queue-header-updates.patch b/packages/glibc/2.13/0009-queue-header-updates.patch
index 7cbe70e..f6515e2 100644
--- a/packages/glibc/2.14.1/150-queue-header-updates.patch
+++ b/packages/glibc/2.13/0009-queue-header-updates.patch
@@ -2,11 +2,12 @@ grab some updates from FreeBSD
http://bugs.gentoo.org/201979
-diff -durN glibc-2.13.orig/misc/sys/queue.h glibc-2.13/misc/sys/queue.h
+---
+ misc/sys/queue.h | 36 ++++++++++++++++++++++++++++++++++++
+ 1 file changed, 36 insertions(+)
-diff -durN glibc-2.13.orig/misc/sys/queue.h glibc-2.13/misc/sys/queue.h
---- glibc-2.13.orig/misc/sys/queue.h 2008-03-05 06:50:30.000000000 +0100
-+++ glibc-2.13/misc/sys/queue.h 2009-11-13 00:49:51.000000000 +0100
+--- a/misc/sys/queue.h
++++ b/misc/sys/queue.h
@@ -136,6 +136,11 @@
(var); \
(var) = ((var)->field.le_next))
diff --git a/packages/glibc/2.14.1/160-manual-no-perl.patch b/packages/glibc/2.13/0010-manual-no-perl.patch
index 5e2b807..14ddc6d 100644
--- a/packages/glibc/2.14.1/160-manual-no-perl.patch
+++ b/packages/glibc/2.13/0010-manual-no-perl.patch
@@ -4,9 +4,12 @@ deal, so just whine a little and continue on our merry way.
http://bugs.gentoo.org/60132
-diff -durN glibc-2.13.orig/manual/Makefile glibc-2.13/manual/Makefile
---- glibc-2.13.orig/manual/Makefile 2006-01-08 07:43:47.000000000 +0100
-+++ glibc-2.13/manual/Makefile 2009-11-13 00:49:54.000000000 +0100
+---
+ manual/Makefile | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/manual/Makefile
++++ b/manual/Makefile
@@ -104,9 +104,14 @@
libm-err.texi: stamp-libm-err
stamp-libm-err: libm-err-tab.pl $(wildcard $(foreach dir,$(sysdirs),\
diff --git a/packages/glibc/2.13/170-localedef-fix-trampoline.patch b/packages/glibc/2.13/0011-localedef-fix-trampoline.patch
index 3cc6559..3b8fd6e 100644
--- a/packages/glibc/2.13/170-localedef-fix-trampoline.patch
+++ b/packages/glibc/2.13/0011-localedef-fix-trampoline.patch
@@ -5,9 +5,12 @@
# DP: Upstream status: Unknown
# DP: Status Details: Unknown
# DP: Date: 2004-03-16
-diff -durN glibc-2.13.orig/locale/programs/3level.h glibc-2.13/locale/programs/3level.h
---- glibc-2.13.orig/locale/programs/3level.h 2007-07-16 02:54:59.000000000 +0200
-+++ glibc-2.13/locale/programs/3level.h 2009-11-13 00:49:56.000000000 +0100
+---
+# locale/programs/3level.h | 36 ++++++++++++++++++++++++++++++++++++
+# 1 file changed, 36 insertions(+)
+#
+--- a/locale/programs/3level.h
++++ b/locale/programs/3level.h
@@ -203,6 +203,42 @@
}
}
diff --git a/packages/glibc/2.13/180-resolv-dynamic.patch b/packages/glibc/2.13/0012-resolv-dynamic.patch
index e916bce..fcc2f80 100644
--- a/packages/glibc/2.13/180-resolv-dynamic.patch
+++ b/packages/glibc/2.13/0012-resolv-dynamic.patch
@@ -5,9 +5,12 @@ already running get the updated information.
http://bugs.gentoo.org/177416
-diff -durN glibc-2.13.orig/resolv/res_libc.c glibc-2.13/resolv/res_libc.c
---- glibc-2.13.orig/resolv/res_libc.c 2009-02-07 05:27:42.000000000 +0100
-+++ glibc-2.13/resolv/res_libc.c 2009-11-13 00:49:59.000000000 +0100
+---
+ resolv/res_libc.c | 15 +++++++++++++++
+ 1 file changed, 15 insertions(+)
+
+--- a/resolv/res_libc.c
++++ b/resolv/res_libc.c
@@ -22,6 +22,7 @@
#include <arpa/nameser.h>
#include <resolv.h>
diff --git a/packages/glibc/2.13/190-localedef-mmap.patch b/packages/glibc/2.13/0013-localedef-mmap.patch
index f3914cd..74e586e 100644
--- a/packages/glibc/2.13/190-localedef-mmap.patch
+++ b/packages/glibc/2.13/0013-localedef-mmap.patch
@@ -7,9 +7,12 @@ http://bugs.gentoo.org/289615
used later with MMAP_FIXED | MMAP_SHARED to cope with different
alignment restrictions.
-diff -durN glibc-2.13.orig/locale/programs/locarchive.c glibc-2.13/locale/programs/locarchive.c
---- glibc-2.13.orig/locale/programs/locarchive.c 2009-04-27 16:07:47.000000000 +0200
-+++ glibc-2.13/locale/programs/locarchive.c 2009-11-13 00:50:01.000000000 +0100
+---
+ locale/programs/locarchive.c | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+--- a/locale/programs/locarchive.c
++++ b/locale/programs/locarchive.c
@@ -134,7 +134,7 @@
size_t reserved = RESERVE_MMAP_SIZE;
int xflags = 0;
diff --git a/packages/glibc/2.14.1/200-fadvise64_64.patch b/packages/glibc/2.13/0014-fadvise64_64.patch
index 71bca38..191d833 100644
--- a/packages/glibc/2.14.1/200-fadvise64_64.patch
+++ b/packages/glibc/2.13/0014-fadvise64_64.patch
@@ -3,9 +3,8 @@ ripped from Debian
sysdeps/unix/sysv/linux/posix_fadvise.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/posix_fadvise.c glibc-2.13/sysdeps/unix/sysv/linux/posix_fadvise.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/posix_fadvise.c 2003-08-17 02:36:22.000000000 +0200
-+++ glibc-2.13/sysdeps/unix/sysv/linux/posix_fadvise.c 2009-11-13 00:50:03.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/posix_fadvise.c
++++ b/sysdeps/unix/sysv/linux/posix_fadvise.c
@@ -35,6 +35,19 @@
return INTERNAL_SYSCALL_ERRNO (ret, err);
return 0;
diff --git a/packages/glibc/2.14.1/220-section-comments.patch b/packages/glibc/2.13/0015-section-comments.patch
index d717829..5960ed0 100644
--- a/packages/glibc/2.14.1/220-section-comments.patch
+++ b/packages/glibc/2.13/0015-section-comments.patch
@@ -3,9 +3,12 @@ http://sources.redhat.com/ml/binutils/2004-04/msg00665.html
fixes building on some architectures (like m68k/arm/cris/etc...) because
it does the right thing
-diff -durN glibc-2.13.orig/include/libc-symbols.h glibc-2.13/include/libc-symbols.h
---- glibc-2.13.orig/include/libc-symbols.h 2009-03-14 00:51:46.000000000 +0100
-+++ glibc-2.13/include/libc-symbols.h 2009-11-13 00:50:07.000000000 +0100
+---
+ include/libc-symbols.h | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+--- a/include/libc-symbols.h
++++ b/include/libc-symbols.h
@@ -239,12 +239,12 @@
# define __make_section_unallocated(section_string)
# endif
diff --git a/packages/glibc/2.14.1/230-no-inline-gmon.patch b/packages/glibc/2.13/0016-no-inline-gmon.patch
index fa33c2b..ed02704 100644
--- a/packages/glibc/2.14.1/230-no-inline-gmon.patch
+++ b/packages/glibc/2.13/0016-no-inline-gmon.patch
@@ -19,12 +19,12 @@ Kazu Hirata
* sysdeps/generic/initfini.c (call_gmon_start): Add
__attribute__ ((noinline)).
-Index: sysdeps/generic/initfini.c
-===================================================================
+---
+ sysdeps/generic/initfini.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
-diff -durN glibc-2.13.orig/sysdeps/generic/initfini.c glibc-2.13/sysdeps/generic/initfini.c
---- glibc-2.13.orig/sysdeps/generic/initfini.c 2007-06-17 20:02:40.000000000 +0200
-+++ glibc-2.13/sysdeps/generic/initfini.c 2009-11-13 00:50:09.000000000 +0100
+--- a/sysdeps/generic/initfini.c
++++ b/sysdeps/generic/initfini.c
@@ -70,7 +70,7 @@
/* The beginning of _init: */
asm ("\n/*@_init_PROLOG_BEGINS*/");
diff --git a/packages/glibc/2.12.1/240-check_native-headers.patch b/packages/glibc/2.13/0017-check_native-headers.patch
index de0cb5b..2b1b619 100644
--- a/packages/glibc/2.12.1/240-check_native-headers.patch
+++ b/packages/glibc/2.13/0017-check_native-headers.patch
@@ -4,9 +4,12 @@ many ports hit this warning:
snipped from suse
-diff -durN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/check_native.c glibc-2.12.1/sysdeps/unix/sysv/linux/check_native.c
---- glibc-2.12.1.orig/sysdeps/unix/sysv/linux/check_native.c 2007-11-24 04:12:17.000000000 +0100
-+++ glibc-2.12.1/sysdeps/unix/sysv/linux/check_native.c 2009-11-13 00:50:11.000000000 +0100
+---
+ sysdeps/unix/sysv/linux/check_native.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/sysdeps/unix/sysv/linux/check_native.c
++++ b/sysdeps/unix/sysv/linux/check_native.c
@@ -23,6 +23,7 @@
#include <stddef.h>
#include <stdint.h>
diff --git a/packages/glibc/2.12.1/250-fix-pr631.patch b/packages/glibc/2.13/0018-fix-pr631.patch
index af5b347..636c45d 100644
--- a/packages/glibc/2.12.1/250-fix-pr631.patch
+++ b/packages/glibc/2.13/0018-fix-pr631.patch
@@ -14,9 +14,13 @@ when building glibc with --enable-static-nss.
See http://sources.redhat.com/bugzilla/show_bug.cgi?id=631
-diff -durN glibc-2.12.1.orig/Makeconfig glibc-2.12.1/Makeconfig
---- glibc-2.12.1.orig/Makeconfig 2009-11-13 00:49:41.000000000 +0100
-+++ glibc-2.12.1/Makeconfig 2009-11-13 00:50:13.000000000 +0100
+---
+ Makeconfig | 2 +-
+ elf/Makefile | 7 +++++++
+ 2 files changed, 8 insertions(+), 1 deletion(-)
+
+--- a/Makeconfig
++++ b/Makeconfig
@@ -531,7 +531,7 @@
# The static libraries.
@@ -26,9 +30,8 @@ diff -durN glibc-2.12.1.orig/Makeconfig glibc-2.12.1/Makeconfig
else
ifeq (yes,$(build-shared))
# We can try to link the programs with lib*_pic.a...
-diff -durN glibc-2.12.1.orig/elf/Makefile glibc-2.12.1/elf/Makefile
---- glibc-2.12.1.orig/elf/Makefile 2009-01-31 01:20:55.000000000 +0100
-+++ glibc-2.12.1/elf/Makefile 2009-11-13 00:50:13.000000000 +0100
+--- a/elf/Makefile
++++ b/elf/Makefile
@@ -146,6 +146,13 @@
install-bin-script = ldd
endif
diff --git a/packages/glibc/2.15/260-assume-pipe2.patch b/packages/glibc/2.13/0019-assume-pipe2.patch
index 42e8f4e..0074ea6 100644
--- a/packages/glibc/2.15/260-assume-pipe2.patch
+++ b/packages/glibc/2.13/0019-assume-pipe2.patch
@@ -20,9 +20,12 @@ __have_sock_cloexec and __have_pipe2 to true. but if glibc was built against
older kernel headers where __NR_pipe2 does not exist, glibc will have a ENOSYS
stub for it. so popen() will always fail as glibc assumes pipe2() works.
-diff -durN glibc-2.13.orig/socket/have_sock_cloexec.c glibc-2.13/socket/have_sock_cloexec.c
---- glibc-2.13.orig/socket/have_sock_cloexec.c 2008-07-25 18:46:23.000000000 +0200
-+++ glibc-2.13/socket/have_sock_cloexec.c 2009-11-13 00:50:15.000000000 +0100
+---
+ socket/have_sock_cloexec.c | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/socket/have_sock_cloexec.c
++++ b/socket/have_sock_cloexec.c
@@ -16,9 +16,14 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
diff --git a/packages/glibc/2.13/270-china.patch b/packages/glibc/2.13/0020-china.patch
index 41d7759..b323cf6 100644
--- a/packages/glibc/2.13/270-china.patch
+++ b/packages/glibc/2.13/0020-china.patch
@@ -1,8 +1,11 @@
-diff -durN glibc-2.13.orig/localedata/locales/zh_TW glibc-2.13/localedata/locales/zh_TW
---- glibc-2.13.orig/localedata/locales/zh_TW 2004-11-01 00:42:28.000000000 +0100
-+++ glibc-2.13/localedata/locales/zh_TW 2009-11-13 00:50:17.000000000 +0100
+---
+ localedata/locales/zh_TW | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+--- a/localedata/locales/zh_TW
++++ b/localedata/locales/zh_TW
@@ -1,7 +1,7 @@
comment_char %
escape_char /
diff --git a/packages/glibc/2.13/280-new-valencian-locale.patch b/packages/glibc/2.13/0021-new-valencian-locale.patch
index 4cdd108..bddc4c7 100644
--- a/packages/glibc/2.13/280-new-valencian-locale.patch
+++ b/packages/glibc/2.13/0021-new-valencian-locale.patch
@@ -1,9 +1,13 @@
http://bugs.gentoo.org/show_bug.cgi?id=131815
http://sourceware.org/bugzilla/show_bug.cgi?id=2522
-diff -durN glibc-2.13.orig/localedata/SUPPORTED glibc-2.13/localedata/SUPPORTED
---- glibc-2.13.orig/localedata/SUPPORTED 2009-04-18 10:43:52.000000000 +0200
-+++ glibc-2.13/localedata/SUPPORTED 2009-11-13 00:50:20.000000000 +0100
+---
+ localedata/SUPPORTED | 2
+ localedata/locales/ca_ES@valencia | 96 ++++++++++++++++++++++++++++++++++++++
+ 2 files changed, 98 insertions(+)
+
+--- a/localedata/SUPPORTED
++++ b/localedata/SUPPORTED
@@ -72,6 +72,8 @@
ca_ES.UTF-8/UTF-8 \
ca_ES/ISO-8859-1 \
@@ -13,9 +17,8 @@ diff -durN glibc-2.13.orig/localedata/SUPPORTED glibc-2.13/localedata/SUPPORTED
ca_FR.UTF-8/UTF-8 \
ca_FR/ISO-8859-15 \
ca_IT.UTF-8/UTF-8 \
-diff -durN glibc-2.13.orig/localedata/locales/ca_ES@valencia glibc-2.13/localedata/locales/ca_ES@valencia
---- glibc-2.13.orig/localedata/locales/ca_ES@valencia 1970-01-01 01:00:00.000000000 +0100
-+++ glibc-2.13/localedata/locales/ca_ES@valencia 2009-11-13 00:50:20.000000000 +0100
+--- /dev/null
++++ b/localedata/locales/ca_ES@valencia
@@ -0,0 +1,96 @@
+comment_char %
+escape_char /
diff --git a/packages/glibc/2.12.2/300-macos-cross-rpcgen.patch b/packages/glibc/2.13/0022-macos-cross-rpcgen.patch
index e654644..b439b0f 100644
--- a/packages/glibc/2.12.2/300-macos-cross-rpcgen.patch
+++ b/packages/glibc/2.13/0022-macos-cross-rpcgen.patch
@@ -14,11 +14,13 @@ Date: Sat Sep 7 00:01:08 2013 +0800
Signed-off-by: Jia Liu <proljc@gmail.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
-diff --git a/sunrpc/rpc/types.h b/sunrpc/rpc/types.h
-index 3dca5c4..beded52 100644
+---
+ sunrpc/rpc/types.h | 5 +++++
+ 1 file changed, 5 insertions(+)
+
--- a/sunrpc/rpc/types.h
+++ b/sunrpc/rpc/types.h
-@@ -69,6 +69,11 @@ typedef unsigned long rpcport_t;
+@@ -69,6 +69,11 @@
#include <sys/types.h>
#endif
diff --git a/packages/glibc/2.14.1/300-nscd-one-fork.patch b/packages/glibc/2.13/0023-nscd-one-fork.patch
index adc9b3f..47217b3 100644
--- a/packages/glibc/2.14.1/300-nscd-one-fork.patch
+++ b/packages/glibc/2.13/0023-nscd-one-fork.patch
@@ -2,9 +2,12 @@ only fork one to assist in stop-start-daemon assumptions about daemon behavior
http://bugs.gentoo.org/190785
-diff -durN glibc-2.13.orig/nscd/nscd.c glibc-2.13/nscd/nscd.c
---- glibc-2.13.orig/nscd/nscd.c 2009-02-06 21:10:27.000000000 +0100
-+++ glibc-2.13/nscd/nscd.c 2009-11-13 00:50:24.000000000 +0100
+---
+ nscd/nscd.c | 12 +++---------
+ 1 file changed, 3 insertions(+), 9 deletions(-)
+
+--- a/nscd/nscd.c
++++ b/nscd/nscd.c
@@ -182,6 +182,9 @@
if (pid != 0)
exit (0);
diff --git a/packages/glibc/2.15/310-hppa-nptl-carlos.patch b/packages/glibc/2.13/0024-hppa-nptl-carlos.patch
index 4c028b2..43c4b68 100644
--- a/packages/glibc/2.15/310-hppa-nptl-carlos.patch
+++ b/packages/glibc/2.13/0024-hppa-nptl-carlos.patch
@@ -1,8 +1,17 @@
-diff -durN glibc-2.13.orig/elf/rtld.c glibc-2.13/elf/rtld.c
---- glibc-2.13.orig/elf/rtld.c 2009-04-17 02:00:08.000000000 +0200
-+++ glibc-2.13/elf/rtld.c 2009-11-13 00:50:26.000000000 +0100
+---
+ elf/rtld.c | 10 +++++-----
+ include/atomic.h | 26 +++++++++++++-------------
+ nptl/Makefile | 35 ++++++++++++++++++++++++++++++++---
+ nptl/pthread_barrier_wait.c | 2 +-
+ nptl/sysdeps/pthread/Makefile | 2 ++
+ stdio-common/Makefile | 2 +-
+ sunrpc/clnt_udp.c | 2 +-
+ 7 files changed, 55 insertions(+), 24 deletions(-)
+
+--- a/elf/rtld.c
++++ b/elf/rtld.c
@@ -392,14 +392,14 @@
know it is available. We do not have to clear the memory if we
do not have to use the temporary bootstrap_map. Global variables
@@ -23,9 +32,8 @@ diff -durN glibc-2.13.orig/elf/rtld.c glibc-2.13/elf/rtld.c
# endif
# if USE___THREAD
bootstrap_map.l_tls_modid = 0;
-diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
---- glibc-2.13.orig/include/atomic.h 2009-02-09 00:49:53.000000000 +0100
-+++ glibc-2.13/include/atomic.h 2009-11-13 00:50:26.000000000 +0100
+--- a/include/atomic.h
++++ b/include/atomic.h
@@ -185,7 +185,7 @@
__typeof (*(mem)) __atg5_value = (newvalue); \
\
@@ -143,9 +151,8 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
while (__builtin_expect \
(atomic_compare_and_exchange_bool_acq (__atg19_memp, \
__atg19_old | __atg19_mask,\
-diff -durN glibc-2.13.orig/nptl/Makefile glibc-2.13/nptl/Makefile
---- glibc-2.13.orig/nptl/Makefile 2008-11-12 14:38:23.000000000 +0100
-+++ glibc-2.13/nptl/Makefile 2009-11-13 00:50:26.000000000 +0100
+--- a/nptl/Makefile
++++ b/nptl/Makefile
@@ -265,9 +265,9 @@
# Files which must not be linked with libpthread.
tests-nolibpthread = tst-unload
@@ -195,9 +202,8 @@ diff -durN glibc-2.13.orig/nptl/Makefile glibc-2.13/nptl/Makefile
CFLAGS-tst-align.c += $(stack-align-test-flags)
CFLAGS-tst-align3.c += $(stack-align-test-flags)
CFLAGS-tst-initializers1.c = -W -Wall -Werror
-diff -durN glibc-2.13.orig/nptl/pthread_barrier_wait.c glibc-2.13/nptl/pthread_barrier_wait.c
---- glibc-2.13.orig/nptl/pthread_barrier_wait.c 2007-08-01 06:18:50.000000000 +0200
-+++ glibc-2.13/nptl/pthread_barrier_wait.c 2009-11-13 00:50:26.000000000 +0100
+--- a/nptl/pthread_barrier_wait.c
++++ b/nptl/pthread_barrier_wait.c
@@ -64,7 +64,7 @@
do
lll_futex_wait (&ibarrier->curr_event, event,
@@ -207,9 +213,8 @@ diff -durN glibc-2.13.orig/nptl/pthread_barrier_wait.c glibc-2.13/nptl/pthread_b
}
/* Make sure the init_count is stored locally or in a register. */
-diff -durN glibc-2.13.orig/nptl/sysdeps/pthread/Makefile glibc-2.13/nptl/sysdeps/pthread/Makefile
---- glibc-2.13.orig/nptl/sysdeps/pthread/Makefile 2006-02-28 08:09:41.000000000 +0100
-+++ glibc-2.13/nptl/sysdeps/pthread/Makefile 2009-11-13 00:50:26.000000000 +0100
+--- a/nptl/sysdeps/pthread/Makefile
++++ b/nptl/sysdeps/pthread/Makefile
@@ -33,7 +33,9 @@
ifeq ($(have-forced-unwind),yes)
@@ -220,9 +225,8 @@ diff -durN glibc-2.13.orig/nptl/sysdeps/pthread/Makefile glibc-2.13/nptl/sysdeps
endif
endif
-diff -durN glibc-2.13.orig/stdio-common/Makefile glibc-2.13/stdio-common/Makefile
---- glibc-2.13.orig/stdio-common/Makefile 2009-04-11 07:29:56.000000000 +0200
-+++ glibc-2.13/stdio-common/Makefile 2009-11-13 00:50:26.000000000 +0100
+--- a/stdio-common/Makefile
++++ b/stdio-common/Makefile
@@ -82,7 +82,7 @@
$(SHELL) -e tst-printf.sh $(common-objpfx) '$(run-program-prefix)'
endif
@@ -232,9 +236,8 @@ diff -durN glibc-2.13.orig/stdio-common/Makefile glibc-2.13/stdio-common/Makefil
CFLAGS-vfwprintf.c = -Wno-uninitialized
CFLAGS-tst-printf.c = -Wno-format
CFLAGS-tstdiomisc.c = -Wno-format
-diff -durN glibc-2.13.orig/sunrpc/clnt_udp.c glibc-2.13/sunrpc/clnt_udp.c
---- glibc-2.13.orig/sunrpc/clnt_udp.c 2008-07-26 10:42:44.000000000 +0200
-+++ glibc-2.13/sunrpc/clnt_udp.c 2009-11-13 00:50:26.000000000 +0100
+--- a/sunrpc/clnt_udp.c
++++ b/sunrpc/clnt_udp.c
@@ -456,7 +456,7 @@
while (inlen < 0 && errno == EINTR);
if (inlen < 0)
diff --git a/packages/glibc/2.13/340-dl_execstack-PaX-support.patch b/packages/glibc/2.13/0025-dl_execstack-PaX-support.patch
index 2402af0..bfd7557 100644
--- a/packages/glibc/2.13/340-dl_execstack-PaX-support.patch
+++ b/packages/glibc/2.13/0025-dl_execstack-PaX-support.patch
@@ -8,9 +8,13 @@
Patch also NPTL. Bug #116086. <kevquinn@gentoo.org> (20 Dec 2005).
-diff -durN glibc-2.13.orig/nptl/allocatestack.c glibc-2.13/nptl/allocatestack.c
---- glibc-2.13.orig/nptl/allocatestack.c 2009-01-29 21:34:16.000000000 +0100
-+++ glibc-2.13/nptl/allocatestack.c 2009-11-13 00:50:33.000000000 +0100
+---
+ nptl/allocatestack.c | 3 ++-
+ sysdeps/unix/sysv/linux/dl-execstack.c | 19 ++++++++++++++++---
+ 2 files changed, 18 insertions(+), 4 deletions(-)
+
+--- a/nptl/allocatestack.c
++++ b/nptl/allocatestack.c
@@ -329,7 +329,8 @@
# error "Define either _STACK_GROWS_DOWN or _STACK_GROWS_UP"
#endif
@@ -21,9 +25,8 @@ diff -durN glibc-2.13.orig/nptl/allocatestack.c glibc-2.13/nptl/allocatestack.c
return 0;
}
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/dl-execstack.c glibc-2.13/sysdeps/unix/sysv/linux/dl-execstack.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/dl-execstack.c 2006-01-08 09:21:15.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/dl-execstack.c 2009-11-13 00:50:33.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/dl-execstack.c
++++ b/sysdeps/unix/sysv/linux/dl-execstack.c
@@ -63,7 +63,10 @@
else
# endif
diff --git a/packages/glibc/2.15/350-pre20040117-pt_pax.patch b/packages/glibc/2.13/0026-pre20040117-pt_pax.patch
index f8f6b83..ec17d24 100644
--- a/packages/glibc/2.15/350-pre20040117-pt_pax.patch
+++ b/packages/glibc/2.13/0026-pre20040117-pt_pax.patch
@@ -1,8 +1,11 @@
-diff -durN glibc-2.13.orig/elf/elf.h glibc-2.13/elf/elf.h
---- glibc-2.13.orig/elf/elf.h 2009-04-15 02:15:54.000000000 +0200
-+++ glibc-2.13/elf/elf.h 2009-11-13 00:50:35.000000000 +0100
+---
+ elf/elf.h | 13 +++++++++++++
+ 1 file changed, 13 insertions(+)
+
+--- a/elf/elf.h
++++ b/elf/elf.h
@@ -580,6 +580,7 @@
#define PT_GNU_EH_FRAME 0x6474e550 /* GCC .eh_frame_hdr segment */
#define PT_GNU_STACK 0x6474e551 /* Indicates stack executability */
diff --git a/packages/glibc/2.16.0/360-tests-sandbox-libdl-paths.patch b/packages/glibc/2.13/0027-tests-sandbox-libdl-paths.patch
index 9f78c52..1c4ee59 100644
--- a/packages/glibc/2.16.0/360-tests-sandbox-libdl-paths.patch
+++ b/packages/glibc/2.13/0027-tests-sandbox-libdl-paths.patch
@@ -15,9 +15,23 @@ Fix by Wormo
http://bugs.gentoo.org/56898
-diff -durN glibc-2.13.orig/grp/tst_fgetgrent.sh glibc-2.13/grp/tst_fgetgrent.sh
---- glibc-2.13.orig/grp/tst_fgetgrent.sh 2001-07-06 06:54:46.000000000 +0200
-+++ glibc-2.13/grp/tst_fgetgrent.sh 2009-11-13 00:50:37.000000000 +0100
+---
+ grp/tst_fgetgrent.sh | 3 ++-
+ iconvdata/run-iconv-test.sh | 2 +-
+ iconvdata/tst-table.sh | 5 ++++-
+ intl/tst-codeset.sh | 3 +++
+ intl/tst-gettext.sh | 5 ++++-
+ intl/tst-gettext2.sh | 5 ++++-
+ intl/tst-translit.sh | 5 ++++-
+ malloc/tst-mtrace.sh | 5 ++++-
+ nptl/tst-tls6.sh | 4 ++--
+ posix/globtest.sh | 2 +-
+ posix/tst-getconf.sh | 5 ++++-
+ posix/wordexp-tst.sh | 5 ++++-
+ 12 files changed, 37 insertions(+), 12 deletions(-)
+
+--- a/grp/tst_fgetgrent.sh
++++ b/grp/tst_fgetgrent.sh
@@ -24,7 +24,8 @@
rtld_installed_name=$1; shift
@@ -28,9 +42,8 @@ diff -durN glibc-2.13.orig/grp/tst_fgetgrent.sh glibc-2.13/grp/tst_fgetgrent.sh
result=0
-diff -durN glibc-2.13.orig/iconvdata/run-iconv-test.sh glibc-2.13/iconvdata/run-iconv-test.sh
---- glibc-2.13.orig/iconvdata/run-iconv-test.sh 2008-05-15 03:59:44.000000000 +0200
-+++ glibc-2.13/iconvdata/run-iconv-test.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/iconvdata/run-iconv-test.sh
++++ b/iconvdata/run-iconv-test.sh
@@ -34,7 +34,7 @@
export GCONV_PATH
@@ -40,9 +53,8 @@ diff -durN glibc-2.13.orig/iconvdata/run-iconv-test.sh glibc-2.13/iconvdata/run-
# How the start the iconv(1) program.
ICONV='$codir/elf/ld.so --library-path $LIBPATH --inhibit-rpath ${from}.so \
-diff -durN glibc-2.13.orig/iconvdata/tst-table.sh glibc-2.13/iconvdata/tst-table.sh
---- glibc-2.13.orig/iconvdata/tst-table.sh 2002-04-24 23:39:35.000000000 +0200
-+++ glibc-2.13/iconvdata/tst-table.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/iconvdata/tst-table.sh
++++ b/iconvdata/tst-table.sh
@@ -59,8 +59,11 @@
irreversible=${charset}.irreversible
fi
@@ -56,9 +68,8 @@ diff -durN glibc-2.13.orig/iconvdata/tst-table.sh glibc-2.13/iconvdata/tst-table
${objpfx}tst-table-from ${charset} \
> ${objpfx}tst-${charset}.table
-diff -durN glibc-2.13.orig/intl/tst-codeset.sh glibc-2.13/intl/tst-codeset.sh
---- glibc-2.13.orig/intl/tst-codeset.sh 2005-04-06 04:18:35.000000000 +0200
-+++ glibc-2.13/intl/tst-codeset.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-codeset.sh
++++ b/intl/tst-codeset.sh
@@ -37,6 +37,9 @@
LOCPATH=${common_objpfx}localedata
export LOCPATH
@@ -69,9 +80,8 @@ diff -durN glibc-2.13.orig/intl/tst-codeset.sh glibc-2.13/intl/tst-codeset.sh
${common_objpfx}elf/ld.so --library-path $common_objpfx \
${objpfx}tst-codeset > ${objpfx}tst-codeset.out
-diff -durN glibc-2.13.orig/intl/tst-gettext.sh glibc-2.13/intl/tst-gettext.sh
---- glibc-2.13.orig/intl/tst-gettext.sh 2004-08-15 21:28:18.000000000 +0200
-+++ glibc-2.13/intl/tst-gettext.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-gettext.sh
++++ b/intl/tst-gettext.sh
@@ -51,9 +51,12 @@
LOCPATH=${common_objpfx}localedata
export LOCPATH
@@ -86,9 +96,8 @@ diff -durN glibc-2.13.orig/intl/tst-gettext.sh glibc-2.13/intl/tst-gettext.sh
${objpfx}tst-gettext > ${objpfx}tst-gettext.out ${objpfx}domaindir
exit $?
-diff -durN glibc-2.13.orig/intl/tst-gettext2.sh glibc-2.13/intl/tst-gettext2.sh
---- glibc-2.13.orig/intl/tst-gettext2.sh 2005-05-04 19:54:48.000000000 +0200
-+++ glibc-2.13/intl/tst-gettext2.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-gettext2.sh
++++ b/intl/tst-gettext2.sh
@@ -65,8 +65,11 @@
LOCPATH=${objpfx}domaindir
export LOCPATH
@@ -102,9 +111,8 @@ diff -durN glibc-2.13.orig/intl/tst-gettext2.sh glibc-2.13/intl/tst-gettext2.sh
${objpfx}tst-gettext2 > ${objpfx}tst-gettext2.out ${objpfx}domaindir &&
cmp ${objpfx}tst-gettext2.out - <<EOF
String1 - Lang1: 1st string
-diff -durN glibc-2.13.orig/intl/tst-translit.sh glibc-2.13/intl/tst-translit.sh
---- glibc-2.13.orig/intl/tst-translit.sh 2005-05-04 19:56:10.000000000 +0200
-+++ glibc-2.13/intl/tst-translit.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-translit.sh
++++ b/intl/tst-translit.sh
@@ -36,7 +36,10 @@
LOCPATH=${common_objpfx}localedata
export LOCPATH
@@ -117,9 +125,8 @@ diff -durN glibc-2.13.orig/intl/tst-translit.sh glibc-2.13/intl/tst-translit.sh
${objpfx}tst-translit > ${objpfx}tst-translit.out ${objpfx}domaindir
exit $?
-diff -durN glibc-2.13.orig/malloc/tst-mtrace.sh glibc-2.13/malloc/tst-mtrace.sh
---- glibc-2.13.orig/malloc/tst-mtrace.sh 2005-10-15 01:40:35.000000000 +0200
-+++ glibc-2.13/malloc/tst-mtrace.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/malloc/tst-mtrace.sh
++++ b/malloc/tst-mtrace.sh
@@ -24,9 +24,12 @@
status=0
trap "rm -f ${common_objpfx}malloc/tst-mtrace.leak; exit 1" 1 2 15
@@ -134,9 +141,8 @@ diff -durN glibc-2.13.orig/malloc/tst-mtrace.sh glibc-2.13/malloc/tst-mtrace.sh
${common_objpfx}malloc/tst-mtrace || status=1
if test $status -eq 0 && test -f ${common_objpfx}malloc/mtrace; then
-diff -durN glibc-2.13.orig/nptl/tst-tls6.sh glibc-2.13/nptl/tst-tls6.sh
---- glibc-2.13.orig/nptl/tst-tls6.sh 2003-09-03 00:02:59.000000000 +0200
-+++ glibc-2.13/nptl/tst-tls6.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/nptl/tst-tls6.sh
++++ b/nptl/tst-tls6.sh
@@ -5,8 +5,8 @@
rtld_installed_name=$1; shift
logfile=$common_objpfx/nptl/tst-tls6.out
@@ -148,9 +154,8 @@ diff -durN glibc-2.13.orig/nptl/tst-tls6.sh glibc-2.13/nptl/tst-tls6.sh
tst_tls5="${elf_objpfx}${rtld_installed_name} --library-path ${library_path} \
${common_objpfx}/nptl/tst-tls5"
-diff -durN glibc-2.13.orig/posix/globtest.sh glibc-2.13/posix/globtest.sh
---- glibc-2.13.orig/posix/globtest.sh 2008-12-06 07:05:39.000000000 +0100
-+++ glibc-2.13/posix/globtest.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/posix/globtest.sh
++++ b/posix/globtest.sh
@@ -18,7 +18,7 @@
esac
@@ -160,9 +165,8 @@ diff -durN glibc-2.13.orig/posix/globtest.sh glibc-2.13/posix/globtest.sh
# Since we use `sort' we must make sure to use the same locale everywhere.
LC_ALL=C
-diff -durN glibc-2.13.orig/posix/tst-getconf.sh glibc-2.13/posix/tst-getconf.sh
---- glibc-2.13.orig/posix/tst-getconf.sh 2002-09-01 13:11:25.000000000 +0200
-+++ glibc-2.13/posix/tst-getconf.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/posix/tst-getconf.sh
++++ b/posix/tst-getconf.sh
@@ -10,7 +10,10 @@
else
rtld_installed_name=$1; shift
@@ -175,9 +179,8 @@ diff -durN glibc-2.13.orig/posix/tst-getconf.sh glibc-2.13/posix/tst-getconf.sh
}
fi
-diff -durN glibc-2.13.orig/posix/wordexp-tst.sh glibc-2.13/posix/wordexp-tst.sh
---- glibc-2.13.orig/posix/wordexp-tst.sh 2000-10-20 18:23:30.000000000 +0200
-+++ glibc-2.13/posix/wordexp-tst.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/posix/wordexp-tst.sh
++++ b/posix/wordexp-tst.sh
@@ -19,8 +19,11 @@
"
export IFS
diff --git a/packages/glibc/2.14.1/380-dont-build-timezone.patch b/packages/glibc/2.13/0028-dont-build-timezone.patch
index 11c358e..b0fb8fc 100644
--- a/packages/glibc/2.14.1/380-dont-build-timezone.patch
+++ b/packages/glibc/2.13/0028-dont-build-timezone.patch
@@ -1,8 +1,11 @@
timezone data has been split into the package sys-libs/timezone-data
-diff -durN glibc-2.13.orig/Makeconfig glibc-2.13/Makeconfig
---- glibc-2.13.orig/Makeconfig 2009-11-13 00:50:13.000000000 +0100
-+++ glibc-2.13/Makeconfig 2009-11-13 00:50:41.000000000 +0100
+---
+ Makeconfig | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/Makeconfig
++++ b/Makeconfig
@@ -944,7 +944,7 @@
stdlib stdio-common libio malloc string wcsmbs time dirent \
grp pwd posix io termios resource misc socket sysvipc gmon \
diff --git a/packages/glibc/2.14.1/400-alpha-xstat.patch b/packages/glibc/2.13/0029-alpha-xstat.patch
index 6e4ab8f..4fa9517 100644
--- a/packages/glibc/2.14.1/400-alpha-xstat.patch
+++ b/packages/glibc/2.13/0029-alpha-xstat.patch
@@ -1,6 +1,9 @@
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h 2009-05-09 08:54:20.000000000 +0200
-+++ glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:50:45.000000000 +0100
+---
+ sysdeps/unix/sysv/linux/kernel-features.h | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
@@ -386,6 +386,11 @@
# define __ASSUME_GETDENTS32_D_TYPE 1
#endif
diff --git a/packages/glibc/2.13/0030-alpha-creat.patch b/packages/glibc/2.13/0030-alpha-creat.patch
new file mode 100644
index 0000000..6ef5278
--- /dev/null
+++ b/packages/glibc/2.13/0030-alpha-creat.patch
@@ -0,0 +1,17 @@
+alpha does not have a __NR_creat
+
+http://bugs.gentoo.org/227275
+http://sourceware.org/bugzilla/show_bug.cgi?id=6650
+
+---
+ sysdeps/unix/sysv/linux/wordsize-64/creat64.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+--- a/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
++++ b/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
+@@ -1 +1,5 @@
+ /* Defined as alias for the syscall. */
++#include <sysdep.h>
++#ifndef __NR_creat
++#include "../../../../../io/creat64.c"
++#endif
diff --git a/packages/glibc/2.14.1/490-alpha_alpha-add-fdatasync-support.patch b/packages/glibc/2.13/0031-alpha_alpha-add-fdatasync-support.patch
index 372f34c..b248cc6 100644
--- a/packages/glibc/2.14.1/490-alpha_alpha-add-fdatasync-support.patch
+++ b/packages/glibc/2.13/0031-alpha_alpha-add-fdatasync-support.patch
@@ -13,9 +13,8 @@
sysdeps/unix/sysv/linux/syscalls.list | 1
4 files changed, 76 insertions(+), 1 deletion(-)
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/Makefile glibc-2.13/sysdeps/unix/sysv/linux/Makefile
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/Makefile 2009-03-02 17:15:13.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/Makefile 2009-11-13 00:51:04.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/Makefile
++++ b/sysdeps/unix/sysv/linux/Makefile
@@ -20,6 +20,7 @@
setfsuid setfsgid makedev epoll_pwait signalfd \
eventfd eventfd_read eventfd_write prlimit
@@ -24,9 +23,8 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/Makefile glibc-2.13/sysdeps/u
CFLAGS-gethostid.c = -fexceptions
sysdep_headers += sys/mount.h sys/acct.h sys/sysctl.h \
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/fdatasync.c glibc-2.13/sysdeps/unix/sysv/linux/fdatasync.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/fdatasync.c 1970-01-01 01:00:00.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/fdatasync.c 2009-11-13 00:51:04.000000000 +0100
+--- /dev/null
++++ b/sysdeps/unix/sysv/linux/fdatasync.c
@@ -0,0 +1,69 @@
+/* fdatasync -- synchronize at least the data part of a file with
+ the underlying media. Linux version.
@@ -97,9 +95,8 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/fdatasync.c glibc-2.13/sysdep
+
+weak_alias (__fdatasync, fdatasync)
+
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:50:45.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:51:04.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
@@ -459,6 +459,12 @@
# define __ASSUME_FUTEX_LOCK_PI 1
#endif
@@ -113,9 +110,8 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.13/
/* Support for utimensat syscall was added in 2.6.22, on SH
only after 2.6.22-rc1. */
#if __LINUX_KERNEL_VERSION >= 0x020616 \
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/syscalls.list glibc-2.13/sysdeps/unix/sysv/linux/syscalls.list
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/syscalls.list 2008-08-02 01:29:08.000000000 +0200
-+++ glibc-2.13/sysdeps/unix/sysv/linux/syscalls.list 2009-11-13 00:51:04.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/syscalls.list
++++ b/sysdeps/unix/sysv/linux/syscalls.list
@@ -11,7 +11,6 @@
epoll_create1 EXTRA epoll_create1 i:i epoll_create1
epoll_ctl EXTRA epoll_ctl i:iiip epoll_ctl
diff --git a/packages/glibc/2.15/560-ppc-atomic.patch b/packages/glibc/2.13/0032-ppc-atomic.patch
index ee1cb90..a38c1c5 100644
--- a/packages/glibc/2.15/560-ppc-atomic.patch
+++ b/packages/glibc/2.13/0032-ppc-atomic.patch
@@ -1,14 +1,13 @@
sniped from suse
-Index: sysdeps/powerpc/bits/atomic.h
-===================================================================
-RCS file: /cvs/glibc/libc/sysdeps/powerpc/bits/atomic.h,v
-retrieving revision 1.17
-diff -u -a -p -r1.17 atomic.h
+---
+ sysdeps/powerpc/bits/atomic.h | 66 ++++++++++-----------
+ sysdeps/powerpc/powerpc32/bits/atomic.h | 16 ++---
+ sysdeps/powerpc/powerpc64/bits/atomic.h | 98 ++++++++++++++++----------------
+ 3 files changed, 90 insertions(+), 90 deletions(-)
-diff -durN glibc-2.13.orig/sysdeps/powerpc/bits/atomic.h glibc-2.13/sysdeps/powerpc/bits/atomic.h
---- glibc-2.13.orig/sysdeps/powerpc/bits/atomic.h 2007-03-26 22:15:28.000000000 +0200
-+++ glibc-2.13/sysdeps/powerpc/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
+--- a/sysdeps/powerpc/bits/atomic.h
++++ b/sysdeps/powerpc/bits/atomic.h
@@ -85,14 +85,14 @@
__typeof (*(mem)) __tmp; \
__typeof (mem) __memp = (mem); \
@@ -151,9 +150,8 @@ diff -durN glibc-2.13.orig/sysdeps/powerpc/bits/atomic.h glibc-2.13/sysdeps/powe
: "cr0", "memory"); \
__val; \
})
-diff -durN glibc-2.13.orig/sysdeps/powerpc/powerpc32/bits/atomic.h glibc-2.13/sysdeps/powerpc/powerpc32/bits/atomic.h
---- glibc-2.13.orig/sysdeps/powerpc/powerpc32/bits/atomic.h 2007-03-26 22:15:45.000000000 +0200
-+++ glibc-2.13/sysdeps/powerpc/powerpc32/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
+--- a/sysdeps/powerpc/powerpc32/bits/atomic.h
++++ b/sysdeps/powerpc/powerpc32/bits/atomic.h
@@ -44,14 +44,14 @@
({ \
unsigned int __tmp; \
@@ -192,9 +190,8 @@ diff -durN glibc-2.13.orig/sysdeps/powerpc/powerpc32/bits/atomic.h glibc-2.13/sy
: "cr0", "memory"); \
__tmp != 0; \
})
-diff -durN glibc-2.13.orig/sysdeps/powerpc/powerpc64/bits/atomic.h glibc-2.13/sysdeps/powerpc/powerpc64/bits/atomic.h
---- glibc-2.13.orig/sysdeps/powerpc/powerpc64/bits/atomic.h 2007-03-26 22:16:03.000000000 +0200
-+++ glibc-2.13/sysdeps/powerpc/powerpc64/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
+--- a/sysdeps/powerpc/powerpc64/bits/atomic.h
++++ b/sysdeps/powerpc/powerpc64/bits/atomic.h
@@ -44,14 +44,14 @@
({ \
unsigned int __tmp, __tmp2; \
diff --git a/packages/glibc/2.13/630-mips_shn_undef-hack.patch b/packages/glibc/2.13/0033-mips_shn_undef-hack.patch
index 791d76c..2f9d656 100644
--- a/packages/glibc/2.13/630-mips_shn_undef-hack.patch
+++ b/packages/glibc/2.13/0033-mips_shn_undef-hack.patch
@@ -1,10 +1,13 @@
-diff -durN glibc-2.13.orig/elf/dl-lookup.c glibc-2.13/elf/dl-lookup.c
---- glibc-2.13.orig/elf/dl-lookup.c 2009-03-30 23:14:32.000000000 +0200
-+++ glibc-2.13/elf/dl-lookup.c 2009-11-13 00:51:36.000000000 +0100
+---
+ elf/dl-lookup.c | 6 ++++++
+ 1 file changed, 6 insertions(+)
+
+--- a/elf/dl-lookup.c
++++ b/elf/dl-lookup.c
@@ -301,6 +301,12 @@
/* FALLTHROUGH */
case STB_GLOBAL:
- success:
+ success:
+#ifdef __mips__
+ /* HACK: MIPS marks its lazy evaluation stubs with SHN_UNDEF
+ symbols, we skip them. */
diff --git a/packages/glibc/2.15/640-alpha-atfcts.patch b/packages/glibc/2.13/0034-alpha-atfcts.patch
index 7a8a94a..2eff918 100644
--- a/packages/glibc/2.15/640-alpha-atfcts.patch
+++ b/packages/glibc/2.13/0034-alpha-atfcts.patch
@@ -1,5 +1,9 @@
---- glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h 2010-07-27 14:34:39.000000000 +0300
-+++ glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h.new 2011-03-10 18:54:37.686795979 +0200
+---
+ sysdeps/unix/sysv/linux/kernel-features.h | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
@@ -437,7 +437,8 @@
the code. On PPC they were introduced in 2.6.17-rc1,
on SH in 2.6.19-rc1. */
diff --git a/packages/glibc/2.13/650-syslog.patch b/packages/glibc/2.13/0035-syslog.patch
index c20cafc..a2d9722 100644
--- a/packages/glibc/2.13/650-syslog.patch
+++ b/packages/glibc/2.13/0035-syslog.patch
@@ -1,6 +1,9 @@
-diff -durN glibc-cvs-2.9.orig/misc/syslog.c glibc-cvs-2.9/misc/syslog.c
---- glibc-cvs-2.9.orig/misc/syslog.c 2009-06-01 10:16:50.000000000 +0200
-+++ glibc-cvs-2.9/misc/syslog.c 2009-06-01 10:17:20.000000000 +0200
+---
+ misc/syslog.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/misc/syslog.c
++++ b/misc/syslog.c
@@ -152,7 +152,7 @@
#define INTERNALLOG LOG_ERR|LOG_CONS|LOG_PERROR|LOG_PID
/* Check for invalid bits. */
diff --git a/packages/glibc/2.13/0036-debug-readlink_chk-readklinkat_chk.patch b/packages/glibc/2.13/0036-debug-readlink_chk-readklinkat_chk.patch
new file mode 100644
index 0000000..0b930f3
--- /dev/null
+++ b/packages/glibc/2.13/0036-debug-readlink_chk-readklinkat_chk.patch
@@ -0,0 +1,27 @@
+---
+ debug/readlink_chk.c | 2 +-
+ debug/readlinkat_chk.c | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+--- a/debug/readlink_chk.c
++++ b/debug/readlink_chk.c
+@@ -25,7 +25,7 @@
+
+
+ ssize_t
+-__readlink_chk (const char *path, void *buf, size_t len, size_t buflen)
++__readlink_chk (const char *path, char *buf, size_t len, size_t buflen)
+ {
+ if (len > buflen)
+ __chk_fail ();
+--- a/debug/readlinkat_chk.c
++++ b/debug/readlinkat_chk.c
+@@ -21,7 +21,7 @@
+
+
+ ssize_t
+-__readlinkat_chk (int fd, const char *path, void *buf, size_t len,
++__readlinkat_chk (int fd, const char *path, char *buf, size_t len,
+ size_t buflen)
+ {
+ if (len > buflen)
diff --git a/packages/glibc/2.13/900-march-i686.patch b/packages/glibc/2.13/0037-march-i686.patch
index 7f5b1ce..e5ad2e0 100644
--- a/packages/glibc/2.13/900-march-i686.patch
+++ b/packages/glibc/2.13/0037-march-i686.patch
@@ -3,9 +3,13 @@
* sysdeps/unix/sysv/linux/i386/sysdep.h: Re-define __i686.
* nptl/sysdeps/pthread/pt-initfini.c: Ditto.
-diff -urN glibc-2.12.1.orig/nptl/sysdeps/pthread/pt-initfini.c glibc-2.12.1/nptl/sysdeps/pthread/pt-initfini.c
---- glibc-2.12.1.orig/nptl/sysdeps/pthread/pt-initfini.c 2009-10-30 18:17:08.000000000 +0100
-+++ glibc-2.12.1/nptl/sysdeps/pthread/pt-initfini.c 2010-12-30 11:36:19.858708534 +0100
+---
+ nptl/sysdeps/pthread/pt-initfini.c | 5 +++++
+ sysdeps/unix/sysv/linux/i386/sysdep.h | 4 ++++
+ 2 files changed, 9 insertions(+)
+
+--- a/nptl/sysdeps/pthread/pt-initfini.c
++++ b/nptl/sysdeps/pthread/pt-initfini.c
@@ -45,6 +45,11 @@
/* Embed an #include to pull in the alignment and .end directives. */
asm ("\n#include \"defs.h\"");
@@ -18,9 +22,8 @@ diff -urN glibc-2.12.1.orig/nptl/sysdeps/pthread/pt-initfini.c glibc-2.12.1/nptl
/* The initial common code ends here. */
asm ("\n/*@HEADER_ENDS*/");
-diff -urN glibc-2.12.1.orig/sysdeps/unix/sysv/linux/i386/sysdep.h glibc-2.12.1/sysdeps/unix/sysv/linux/i386/sysdep.h
---- glibc-2.12.1.orig/sysdeps/unix/sysv/linux/i386/sysdep.h 2009-10-30 18:17:08.000000000 +0100
-+++ glibc-2.12.1/sysdeps/unix/sysv/linux/i386/sysdep.h 2010-12-30 11:36:19.858708534 +0100
+--- a/sysdeps/unix/sysv/linux/i386/sysdep.h
++++ b/sysdeps/unix/sysv/linux/i386/sysdep.h
@@ -29,6 +29,10 @@
#include <dl-sysdep.h>
#include <tls.h>
diff --git a/packages/glibc/2.19/910-typedef-caddr.patch b/packages/glibc/2.13/0038-typedef-caddr.patch
index e29e810..384338a 100644
--- a/packages/glibc/2.19/910-typedef-caddr.patch
+++ b/packages/glibc/2.13/0038-typedef-caddr.patch
@@ -1,6 +1,10 @@
-diff -urN glibc-2.12.1-orig/posix/sys/types.h glibc-2.12.1/posix/sys/types.h
---- glibc-2.12.1-orig/posix/sys/types.h 2010-12-13 11:47:26.000000000 +0100
-+++ glibc-2.12.1/posix/sys/types.h 2011-03-29 14:16:00.374064708 +0200
+---
+ posix/sys/types.h | 3 +++
+ sunrpc/rpc/types.h | 3 +++
+ 2 files changed, 6 insertions(+)
+
+--- a/posix/sys/types.h
++++ b/posix/sys/types.h
@@ -114,7 +114,10 @@
#ifdef __USE_BSD
# ifndef __daddr_t_defined
@@ -12,10 +16,9 @@ diff -urN glibc-2.12.1-orig/posix/sys/types.h glibc-2.12.1/posix/sys/types.h
# define __daddr_t_defined
# endif
#endif
-diff -urN glibc-2.12.1-orig/sunrpc/rpc/types.h glibc-2.12.1/sunrpc/rpc/types.h
---- glibc-2.12.1-orig/sunrpc/rpc/types.h 2010-12-13 11:47:26.000000000 +0100
-+++ glibc-2.12.1/sunrpc/rpc/types.h 2011-03-29 14:16:32.988910439 +0200
-@@ -80,7 +80,10 @@
+--- a/sunrpc/rpc/types.h
++++ b/sunrpc/rpc/types.h
+@@ -86,7 +86,10 @@
#endif
#ifndef __daddr_t_defined
typedef __daddr_t daddr_t;
diff --git a/packages/glibc/2.12.2/920-fix-rpc_parse-format.patch b/packages/glibc/2.13/0039-fix-rpc_parse-format.patch
index 37e58da..341d541 100644
--- a/packages/glibc/2.12.2/920-fix-rpc_parse-format.patch
+++ b/packages/glibc/2.13/0039-fix-rpc_parse-format.patch
@@ -45,11 +45,13 @@ Date: Tue Nov 8 23:44:51 2016 +0000
[$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
[$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
-diff --git a/sunrpc/rpc_parse.c b/sunrpc/rpc_parse.c
-index 1a1df6d8c2..505a6554cf 100644
+---
+ sunrpc/rpc_parse.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
--- a/sunrpc/rpc_parse.c
+++ b/sunrpc/rpc_parse.c
-@@ -521,7 +521,7 @@ static void
+@@ -521,7 +521,7 @@
get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
{
token tok;
diff --git a/packages/glibc/2.13/940-nis-bogus-conditional.patch b/packages/glibc/2.13/0040-nis-bogus-conditional.patch
index 09b38cf..732b859 100644
--- a/packages/glibc/2.13/940-nis-bogus-conditional.patch
+++ b/packages/glibc/2.13/0040-nis-bogus-conditional.patch
@@ -47,11 +47,13 @@ Date: Wed Dec 21 23:44:01 2016 +0000
* nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
Compare name == NULL, not name != NULL.
-diff --git a/nis/nss_nisplus/nisplus-alias.c b/nis/nss_nisplus/nisplus-alias.c
-index 7f698b4e6d..cb5acce01d 100644
+---
+ nis/nss_nisplus/nisplus-alias.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
--- a/nis/nss_nisplus/nisplus-alias.c
+++ b/nis/nss_nisplus/nisplus-alias.c
-@@ -291,7 +291,7 @@ _nss_nisplus_getaliasbyname_r (const char *name, struct aliasent *alias,
+@@ -293,7 +293,7 @@
return status;
}
diff --git a/packages/glibc/2.13/950-initfini-ppc64.patch b/packages/glibc/2.13/0041-initfini-ppc64.patch
index 87f8d23..c63c654 100644
--- a/packages/glibc/2.13/950-initfini-ppc64.patch
+++ b/packages/glibc/2.13/0041-initfini-ppc64.patch
@@ -7,9 +7,13 @@ commit 1fe05ea95e1460e5e1cf1568a8ce3982f0f02de6
Author: Ryan S. Arnold <rsa@us.ibm.com>
Date: Tue May 3 17:26:17 2011 -0500
---- glibc.orig/sysdeps/powerpc/powerpc64/Makefile 2012-12-22 19:10:06.713568781 -0800
-+++ glibc/sysdeps/powerpc/powerpc64/Makefile 2012-12-22 19:10:50.318605517 -0800
-@@ -31,7 +31,7 @@
+---
+ sysdeps/powerpc/powerpc64/Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/sysdeps/powerpc/powerpc64/Makefile
++++ b/sysdeps/powerpc/powerpc64/Makefile
+@@ -28,7 +28,7 @@
ifneq ($(elf),no)
# The initfini generation code doesn't work in the presence of -fPIC, so
# we use -fpic instead which is much better.
diff --git a/packages/glibc/2.12.1/998-obstack-common.patch b/packages/glibc/2.13/0042-obstack-common.patch
index 4b95f06..1993be2 100644
--- a/packages/glibc/2.12.1/998-obstack-common.patch
+++ b/packages/glibc/2.13/0042-obstack-common.patch
@@ -15,11 +15,13 @@ Date: Wed May 15 20:28:08 2013 +0200
* malloc/obstack.c (_obstack_compat): Add initializer.
-
-diff --git a/malloc/obstack.c b/malloc/obstack.c
-index 25a90514f7..c3c7db4a96 100644
+---
+ malloc/obstack.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
--- a/malloc/obstack.c
+++ b/malloc/obstack.c
-@@ -115,7 +115,7 @@ int obstack_exit_failure = EXIT_FAILURE;
+@@ -117,7 +117,7 @@
/* A looong time ago (before 1994, anyway; we're not sure) this global variable
was used by non-GNU-C macros to avoid multiple evaluation. The GNU C
library still exports it because somebody might use it. */
diff --git a/packages/glibc/2.13/999-new-tools.patch b/packages/glibc/2.13/0043-new-tools.patch
index d2d498a..4408ffe 100644
--- a/packages/glibc/2.13/999-new-tools.patch
+++ b/packages/glibc/2.13/0043-new-tools.patch
@@ -1,7 +1,11 @@
-diff -urpN glibc-2.13.orig/configure glibc-2.13/configure
---- glibc-2.13.orig/configure 2011-01-17 20:34:07.000000000 -0800
-+++ glibc-2.13/configure 2017-02-08 00:38:22.017735530 -0800
-@@ -5041,7 +5041,7 @@ $as_echo_n "checking version of $CC... "
+---
+ configure | 8 ++++----
+ configure.in | 8 ++++----
+ 2 files changed, 8 insertions(+), 8 deletions(-)
+
+--- a/configure
++++ b/configure
+@@ -5041,7 +5041,7 @@
ac_prog_version=`$CC -v 2>&1 | sed -n 's/^.*version \([egcygnustpi-]*[0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -10,7 +14,7 @@ diff -urpN glibc-2.13.orig/configure glibc-2.13/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5104,7 +5104,7 @@ $as_echo_n "checking version of $MAKE...
+@@ -5104,7 +5104,7 @@
ac_prog_version=`$MAKE --version 2>&1 | sed -n 's/^.*GNU Make[^0-9]*\([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -19,7 +23,7 @@ diff -urpN glibc-2.13.orig/configure glibc-2.13/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5231,7 +5231,7 @@ $as_echo_n "checking version of $MAKEINF
+@@ -5231,7 +5231,7 @@
ac_prog_version=`$MAKEINFO --version 2>&1 | sed -n 's/^.*GNU texinfo.* \([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -28,7 +32,7 @@ diff -urpN glibc-2.13.orig/configure glibc-2.13/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5291,7 +5291,7 @@ else
+@@ -5291,7 +5291,7 @@
# Found it, now check the version.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking version of $SED" >&5
$as_echo_n "checking version of $SED... " >&6; }
@@ -37,10 +41,9 @@ diff -urpN glibc-2.13.orig/configure glibc-2.13/configure
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
3.0[2-9]*|3.[1-9]*|[4-9]*)
-diff -urpN glibc-2.13.orig/configure.in glibc-2.13/configure.in
---- glibc-2.13.orig/configure.in 2011-01-17 20:34:07.000000000 -0800
-+++ glibc-2.13/configure.in 2017-02-08 00:30:01.720295526 -0800
-@@ -1026,11 +1026,11 @@ fi
+--- a/configure.in
++++ b/configure.in
+@@ -1026,11 +1026,11 @@
# These programs are version sensitive.
AC_CHECK_TOOL_PREFIX
AC_CHECK_PROG_VER(CC, ${ac_tool_prefix}gcc ${ac_tool_prefix}cc, -v,
@@ -54,7 +57,7 @@ diff -urpN glibc-2.13.orig/configure.in glibc-2.13/configure.in
AC_CHECK_PROG_VER(MSGFMT, gnumsgfmt gmsgfmt msgfmt, --version,
[GNU gettext.* \([0-9]*\.[0-9.]*\)],
-@@ -1038,10 +1038,10 @@ AC_CHECK_PROG_VER(MSGFMT, gnumsgfmt gmsg
+@@ -1038,10 +1038,10 @@
MSGFMT=: aux_missing="$aux_missing msgfmt")
AC_CHECK_PROG_VER(MAKEINFO, makeinfo, --version,
[GNU texinfo.* \([0-9][0-9.]*\)],
diff --git a/packages/glibc/2.13/430-alpha-creat.patch b/packages/glibc/2.13/430-alpha-creat.patch
deleted file mode 100644
index da6ddda..0000000
--- a/packages/glibc/2.13/430-alpha-creat.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-alpha does not have a __NR_creat
-
-http://bugs.gentoo.org/227275
-http://sourceware.org/bugzilla/show_bug.cgi?id=6650
-
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/wordsize-64/creat64.c glibc-2.13/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/wordsize-64/creat64.c 2007-11-10 20:34:26.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/wordsize-64/creat64.c 2009-11-13 00:50:51.000000000 +0100
-@@ -1 +1,5 @@
- /* Defined as alias for the syscall. */
-+#include <sysdep.h>
-+#ifndef __NR_creat
-+#include "../../../../../io/creat64.c"
-+#endif
diff --git a/packages/glibc/2.13/660-debug-readlink_chk-readklinkat_chk.patch b/packages/glibc/2.13/660-debug-readlink_chk-readklinkat_chk.patch
deleted file mode 100644
index a5a7052..0000000
--- a/packages/glibc/2.13/660-debug-readlink_chk-readklinkat_chk.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-diff -dur glibc-cvs-2.9.orig/debug/readlink_chk.c glibc-cvs-2.9/debug/readlink_chk.c
---- glibc-cvs-2.9.orig/debug/readlink_chk.c 2005-03-01 01:41:15.000000000 +0100
-+++ glibc-cvs-2.9/debug/readlink_chk.c 2009-06-01 10:59:37.000000000 +0200
-@@ -25,7 +25,7 @@
-
-
- ssize_t
--__readlink_chk (const char *path, void *buf, size_t len, size_t buflen)
-+__readlink_chk (const char *path, char *buf, size_t len, size_t buflen)
- {
- if (len > buflen)
- __chk_fail ();
-diff -dur glibc-cvs-2.9.orig/debug/readlinkat_chk.c glibc-cvs-2.9/debug/readlinkat_chk.c
---- glibc-cvs-2.9.orig/debug/readlinkat_chk.c 2006-04-24 18:56:12.000000000 +0200
-+++ glibc-cvs-2.9/debug/readlinkat_chk.c 2009-06-01 11:07:26.000000000 +0200
-@@ -21,7 +21,7 @@
-
-
- ssize_t
--__readlinkat_chk (int fd, const char *path, void *buf, size_t len,
-+__readlinkat_chk (int fd, const char *path, char *buf, size_t len,
- size_t buflen)
- {
- if (len > buflen)
diff --git a/packages/glibc/2.14.1/100-respect-env-CPPFLAGS.patch b/packages/glibc/2.14.1/0000-respect-env-CPPFLAGS.patch
index 3798cb2..8bb8679 100644
--- a/packages/glibc/2.14.1/100-respect-env-CPPFLAGS.patch
+++ b/packages/glibc/2.14.1/0000-respect-env-CPPFLAGS.patch
@@ -1,10 +1,13 @@
Respect environment CPPFLAGS when we run ./configure so we can inject
random -D things without having to set CFLAGS/ASFLAGS
-diff -durN glibc-2.13.orig/Makeconfig glibc-2.13/Makeconfig
---- glibc-2.13.orig/Makeconfig 2009-05-09 23:57:56.000000000 +0200
-+++ glibc-2.13/Makeconfig 2009-11-13 00:49:41.000000000 +0100
-@@ -697,6 +697,7 @@
+---
+ Makeconfig | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/Makeconfig
++++ b/Makeconfig
+@@ -699,6 +699,7 @@
$(foreach lib,$(libof-$(basename $(@F))) \
$(libof-$(<F)) $(libof-$(@F)),$(CPPFLAGS-$(lib))) \
$(CPPFLAGS-$(<F)) $(CPPFLAGS-$(@F)) $(CPPFLAGS-$(basename $(@F)))
diff --git a/packages/glibc/2.14.1/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.14.1/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
index 6fd663a..30a70a2 100644
--- a/packages/glibc/2.14.1/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
+++ b/packages/glibc/2.14.1/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
@@ -5,16 +5,13 @@ Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
-Wparentheses
---
- ChangeLog | 5 +++++
- nis/nis_call.c | 20 +++++++++++---------
- stdlib/setenv.c | 26 ++++++++++++++------------
- 3 files changed, 30 insertions(+), 21 deletions(-)
+ nis/nis_call.c | 20 +++++++++++---------
+ stdlib/setenv.c | 24 +++++++++++++-----------
+ 2 files changed, 24 insertions(+), 20 deletions(-)
-diff --git a/nis/nis_call.c b/nis/nis_call.c
-index 3fa37e4..cb7839a 100644
--- a/nis/nis_call.c
+++ b/nis/nis_call.c
-@@ -680,16 +680,18 @@ nis_server_cache_add (const_nis_name name, int search_parent,
+@@ -682,16 +682,18 @@
/* Choose which entry should be evicted from the cache. */
loc = &nis_server_cache[0];
if (*loc != NULL)
@@ -42,11 +39,9 @@ index 3fa37e4..cb7839a 100644
old = *loc;
*loc = new;
-diff --git a/stdlib/setenv.c b/stdlib/setenv.c
-index da61ee0..e66045f 100644
--- a/stdlib/setenv.c
+++ b/stdlib/setenv.c
-@@ -278,18 +278,20 @@ unsetenv (const char *name)
+@@ -328,18 +328,20 @@
ep = __environ;
if (ep != NULL)
while (*ep != NULL)
@@ -54,7 +49,12 @@ index da61ee0..e66045f 100644
- {
- /* Found it. Remove this pointer by moving later ones back. */
- char **dp = ep;
--
++ {
++ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
++ {
++ /* Found it. Remove this pointer by moving later ones back. */
++ char **dp = ep;
+
- do
- dp[0] = dp[1];
- while (*dp++);
@@ -62,12 +62,6 @@ index da61ee0..e66045f 100644
- }
- else
- ++ep;
-+ {
-+ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-+ {
-+ /* Found it. Remove this pointer by moving later ones back. */
-+ char **dp = ep;
-+
+ do
+ dp[0] = dp[1];
+ while (*dp++);
@@ -79,6 +73,3 @@ index da61ee0..e66045f 100644
UNLOCK;
---
-2.7.4
-
diff --git a/packages/glibc/2.12.1/102-fix-signed-shift-overlow.patch b/packages/glibc/2.14.1/0002-fix-signed-shift-overlow.patch
index ef49f83..5f76afe 100644
--- a/packages/glibc/2.12.1/102-fix-signed-shift-overlow.patch
+++ b/packages/glibc/2.14.1/0002-fix-signed-shift-overlow.patch
@@ -12,11 +12,16 @@ Date: Tue Jul 21 22:50:29 2015 -0700
* string/strchrnul.c (STRCHRNUL):
Rewrite code to avoid issues with signed shift overflow.
-diff --git a/string/memrchr.c b/string/memrchr.c
-index 0c8fd84..86cd5b9 100644
+---
+ string/memrchr.c | 11 ++---------
+ string/rawmemchr.c | 11 ++---------
+ string/strchr.c | 9 ++-------
+ string/strchrnul.c | 9 ++-------
+ 4 files changed, 8 insertions(+), 32 deletions(-)
+
--- a/string/memrchr.c
+++ b/string/memrchr.c
-@@ -96,15 +96,8 @@ MEMRCHR
+@@ -98,15 +98,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
@@ -34,11 +39,9 @@ index 0c8fd84..86cd5b9 100644
/* Set up a longword, each of whose bytes is C. */
charmask = c | (c << 8);
-diff --git a/string/rawmemchr.c b/string/rawmemchr.c
-index 05b22be..228ca9d 100644
--- a/string/rawmemchr.c
+++ b/string/rawmemchr.c
-@@ -86,15 +86,8 @@ RAWMEMCHR (s, c_in)
+@@ -90,15 +90,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
@@ -56,11 +59,9 @@ index 05b22be..228ca9d 100644
/* Set up a longword, each of whose bytes is C. */
charmask = c | (c << 8);
-diff --git a/string/strchr.c b/string/strchr.c
-index 5f90075..f13b2b3 100644
--- a/string/strchr.c
+++ b/string/strchr.c
-@@ -60,13 +60,8 @@ strchr (const char *s, int c_in)
+@@ -65,13 +65,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
@@ -76,11 +77,9 @@ index 5f90075..f13b2b3 100644
/* Set up a longword, each of whose bytes is C. */
charmask = c | (c << 8);
-diff --git a/string/strchrnul.c b/string/strchrnul.c
-index 2678f1d..daf0b3f 100644
--- a/string/strchrnul.c
+++ b/string/strchrnul.c
-@@ -66,13 +66,8 @@ STRCHRNUL (s, c_in)
+@@ -63,13 +63,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
diff --git a/packages/glibc/2.14.1/0003-dl-openat64-variadic.patch b/packages/glibc/2.14.1/0003-dl-openat64-variadic.patch
new file mode 100644
index 0000000..e69bb17
--- /dev/null
+++ b/packages/glibc/2.14.1/0003-dl-openat64-variadic.patch
@@ -0,0 +1,197 @@
+commit 9dd346ff431fc761f1b748bd4da8bb59f7652094
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Tue Oct 20 11:54:09 2015 +0000
+
+ Convert 113 more function definitions to prototype style (files with assertions).
+
+ This mostly automatically-generated patch converts 113 function
+ definitions in glibc from old-style K&R to prototype-style. Following
+ my other recent such patches, this one deals with the case of function
+ definitions in files that either contain assertions or where grep
+ suggested they might contain assertions - and thus where it isn't
+ possible to use a simple object code comparison as a sanity check on
+ the correctness of the patch, because line numbers are changed.
+
+ A few such automatically-generated changes needed to be supplemented
+ by manual changes for the result to compile. openat64 had a prototype
+ declaration with "..." but an old-style definition in
+ sysdeps/unix/sysv/linux/dl-openat64.c, and "..." needed adding to the
+ generated prototype in the definition (I've filed
+ <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68024> for diagnosing
+ such cases in GCC; the old state was undefined behavior not requiring
+ a diagnostic, but one seems a good idea). In addition, as Florian has
+ noted regparm attribute mismatches between declaration and definition
+ are only diagnosed for prototype definitions, and five functions
+ needed internal_function added to their definitions (in the case of
+ __pthread_mutex_cond_lock, via the macro definition of
+ __pthread_mutex_lock) to compile on i386.
+
+ After this patch is in, remaining old-style definitions are probably
+ most readily fixed manually before we can turn on
+ -Wold-style-definition for all builds.
+
+ Tested for x86_64 and x86 (testsuite).
+
+ * crypt/md5-crypt.c (__md5_crypt_r): Convert to prototype-style
+ function definition.
+ * crypt/sha256-crypt.c (__sha256_crypt_r): Likewise.
+ * crypt/sha512-crypt.c (__sha512_crypt_r): Likewise.
+ * debug/backtracesyms.c (__backtrace_symbols): Likewise.
+ * elf/dl-minimal.c (_itoa): Likewise.
+ * hurd/hurdmalloc.c (malloc): Likewise.
+ (free): Likewise.
+ (realloc): Likewise.
+ * inet/inet6_option.c (inet6_option_space): Likewise.
+ (inet6_option_init): Likewise.
+ (inet6_option_append): Likewise.
+ (inet6_option_alloc): Likewise.
+ (inet6_option_next): Likewise.
+ (inet6_option_find): Likewise.
+ * io/ftw.c (FTW_NAME): Likewise.
+ (NFTW_NAME): Likewise.
+ (NFTW_NEW_NAME): Likewise.
+ (NFTW_OLD_NAME): Likewise.
+ * libio/iofwide.c (_IO_fwide): Likewise.
+ * libio/strops.c (_IO_str_init_static_internal): Likewise.
+ (_IO_str_init_static): Likewise.
+ (_IO_str_init_readonly): Likewise.
+ (_IO_str_overflow): Likewise.
+ (_IO_str_underflow): Likewise.
+ (_IO_str_count): Likewise.
+ (_IO_str_seekoff): Likewise.
+ (_IO_str_pbackfail): Likewise.
+ (_IO_str_finish): Likewise.
+ * libio/wstrops.c (_IO_wstr_init_static): Likewise.
+ (_IO_wstr_overflow): Likewise.
+ (_IO_wstr_underflow): Likewise.
+ (_IO_wstr_count): Likewise.
+ (_IO_wstr_seekoff): Likewise.
+ (_IO_wstr_pbackfail): Likewise.
+ (_IO_wstr_finish): Likewise.
+ * locale/programs/localedef.c (normalize_codeset): Likewise.
+ * locale/programs/locarchive.c (add_locale_to_archive): Likewise.
+ (add_locales_to_archive): Likewise.
+ (delete_locales_from_archive): Likewise.
+ * malloc/malloc.c (__libc_mallinfo): Likewise.
+ * math/gen-auto-libm-tests.c (init_fp_formats): Likewise.
+ * misc/tsearch.c (__tfind): Likewise.
+ * nptl/pthread_attr_destroy.c (__pthread_attr_destroy): Likewise.
+ * nptl/pthread_attr_getdetachstate.c
+ (__pthread_attr_getdetachstate): Likewise.
+ * nptl/pthread_attr_getguardsize.c (pthread_attr_getguardsize):
+ Likewise.
+ * nptl/pthread_attr_getinheritsched.c
+ (__pthread_attr_getinheritsched): Likewise.
+ * nptl/pthread_attr_getschedparam.c
+ (__pthread_attr_getschedparam): Likewise.
+ * nptl/pthread_attr_getschedpolicy.c
+ (__pthread_attr_getschedpolicy): Likewise.
+ * nptl/pthread_attr_getscope.c (__pthread_attr_getscope):
+ Likewise.
+ * nptl/pthread_attr_getstack.c (__pthread_attr_getstack):
+ Likewise.
+ * nptl/pthread_attr_getstackaddr.c (__pthread_attr_getstackaddr):
+ Likewise.
+ * nptl/pthread_attr_getstacksize.c (__pthread_attr_getstacksize):
+ Likewise.
+ * nptl/pthread_attr_init.c (__pthread_attr_init_2_1): Likewise.
+ (__pthread_attr_init_2_0): Likewise.
+ * nptl/pthread_attr_setdetachstate.c
+ (__pthread_attr_setdetachstate): Likewise.
+ * nptl/pthread_attr_setguardsize.c (pthread_attr_setguardsize):
+ Likewise.
+ * nptl/pthread_attr_setinheritsched.c
+ (__pthread_attr_setinheritsched): Likewise.
+ * nptl/pthread_attr_setschedparam.c
+ (__pthread_attr_setschedparam): Likewise.
+ * nptl/pthread_attr_setschedpolicy.c
+ (__pthread_attr_setschedpolicy): Likewise.
+ * nptl/pthread_attr_setscope.c (__pthread_attr_setscope):
+ Likewise.
+ * nptl/pthread_attr_setstack.c (__pthread_attr_setstack):
+ Likewise.
+ * nptl/pthread_attr_setstackaddr.c (__pthread_attr_setstackaddr):
+ Likewise.
+ * nptl/pthread_attr_setstacksize.c (__pthread_attr_setstacksize):
+ Likewise.
+ * nptl/pthread_condattr_setclock.c (pthread_condattr_setclock):
+ Likewise.
+ * nptl/pthread_create.c (__find_in_stack_list): Likewise.
+ * nptl/pthread_getattr_np.c (pthread_getattr_np): Likewise.
+ * nptl/pthread_mutex_cond_lock.c (__pthread_mutex_lock): Define to
+ use internal_function.
+ * nptl/pthread_mutex_init.c (__pthread_mutex_init): Convert to
+ prototype-style function definition.
+ * nptl/pthread_mutex_lock.c (__pthread_mutex_lock): Likewise.
+ (__pthread_mutex_cond_lock_adjust): Likewise. Use
+ internal_function.
+ * nptl/pthread_mutex_timedlock.c (pthread_mutex_timedlock):
+ Convert to prototype-style function definition.
+ * nptl/pthread_mutex_trylock.c (__pthread_mutex_trylock):
+ Likewise.
+ * nptl/pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt):
+ Likewise.
+ (__pthread_mutex_unlock): Likewise.
+ * nptl_db/td_ta_clear_event.c (td_ta_clear_event): Likewise.
+ * nptl_db/td_ta_set_event.c (td_ta_set_event): Likewise.
+ * nptl_db/td_thr_clear_event.c (td_thr_clear_event): Likewise.
+ * nptl_db/td_thr_event_enable.c (td_thr_event_enable): Likewise.
+ * nptl_db/td_thr_set_event.c (td_thr_set_event): Likewise.
+ * nss/makedb.c (process_input): Likewise.
+ * posix/fnmatch.c (__strchrnul): Likewise.
+ (__wcschrnul): Likewise.
+ (fnmatch): Likewise.
+ * posix/fnmatch_loop.c (FCT): Likewise.
+ * posix/glob.c (globfree): Likewise.
+ (__glob_pattern_type): Likewise.
+ (__glob_pattern_p): Likewise.
+ * posix/regcomp.c (re_compile_pattern): Likewise.
+ (re_set_syntax): Likewise.
+ (re_compile_fastmap): Likewise.
+ (regcomp): Likewise.
+ (regerror): Likewise.
+ (regfree): Likewise.
+ * posix/regexec.c (regexec): Likewise.
+ (re_match): Likewise.
+ (re_search): Likewise.
+ (re_match_2): Likewise.
+ (re_search_2): Likewise.
+ (re_search_stub): Likewise. Use internal_function
+ (re_copy_regs): Likewise.
+ (re_set_registers): Convert to prototype-style function
+ definition.
+ (prune_impossible_nodes): Likewise. Use internal_function.
+ * resolv/inet_net_pton.c (inet_net_pton): Convert to
+ prototype-style function definition.
+ (inet_net_pton_ipv4): Likewise.
+ * stdlib/strtod_l.c (____STRTOF_INTERNAL): Likewise.
+ * sysdeps/pthread/aio_cancel.c (aio_cancel): Likewise.
+ * sysdeps/pthread/aio_suspend.c (aio_suspend): Likewise.
+ * sysdeps/pthread/timer_delete.c (timer_delete): Likewise.
+ * sysdeps/unix/sysv/linux/dl-openat64.c (openat64): Likewise.
+ Make variadic.
+ * time/strptime_l.c (localtime_r): Convert to prototype-style
+ function definition.
+ * wcsmbs/mbsnrtowcs.c (__mbsnrtowcs): Likewise.
+ * wcsmbs/mbsrtowcs_l.c (__mbsrtowcs_l): Likewise.
+ * wcsmbs/wcsnrtombs.c (__wcsnrtombs): Likewise.
+ * wcsmbs/wcsrtombs.c (__wcsrtombs): Likewise.
+
+---
+ sysdeps/unix/sysv/linux/dl-openat64.c | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
+--- a/sysdeps/unix/sysv/linux/dl-openat64.c
++++ b/sysdeps/unix/sysv/linux/dl-openat64.c
+@@ -24,10 +24,7 @@
+
+
+ int
+-openat64 (dfd, file, oflag)
+- int dfd;
+- const char *file;
+- int oflag;
++openat64 (int dfd, const char *file, int oflag, ...)
+ {
+ assert ((oflag & O_CREAT) == 0);
+
diff --git a/packages/glibc/2.12.1/104-unused-variables.patch b/packages/glibc/2.14.1/0004-unused-variables.patch
index e063675..18adb17 100644
--- a/packages/glibc/2.12.1/104-unused-variables.patch
+++ b/packages/glibc/2.14.1/0004-unused-variables.patch
@@ -19,8 +19,18 @@ Date: Fri Sep 18 20:27:20 2015 +0100
* timezone/private.h (time_t_min): Likewise. (time_t_max):
Likewise.
-diff --git a/resolv/base64.c b/resolv/base64.c
-index ea584ed..519e5d2 100644
+---
+ resolv/base64.c | 4 ----
+ sysdeps/ieee754/dbl-64/atnat2.h | 4 ----
+ sysdeps/ieee754/dbl-64/uexp.h | 2 +-
+ sysdeps/ieee754/dbl-64/upow.h | 2 --
+ sysdeps/ieee754/flt-32/e_log10f.c | 6 ------
+ sysdeps/ieee754/flt-32/s_cosf.c | 6 ------
+ sysdeps/ieee754/ldbl-128/e_lgammal_r.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_erfl.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_log1pl.c | 1 -
+ 9 files changed, 1 insertion(+), 26 deletions(-)
+
--- a/resolv/base64.c
+++ b/resolv/base64.c
@@ -40,10 +40,6 @@
@@ -34,11 +44,9 @@ index ea584ed..519e5d2 100644
#include <sys/types.h>
#include <sys/param.h>
#include <sys/socket.h>
-diff --git a/sysdeps/ieee754/dbl-64/atnat2.h b/sysdeps/ieee754/dbl-64/atnat2.h
-index e0d65af..82943f9 100644
--- a/sysdeps/ieee754/dbl-64/atnat2.h
+++ b/sysdeps/ieee754/dbl-64/atnat2.h
-@@ -65,10 +65,8 @@
+@@ -69,10 +69,8 @@
/**/ hpi1 = {{0x3c91a626, 0x33145c07} }, /* pi/2-hpi */
/**/ mhpi = {{0xbff921fb, 0x54442d18} }, /* -pi/2 */
/**/ qpi = {{0x3fe921fb, 0x54442d18} }, /* pi/4 */
@@ -49,7 +57,7 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0xc002d97c, 0x7f3321d2} }, /* -3pi/4 */
/**/ u1 = {{0x3c314c2a, 0x00000000} }, /* 9.377e-19 */
/**/ u2 = {{0x3bf955e4, 0x00000000} }, /* 8.584e-20 */
-@@ -129,10 +127,8 @@
+@@ -139,10 +137,8 @@
/**/ hpi1 = {{0x33145c07, 0x3c91a626} }, /* pi/2-hpi */
/**/ mhpi = {{0x54442d18, 0xbff921fb} }, /* -pi/2 */
/**/ qpi = {{0x54442d18, 0x3fe921fb} }, /* pi/4 */
@@ -60,11 +68,9 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0x7f3321d2, 0xc002d97c} }, /* -3pi/4 */
/**/ u1 = {{0x00000000, 0x3c314c2a} }, /* 9.377e-19 */
/**/ u2 = {{0x00000000, 0x3bf955e4} }, /* 8.584e-20 */
-diff --git a/sysdeps/ieee754/dbl-64/uexp.h b/sysdeps/ieee754/dbl-64/uexp.h
-index 6817eaf..42b21f2 100644
--- a/sysdeps/ieee754/dbl-64/uexp.h
+++ b/sysdeps/ieee754/dbl-64/uexp.h
-@@ -29,7 +29,7 @@
+@@ -30,7 +30,7 @@
#include "mydefs.h"
@@ -73,11 +79,9 @@ index 6817eaf..42b21f2 100644
err_0 = 1.000014, err_1 = 0.000016;
const static int4 bigint = 0x40862002,
badint = 0x40876000,smallint = 0x3C8fffff;
-diff --git a/sysdeps/ieee754/dbl-64/upow.h b/sysdeps/ieee754/dbl-64/upow.h
-index c8569a9..b4911e5 100644
--- a/sysdeps/ieee754/dbl-64/upow.h
+++ b/sysdeps/ieee754/dbl-64/upow.h
-@@ -34,7 +34,6 @@
+@@ -36,7 +36,6 @@
/**/ INF = {{0x7ff00000, 0x00000000}}, /* INF */
/**/ nINF = {{0xfff00000, 0x00000000}}, /* -INF */
/**/ NaNQ = {{0x7ff80000, 0x00000000}}, /* NaNQ */
@@ -85,7 +89,7 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0x3fe62e42, 0xfefa3800}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x3d2ef357, 0x93c76730}}, /* ln(2)-ln2a */
/**/ bigu = {{0x4297ffff, 0xfffffd2c}}, /* 1.5*2**42 -724*2**-10 */
-@@ -48,7 +47,6 @@
+@@ -51,7 +50,6 @@
/**/ INF = {{0x00000000, 0x7ff00000}}, /* INF */
/**/ nINF = {{0x00000000, 0xfff00000}}, /* -INF */
/**/ NaNQ = {{0x00000000, 0x7ff80000}}, /* NaNQ */
@@ -93,45 +97,39 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0xfefa3800, 0x3fe62e42}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x93c76730, 0x3d2ef357}}, /* ln(2)-ln2a */
/**/ bigu = {{0xfffffd2c, 0x4297ffff}}, /* 1.5*2**42 -724*2**-10 */
-diff --git a/sysdeps/ieee754/flt-32/e_log10f.c b/sysdeps/ieee754/flt-32/e_log10f.c
-index 96f0e81..1daeef7 100644
--- a/sysdeps/ieee754/flt-32/e_log10f.c
+++ b/sysdeps/ieee754/flt-32/e_log10f.c
-@@ -22,12 +22,6 @@ ivln10 = 4.3429449201e-01, /* 0x3ede5bd9 */
- log10_2hi = 3.0102920532e-01, /* 0x3e9a2080 */
+@@ -31,12 +31,6 @@
log10_2lo = 7.9034151668e-07; /* 0x355427db */
--#ifdef __STDC__
+ #ifdef __STDC__
-static const float zero = 0.0;
-#else
-static float zero = 0.0;
-#endif
-
- #ifdef __STDC__
+-#ifdef __STDC__
float __ieee754_log10f(float x)
#else
-diff --git a/sysdeps/ieee754/flt-32/s_cosf.c b/sysdeps/ieee754/flt-32/s_cosf.c
-index 864ab27..0affd40 100644
+ float __ieee754_log10f(x)
--- a/sysdeps/ieee754/flt-32/s_cosf.c
+++ b/sysdeps/ieee754/flt-32/s_cosf.c
-@@ -21,12 +21,6 @@ static char rcsid[] = "$NetBSD: s_cosf.c,v 1.4 1995/05/10 20:47:03 jtc Exp $";
- #include "math.h"
+@@ -22,12 +22,6 @@
#include "math_private.h"
--#ifdef __STDC__
+ #ifdef __STDC__
-static const float one=1.0;
-#else
-static float one=1.0;
-#endif
-
- #ifdef __STDC__
+-#ifdef __STDC__
float __cosf(float x)
#else
-diff --git a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-index 500aacc..ab5a96e 100644
+ float __cosf(x)
--- a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
+++ b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-@@ -82,7 +82,6 @@ DIAG_IGNORE_NEEDS_COMMENT (4.6, "-Woverflow");
+@@ -74,7 +74,6 @@
static const long double PIL = 3.1415926535897932384626433832795028841972E0L;
static const long double MAXLGM = 1.0485738685148938358098967157129705071571E4928L;
static const long double one = 1.0L;
@@ -139,11 +137,9 @@ index 500aacc..ab5a96e 100644
static const long double huge = 1.0e4000L;
/* log gamma(x) = ( x - 0.5 ) * log(x) - x + LS2PI + 1/x P(1/x^2)
-diff --git a/sysdeps/ieee754/ldbl-128/s_erfl.c b/sysdeps/ieee754/ldbl-128/s_erfl.c
-index fa4609f..08c80a3 100644
--- a/sysdeps/ieee754/ldbl-128/s_erfl.c
+++ b/sysdeps/ieee754/ldbl-128/s_erfl.c
-@@ -140,7 +140,6 @@ deval (long double x, const long double *p, int n)
+@@ -142,7 +142,6 @@
static long double
#endif
tiny = 1e-4931L,
@@ -151,11 +147,9 @@ index fa4609f..08c80a3 100644
one = 1.0L,
two = 2.0L,
/* 2/sqrt(pi) - 1 */
-diff --git a/sysdeps/ieee754/ldbl-128/s_log1pl.c b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-index ff759bc..9609550 100644
--- a/sysdeps/ieee754/ldbl-128/s_log1pl.c
+++ b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-@@ -117,7 +117,6 @@ static const long double C2 = 1.428606820309417232121458176568075500134E-6L;
+@@ -116,7 +116,6 @@
static const long double sqrth = 0.7071067811865475244008443621048490392848L;
/* ln (2^16384 * (1 - 2^-113)) */
diff --git a/packages/glibc/2.15/105-misleading-indentation.patch b/packages/glibc/2.14.1/0005-misleading-indentation.patch
index 1dd8d85..35bcb1b 100644
--- a/packages/glibc/2.15/105-misleading-indentation.patch
+++ b/packages/glibc/2.14.1/0005-misleading-indentation.patch
@@ -7,11 +7,13 @@ Date: Fri Dec 11 09:19:37 2015 -0800
* sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
Fix indentation.
-diff --git a/sysdeps/ieee754/flt-32/k_rem_pio2f.c b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-index 0c7685c..392afdb 100644
+---
+ sysdeps/ieee754/flt-32/k_rem_pio2f.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
--- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
+++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-@@ -65,7 +65,9 @@ int __kernel_rem_pio2f(float *x, float *y, int e0, int nx, int prec, const int32
+@@ -82,7 +82,9 @@
/* compute q[0],q[1],...q[jk] */
for (i=0;i<=jk;i++) {
diff --git a/packages/glibc/2.15/106-dl-open-array-bounds.patch b/packages/glibc/2.14.1/0006-dl-open-array-bounds.patch
index bdb5c19..a61f1a5 100644
--- a/packages/glibc/2.15/106-dl-open-array-bounds.patch
+++ b/packages/glibc/2.14.1/0006-dl-open-array-bounds.patch
@@ -4,11 +4,13 @@ Date: Fri Apr 17 12:11:58 2015 -0700
Fuller check for invalid NSID in _dl_open.
-diff --git a/elf/dl-open.c b/elf/dl-open.c
-index 0dbe07f..2d0e082 100644
+---
+ elf/dl-open.c | 10 ++++++++--
+ 1 file changed, 8 insertions(+), 2 deletions(-)
+
--- a/elf/dl-open.c
+++ b/elf/dl-open.c
-@@ -619,8 +619,14 @@ no more namespaces available for dlmopen()"));
+@@ -540,8 +540,14 @@
/* Never allow loading a DSO in a namespace which is empty. Such
direct placements is only causing problems. Also don't allow
loading into a namespace used for auditing. */
diff --git a/packages/glibc/2.15/120-i386-x86_64-revert-clone-cfi.patch b/packages/glibc/2.14.1/0007-i386-x86_64-revert-clone-cfi.patch
index c7f6182..f872bac 100644
--- a/packages/glibc/2.15/120-i386-x86_64-revert-clone-cfi.patch
+++ b/packages/glibc/2.14.1/0007-i386-x86_64-revert-clone-cfi.patch
@@ -4,16 +4,13 @@ elsewhere. this cfi code does not gain us a whole lot anyways.
http://gcc.gnu.org/ml/gcc/2006-12/msg00293.html
-Index: sysdeps/unix/sysv/linux/i386/clone.S
-===================================================================
-RCS file: /cvs/glibc/libc/sysdeps/unix/sysv/linux/i386/clone.S,v
-retrieving revision 1.27
-retrieving revision 1.26
-diff -u -p -r1.27 -r1.26
+---
+ sysdeps/unix/sysv/linux/i386/clone.S | 4 ----
+ sysdeps/unix/sysv/linux/x86_64/clone.S | 4 ----
+ 2 files changed, 8 deletions(-)
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/i386/clone.S glibc-2.13/sysdeps/unix/sysv/linux/i386/clone.S
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/i386/clone.S 2006-12-04 00:12:36.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/i386/clone.S 2009-11-13 00:49:45.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/i386/clone.S
++++ b/sysdeps/unix/sysv/linux/i386/clone.S
@@ -120,9 +120,6 @@
ret
@@ -32,9 +29,8 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/i386/clone.S glibc-2.13/sysde
cfi_startproc
PSEUDO_END (BP_SYM (__clone))
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/x86_64/clone.S glibc-2.13/sysdeps/unix/sysv/linux/x86_64/clone.S
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/x86_64/clone.S 2006-12-04 00:12:36.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/x86_64/clone.S 2009-11-13 00:49:45.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/x86_64/clone.S
++++ b/sysdeps/unix/sysv/linux/x86_64/clone.S
@@ -89,9 +89,6 @@
ret
diff --git a/packages/glibc/2.16.0/140-disable-ldconfig.patch b/packages/glibc/2.14.1/0008-disable-ldconfig.patch
index 378e1df..d60cb40 100644
--- a/packages/glibc/2.16.0/140-disable-ldconfig.patch
+++ b/packages/glibc/2.14.1/0008-disable-ldconfig.patch
@@ -3,9 +3,12 @@ file outside of the chroot. doesnt matter anyways as we wont use the cache
results (portage will rebuild cache), so running ldconfig is simply a waste
of time.
-diff -durN glibc-2.13.orig/Makefile glibc-2.13/Makefile
---- glibc-2.13.orig/Makefile 2009-04-23 20:23:03.000000000 +0200
-+++ glibc-2.13/Makefile 2009-11-13 00:49:49.000000000 +0100
+---
+ Makefile | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/Makefile
++++ b/Makefile
@@ -116,6 +116,7 @@
rm -f $(symbolic-link-list)
diff --git a/packages/glibc/2.14.1/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.14.1/0009-Fix-combreloc-test-BSD-grep.patch
index d720d39..5e68aa3 100644
--- a/packages/glibc/2.14.1/140-Fix-combreloc-test-BSD-grep.patch
+++ b/packages/glibc/2.14.1/0009-Fix-combreloc-test-BSD-grep.patch
@@ -13,15 +13,13 @@ by configure as "not found". As a result, support for "-z combreloc"
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
+ configure | 2 +-
+ configure.in | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
-diff -urpN glibc-2.14.1.orig/configure glibc-2.14.1/configure
---- glibc-2.14.1.orig/configure 2011-10-07 02:48:55.000000000 -0700
-+++ glibc-2.14.1/configure 2017-03-08 21:06:36.000000000 -0800
-@@ -6377,7 +6377,7 @@ EOF
+--- a/configure
++++ b/configure
+@@ -6377,7 +6377,7 @@
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; }
then
@@ -30,10 +28,9 @@ diff -urpN glibc-2.14.1.orig/configure glibc-2.14.1/configure
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
-diff -urpN glibc-2.14.1.orig/configure.in glibc-2.14.1/configure.in
---- glibc-2.14.1.orig/configure.in 2011-10-07 02:48:55.000000000 -0700
-+++ glibc-2.14.1/configure.in 2017-03-08 21:06:50.000000000 -0800
-@@ -1655,7 +1655,7 @@ dnl cross-platform since the gcc used ca
+--- a/configure.in
++++ b/configure.in
+@@ -1655,7 +1655,7 @@
dnl introducing new options this is not easily doable. Instead use a tool
dnl which always is cross-platform: readelf. To detect whether -z combreloc
dnl look for a section named .rel.dyn.
diff --git a/packages/glibc/2.15/150-queue-header-updates.patch b/packages/glibc/2.14.1/0010-queue-header-updates.patch
index 7cbe70e..f6515e2 100644
--- a/packages/glibc/2.15/150-queue-header-updates.patch
+++ b/packages/glibc/2.14.1/0010-queue-header-updates.patch
@@ -2,11 +2,12 @@ grab some updates from FreeBSD
http://bugs.gentoo.org/201979
-diff -durN glibc-2.13.orig/misc/sys/queue.h glibc-2.13/misc/sys/queue.h
+---
+ misc/sys/queue.h | 36 ++++++++++++++++++++++++++++++++++++
+ 1 file changed, 36 insertions(+)
-diff -durN glibc-2.13.orig/misc/sys/queue.h glibc-2.13/misc/sys/queue.h
---- glibc-2.13.orig/misc/sys/queue.h 2008-03-05 06:50:30.000000000 +0100
-+++ glibc-2.13/misc/sys/queue.h 2009-11-13 00:49:51.000000000 +0100
+--- a/misc/sys/queue.h
++++ b/misc/sys/queue.h
@@ -136,6 +136,11 @@
(var); \
(var) = ((var)->field.le_next))
diff --git a/packages/glibc/2.15/160-manual-no-perl.patch b/packages/glibc/2.14.1/0011-manual-no-perl.patch
index 5e2b807..7e232aa 100644
--- a/packages/glibc/2.15/160-manual-no-perl.patch
+++ b/packages/glibc/2.14.1/0011-manual-no-perl.patch
@@ -4,10 +4,13 @@ deal, so just whine a little and continue on our merry way.
http://bugs.gentoo.org/60132
-diff -durN glibc-2.13.orig/manual/Makefile glibc-2.13/manual/Makefile
---- glibc-2.13.orig/manual/Makefile 2006-01-08 07:43:47.000000000 +0100
-+++ glibc-2.13/manual/Makefile 2009-11-13 00:49:54.000000000 +0100
-@@ -104,9 +104,14 @@
+---
+ manual/Makefile | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/manual/Makefile
++++ b/manual/Makefile
+@@ -106,9 +106,14 @@
libm-err.texi: stamp-libm-err
stamp-libm-err: libm-err-tab.pl $(wildcard $(foreach dir,$(sysdirs),\
$(dir)/libm-test-ulps))
diff --git a/packages/glibc/2.15/170-localedef-fix-trampoline.patch b/packages/glibc/2.14.1/0012-localedef-fix-trampoline.patch
index 3cc6559..3b8fd6e 100644
--- a/packages/glibc/2.15/170-localedef-fix-trampoline.patch
+++ b/packages/glibc/2.14.1/0012-localedef-fix-trampoline.patch
@@ -5,9 +5,12 @@
# DP: Upstream status: Unknown
# DP: Status Details: Unknown
# DP: Date: 2004-03-16
-diff -durN glibc-2.13.orig/locale/programs/3level.h glibc-2.13/locale/programs/3level.h
---- glibc-2.13.orig/locale/programs/3level.h 2007-07-16 02:54:59.000000000 +0200
-+++ glibc-2.13/locale/programs/3level.h 2009-11-13 00:49:56.000000000 +0100
+---
+# locale/programs/3level.h | 36 ++++++++++++++++++++++++++++++++++++
+# 1 file changed, 36 insertions(+)
+#
+--- a/locale/programs/3level.h
++++ b/locale/programs/3level.h
@@ -203,6 +203,42 @@
}
}
diff --git a/packages/glibc/2.16.0/180-resolv-dynamic.patch b/packages/glibc/2.14.1/0013-resolv-dynamic.patch
index e916bce..fcc2f80 100644
--- a/packages/glibc/2.16.0/180-resolv-dynamic.patch
+++ b/packages/glibc/2.14.1/0013-resolv-dynamic.patch
@@ -5,9 +5,12 @@ already running get the updated information.
http://bugs.gentoo.org/177416
-diff -durN glibc-2.13.orig/resolv/res_libc.c glibc-2.13/resolv/res_libc.c
---- glibc-2.13.orig/resolv/res_libc.c 2009-02-07 05:27:42.000000000 +0100
-+++ glibc-2.13/resolv/res_libc.c 2009-11-13 00:49:59.000000000 +0100
+---
+ resolv/res_libc.c | 15 +++++++++++++++
+ 1 file changed, 15 insertions(+)
+
+--- a/resolv/res_libc.c
++++ b/resolv/res_libc.c
@@ -22,6 +22,7 @@
#include <arpa/nameser.h>
#include <resolv.h>
diff --git a/packages/glibc/2.12.1/190-localedef-mmap.patch b/packages/glibc/2.14.1/0014-localedef-mmap.patch
index b24ed80..74e586e 100644
--- a/packages/glibc/2.12.1/190-localedef-mmap.patch
+++ b/packages/glibc/2.14.1/0014-localedef-mmap.patch
@@ -7,9 +7,12 @@ http://bugs.gentoo.org/289615
used later with MMAP_FIXED | MMAP_SHARED to cope with different
alignment restrictions.
-diff -durN glibc-2.12.1.orig/locale/programs/locarchive.c glibc-2.12.1/locale/programs/locarchive.c
---- glibc-2.12.1.orig/locale/programs/locarchive.c 2009-04-27 16:07:47.000000000 +0200
-+++ glibc-2.12.1/locale/programs/locarchive.c 2009-11-13 00:50:01.000000000 +0100
+---
+ locale/programs/locarchive.c | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+--- a/locale/programs/locarchive.c
++++ b/locale/programs/locarchive.c
@@ -134,7 +134,7 @@
size_t reserved = RESERVE_MMAP_SIZE;
int xflags = 0;
diff --git a/packages/glibc/2.16.0/200-fadvise64_64.patch b/packages/glibc/2.14.1/0015-fadvise64_64.patch
index 71bca38..191d833 100644
--- a/packages/glibc/2.16.0/200-fadvise64_64.patch
+++ b/packages/glibc/2.14.1/0015-fadvise64_64.patch
@@ -3,9 +3,8 @@ ripped from Debian
sysdeps/unix/sysv/linux/posix_fadvise.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/posix_fadvise.c glibc-2.13/sysdeps/unix/sysv/linux/posix_fadvise.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/posix_fadvise.c 2003-08-17 02:36:22.000000000 +0200
-+++ glibc-2.13/sysdeps/unix/sysv/linux/posix_fadvise.c 2009-11-13 00:50:03.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/posix_fadvise.c
++++ b/sysdeps/unix/sysv/linux/posix_fadvise.c
@@ -35,6 +35,19 @@
return INTERNAL_SYSCALL_ERRNO (ret, err);
return 0;
diff --git a/packages/glibc/2.15/220-section-comments.patch b/packages/glibc/2.14.1/0016-section-comments.patch
index d717829..4718f22 100644
--- a/packages/glibc/2.15/220-section-comments.patch
+++ b/packages/glibc/2.14.1/0016-section-comments.patch
@@ -3,10 +3,13 @@ http://sources.redhat.com/ml/binutils/2004-04/msg00665.html
fixes building on some architectures (like m68k/arm/cris/etc...) because
it does the right thing
-diff -durN glibc-2.13.orig/include/libc-symbols.h glibc-2.13/include/libc-symbols.h
---- glibc-2.13.orig/include/libc-symbols.h 2009-03-14 00:51:46.000000000 +0100
-+++ glibc-2.13/include/libc-symbols.h 2009-11-13 00:50:07.000000000 +0100
-@@ -239,12 +239,12 @@
+---
+ include/libc-symbols.h | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+--- a/include/libc-symbols.h
++++ b/include/libc-symbols.h
+@@ -240,12 +240,12 @@
# define __make_section_unallocated(section_string)
# endif
diff --git a/packages/glibc/2.13/230-no-inline-gmon.patch b/packages/glibc/2.14.1/0017-no-inline-gmon.patch
index fa33c2b..ed02704 100644
--- a/packages/glibc/2.13/230-no-inline-gmon.patch
+++ b/packages/glibc/2.14.1/0017-no-inline-gmon.patch
@@ -19,12 +19,12 @@ Kazu Hirata
* sysdeps/generic/initfini.c (call_gmon_start): Add
__attribute__ ((noinline)).
-Index: sysdeps/generic/initfini.c
-===================================================================
+---
+ sysdeps/generic/initfini.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
-diff -durN glibc-2.13.orig/sysdeps/generic/initfini.c glibc-2.13/sysdeps/generic/initfini.c
---- glibc-2.13.orig/sysdeps/generic/initfini.c 2007-06-17 20:02:40.000000000 +0200
-+++ glibc-2.13/sysdeps/generic/initfini.c 2009-11-13 00:50:09.000000000 +0100
+--- a/sysdeps/generic/initfini.c
++++ b/sysdeps/generic/initfini.c
@@ -70,7 +70,7 @@
/* The beginning of _init: */
asm ("\n/*@_init_PROLOG_BEGINS*/");
diff --git a/packages/glibc/2.13/260-assume-pipe2.patch b/packages/glibc/2.14.1/0018-assume-pipe2.patch
index 42e8f4e..0074ea6 100644
--- a/packages/glibc/2.13/260-assume-pipe2.patch
+++ b/packages/glibc/2.14.1/0018-assume-pipe2.patch
@@ -20,9 +20,12 @@ __have_sock_cloexec and __have_pipe2 to true. but if glibc was built against
older kernel headers where __NR_pipe2 does not exist, glibc will have a ENOSYS
stub for it. so popen() will always fail as glibc assumes pipe2() works.
-diff -durN glibc-2.13.orig/socket/have_sock_cloexec.c glibc-2.13/socket/have_sock_cloexec.c
---- glibc-2.13.orig/socket/have_sock_cloexec.c 2008-07-25 18:46:23.000000000 +0200
-+++ glibc-2.13/socket/have_sock_cloexec.c 2009-11-13 00:50:15.000000000 +0100
+---
+ socket/have_sock_cloexec.c | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/socket/have_sock_cloexec.c
++++ b/socket/have_sock_cloexec.c
@@ -16,9 +16,14 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
diff --git a/packages/glibc/2.15/270-china.patch b/packages/glibc/2.14.1/0019-china.patch
index 41d7759..b323cf6 100644
--- a/packages/glibc/2.15/270-china.patch
+++ b/packages/glibc/2.14.1/0019-china.patch
@@ -1,8 +1,11 @@
-diff -durN glibc-2.13.orig/localedata/locales/zh_TW glibc-2.13/localedata/locales/zh_TW
---- glibc-2.13.orig/localedata/locales/zh_TW 2004-11-01 00:42:28.000000000 +0100
-+++ glibc-2.13/localedata/locales/zh_TW 2009-11-13 00:50:17.000000000 +0100
+---
+ localedata/locales/zh_TW | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+--- a/localedata/locales/zh_TW
++++ b/localedata/locales/zh_TW
@@ -1,7 +1,7 @@
comment_char %
escape_char /
diff --git a/packages/glibc/2.15/280-new-valencian-locale.patch b/packages/glibc/2.14.1/0020-new-valencian-locale.patch
index 4cdd108..fab1ee3 100644
--- a/packages/glibc/2.15/280-new-valencian-locale.patch
+++ b/packages/glibc/2.14.1/0020-new-valencian-locale.patch
@@ -1,10 +1,14 @@
http://bugs.gentoo.org/show_bug.cgi?id=131815
http://sourceware.org/bugzilla/show_bug.cgi?id=2522
-diff -durN glibc-2.13.orig/localedata/SUPPORTED glibc-2.13/localedata/SUPPORTED
---- glibc-2.13.orig/localedata/SUPPORTED 2009-04-18 10:43:52.000000000 +0200
-+++ glibc-2.13/localedata/SUPPORTED 2009-11-13 00:50:20.000000000 +0100
-@@ -72,6 +72,8 @@
+---
+ localedata/SUPPORTED | 2
+ localedata/locales/ca_ES@valencia | 96 ++++++++++++++++++++++++++++++++++++++
+ 2 files changed, 98 insertions(+)
+
+--- a/localedata/SUPPORTED
++++ b/localedata/SUPPORTED
+@@ -73,6 +73,8 @@
ca_ES.UTF-8/UTF-8 \
ca_ES/ISO-8859-1 \
ca_ES@euro/ISO-8859-15 \
@@ -13,9 +17,8 @@ diff -durN glibc-2.13.orig/localedata/SUPPORTED glibc-2.13/localedata/SUPPORTED
ca_FR.UTF-8/UTF-8 \
ca_FR/ISO-8859-15 \
ca_IT.UTF-8/UTF-8 \
-diff -durN glibc-2.13.orig/localedata/locales/ca_ES@valencia glibc-2.13/localedata/locales/ca_ES@valencia
---- glibc-2.13.orig/localedata/locales/ca_ES@valencia 1970-01-01 01:00:00.000000000 +0100
-+++ glibc-2.13/localedata/locales/ca_ES@valencia 2009-11-13 00:50:20.000000000 +0100
+--- /dev/null
++++ b/localedata/locales/ca_ES@valencia
@@ -0,0 +1,96 @@
+comment_char %
+escape_char /
diff --git a/packages/glibc/2.12.1/300-macos-cross-rpcgen.patch b/packages/glibc/2.14.1/0021-macos-cross-rpcgen.patch
index e654644..b439b0f 100644
--- a/packages/glibc/2.12.1/300-macos-cross-rpcgen.patch
+++ b/packages/glibc/2.14.1/0021-macos-cross-rpcgen.patch
@@ -14,11 +14,13 @@ Date: Sat Sep 7 00:01:08 2013 +0800
Signed-off-by: Jia Liu <proljc@gmail.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
-diff --git a/sunrpc/rpc/types.h b/sunrpc/rpc/types.h
-index 3dca5c4..beded52 100644
+---
+ sunrpc/rpc/types.h | 5 +++++
+ 1 file changed, 5 insertions(+)
+
--- a/sunrpc/rpc/types.h
+++ b/sunrpc/rpc/types.h
-@@ -69,6 +69,11 @@ typedef unsigned long rpcport_t;
+@@ -69,6 +69,11 @@
#include <sys/types.h>
#endif
diff --git a/packages/glibc/2.15/300-nscd-one-fork.patch b/packages/glibc/2.14.1/0022-nscd-one-fork.patch
index adc9b3f..47217b3 100644
--- a/packages/glibc/2.15/300-nscd-one-fork.patch
+++ b/packages/glibc/2.14.1/0022-nscd-one-fork.patch
@@ -2,9 +2,12 @@ only fork one to assist in stop-start-daemon assumptions about daemon behavior
http://bugs.gentoo.org/190785
-diff -durN glibc-2.13.orig/nscd/nscd.c glibc-2.13/nscd/nscd.c
---- glibc-2.13.orig/nscd/nscd.c 2009-02-06 21:10:27.000000000 +0100
-+++ glibc-2.13/nscd/nscd.c 2009-11-13 00:50:24.000000000 +0100
+---
+ nscd/nscd.c | 12 +++---------
+ 1 file changed, 3 insertions(+), 9 deletions(-)
+
+--- a/nscd/nscd.c
++++ b/nscd/nscd.c
@@ -182,6 +182,9 @@
if (pid != 0)
exit (0);
diff --git a/packages/glibc/2.13/310-hppa-nptl-carlos.patch b/packages/glibc/2.14.1/0023-hppa-nptl-carlos.patch
index 4c028b2..a385a6b 100644
--- a/packages/glibc/2.13/310-hppa-nptl-carlos.patch
+++ b/packages/glibc/2.14.1/0023-hppa-nptl-carlos.patch
@@ -1,8 +1,17 @@
-diff -durN glibc-2.13.orig/elf/rtld.c glibc-2.13/elf/rtld.c
---- glibc-2.13.orig/elf/rtld.c 2009-04-17 02:00:08.000000000 +0200
-+++ glibc-2.13/elf/rtld.c 2009-11-13 00:50:26.000000000 +0100
+---
+ elf/rtld.c | 10 +++++-----
+ include/atomic.h | 26 +++++++++++++-------------
+ nptl/Makefile | 35 ++++++++++++++++++++++++++++++++---
+ nptl/pthread_barrier_wait.c | 2 +-
+ nptl/sysdeps/pthread/Makefile | 2 ++
+ stdio-common/Makefile | 2 +-
+ sunrpc/clnt_udp.c | 2 +-
+ 7 files changed, 55 insertions(+), 24 deletions(-)
+
+--- a/elf/rtld.c
++++ b/elf/rtld.c
@@ -392,14 +392,14 @@
know it is available. We do not have to clear the memory if we
do not have to use the temporary bootstrap_map. Global variables
@@ -23,9 +32,8 @@ diff -durN glibc-2.13.orig/elf/rtld.c glibc-2.13/elf/rtld.c
# endif
# if USE___THREAD
bootstrap_map.l_tls_modid = 0;
-diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
---- glibc-2.13.orig/include/atomic.h 2009-02-09 00:49:53.000000000 +0100
-+++ glibc-2.13/include/atomic.h 2009-11-13 00:50:26.000000000 +0100
+--- a/include/atomic.h
++++ b/include/atomic.h
@@ -185,7 +185,7 @@
__typeof (*(mem)) __atg5_value = (newvalue); \
\
@@ -143,9 +151,8 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
while (__builtin_expect \
(atomic_compare_and_exchange_bool_acq (__atg19_memp, \
__atg19_old | __atg19_mask,\
-diff -durN glibc-2.13.orig/nptl/Makefile glibc-2.13/nptl/Makefile
---- glibc-2.13.orig/nptl/Makefile 2008-11-12 14:38:23.000000000 +0100
-+++ glibc-2.13/nptl/Makefile 2009-11-13 00:50:26.000000000 +0100
+--- a/nptl/Makefile
++++ b/nptl/Makefile
@@ -265,9 +265,9 @@
# Files which must not be linked with libpthread.
tests-nolibpthread = tst-unload
@@ -195,9 +202,8 @@ diff -durN glibc-2.13.orig/nptl/Makefile glibc-2.13/nptl/Makefile
CFLAGS-tst-align.c += $(stack-align-test-flags)
CFLAGS-tst-align3.c += $(stack-align-test-flags)
CFLAGS-tst-initializers1.c = -W -Wall -Werror
-diff -durN glibc-2.13.orig/nptl/pthread_barrier_wait.c glibc-2.13/nptl/pthread_barrier_wait.c
---- glibc-2.13.orig/nptl/pthread_barrier_wait.c 2007-08-01 06:18:50.000000000 +0200
-+++ glibc-2.13/nptl/pthread_barrier_wait.c 2009-11-13 00:50:26.000000000 +0100
+--- a/nptl/pthread_barrier_wait.c
++++ b/nptl/pthread_barrier_wait.c
@@ -64,7 +64,7 @@
do
lll_futex_wait (&ibarrier->curr_event, event,
@@ -207,9 +213,8 @@ diff -durN glibc-2.13.orig/nptl/pthread_barrier_wait.c glibc-2.13/nptl/pthread_b
}
/* Make sure the init_count is stored locally or in a register. */
-diff -durN glibc-2.13.orig/nptl/sysdeps/pthread/Makefile glibc-2.13/nptl/sysdeps/pthread/Makefile
---- glibc-2.13.orig/nptl/sysdeps/pthread/Makefile 2006-02-28 08:09:41.000000000 +0100
-+++ glibc-2.13/nptl/sysdeps/pthread/Makefile 2009-11-13 00:50:26.000000000 +0100
+--- a/nptl/sysdeps/pthread/Makefile
++++ b/nptl/sysdeps/pthread/Makefile
@@ -33,7 +33,9 @@
ifeq ($(have-forced-unwind),yes)
@@ -220,9 +225,8 @@ diff -durN glibc-2.13.orig/nptl/sysdeps/pthread/Makefile glibc-2.13/nptl/sysdeps
endif
endif
-diff -durN glibc-2.13.orig/stdio-common/Makefile glibc-2.13/stdio-common/Makefile
---- glibc-2.13.orig/stdio-common/Makefile 2009-04-11 07:29:56.000000000 +0200
-+++ glibc-2.13/stdio-common/Makefile 2009-11-13 00:50:26.000000000 +0100
+--- a/stdio-common/Makefile
++++ b/stdio-common/Makefile
@@ -82,7 +82,7 @@
$(SHELL) -e tst-printf.sh $(common-objpfx) '$(run-program-prefix)'
endif
@@ -232,10 +236,9 @@ diff -durN glibc-2.13.orig/stdio-common/Makefile glibc-2.13/stdio-common/Makefil
CFLAGS-vfwprintf.c = -Wno-uninitialized
CFLAGS-tst-printf.c = -Wno-format
CFLAGS-tstdiomisc.c = -Wno-format
-diff -durN glibc-2.13.orig/sunrpc/clnt_udp.c glibc-2.13/sunrpc/clnt_udp.c
---- glibc-2.13.orig/sunrpc/clnt_udp.c 2008-07-26 10:42:44.000000000 +0200
-+++ glibc-2.13/sunrpc/clnt_udp.c 2009-11-13 00:50:26.000000000 +0100
-@@ -456,7 +456,7 @@
+--- a/sunrpc/clnt_udp.c
++++ b/sunrpc/clnt_udp.c
+@@ -463,7 +463,7 @@
while (inlen < 0 && errno == EINTR);
if (inlen < 0)
{
diff --git a/packages/glibc/2.14.1/340-dl_execstack-PaX-support.patch b/packages/glibc/2.14.1/0024-dl_execstack-PaX-support.patch
index 2402af0..7b56549 100644
--- a/packages/glibc/2.14.1/340-dl_execstack-PaX-support.patch
+++ b/packages/glibc/2.14.1/0024-dl_execstack-PaX-support.patch
@@ -8,10 +8,14 @@
Patch also NPTL. Bug #116086. <kevquinn@gentoo.org> (20 Dec 2005).
-diff -durN glibc-2.13.orig/nptl/allocatestack.c glibc-2.13/nptl/allocatestack.c
---- glibc-2.13.orig/nptl/allocatestack.c 2009-01-29 21:34:16.000000000 +0100
-+++ glibc-2.13/nptl/allocatestack.c 2009-11-13 00:50:33.000000000 +0100
-@@ -329,7 +329,8 @@
+---
+ nptl/allocatestack.c | 3 ++-
+ sysdeps/unix/sysv/linux/dl-execstack.c | 19 ++++++++++++++++---
+ 2 files changed, 18 insertions(+), 4 deletions(-)
+
+--- a/nptl/allocatestack.c
++++ b/nptl/allocatestack.c
+@@ -335,7 +335,8 @@
# error "Define either _STACK_GROWS_DOWN or _STACK_GROWS_UP"
#endif
if (mprotect (stack, len, PROT_READ | PROT_WRITE | PROT_EXEC) != 0)
@@ -21,9 +25,8 @@ diff -durN glibc-2.13.orig/nptl/allocatestack.c glibc-2.13/nptl/allocatestack.c
return 0;
}
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/dl-execstack.c glibc-2.13/sysdeps/unix/sysv/linux/dl-execstack.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/dl-execstack.c 2006-01-08 09:21:15.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/dl-execstack.c 2009-11-13 00:50:33.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/dl-execstack.c
++++ b/sysdeps/unix/sysv/linux/dl-execstack.c
@@ -63,7 +63,10 @@
else
# endif
diff --git a/packages/glibc/2.16.0/350-pre20040117-pt_pax.patch b/packages/glibc/2.14.1/0025-pre20040117-pt_pax.patch
index f8f6b83..ec17d24 100644
--- a/packages/glibc/2.16.0/350-pre20040117-pt_pax.patch
+++ b/packages/glibc/2.14.1/0025-pre20040117-pt_pax.patch
@@ -1,8 +1,11 @@
-diff -durN glibc-2.13.orig/elf/elf.h glibc-2.13/elf/elf.h
---- glibc-2.13.orig/elf/elf.h 2009-04-15 02:15:54.000000000 +0200
-+++ glibc-2.13/elf/elf.h 2009-11-13 00:50:35.000000000 +0100
+---
+ elf/elf.h | 13 +++++++++++++
+ 1 file changed, 13 insertions(+)
+
+--- a/elf/elf.h
++++ b/elf/elf.h
@@ -580,6 +580,7 @@
#define PT_GNU_EH_FRAME 0x6474e550 /* GCC .eh_frame_hdr segment */
#define PT_GNU_STACK 0x6474e551 /* Indicates stack executability */
diff --git a/packages/glibc/2.13/360-tests-sandbox-libdl-paths.patch b/packages/glibc/2.14.1/0026-tests-sandbox-libdl-paths.patch
index 9f78c52..1c4ee59 100644
--- a/packages/glibc/2.13/360-tests-sandbox-libdl-paths.patch
+++ b/packages/glibc/2.14.1/0026-tests-sandbox-libdl-paths.patch
@@ -15,9 +15,23 @@ Fix by Wormo
http://bugs.gentoo.org/56898
-diff -durN glibc-2.13.orig/grp/tst_fgetgrent.sh glibc-2.13/grp/tst_fgetgrent.sh
---- glibc-2.13.orig/grp/tst_fgetgrent.sh 2001-07-06 06:54:46.000000000 +0200
-+++ glibc-2.13/grp/tst_fgetgrent.sh 2009-11-13 00:50:37.000000000 +0100
+---
+ grp/tst_fgetgrent.sh | 3 ++-
+ iconvdata/run-iconv-test.sh | 2 +-
+ iconvdata/tst-table.sh | 5 ++++-
+ intl/tst-codeset.sh | 3 +++
+ intl/tst-gettext.sh | 5 ++++-
+ intl/tst-gettext2.sh | 5 ++++-
+ intl/tst-translit.sh | 5 ++++-
+ malloc/tst-mtrace.sh | 5 ++++-
+ nptl/tst-tls6.sh | 4 ++--
+ posix/globtest.sh | 2 +-
+ posix/tst-getconf.sh | 5 ++++-
+ posix/wordexp-tst.sh | 5 ++++-
+ 12 files changed, 37 insertions(+), 12 deletions(-)
+
+--- a/grp/tst_fgetgrent.sh
++++ b/grp/tst_fgetgrent.sh
@@ -24,7 +24,8 @@
rtld_installed_name=$1; shift
@@ -28,9 +42,8 @@ diff -durN glibc-2.13.orig/grp/tst_fgetgrent.sh glibc-2.13/grp/tst_fgetgrent.sh
result=0
-diff -durN glibc-2.13.orig/iconvdata/run-iconv-test.sh glibc-2.13/iconvdata/run-iconv-test.sh
---- glibc-2.13.orig/iconvdata/run-iconv-test.sh 2008-05-15 03:59:44.000000000 +0200
-+++ glibc-2.13/iconvdata/run-iconv-test.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/iconvdata/run-iconv-test.sh
++++ b/iconvdata/run-iconv-test.sh
@@ -34,7 +34,7 @@
export GCONV_PATH
@@ -40,9 +53,8 @@ diff -durN glibc-2.13.orig/iconvdata/run-iconv-test.sh glibc-2.13/iconvdata/run-
# How the start the iconv(1) program.
ICONV='$codir/elf/ld.so --library-path $LIBPATH --inhibit-rpath ${from}.so \
-diff -durN glibc-2.13.orig/iconvdata/tst-table.sh glibc-2.13/iconvdata/tst-table.sh
---- glibc-2.13.orig/iconvdata/tst-table.sh 2002-04-24 23:39:35.000000000 +0200
-+++ glibc-2.13/iconvdata/tst-table.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/iconvdata/tst-table.sh
++++ b/iconvdata/tst-table.sh
@@ -59,8 +59,11 @@
irreversible=${charset}.irreversible
fi
@@ -56,9 +68,8 @@ diff -durN glibc-2.13.orig/iconvdata/tst-table.sh glibc-2.13/iconvdata/tst-table
${objpfx}tst-table-from ${charset} \
> ${objpfx}tst-${charset}.table
-diff -durN glibc-2.13.orig/intl/tst-codeset.sh glibc-2.13/intl/tst-codeset.sh
---- glibc-2.13.orig/intl/tst-codeset.sh 2005-04-06 04:18:35.000000000 +0200
-+++ glibc-2.13/intl/tst-codeset.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-codeset.sh
++++ b/intl/tst-codeset.sh
@@ -37,6 +37,9 @@
LOCPATH=${common_objpfx}localedata
export LOCPATH
@@ -69,9 +80,8 @@ diff -durN glibc-2.13.orig/intl/tst-codeset.sh glibc-2.13/intl/tst-codeset.sh
${common_objpfx}elf/ld.so --library-path $common_objpfx \
${objpfx}tst-codeset > ${objpfx}tst-codeset.out
-diff -durN glibc-2.13.orig/intl/tst-gettext.sh glibc-2.13/intl/tst-gettext.sh
---- glibc-2.13.orig/intl/tst-gettext.sh 2004-08-15 21:28:18.000000000 +0200
-+++ glibc-2.13/intl/tst-gettext.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-gettext.sh
++++ b/intl/tst-gettext.sh
@@ -51,9 +51,12 @@
LOCPATH=${common_objpfx}localedata
export LOCPATH
@@ -86,9 +96,8 @@ diff -durN glibc-2.13.orig/intl/tst-gettext.sh glibc-2.13/intl/tst-gettext.sh
${objpfx}tst-gettext > ${objpfx}tst-gettext.out ${objpfx}domaindir
exit $?
-diff -durN glibc-2.13.orig/intl/tst-gettext2.sh glibc-2.13/intl/tst-gettext2.sh
---- glibc-2.13.orig/intl/tst-gettext2.sh 2005-05-04 19:54:48.000000000 +0200
-+++ glibc-2.13/intl/tst-gettext2.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-gettext2.sh
++++ b/intl/tst-gettext2.sh
@@ -65,8 +65,11 @@
LOCPATH=${objpfx}domaindir
export LOCPATH
@@ -102,9 +111,8 @@ diff -durN glibc-2.13.orig/intl/tst-gettext2.sh glibc-2.13/intl/tst-gettext2.sh
${objpfx}tst-gettext2 > ${objpfx}tst-gettext2.out ${objpfx}domaindir &&
cmp ${objpfx}tst-gettext2.out - <<EOF
String1 - Lang1: 1st string
-diff -durN glibc-2.13.orig/intl/tst-translit.sh glibc-2.13/intl/tst-translit.sh
---- glibc-2.13.orig/intl/tst-translit.sh 2005-05-04 19:56:10.000000000 +0200
-+++ glibc-2.13/intl/tst-translit.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-translit.sh
++++ b/intl/tst-translit.sh
@@ -36,7 +36,10 @@
LOCPATH=${common_objpfx}localedata
export LOCPATH
@@ -117,9 +125,8 @@ diff -durN glibc-2.13.orig/intl/tst-translit.sh glibc-2.13/intl/tst-translit.sh
${objpfx}tst-translit > ${objpfx}tst-translit.out ${objpfx}domaindir
exit $?
-diff -durN glibc-2.13.orig/malloc/tst-mtrace.sh glibc-2.13/malloc/tst-mtrace.sh
---- glibc-2.13.orig/malloc/tst-mtrace.sh 2005-10-15 01:40:35.000000000 +0200
-+++ glibc-2.13/malloc/tst-mtrace.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/malloc/tst-mtrace.sh
++++ b/malloc/tst-mtrace.sh
@@ -24,9 +24,12 @@
status=0
trap "rm -f ${common_objpfx}malloc/tst-mtrace.leak; exit 1" 1 2 15
@@ -134,9 +141,8 @@ diff -durN glibc-2.13.orig/malloc/tst-mtrace.sh glibc-2.13/malloc/tst-mtrace.sh
${common_objpfx}malloc/tst-mtrace || status=1
if test $status -eq 0 && test -f ${common_objpfx}malloc/mtrace; then
-diff -durN glibc-2.13.orig/nptl/tst-tls6.sh glibc-2.13/nptl/tst-tls6.sh
---- glibc-2.13.orig/nptl/tst-tls6.sh 2003-09-03 00:02:59.000000000 +0200
-+++ glibc-2.13/nptl/tst-tls6.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/nptl/tst-tls6.sh
++++ b/nptl/tst-tls6.sh
@@ -5,8 +5,8 @@
rtld_installed_name=$1; shift
logfile=$common_objpfx/nptl/tst-tls6.out
@@ -148,9 +154,8 @@ diff -durN glibc-2.13.orig/nptl/tst-tls6.sh glibc-2.13/nptl/tst-tls6.sh
tst_tls5="${elf_objpfx}${rtld_installed_name} --library-path ${library_path} \
${common_objpfx}/nptl/tst-tls5"
-diff -durN glibc-2.13.orig/posix/globtest.sh glibc-2.13/posix/globtest.sh
---- glibc-2.13.orig/posix/globtest.sh 2008-12-06 07:05:39.000000000 +0100
-+++ glibc-2.13/posix/globtest.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/posix/globtest.sh
++++ b/posix/globtest.sh
@@ -18,7 +18,7 @@
esac
@@ -160,9 +165,8 @@ diff -durN glibc-2.13.orig/posix/globtest.sh glibc-2.13/posix/globtest.sh
# Since we use `sort' we must make sure to use the same locale everywhere.
LC_ALL=C
-diff -durN glibc-2.13.orig/posix/tst-getconf.sh glibc-2.13/posix/tst-getconf.sh
---- glibc-2.13.orig/posix/tst-getconf.sh 2002-09-01 13:11:25.000000000 +0200
-+++ glibc-2.13/posix/tst-getconf.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/posix/tst-getconf.sh
++++ b/posix/tst-getconf.sh
@@ -10,7 +10,10 @@
else
rtld_installed_name=$1; shift
@@ -175,9 +179,8 @@ diff -durN glibc-2.13.orig/posix/tst-getconf.sh glibc-2.13/posix/tst-getconf.sh
}
fi
-diff -durN glibc-2.13.orig/posix/wordexp-tst.sh glibc-2.13/posix/wordexp-tst.sh
---- glibc-2.13.orig/posix/wordexp-tst.sh 2000-10-20 18:23:30.000000000 +0200
-+++ glibc-2.13/posix/wordexp-tst.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/posix/wordexp-tst.sh
++++ b/posix/wordexp-tst.sh
@@ -19,8 +19,11 @@
"
export IFS
diff --git a/packages/glibc/2.16.0/380-dont-build-timezone.patch b/packages/glibc/2.14.1/0027-dont-build-timezone.patch
index 11c358e..9bbcde3 100644
--- a/packages/glibc/2.16.0/380-dont-build-timezone.patch
+++ b/packages/glibc/2.14.1/0027-dont-build-timezone.patch
@@ -1,9 +1,12 @@
timezone data has been split into the package sys-libs/timezone-data
-diff -durN glibc-2.13.orig/Makeconfig glibc-2.13/Makeconfig
---- glibc-2.13.orig/Makeconfig 2009-11-13 00:50:13.000000000 +0100
-+++ glibc-2.13/Makeconfig 2009-11-13 00:50:41.000000000 +0100
-@@ -944,7 +944,7 @@
+---
+ Makeconfig | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/Makeconfig
++++ b/Makeconfig
+@@ -946,7 +946,7 @@
stdlib stdio-common libio malloc string wcsmbs time dirent \
grp pwd posix io termios resource misc socket sysvipc gmon \
gnulib iconv iconvdata wctype manual shadow gshadow po argp \
diff --git a/packages/glibc/2.16.0/400-alpha-xstat.patch b/packages/glibc/2.14.1/0028-alpha-xstat.patch
index 6e4ab8f..4fa9517 100644
--- a/packages/glibc/2.16.0/400-alpha-xstat.patch
+++ b/packages/glibc/2.14.1/0028-alpha-xstat.patch
@@ -1,6 +1,9 @@
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h 2009-05-09 08:54:20.000000000 +0200
-+++ glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:50:45.000000000 +0100
+---
+ sysdeps/unix/sysv/linux/kernel-features.h | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
@@ -386,6 +386,11 @@
# define __ASSUME_GETDENTS32_D_TYPE 1
#endif
diff --git a/packages/glibc/2.14.1/0029-alpha-creat.patch b/packages/glibc/2.14.1/0029-alpha-creat.patch
new file mode 100644
index 0000000..6ef5278
--- /dev/null
+++ b/packages/glibc/2.14.1/0029-alpha-creat.patch
@@ -0,0 +1,17 @@
+alpha does not have a __NR_creat
+
+http://bugs.gentoo.org/227275
+http://sourceware.org/bugzilla/show_bug.cgi?id=6650
+
+---
+ sysdeps/unix/sysv/linux/wordsize-64/creat64.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+--- a/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
++++ b/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
+@@ -1 +1,5 @@
+ /* Defined as alias for the syscall. */
++#include <sysdep.h>
++#ifndef __NR_creat
++#include "../../../../../io/creat64.c"
++#endif
diff --git a/packages/glibc/2.13/490-alpha_alpha-add-fdatasync-support.patch b/packages/glibc/2.14.1/0030-alpha_alpha-add-fdatasync-support.patch
index 372f34c..eeef22a 100644
--- a/packages/glibc/2.13/490-alpha_alpha-add-fdatasync-support.patch
+++ b/packages/glibc/2.14.1/0030-alpha_alpha-add-fdatasync-support.patch
@@ -13,10 +13,9 @@
sysdeps/unix/sysv/linux/syscalls.list | 1
4 files changed, 76 insertions(+), 1 deletion(-)
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/Makefile glibc-2.13/sysdeps/unix/sysv/linux/Makefile
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/Makefile 2009-03-02 17:15:13.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/Makefile 2009-11-13 00:51:04.000000000 +0100
-@@ -20,6 +20,7 @@
+--- a/sysdeps/unix/sysv/linux/Makefile
++++ b/sysdeps/unix/sysv/linux/Makefile
+@@ -21,6 +21,7 @@
setfsuid setfsgid makedev epoll_pwait signalfd \
eventfd eventfd_read eventfd_write prlimit
@@ -24,9 +23,8 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/Makefile glibc-2.13/sysdeps/u
CFLAGS-gethostid.c = -fexceptions
sysdep_headers += sys/mount.h sys/acct.h sys/sysctl.h \
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/fdatasync.c glibc-2.13/sysdeps/unix/sysv/linux/fdatasync.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/fdatasync.c 1970-01-01 01:00:00.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/fdatasync.c 2009-11-13 00:51:04.000000000 +0100
+--- /dev/null
++++ b/sysdeps/unix/sysv/linux/fdatasync.c
@@ -0,0 +1,69 @@
+/* fdatasync -- synchronize at least the data part of a file with
+ the underlying media. Linux version.
@@ -97,9 +95,8 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/fdatasync.c glibc-2.13/sysdep
+
+weak_alias (__fdatasync, fdatasync)
+
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:50:45.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:51:04.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
@@ -459,6 +459,12 @@
# define __ASSUME_FUTEX_LOCK_PI 1
#endif
@@ -113,10 +110,9 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.13/
/* Support for utimensat syscall was added in 2.6.22, on SH
only after 2.6.22-rc1. */
#if __LINUX_KERNEL_VERSION >= 0x020616 \
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/syscalls.list glibc-2.13/sysdeps/unix/sysv/linux/syscalls.list
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/syscalls.list 2008-08-02 01:29:08.000000000 +0200
-+++ glibc-2.13/sysdeps/unix/sysv/linux/syscalls.list 2009-11-13 00:51:04.000000000 +0100
-@@ -11,7 +11,6 @@
+--- a/sysdeps/unix/sysv/linux/syscalls.list
++++ b/sysdeps/unix/sysv/linux/syscalls.list
+@@ -12,7 +12,6 @@
epoll_create1 EXTRA epoll_create1 i:i epoll_create1
epoll_ctl EXTRA epoll_ctl i:iiip epoll_ctl
epoll_wait EXTRA epoll_wait Ci:ipii epoll_wait
diff --git a/packages/glibc/2.16.0/560-ppc-atomic.patch b/packages/glibc/2.14.1/0031-ppc-atomic.patch
index ee1cb90..a38c1c5 100644
--- a/packages/glibc/2.16.0/560-ppc-atomic.patch
+++ b/packages/glibc/2.14.1/0031-ppc-atomic.patch
@@ -1,14 +1,13 @@
sniped from suse
-Index: sysdeps/powerpc/bits/atomic.h
-===================================================================
-RCS file: /cvs/glibc/libc/sysdeps/powerpc/bits/atomic.h,v
-retrieving revision 1.17
-diff -u -a -p -r1.17 atomic.h
+---
+ sysdeps/powerpc/bits/atomic.h | 66 ++++++++++-----------
+ sysdeps/powerpc/powerpc32/bits/atomic.h | 16 ++---
+ sysdeps/powerpc/powerpc64/bits/atomic.h | 98 ++++++++++++++++----------------
+ 3 files changed, 90 insertions(+), 90 deletions(-)
-diff -durN glibc-2.13.orig/sysdeps/powerpc/bits/atomic.h glibc-2.13/sysdeps/powerpc/bits/atomic.h
---- glibc-2.13.orig/sysdeps/powerpc/bits/atomic.h 2007-03-26 22:15:28.000000000 +0200
-+++ glibc-2.13/sysdeps/powerpc/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
+--- a/sysdeps/powerpc/bits/atomic.h
++++ b/sysdeps/powerpc/bits/atomic.h
@@ -85,14 +85,14 @@
__typeof (*(mem)) __tmp; \
__typeof (mem) __memp = (mem); \
@@ -151,9 +150,8 @@ diff -durN glibc-2.13.orig/sysdeps/powerpc/bits/atomic.h glibc-2.13/sysdeps/powe
: "cr0", "memory"); \
__val; \
})
-diff -durN glibc-2.13.orig/sysdeps/powerpc/powerpc32/bits/atomic.h glibc-2.13/sysdeps/powerpc/powerpc32/bits/atomic.h
---- glibc-2.13.orig/sysdeps/powerpc/powerpc32/bits/atomic.h 2007-03-26 22:15:45.000000000 +0200
-+++ glibc-2.13/sysdeps/powerpc/powerpc32/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
+--- a/sysdeps/powerpc/powerpc32/bits/atomic.h
++++ b/sysdeps/powerpc/powerpc32/bits/atomic.h
@@ -44,14 +44,14 @@
({ \
unsigned int __tmp; \
@@ -192,9 +190,8 @@ diff -durN glibc-2.13.orig/sysdeps/powerpc/powerpc32/bits/atomic.h glibc-2.13/sy
: "cr0", "memory"); \
__tmp != 0; \
})
-diff -durN glibc-2.13.orig/sysdeps/powerpc/powerpc64/bits/atomic.h glibc-2.13/sysdeps/powerpc/powerpc64/bits/atomic.h
---- glibc-2.13.orig/sysdeps/powerpc/powerpc64/bits/atomic.h 2007-03-26 22:16:03.000000000 +0200
-+++ glibc-2.13/sysdeps/powerpc/powerpc64/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
+--- a/sysdeps/powerpc/powerpc64/bits/atomic.h
++++ b/sysdeps/powerpc/powerpc64/bits/atomic.h
@@ -44,14 +44,14 @@
({ \
unsigned int __tmp, __tmp2; \
diff --git a/packages/glibc/2.16.0/630-mips_shn_undef-hack.patch b/packages/glibc/2.14.1/0032-mips_shn_undef-hack.patch
index 791d76c..a12c977 100644
--- a/packages/glibc/2.16.0/630-mips_shn_undef-hack.patch
+++ b/packages/glibc/2.14.1/0032-mips_shn_undef-hack.patch
@@ -1,10 +1,13 @@
-diff -durN glibc-2.13.orig/elf/dl-lookup.c glibc-2.13/elf/dl-lookup.c
---- glibc-2.13.orig/elf/dl-lookup.c 2009-03-30 23:14:32.000000000 +0200
-+++ glibc-2.13/elf/dl-lookup.c 2009-11-13 00:51:36.000000000 +0100
-@@ -301,6 +301,12 @@
+---
+ elf/dl-lookup.c | 6 ++++++
+ 1 file changed, 6 insertions(+)
+
+--- a/elf/dl-lookup.c
++++ b/elf/dl-lookup.c
+@@ -300,6 +300,12 @@
/* FALLTHROUGH */
case STB_GLOBAL:
- success:
+ success:
+#ifdef __mips__
+ /* HACK: MIPS marks its lazy evaluation stubs with SHN_UNDEF
+ symbols, we skip them. */
diff --git a/packages/glibc/2.12.1/640-alpha-atfcts.patch b/packages/glibc/2.14.1/0033-alpha-atfcts.patch
index 90a9d0d..2eff918 100644
--- a/packages/glibc/2.12.1/640-alpha-atfcts.patch
+++ b/packages/glibc/2.14.1/0033-alpha-atfcts.patch
@@ -1,5 +1,9 @@
---- glibc-2.12.1/sysdeps/unix/sysv/linux/kernel-features.h 2010-07-27 14:34:39.000000000 +0300
-+++ glibc-2.12.1/sysdeps/unix/sysv/linux/kernel-features.h.new 2011-03-10 18:54:37.686795979 +0200
+---
+ sysdeps/unix/sysv/linux/kernel-features.h | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
@@ -437,7 +437,8 @@
the code. On PPC they were introduced in 2.6.17-rc1,
on SH in 2.6.19-rc1. */
diff --git a/packages/glibc/2.15/650-syslog.patch b/packages/glibc/2.14.1/0034-syslog.patch
index c20cafc..a2d9722 100644
--- a/packages/glibc/2.15/650-syslog.patch
+++ b/packages/glibc/2.14.1/0034-syslog.patch
@@ -1,6 +1,9 @@
-diff -durN glibc-cvs-2.9.orig/misc/syslog.c glibc-cvs-2.9/misc/syslog.c
---- glibc-cvs-2.9.orig/misc/syslog.c 2009-06-01 10:16:50.000000000 +0200
-+++ glibc-cvs-2.9/misc/syslog.c 2009-06-01 10:17:20.000000000 +0200
+---
+ misc/syslog.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/misc/syslog.c
++++ b/misc/syslog.c
@@ -152,7 +152,7 @@
#define INTERNALLOG LOG_ERR|LOG_CONS|LOG_PERROR|LOG_PID
/* Check for invalid bits. */
diff --git a/packages/glibc/2.14.1/0035-debug-readlink_chk-readklinkat_chk.patch b/packages/glibc/2.14.1/0035-debug-readlink_chk-readklinkat_chk.patch
new file mode 100644
index 0000000..0b930f3
--- /dev/null
+++ b/packages/glibc/2.14.1/0035-debug-readlink_chk-readklinkat_chk.patch
@@ -0,0 +1,27 @@
+---
+ debug/readlink_chk.c | 2 +-
+ debug/readlinkat_chk.c | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+--- a/debug/readlink_chk.c
++++ b/debug/readlink_chk.c
+@@ -25,7 +25,7 @@
+
+
+ ssize_t
+-__readlink_chk (const char *path, void *buf, size_t len, size_t buflen)
++__readlink_chk (const char *path, char *buf, size_t len, size_t buflen)
+ {
+ if (len > buflen)
+ __chk_fail ();
+--- a/debug/readlinkat_chk.c
++++ b/debug/readlinkat_chk.c
+@@ -21,7 +21,7 @@
+
+
+ ssize_t
+-__readlinkat_chk (int fd, const char *path, void *buf, size_t len,
++__readlinkat_chk (int fd, const char *path, char *buf, size_t len,
+ size_t buflen)
+ {
+ if (len > buflen)
diff --git a/packages/glibc/2.14.1/900-cpuid-include.patch b/packages/glibc/2.14.1/0036-cpuid-include.patch
index 0b8db71..ac5c153 100644
--- a/packages/glibc/2.14.1/900-cpuid-include.patch
+++ b/packages/glibc/2.14.1/0036-cpuid-include.patch
@@ -17,9 +17,13 @@ Tested x86_64 (native).
Origin: http://sourceware.org/ml/libc-alpha/2012-03/msg00177.html
-diff -Nur glibc-2.14.1.orig/sysdeps/i386/configure glibc-2.14.1/sysdeps/i386/configure
---- glibc-2.14.1.orig/sysdeps/i386/configure 2011-10-07 20:48:55.000000000 +1100
-+++ glibc-2.14.1/sysdeps/i386/configure 2012-07-25 01:23:11.799118927 +1000
+---
+ sysdeps/i386/configure | 502 +---------------------------------------------
+ sysdeps/i386/configure.in | 5
+ 2 files changed, 17 insertions(+), 490 deletions(-)
+
+--- a/sysdeps/i386/configure
++++ b/sysdeps/i386/configure
@@ -16,23 +16,6 @@
as_fn_set_status $1
exit $1
@@ -610,9 +614,8 @@ diff -Nur glibc-2.14.1.orig/sysdeps/i386/configure glibc-2.14.1/sysdeps/i386/con
$as_echo_n "(cached) " >&6
else
if { ac_try='${CC-cc} -mno-vzeroupper -xc /dev/null -S -o /dev/null'
-diff -Nur glibc-2.14.1.orig/sysdeps/i386/configure.in glibc-2.14.1/sysdeps/i386/configure.in
---- glibc-2.14.1.orig/sysdeps/i386/configure.in 2011-10-07 20:48:55.000000000 +1100
-+++ glibc-2.14.1/sysdeps/i386/configure.in 2012-07-25 01:00:49.345025022 +1000
+--- a/sysdeps/i386/configure.in
++++ b/sysdeps/i386/configure.in
@@ -1,8 +1,9 @@
GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
# Local configure fragment for sysdeps/i386.
@@ -625,4 +628,3 @@ diff -Nur glibc-2.14.1.orig/sysdeps/i386/configure.in glibc-2.14.1/sysdeps/i386/
AC_CACHE_CHECK(if -g produces usable source locations for assembler-with-cpp,
libc_cv_cpp_asm_debuginfo, [dnl
-
diff --git a/packages/glibc/2.15/910-asm-i686.patch b/packages/glibc/2.14.1/0037-asm-i686.patch
index b049887..ea3c88a 100644
--- a/packages/glibc/2.15/910-asm-i686.patch
+++ b/packages/glibc/2.14.1/0037-asm-i686.patch
@@ -18,9 +18,13 @@ Description: Fixes the following build problem with GCC-4.5.0:
./sysdeps/i386/fpu/s_frexp.S:66: Error: junk `.get_pc_thunk.dx' after expression
make[2]: *** [/mnt/lfs/sources/libc-build/math/s_frexp.os] Error 1
-diff -Naur glibc-2.11.1.orig/nptl/sysdeps/pthread/pt-initfini.c glibc-2.11.1/nptl/sysdeps/pthread/pt-initfini.c
---- glibc-2.11.1.orig/nptl/sysdeps/pthread/pt-initfini.c 2009-12-08 20:10:20.000000000 +0000
-+++ glibc-2.11.1/nptl/sysdeps/pthread/pt-initfini.c 2010-04-17 11:34:06.882681001 +0000
+---
+ nptl/sysdeps/pthread/pt-initfini.c | 5 +++++
+ sysdeps/unix/sysv/linux/i386/sysdep.h | 4 ++++
+ 2 files changed, 9 insertions(+)
+
+--- a/nptl/sysdeps/pthread/pt-initfini.c
++++ b/nptl/sysdeps/pthread/pt-initfini.c
@@ -45,6 +45,11 @@
/* Embed an #include to pull in the alignment and .end directives. */
asm ("\n#include \"defs.h\"");
@@ -33,9 +37,8 @@ diff -Naur glibc-2.11.1.orig/nptl/sysdeps/pthread/pt-initfini.c glibc-2.11.1/npt
/* The initial common code ends here. */
asm ("\n/*@HEADER_ENDS*/");
-diff -Naur glibc-2.11.1.orig/sysdeps/unix/sysv/linux/i386/sysdep.h glibc-2.11.1/sysdeps/unix/sysv/linux/i386/sysdep.h
---- glibc-2.11.1.orig/sysdeps/unix/sysv/linux/i386/sysdep.h 2009-12-08 20:10:20.000000000 +0000
-+++ glibc-2.11.1/sysdeps/unix/sysv/linux/i386/sysdep.h 2010-04-17 11:34:06.882681001 +0000
+--- a/sysdeps/unix/sysv/linux/i386/sysdep.h
++++ b/sysdeps/unix/sysv/linux/i386/sysdep.h
@@ -29,6 +29,10 @@
#include <dl-sysdep.h>
#include <tls.h>
@@ -47,4 +50,3 @@ diff -Naur glibc-2.11.1.orig/sysdeps/unix/sysv/linux/i386/sysdep.h glibc-2.11.1/
/* For Linux we can use the system call table in the header file
/usr/include/asm/unistd.h
-
diff --git a/packages/glibc/2.12.1/920-fix-rpc_parse-format.patch b/packages/glibc/2.14.1/0038-fix-rpc_parse-format.patch
index 37e58da..341d541 100644
--- a/packages/glibc/2.12.1/920-fix-rpc_parse-format.patch
+++ b/packages/glibc/2.14.1/0038-fix-rpc_parse-format.patch
@@ -45,11 +45,13 @@ Date: Tue Nov 8 23:44:51 2016 +0000
[$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
[$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
-diff --git a/sunrpc/rpc_parse.c b/sunrpc/rpc_parse.c
-index 1a1df6d8c2..505a6554cf 100644
+---
+ sunrpc/rpc_parse.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
--- a/sunrpc/rpc_parse.c
+++ b/sunrpc/rpc_parse.c
-@@ -521,7 +521,7 @@ static void
+@@ -521,7 +521,7 @@
get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
{
token tok;
diff --git a/packages/glibc/2.14.1/940-nis-bogus-conditional.patch b/packages/glibc/2.14.1/0039-nis-bogus-conditional.patch
index 09b38cf..732b859 100644
--- a/packages/glibc/2.14.1/940-nis-bogus-conditional.patch
+++ b/packages/glibc/2.14.1/0039-nis-bogus-conditional.patch
@@ -47,11 +47,13 @@ Date: Wed Dec 21 23:44:01 2016 +0000
* nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
Compare name == NULL, not name != NULL.
-diff --git a/nis/nss_nisplus/nisplus-alias.c b/nis/nss_nisplus/nisplus-alias.c
-index 7f698b4e6d..cb5acce01d 100644
+---
+ nis/nss_nisplus/nisplus-alias.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
--- a/nis/nss_nisplus/nisplus-alias.c
+++ b/nis/nss_nisplus/nisplus-alias.c
-@@ -291,7 +291,7 @@ _nss_nisplus_getaliasbyname_r (const char *name, struct aliasent *alias,
+@@ -293,7 +293,7 @@
return status;
}
diff --git a/packages/glibc/2.14.1/950-initfini-ppc64.patch b/packages/glibc/2.14.1/0040-initfini-ppc64.patch
index 87f8d23..247c103 100644
--- a/packages/glibc/2.14.1/950-initfini-ppc64.patch
+++ b/packages/glibc/2.14.1/0040-initfini-ppc64.patch
@@ -7,8 +7,12 @@ commit 1fe05ea95e1460e5e1cf1568a8ce3982f0f02de6
Author: Ryan S. Arnold <rsa@us.ibm.com>
Date: Tue May 3 17:26:17 2011 -0500
---- glibc.orig/sysdeps/powerpc/powerpc64/Makefile 2012-12-22 19:10:06.713568781 -0800
-+++ glibc/sysdeps/powerpc/powerpc64/Makefile 2012-12-22 19:10:50.318605517 -0800
+---
+ sysdeps/powerpc/powerpc64/Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/sysdeps/powerpc/powerpc64/Makefile
++++ b/sysdeps/powerpc/powerpc64/Makefile
@@ -31,7 +31,7 @@
ifneq ($(elf),no)
# The initfini generation code doesn't work in the presence of -fPIC, so
diff --git a/packages/glibc/2.14.1/996-obsolete-rpc.patch b/packages/glibc/2.14.1/0041-obsolete-rpc.patch
index 38cb521..eef16c7 100644
--- a/packages/glibc/2.14.1/996-obsolete-rpc.patch
+++ b/packages/glibc/2.14.1/0041-obsolete-rpc.patch
@@ -10,11 +10,68 @@ Date: Thu May 10 20:16:53 2012 +0200
after the TI-RPC library becomes fully sufficient for the needs of
existing applications.
-diff --git a/config.h.in b/config.h.in
-index 787873b4c0..54952609ef 100644
+---
+ config.h.in | 3 +++
+ config.make.in | 1 +
+ configure | 18 ++++++++++++++++++
+ configure.in | 11 +++++++++++
+ include/libc-symbols.h | 7 ++++++-
+ nis/Makefile | 6 ++++++
+ sunrpc/Makefile | 6 ++++++
+ sunrpc/auth_des.c | 4 ++--
+ sunrpc/auth_none.c | 2 +-
+ sunrpc/auth_unix.c | 4 ++--
+ sunrpc/authdes_prot.c | 4 ++--
+ sunrpc/authuxprot.c | 2 +-
+ sunrpc/clnt_gen.c | 2 +-
+ sunrpc/clnt_perr.c | 10 +++++-----
+ sunrpc/clnt_raw.c | 2 +-
+ sunrpc/clnt_simp.c | 2 +-
+ sunrpc/clnt_tcp.c | 2 +-
+ sunrpc/clnt_udp.c | 6 +++---
+ sunrpc/clnt_unix.c | 2 +-
+ sunrpc/des_crypt.c | 4 ++--
+ sunrpc/des_soft.c | 2 +-
+ sunrpc/get_myaddr.c | 2 +-
+ sunrpc/key_call.c | 18 +++++++++---------
+ sunrpc/key_prot.c | 20 ++++++++++----------
+ sunrpc/netname.c | 10 +++++-----
+ sunrpc/pm_getmaps.c | 2 +-
+ sunrpc/pm_getport.c | 4 ++--
+ sunrpc/pmap_clnt.c | 4 ++--
+ sunrpc/pmap_prot.c | 2 +-
+ sunrpc/pmap_prot2.c | 2 +-
+ sunrpc/pmap_rmt.c | 8 ++++----
+ sunrpc/publickey.c | 4 ++--
+ sunrpc/rpc_cmsg.c | 2 +-
+ sunrpc/rpc_common.c | 2 +-
+ sunrpc/rpc_dtable.c | 2 +-
+ sunrpc/rpc_prot.c | 14 +++++++-------
+ sunrpc/rpc_thread.c | 8 ++++----
+ sunrpc/rtime.c | 2 +-
+ sunrpc/svc.c | 32 ++++++++++++++++----------------
+ sunrpc/svc_auth.c | 2 +-
+ sunrpc/svc_raw.c | 2 +-
+ sunrpc/svc_run.c | 4 ++--
+ sunrpc/svc_tcp.c | 4 ++--
+ sunrpc/svc_udp.c | 6 +++---
+ sunrpc/svc_unix.c | 4 ++--
+ sunrpc/svcauth_des.c | 2 +-
+ sunrpc/xcrypt.c | 4 ++--
+ sunrpc/xdr.c | 44 ++++++++++++++++++++++----------------------
+ sunrpc/xdr_array.c | 4 ++--
+ sunrpc/xdr_float.c | 4 ++--
+ sunrpc/xdr_intXX_t.c | 20 ++++++++++----------
+ sunrpc/xdr_mem.c | 2 +-
+ sunrpc/xdr_rec.c | 8 ++++----
+ sunrpc/xdr_ref.c | 4 ++--
+ sunrpc/xdr_sizeof.c | 2 +-
+ sunrpc/xdr_stdio.c | 2 +-
+ 56 files changed, 203 insertions(+), 153 deletions(-)
+
--- a/config.h.in
+++ b/config.h.in
-@@ -178,6 +178,9 @@
+@@ -204,6 +204,9 @@
/* Define if `.ctors' and `.dtors' sections shouldn't be used. */
#undef NO_CTORS_DTORS_SECTIONS
@@ -24,11 +81,9 @@ index 787873b4c0..54952609ef 100644
/*
*/
-diff --git a/config.make.in b/config.make.in
-index 5f6f9e281d..6c4d04ee33 100644
--- a/config.make.in
+++ b/config.make.in
-@@ -96,6 +96,7 @@ add-on-subdirs = @add_on_subdirs@
+@@ -102,6 +102,7 @@
sysdeps-add-ons = @sysdeps_add_ons@
cross-compiling = @cross_compiling@
force-install = @force_install@
@@ -36,11 +91,9 @@ index 5f6f9e281d..6c4d04ee33 100644
# Build tools.
CC = @CC@
-diff --git a/configure b/configure
-index 1c5f4adbea..c7cb47d0c2 100755
--- a/configure
+++ b/configure
-@@ -687,6 +687,7 @@ multi_arch
+@@ -682,6 +682,7 @@
base_machine
add_on_subdirs
add_ons
@@ -48,7 +101,7 @@ index 1c5f4adbea..c7cb47d0c2 100755
libc_cv_nss_crypt
experimental_malloc
all_warnings
-@@ -779,6 +780,7 @@ enable_kernel
+@@ -784,6 +785,7 @@
enable_multi_arch
enable_experimental_malloc
enable_nss_crypt
@@ -56,7 +109,7 @@ index 1c5f4adbea..c7cb47d0c2 100755
with_cpu
'
ac_precious_vars='build_alias
-@@ -1434,6 +1436,8 @@ Optional Features:
+@@ -1444,6 +1446,8 @@
--enable-experimental-malloc
enable experimental malloc features
--enable-nss-crypt enable libcrypt to use nss
@@ -65,7 +118,7 @@ index 1c5f4adbea..c7cb47d0c2 100755
Optional Packages:
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
-@@ -3746,6 +3750,20 @@ else
+@@ -3823,6 +3827,20 @@
fi
@@ -86,11 +139,9 @@ index 1c5f4adbea..c7cb47d0c2 100755
# The way shlib-versions is used to generate soversions.mk uses a
# fairly simplistic model for name recognition that can't distinguish
# i486-pc-linux-gnu fully from i486-pc-gnu. So we mutate a $host_os
-diff --git a/configure.in b/configure.in
-index 19a2c1a0f0..4eb9277e8c 100644
--- a/configure.in
+++ b/configure.in
-@@ -252,6 +252,17 @@ else
+@@ -316,6 +316,17 @@
fi
AC_SUBST(libc_cv_nss_crypt)
@@ -108,11 +159,9 @@ index 19a2c1a0f0..4eb9277e8c 100644
# The way shlib-versions is used to generate soversions.mk uses a
# fairly simplistic model for name recognition that can't distinguish
# i486-pc-linux-gnu fully from i486-pc-gnu. So we mutate a $host_os
-diff --git a/include/libc-symbols.h b/include/libc-symbols.h
-index 951e46a6e3..0c3274e253 100644
--- a/include/libc-symbols.h
+++ b/include/libc-symbols.h
-@@ -556,7 +556,12 @@ for linking")
+@@ -635,7 +635,12 @@
# define libc_hidden_proto(name, attrs...) hidden_proto (name, ##attrs)
# define libc_hidden_def(name) hidden_def (name)
# define libc_hidden_weak(name) hidden_weak (name)
@@ -126,11 +175,9 @@ index 951e46a6e3..0c3274e253 100644
# define libc_hidden_ver(local, name) hidden_ver (local, name)
# define libc_hidden_data_def(name) hidden_data_def (name)
# define libc_hidden_data_weak(name) hidden_data_weak (name)
-diff --git a/nis/Makefile b/nis/Makefile
-index a48753f7a9..b412cee304 100644
--- a/nis/Makefile
+++ b/nis/Makefile
-@@ -23,6 +23,12 @@ subdir := nis
+@@ -23,6 +23,12 @@
aux := nis_hash
@@ -143,11 +190,9 @@ index a48753f7a9..b412cee304 100644
distribute := nss-nis.h nss-nisplus.h nis_intern.h Banner \
nisplus-parser.h nis_xdr.h nss \
$(wildcard rpcsvc/*.[hx])
-diff --git a/sunrpc/Makefile b/sunrpc/Makefile
-index e61efd02b3..3b79dcdb72 100644
--- a/sunrpc/Makefile
+++ b/sunrpc/Makefile
-@@ -60,6 +60,10 @@ generated-dirs := rpcsvc
+@@ -61,6 +61,10 @@
include ../Makeconfig
@@ -158,7 +203,7 @@ index e61efd02b3..3b79dcdb72 100644
ifeq ($(versioning),yes)
need-export-routines := auth_des auth_unix clnt_gen clnt_perr clnt_tcp \
clnt_udp get_myaddr key_call netname pm_getport \
-@@ -73,9 +77,11 @@ routines := auth_none authuxprot bindrsvprt clnt_raw clnt_simp \
+@@ -74,9 +78,11 @@
svc_simple xdr_float xdr_rec publickey authdes_prot \
des_crypt des_impl des_soft key_prot openchild rtime svcauth_des \
clnt_unix svc_unix create_xid $(need-export-routines)
@@ -170,11 +215,9 @@ index e61efd02b3..3b79dcdb72 100644
# We do not build rpcinfo anymore. It is not needed for a bootstrap
# and not wanted on complete systems.
-diff --git a/sunrpc/auth_des.c b/sunrpc/auth_des.c
-index 96bbcfc328..0408d60826 100644
--- a/sunrpc/auth_des.c
+++ b/sunrpc/auth_des.c
-@@ -117,7 +117,7 @@ authdes_create (const char *servername, u_int window,
+@@ -117,7 +117,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (authdes_create)
#else
@@ -183,7 +226,7 @@ index 96bbcfc328..0408d60826 100644
#endif
AUTH *
-@@ -211,7 +211,7 @@ failed:
+@@ -211,7 +211,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (authdes_pk_create)
#else
@@ -192,11 +235,9 @@ index 96bbcfc328..0408d60826 100644
#endif
/*
-diff --git a/sunrpc/auth_none.c b/sunrpc/auth_none.c
-index 5f252a9544..3af5966794 100644
--- a/sunrpc/auth_none.c
+++ b/sunrpc/auth_none.c
-@@ -95,7 +95,7 @@ authnone_create (void)
+@@ -95,7 +95,7 @@
__libc_once (authnone_private_guard, authnone_create_once);
return &authnone_private.no_client;
}
@@ -205,11 +246,9 @@ index 5f252a9544..3af5966794 100644
static bool_t
authnone_marshal (AUTH *client, XDR *xdrs)
-diff --git a/sunrpc/auth_unix.c b/sunrpc/auth_unix.c
-index d3b5dc7dee..68b42d7b1f 100644
--- a/sunrpc/auth_unix.c
+++ b/sunrpc/auth_unix.c
-@@ -149,7 +149,7 @@ no_memory:
+@@ -151,7 +151,7 @@
marshal_new_auth (auth);
return auth;
}
@@ -218,7 +257,7 @@ index d3b5dc7dee..68b42d7b1f 100644
/*
* Returns an auth handle with parameters determined by doing lots of
-@@ -216,7 +216,7 @@ authunix_create_default (void)
+@@ -218,7 +218,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (authunix_create_default)
#else
@@ -227,11 +266,9 @@ index d3b5dc7dee..68b42d7b1f 100644
#endif
/*
-diff --git a/sunrpc/authdes_prot.c b/sunrpc/authdes_prot.c
-index 0a25bac143..164c1223ca 100644
--- a/sunrpc/authdes_prot.c
+++ b/sunrpc/authdes_prot.c
-@@ -63,7 +63,7 @@ xdr_authdes_cred (XDR *xdrs, struct authdes_cred *cred)
+@@ -63,7 +63,7 @@
return FALSE;
}
}
@@ -240,38 +277,32 @@ index 0a25bac143..164c1223ca 100644
bool_t
-@@ -78,4 +78,4 @@ xdr_authdes_verf (register XDR *xdrs, register struct authdes_verf *verf)
+@@ -78,4 +78,4 @@
sizeof (verf->adv_int_u)));
return TRUE;
}
-libc_hidden_nolink (xdr_authdes_verf, GLIBC_2_1)
+libc_hidden_nolink_sunrpc (xdr_authdes_verf, GLIBC_2_1)
-diff --git a/sunrpc/authuxprot.c b/sunrpc/authuxprot.c
-index 64da1799e0..d37faee0c7 100644
--- a/sunrpc/authuxprot.c
+++ b/sunrpc/authuxprot.c
-@@ -63,4 +63,4 @@ xdr_authunix_parms (XDR * xdrs, struct authunix_parms *p)
+@@ -63,4 +63,4 @@
}
return FALSE;
}
-libc_hidden_nolink (xdr_authunix_parms, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_authunix_parms, GLIBC_2_0)
-diff --git a/sunrpc/clnt_gen.c b/sunrpc/clnt_gen.c
-index 2b7096cf20..df34672d72 100644
--- a/sunrpc/clnt_gen.c
+++ b/sunrpc/clnt_gen.c
-@@ -175,5 +175,5 @@ clnt_create (const char *hostname, u_long prog, u_long vers,
+@@ -175,5 +175,5 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (clnt_create)
#else
-libc_hidden_nolink (clnt_create, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (clnt_create, GLIBC_2_0)
#endif
-diff --git a/sunrpc/clnt_perr.c b/sunrpc/clnt_perr.c
-index 175370ebfc..b4f84c92e8 100644
--- a/sunrpc/clnt_perr.c
+++ b/sunrpc/clnt_perr.c
-@@ -127,7 +127,7 @@ clnt_sperror (CLIENT * rpch, const char *msg)
+@@ -130,7 +130,7 @@
return str;
}
@@ -280,7 +311,7 @@ index 175370ebfc..b4f84c92e8 100644
void
clnt_perror (CLIENT * rpch, const char *msg)
-@@ -137,7 +137,7 @@ clnt_perror (CLIENT * rpch, const char *msg)
+@@ -140,7 +140,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (clnt_perror)
#else
@@ -289,7 +320,7 @@ index 175370ebfc..b4f84c92e8 100644
#endif
-@@ -270,7 +270,7 @@ clnt_perrno (enum clnt_stat num)
+@@ -273,7 +273,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (clnt_perrno)
#else
@@ -298,7 +329,7 @@ index 175370ebfc..b4f84c92e8 100644
#endif
char *
-@@ -308,7 +308,7 @@ clnt_spcreateerror (const char *msg)
+@@ -311,7 +311,7 @@
return str;
}
@@ -307,7 +338,7 @@ index 175370ebfc..b4f84c92e8 100644
void
clnt_pcreateerror (const char *msg)
-@@ -318,7 +318,7 @@ clnt_pcreateerror (const char *msg)
+@@ -321,7 +321,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (clnt_pcreateerror)
#else
@@ -316,11 +347,9 @@ index 175370ebfc..b4f84c92e8 100644
#endif
struct auth_errtab
-diff --git a/sunrpc/clnt_raw.c b/sunrpc/clnt_raw.c
-index 95e3eae988..4004c6b6a8 100644
--- a/sunrpc/clnt_raw.c
+++ b/sunrpc/clnt_raw.c
-@@ -129,7 +129,7 @@ clntraw_create (u_long prog, u_long vers)
+@@ -129,7 +129,7 @@
client->cl_auth = authnone_create ();
return client;
}
@@ -329,11 +358,9 @@ index 95e3eae988..4004c6b6a8 100644
static enum clnt_stat
clntraw_call (h, proc, xargs, argsp, xresults, resultsp, timeout)
-diff --git a/sunrpc/clnt_simp.c b/sunrpc/clnt_simp.c
-index d2dd3b307a..d612df09a0 100644
--- a/sunrpc/clnt_simp.c
+++ b/sunrpc/clnt_simp.c
-@@ -139,7 +139,7 @@ callrpc (const char *host, u_long prognum, u_long versnum, u_long procnum,
+@@ -139,7 +139,7 @@
crp->valid = 0;
return (int) clnt_stat;
}
@@ -342,11 +369,9 @@ index d2dd3b307a..d612df09a0 100644
#ifdef _RPC_THREAD_SAFE_
void
-diff --git a/sunrpc/clnt_tcp.c b/sunrpc/clnt_tcp.c
-index d1fc43dbfd..6bd4c8c0cd 100644
--- a/sunrpc/clnt_tcp.c
+++ b/sunrpc/clnt_tcp.c
-@@ -220,7 +220,7 @@ fooy:
+@@ -222,7 +222,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (clnttcp_create)
#else
@@ -355,11 +380,9 @@ index d1fc43dbfd..6bd4c8c0cd 100644
#endif
static enum clnt_stat
-diff --git a/sunrpc/clnt_udp.c b/sunrpc/clnt_udp.c
-index 294e13a58c..7ecf2ef5a5 100644
--- a/sunrpc/clnt_udp.c
+++ b/sunrpc/clnt_udp.c
-@@ -239,7 +239,7 @@ fooy:
+@@ -240,7 +240,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (__libc_clntudp_bufcreate)
#else
@@ -368,7 +391,7 @@ index 294e13a58c..7ecf2ef5a5 100644
#endif
CLIENT *
-@@ -250,7 +250,7 @@ clntudp_bufcreate (struct sockaddr_in *raddr, u_long program, u_long version,
+@@ -251,7 +251,7 @@
return __libc_clntudp_bufcreate (raddr, program, version, wait,
sockp, sendsz, recvsz, 0);
}
@@ -377,7 +400,7 @@ index 294e13a58c..7ecf2ef5a5 100644
CLIENT *
clntudp_create (raddr, program, version, wait, sockp)
-@@ -266,7 +266,7 @@ clntudp_create (raddr, program, version, wait, sockp)
+@@ -267,7 +267,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (clntudp_create)
#else
@@ -386,11 +409,9 @@ index 294e13a58c..7ecf2ef5a5 100644
#endif
static int
-diff --git a/sunrpc/clnt_unix.c b/sunrpc/clnt_unix.c
-index 282127bb8b..776ceab484 100644
--- a/sunrpc/clnt_unix.c
+++ b/sunrpc/clnt_unix.c
-@@ -200,7 +200,7 @@ fooy:
+@@ -202,7 +202,7 @@
mem_free ((caddr_t) h, sizeof (CLIENT));
return (CLIENT *) NULL;
}
@@ -399,11 +420,9 @@ index 282127bb8b..776ceab484 100644
static enum clnt_stat
clntunix_call (h, proc, xdr_args, args_ptr, xdr_results, results_ptr, timeout)
-diff --git a/sunrpc/des_crypt.c b/sunrpc/des_crypt.c
-index 8745900b82..22a34b7f3a 100644
--- a/sunrpc/des_crypt.c
+++ b/sunrpc/des_crypt.c
-@@ -102,7 +102,7 @@ cbc_crypt (char *key, char *buf, unsigned int len, unsigned int mode,
+@@ -102,7 +102,7 @@
COPY8 (dp.des_ivec, ivec);
return err;
}
@@ -412,38 +431,32 @@ index 8745900b82..22a34b7f3a 100644
/*
* ECB mode encryption
-@@ -115,4 +115,4 @@ ecb_crypt (char *key, char *buf, unsigned int len, unsigned int mode)
+@@ -115,4 +115,4 @@
dp.des_mode = ECB;
return common_crypt (key, buf, len, mode, &dp);
}
-libc_hidden_nolink (ecb_crypt, GLIBC_2_1)
+libc_hidden_nolink_sunrpc (ecb_crypt, GLIBC_2_1)
-diff --git a/sunrpc/des_soft.c b/sunrpc/des_soft.c
-index 27d918c64d..cddef5d76b 100644
--- a/sunrpc/des_soft.c
+++ b/sunrpc/des_soft.c
-@@ -70,4 +70,4 @@ des_setparity (char *p)
+@@ -70,4 +70,4 @@
p++;
}
}
-libc_hidden_nolink (des_setparity, GLIBC_2_1)
+libc_hidden_nolink_sunrpc (des_setparity, GLIBC_2_1)
-diff --git a/sunrpc/get_myaddr.c b/sunrpc/get_myaddr.c
-index def5b7a74a..24407b53ec 100644
--- a/sunrpc/get_myaddr.c
+++ b/sunrpc/get_myaddr.c
-@@ -99,5 +99,5 @@ get_myaddress (struct sockaddr_in *addr)
+@@ -99,5 +99,5 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (get_myaddress)
#else
-libc_hidden_nolink (get_myaddress, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (get_myaddress, GLIBC_2_0)
#endif
-diff --git a/sunrpc/key_call.c b/sunrpc/key_call.c
-index 6d08bf8e80..e0a076b47f 100644
--- a/sunrpc/key_call.c
+++ b/sunrpc/key_call.c
-@@ -80,7 +80,7 @@ key_setsecret (char *secretkey)
+@@ -80,7 +80,7 @@
}
return 0;
}
@@ -452,7 +465,7 @@ index 6d08bf8e80..e0a076b47f 100644
/* key_secretkey_is_set() returns 1 if the keyserver has a secret key
* stored for the caller's effective uid; it returns 0 otherwise
-@@ -109,7 +109,7 @@ key_secretkey_is_set (void)
+@@ -109,7 +109,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (key_secretkey_is_set)
#else
@@ -461,7 +474,7 @@ index 6d08bf8e80..e0a076b47f 100644
#endif
int
-@@ -133,7 +133,7 @@ key_encryptsession (char *remotename, des_block *deskey)
+@@ -133,7 +133,7 @@
*deskey = res.cryptkeyres_u.deskey;
return 0;
}
@@ -470,7 +483,7 @@ index 6d08bf8e80..e0a076b47f 100644
int
key_decryptsession (char *remotename, des_block *deskey)
-@@ -155,7 +155,7 @@ key_decryptsession (char *remotename, des_block *deskey)
+@@ -155,7 +155,7 @@
*deskey = res.cryptkeyres_u.deskey;
return 0;
}
@@ -479,7 +492,7 @@ index 6d08bf8e80..e0a076b47f 100644
int
key_encryptsession_pk (char *remotename, netobj *remotekey,
-@@ -180,7 +180,7 @@ key_encryptsession_pk (char *remotename, netobj *remotekey,
+@@ -180,7 +180,7 @@
*deskey = res.cryptkeyres_u.deskey;
return 0;
}
@@ -488,7 +501,7 @@ index 6d08bf8e80..e0a076b47f 100644
int
key_decryptsession_pk (char *remotename, netobj *remotekey,
-@@ -205,7 +205,7 @@ key_decryptsession_pk (char *remotename, netobj *remotekey,
+@@ -205,7 +205,7 @@
*deskey = res.cryptkeyres_u.deskey;
return 0;
}
@@ -497,7 +510,7 @@ index 6d08bf8e80..e0a076b47f 100644
int
key_gendes (des_block *key)
-@@ -239,7 +239,7 @@ key_gendes (des_block *key)
+@@ -239,7 +239,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (key_gendes)
#else
@@ -506,7 +519,7 @@ index 6d08bf8e80..e0a076b47f 100644
#endif
int
-@@ -259,7 +259,7 @@ key_setnet (struct key_netstarg *arg)
+@@ -259,7 +259,7 @@
}
return 1;
}
@@ -515,7 +528,7 @@ index 6d08bf8e80..e0a076b47f 100644
int
key_get_conv (char *pkey, des_block *deskey)
-@@ -278,7 +278,7 @@ key_get_conv (char *pkey, des_block *deskey)
+@@ -278,7 +278,7 @@
*deskey = res.cryptkeyres_u.deskey;
return 0;
}
@@ -524,11 +537,9 @@ index 6d08bf8e80..e0a076b47f 100644
/*
* Hack to allow the keyserver to use AUTH_DES (for authenticated
-diff --git a/sunrpc/key_prot.c b/sunrpc/key_prot.c
-index dd73f5e3cb..2899c9a448 100644
--- a/sunrpc/key_prot.c
+++ b/sunrpc/key_prot.c
-@@ -38,7 +38,7 @@ xdr_keystatus (XDR * xdrs, keystatus * objp)
+@@ -38,7 +38,7 @@
return TRUE;
}
@@ -537,7 +548,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_keybuf (XDR * xdrs, keybuf objp)
-@@ -48,7 +48,7 @@ xdr_keybuf (XDR * xdrs, keybuf objp)
+@@ -48,7 +48,7 @@
return TRUE;
}
@@ -546,7 +557,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_netnamestr (XDR * xdrs, netnamestr * objp)
-@@ -58,7 +58,7 @@ xdr_netnamestr (XDR * xdrs, netnamestr * objp)
+@@ -58,7 +58,7 @@
return TRUE;
}
@@ -555,7 +566,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_cryptkeyarg (XDR * xdrs, cryptkeyarg * objp)
-@@ -71,7 +71,7 @@ xdr_cryptkeyarg (XDR * xdrs, cryptkeyarg * objp)
+@@ -71,7 +71,7 @@
return TRUE;
}
@@ -564,7 +575,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_cryptkeyarg2 (XDR * xdrs, cryptkeyarg2 * objp)
-@@ -84,7 +84,7 @@ xdr_cryptkeyarg2 (XDR * xdrs, cryptkeyarg2 * objp)
+@@ -84,7 +84,7 @@
return FALSE;
return TRUE;
}
@@ -573,7 +584,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_cryptkeyres (XDR * xdrs, cryptkeyres * objp)
-@@ -102,7 +102,7 @@ xdr_cryptkeyres (XDR * xdrs, cryptkeyres * objp)
+@@ -102,7 +102,7 @@
}
return TRUE;
}
@@ -582,7 +593,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_unixcred (XDR * xdrs, unixcred * objp)
-@@ -117,7 +117,7 @@ xdr_unixcred (XDR * xdrs, unixcred * objp)
+@@ -117,7 +117,7 @@
return FALSE;
return TRUE;
}
@@ -591,7 +602,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_getcredres (XDR * xdrs, getcredres * objp)
-@@ -135,7 +135,7 @@ xdr_getcredres (XDR * xdrs, getcredres * objp)
+@@ -135,7 +135,7 @@
}
return TRUE;
}
@@ -600,7 +611,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_key_netstarg (XDR * xdrs, key_netstarg * objp)
-@@ -148,7 +148,7 @@ xdr_key_netstarg (XDR * xdrs, key_netstarg * objp)
+@@ -148,7 +148,7 @@
return FALSE;
return TRUE;
}
@@ -609,17 +620,15 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_key_netstres (XDR * xdrs, key_netstres * objp)
-@@ -166,4 +166,4 @@ xdr_key_netstres (XDR * xdrs, key_netstres * objp)
+@@ -166,4 +166,4 @@
}
return TRUE;
}
-libc_hidden_nolink (xdr_key_netstres, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_key_netstres, GLIBC_2_0)
-diff --git a/sunrpc/netname.c b/sunrpc/netname.c
-index 0b4980074c..197d503eae 100644
--- a/sunrpc/netname.c
+++ b/sunrpc/netname.c
-@@ -54,7 +54,7 @@ user2netname (char netname[MAXNETNAMELEN + 1], const uid_t uid,
+@@ -55,7 +55,7 @@
netname[i - 1] = '\0';
return 1;
}
@@ -628,7 +637,7 @@ index 0b4980074c..197d503eae 100644
int
host2netname (char netname[MAXNETNAMELEN + 1], const char *host,
-@@ -118,7 +118,7 @@ host2netname (char netname[MAXNETNAMELEN + 1], const char *host,
+@@ -119,7 +119,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (host2netname)
#else
@@ -637,7 +646,7 @@ index 0b4980074c..197d503eae 100644
#endif
int
-@@ -134,7 +134,7 @@ getnetname (char name[MAXNETNAMELEN + 1])
+@@ -135,7 +135,7 @@
dummy = user2netname (name, uid, NULL);
return (dummy);
}
@@ -646,7 +655,7 @@ index 0b4980074c..197d503eae 100644
/* Type of the lookup function for netname2user. */
typedef int (*netname2user_function) (const char netname[MAXNETNAMELEN + 1],
-@@ -187,7 +187,7 @@ netname2user (const char netname[MAXNETNAMELEN + 1], uid_t * uidp, gid_t * gidp,
+@@ -188,7 +188,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (netname2user)
#else
@@ -655,27 +664,23 @@ index 0b4980074c..197d503eae 100644
#endif
int
-@@ -214,4 +214,4 @@ netname2host (const char netname[MAXNETNAMELEN + 1], char *hostname,
+@@ -216,4 +216,4 @@
return 1;
}
-libc_hidden_nolink (netname2host, GLIBC_2_1)
+libc_hidden_nolink_sunrpc (netname2host, GLIBC_2_1)
-diff --git a/sunrpc/pm_getmaps.c b/sunrpc/pm_getmaps.c
-index 6b61d324f9..6f7ad10ef6 100644
--- a/sunrpc/pm_getmaps.c
+++ b/sunrpc/pm_getmaps.c
-@@ -84,4 +84,4 @@ pmap_getmaps (struct sockaddr_in *address)
+@@ -84,4 +84,4 @@
address->sin_port = 0;
return head;
}
-libc_hidden_nolink (pmap_getmaps, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (pmap_getmaps, GLIBC_2_0)
-diff --git a/sunrpc/pm_getport.c b/sunrpc/pm_getport.c
-index 58974a5661..f10f87250d 100644
--- a/sunrpc/pm_getport.c
+++ b/sunrpc/pm_getport.c
-@@ -142,7 +142,7 @@ __libc_rpc_getport (address, program, version, protocol, timeout_sec,
+@@ -142,7 +142,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (__libc_rpc_getport)
#else
@@ -684,17 +689,15 @@ index 58974a5661..f10f87250d 100644
#endif
-@@ -160,4 +160,4 @@ pmap_getport (address, program, version, protocol)
+@@ -160,4 +160,4 @@
{
return __libc_rpc_getport (address, program, version, protocol, 5, 60);
}
-libc_hidden_nolink (pmap_getport, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (pmap_getport, GLIBC_2_0)
-diff --git a/sunrpc/pmap_clnt.c b/sunrpc/pmap_clnt.c
-index 36479f0e5c..5d7d185766 100644
--- a/sunrpc/pmap_clnt.c
+++ b/sunrpc/pmap_clnt.c
-@@ -131,7 +131,7 @@ pmap_set (u_long program, u_long version, int protocol, u_short port)
+@@ -131,7 +131,7 @@
/* (void)close(socket); CLNT_DESTROY closes it */
return rslt;
}
@@ -703,37 +706,31 @@ index 36479f0e5c..5d7d185766 100644
/*
* Remove the mapping between program,version and port.
-@@ -162,4 +162,4 @@ pmap_unset (u_long program, u_long version)
+@@ -162,4 +162,4 @@
/* (void)close(socket); CLNT_DESTROY already closed it */
return rslt;
}
-libc_hidden_nolink (pmap_unset, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (pmap_unset, GLIBC_2_0)
-diff --git a/sunrpc/pmap_prot.c b/sunrpc/pmap_prot.c
-index 5a2e052728..8df41dc5f2 100644
--- a/sunrpc/pmap_prot.c
+++ b/sunrpc/pmap_prot.c
-@@ -49,4 +49,4 @@ xdr_pmap (xdrs, regs)
+@@ -49,4 +49,4 @@
return xdr_u_long (xdrs, &regs->pm_port);
return FALSE;
}
-libc_hidden_nolink (xdr_pmap, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_pmap, GLIBC_2_0)
-diff --git a/sunrpc/pmap_prot2.c b/sunrpc/pmap_prot2.c
-index 3213898ce8..57b0800178 100644
--- a/sunrpc/pmap_prot2.c
+++ b/sunrpc/pmap_prot2.c
-@@ -110,4 +110,4 @@ xdr_pmaplist (xdrs, rp)
+@@ -110,4 +110,4 @@
rp = freeing ? &next : &((*rp)->pml_next);
}
}
-libc_hidden_nolink (xdr_pmaplist, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_pmaplist, GLIBC_2_0)
-diff --git a/sunrpc/pmap_rmt.c b/sunrpc/pmap_rmt.c
-index 16f322773e..fd8de85589 100644
--- a/sunrpc/pmap_rmt.c
+++ b/sunrpc/pmap_rmt.c
-@@ -104,7 +104,7 @@ pmap_rmtcall (addr, prog, vers, proc, xdrargs, argsp, xdrres, resp, tout, port_p
+@@ -104,7 +104,7 @@
addr->sin_port = 0;
return stat;
}
@@ -742,7 +739,7 @@ index 16f322773e..fd8de85589 100644
/*
-@@ -137,7 +137,7 @@ xdr_rmtcall_args (XDR *xdrs, struct rmtcallargs *cap)
+@@ -137,7 +137,7 @@
}
return FALSE;
}
@@ -751,7 +748,7 @@ index 16f322773e..fd8de85589 100644
/*
* XDR remote call results
-@@ -160,7 +160,7 @@ xdr_rmtcallres (xdrs, crp)
+@@ -160,7 +160,7 @@
}
return FALSE;
}
@@ -760,17 +757,15 @@ index 16f322773e..fd8de85589 100644
/*
-@@ -388,4 +388,4 @@ done_broad:
+@@ -388,4 +388,4 @@
AUTH_DESTROY (unix_auth);
return stat;
}
-libc_hidden_nolink (clnt_broadcast, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (clnt_broadcast, GLIBC_2_0)
-diff --git a/sunrpc/publickey.c b/sunrpc/publickey.c
-index 4d0b09874c..089b544953 100644
--- a/sunrpc/publickey.c
+++ b/sunrpc/publickey.c
-@@ -75,7 +75,7 @@ getpublickey (const char *name, char *key)
+@@ -76,7 +76,7 @@
return status == NSS_STATUS_SUCCESS;
}
@@ -779,24 +774,20 @@ index 4d0b09874c..089b544953 100644
int
-@@ -118,4 +118,4 @@ getsecretkey (const char *name, char *key, const char *passwd)
+@@ -119,4 +119,4 @@
return status == NSS_STATUS_SUCCESS;
}
-libc_hidden_nolink (getsecretkey, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (getsecretkey, GLIBC_2_0)
-diff --git a/sunrpc/rpc_cmsg.c b/sunrpc/rpc_cmsg.c
-index ed70104b68..62d95fcc83 100644
--- a/sunrpc/rpc_cmsg.c
+++ b/sunrpc/rpc_cmsg.c
-@@ -194,4 +194,4 @@ xdr_callmsg (XDR *xdrs, struct rpc_msg *cmsg)
+@@ -194,4 +194,4 @@
return xdr_opaque_auth (xdrs, &(cmsg->rm_call.cb_verf));
return FALSE;
}
-libc_hidden_nolink (xdr_callmsg, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_callmsg, GLIBC_2_0)
-diff --git a/sunrpc/rpc_common.c b/sunrpc/rpc_common.c
-index 44b4b38f4d..710191163c 100644
--- a/sunrpc/rpc_common.c
+++ b/sunrpc/rpc_common.c
@@ -45,7 +45,7 @@
@@ -808,21 +799,17 @@ index 44b4b38f4d..710191163c 100644
fd_set svc_fdset;
struct rpc_createerr rpc_createerr;
struct pollfd *svc_pollfd;
-diff --git a/sunrpc/rpc_dtable.c b/sunrpc/rpc_dtable.c
-index 9bee215496..81ddf8f55a 100644
--- a/sunrpc/rpc_dtable.c
+++ b/sunrpc/rpc_dtable.c
-@@ -46,4 +46,4 @@ _rpc_dtablesize (void)
+@@ -46,4 +46,4 @@
return size;
}
-libc_hidden_nolink (_rpc_dtablesize, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (_rpc_dtablesize, GLIBC_2_0)
-diff --git a/sunrpc/rpc_prot.c b/sunrpc/rpc_prot.c
-index 9a23cc1b02..dc24f3673b 100644
--- a/sunrpc/rpc_prot.c
+++ b/sunrpc/rpc_prot.c
-@@ -57,7 +57,7 @@ xdr_opaque_auth (XDR *xdrs, struct opaque_auth *ap)
+@@ -57,7 +57,7 @@
&ap->oa_length, MAX_AUTH_BYTES);
return FALSE;
}
@@ -831,7 +818,7 @@ index 9a23cc1b02..dc24f3673b 100644
/*
* XDR a DES block
-@@ -67,7 +67,7 @@ xdr_des_block (XDR *xdrs, des_block *blkp)
+@@ -67,7 +67,7 @@
{
return xdr_opaque (xdrs, (caddr_t) blkp, sizeof (des_block));
}
@@ -840,7 +827,7 @@ index 9a23cc1b02..dc24f3673b 100644
/* * * * * * * * * * * * * * XDR RPC MESSAGE * * * * * * * * * * * * * * * */
-@@ -95,7 +95,7 @@ xdr_accepted_reply (XDR *xdrs, struct accepted_reply *ar)
+@@ -95,7 +95,7 @@
}
return TRUE; /* TRUE => open ended set of problems */
}
@@ -849,7 +836,7 @@ index 9a23cc1b02..dc24f3673b 100644
/*
* XDR the MSG_DENIED part of a reply message union
-@@ -118,7 +118,7 @@ xdr_rejected_reply (XDR *xdrs, struct rejected_reply *rr)
+@@ -118,7 +118,7 @@
}
return FALSE;
}
@@ -858,7 +845,7 @@ index 9a23cc1b02..dc24f3673b 100644
static const struct xdr_discrim reply_dscrm[3] =
{
-@@ -142,7 +142,7 @@ xdr_replymsg (xdrs, rmsg)
+@@ -142,7 +142,7 @@
NULL_xdrproc_t);
return FALSE;
}
@@ -867,7 +854,7 @@ index 9a23cc1b02..dc24f3673b 100644
/*
-@@ -167,7 +167,7 @@ xdr_callhdr (xdrs, cmsg)
+@@ -167,7 +167,7 @@
return xdr_u_long (xdrs, &(cmsg->rm_call.cb_vers));
return FALSE;
}
@@ -876,17 +863,15 @@ index 9a23cc1b02..dc24f3673b 100644
/* ************************** Client utility routine ************* */
-@@ -277,4 +277,4 @@ _seterr_reply (struct rpc_msg *msg,
+@@ -277,4 +277,4 @@
break;
}
}
-libc_hidden_nolink (_seterr_reply, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (_seterr_reply, GLIBC_2_0)
-diff --git a/sunrpc/rpc_thread.c b/sunrpc/rpc_thread.c
-index ac4c18fcee..94d9f1fd80 100644
--- a/sunrpc/rpc_thread.c
+++ b/sunrpc/rpc_thread.c
-@@ -97,7 +97,7 @@ __rpc_thread_svc_fdset (void)
+@@ -97,7 +97,7 @@
return &svc_fdset;
return &tvp->svc_fdset_s;
}
@@ -895,7 +880,7 @@ index ac4c18fcee..94d9f1fd80 100644
struct rpc_createerr *
__rpc_thread_createerr (void)
-@@ -109,7 +109,7 @@ __rpc_thread_createerr (void)
+@@ -109,7 +109,7 @@
return &rpc_createerr;
return &tvp->rpc_createerr_s;
}
@@ -904,7 +889,7 @@ index ac4c18fcee..94d9f1fd80 100644
struct pollfd **
__rpc_thread_svc_pollfd (void)
-@@ -124,7 +124,7 @@ __rpc_thread_svc_pollfd (void)
+@@ -124,7 +124,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (__rpc_thread_svc_pollfd)
#else
@@ -913,7 +898,7 @@ index ac4c18fcee..94d9f1fd80 100644
#endif
int *
-@@ -140,7 +140,7 @@ __rpc_thread_svc_max_pollfd (void)
+@@ -140,7 +140,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (__rpc_thread_svc_max_pollfd)
#else
@@ -922,21 +907,17 @@ index ac4c18fcee..94d9f1fd80 100644
#endif
#endif /* _RPC_THREAD_SAFE_ */
-diff --git a/sunrpc/rtime.c b/sunrpc/rtime.c
-index 8506df554c..bcb280b48f 100644
--- a/sunrpc/rtime.c
+++ b/sunrpc/rtime.c
-@@ -140,4 +140,4 @@ rtime (struct sockaddr_in *addrp, struct rpc_timeval *timep,
+@@ -140,4 +140,4 @@
timep->tv_usec = 0;
return 0;
}
-libc_hidden_nolink (rtime, GLIBC_2_1)
+libc_hidden_nolink_sunrpc (rtime, GLIBC_2_1)
-diff --git a/sunrpc/svc.c b/sunrpc/svc.c
-index e1f4a322e8..103770a42c 100644
--- a/sunrpc/svc.c
+++ b/sunrpc/svc.c
-@@ -115,7 +115,7 @@ xprt_register (SVCXPRT *xprt)
+@@ -115,7 +115,7 @@
POLLRDNORM | POLLRDBAND);
}
}
@@ -945,7 +926,7 @@ index e1f4a322e8..103770a42c 100644
/* De-activate a transport handle. */
void
-@@ -139,7 +139,7 @@ xprt_unregister (SVCXPRT *xprt)
+@@ -139,7 +139,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xprt_unregister)
#else
@@ -954,7 +935,7 @@ index e1f4a322e8..103770a42c 100644
#endif
-@@ -218,7 +218,7 @@ pmap_it:
+@@ -218,7 +218,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svc_register)
#else
@@ -963,7 +944,7 @@ index e1f4a322e8..103770a42c 100644
#endif
/* Remove a service program from the callout list. */
-@@ -242,7 +242,7 @@ svc_unregister (rpcprog_t prog, rpcvers_t vers)
+@@ -242,7 +242,7 @@
if (! svc_is_mapped (prog, vers))
pmap_unset (prog, vers);
}
@@ -972,7 +953,7 @@ index e1f4a322e8..103770a42c 100644
/* ******************* REPLY GENERATION ROUTINES ************ */
-@@ -264,7 +264,7 @@ svc_sendreply (register SVCXPRT *xprt, xdrproc_t xdr_results,
+@@ -264,7 +264,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svc_sendreply)
#else
@@ -981,7 +962,7 @@ index e1f4a322e8..103770a42c 100644
#endif
/* No procedure error reply */
-@@ -282,7 +282,7 @@ svcerr_noproc (register SVCXPRT *xprt)
+@@ -282,7 +282,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svcerr_noproc)
#else
@@ -990,7 +971,7 @@ index e1f4a322e8..103770a42c 100644
#endif
/* Can't decode args error reply */
-@@ -300,7 +300,7 @@ svcerr_decode (register SVCXPRT *xprt)
+@@ -300,7 +300,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svcerr_decode)
#else
@@ -999,7 +980,7 @@ index e1f4a322e8..103770a42c 100644
#endif
/* Some system error */
-@@ -318,7 +318,7 @@ svcerr_systemerr (register SVCXPRT *xprt)
+@@ -318,7 +318,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svcerr_systemerr)
#else
@@ -1008,7 +989,7 @@ index e1f4a322e8..103770a42c 100644
#endif
/* Authentication error reply */
-@@ -333,7 +333,7 @@ svcerr_auth (SVCXPRT *xprt, enum auth_stat why)
+@@ -333,7 +333,7 @@
rply.rjcted_rply.rj_why = why;
SVC_REPLY (xprt, &rply);
}
@@ -1017,7 +998,7 @@ index e1f4a322e8..103770a42c 100644
/* Auth too weak error reply */
void
-@@ -341,7 +341,7 @@ svcerr_weakauth (SVCXPRT *xprt)
+@@ -341,7 +341,7 @@
{
svcerr_auth (xprt, AUTH_TOOWEAK);
}
@@ -1026,7 +1007,7 @@ index e1f4a322e8..103770a42c 100644
/* Program unavailable error reply */
void
-@@ -355,7 +355,7 @@ svcerr_noprog (register SVCXPRT *xprt)
+@@ -355,7 +355,7 @@
rply.acpted_rply.ar_stat = PROG_UNAVAIL;
SVC_REPLY (xprt, &rply);
}
@@ -1035,7 +1016,7 @@ index e1f4a322e8..103770a42c 100644
/* Program version mismatch error reply */
void
-@@ -372,7 +372,7 @@ svcerr_progvers (register SVCXPRT *xprt, rpcvers_t low_vers,
+@@ -372,7 +372,7 @@
rply.acpted_rply.ar_vers.high = high_vers;
SVC_REPLY (xprt, &rply);
}
@@ -1044,7 +1025,7 @@ index e1f4a322e8..103770a42c 100644
/* ******************* SERVER INPUT STUFF ******************* */
-@@ -401,7 +401,7 @@ svc_getreq (int rdfds)
+@@ -401,7 +401,7 @@
readfds.fds_bits[0] = rdfds;
svc_getreqset (&readfds);
}
@@ -1053,7 +1034,7 @@ index e1f4a322e8..103770a42c 100644
void
svc_getreqset (fd_set *readfds)
-@@ -420,7 +420,7 @@ svc_getreqset (fd_set *readfds)
+@@ -420,7 +420,7 @@
for (mask = *maskp++; (bit = ffsl (mask)); mask ^= (1L << (bit - 1)))
svc_getreq_common (sock + bit - 1);
}
@@ -1062,7 +1043,7 @@ index e1f4a322e8..103770a42c 100644
void
svc_getreq_poll (struct pollfd *pfdp, int pollretval)
-@@ -449,7 +449,7 @@ svc_getreq_poll (struct pollfd *pfdp, int pollretval)
+@@ -449,7 +449,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svc_getreq_poll)
#else
@@ -1071,7 +1052,7 @@ index e1f4a322e8..103770a42c 100644
#endif
-@@ -542,7 +542,7 @@ svc_getreq_common (const int fd)
+@@ -542,7 +542,7 @@
}
while (stat == XPRT_MOREREQS);
}
@@ -1080,11 +1061,9 @@ index e1f4a322e8..103770a42c 100644
#ifdef _RPC_THREAD_SAFE_
-diff --git a/sunrpc/svc_auth.c b/sunrpc/svc_auth.c
-index facbb13982..f33bda2f20 100644
--- a/sunrpc/svc_auth.c
+++ b/sunrpc/svc_auth.c
-@@ -105,7 +105,7 @@ _authenticate (register struct svc_req *rqst, struct rpc_msg *msg)
+@@ -105,7 +105,7 @@
return AUTH_REJECTEDCRED;
}
@@ -1093,11 +1072,9 @@ index facbb13982..f33bda2f20 100644
static enum auth_stat
_svcauth_null (struct svc_req *rqst, struct rpc_msg *msg)
-diff --git a/sunrpc/svc_raw.c b/sunrpc/svc_raw.c
-index 90f5d96e63..7d885574af 100644
--- a/sunrpc/svc_raw.c
+++ b/sunrpc/svc_raw.c
-@@ -88,7 +88,7 @@ svcraw_create (void)
+@@ -88,7 +88,7 @@
xdrmem_create (&srp->xdr_stream, srp->_raw_buf, UDPMSGSIZE, XDR_FREE);
return &srp->server;
}
@@ -1106,11 +1083,9 @@ index 90f5d96e63..7d885574af 100644
static enum xprt_stat
svcraw_stat (SVCXPRT *xprt)
-diff --git a/sunrpc/svc_run.c b/sunrpc/svc_run.c
-index 09f40dd188..90dfc94056 100644
--- a/sunrpc/svc_run.c
+++ b/sunrpc/svc_run.c
-@@ -46,7 +46,7 @@ svc_exit (void)
+@@ -46,7 +46,7 @@
svc_pollfd = NULL;
svc_max_pollfd = 0;
}
@@ -1119,18 +1094,16 @@ index 09f40dd188..90dfc94056 100644
void
svc_run (void)
-@@ -104,5 +104,5 @@ svc_run (void)
+@@ -104,5 +104,5 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svc_run)
#else
-libc_hidden_nolink (svc_run, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (svc_run, GLIBC_2_0)
#endif
-diff --git a/sunrpc/svc_tcp.c b/sunrpc/svc_tcp.c
-index e0515322a5..eb615494d8 100644
--- a/sunrpc/svc_tcp.c
+++ b/sunrpc/svc_tcp.c
-@@ -187,7 +187,7 @@ svctcp_create (int sock, u_int sendsize, u_int recvsize)
+@@ -189,7 +189,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svctcp_create)
#else
@@ -1139,7 +1112,7 @@ index e0515322a5..eb615494d8 100644
#endif
/*
-@@ -199,7 +199,7 @@ svcfd_create (int fd, u_int sendsize, u_int recvsize)
+@@ -201,7 +201,7 @@
{
return makefd_xprt (fd, sendsize, recvsize);
}
@@ -1148,11 +1121,9 @@ index e0515322a5..eb615494d8 100644
static SVCXPRT *
internal_function
-diff --git a/sunrpc/svc_udp.c b/sunrpc/svc_udp.c
-index 04c8407e64..6c4d75a814 100644
--- a/sunrpc/svc_udp.c
+++ b/sunrpc/svc_udp.c
-@@ -184,7 +184,7 @@ svcudp_create: xp_pad is too small for IP_PKTINFO\n"));
+@@ -186,7 +186,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svcudp_bufcreate)
#else
@@ -1161,7 +1132,7 @@ index 04c8407e64..6c4d75a814 100644
#endif
SVCXPRT *
-@@ -196,7 +196,7 @@ svcudp_create (sock)
+@@ -198,7 +198,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svcudp_create)
#else
@@ -1170,7 +1141,7 @@ index 04c8407e64..6c4d75a814 100644
#endif
static enum xprt_stat
-@@ -500,7 +500,7 @@ svcudp_enablecache (SVCXPRT *transp, u_long size)
+@@ -502,7 +502,7 @@
su->su_cache = (char *) uc;
return 1;
}
@@ -1179,11 +1150,9 @@ index 04c8407e64..6c4d75a814 100644
/*
-diff --git a/sunrpc/svc_unix.c b/sunrpc/svc_unix.c
-index 2b02682e72..94507b2403 100644
--- a/sunrpc/svc_unix.c
+++ b/sunrpc/svc_unix.c
-@@ -184,7 +184,7 @@ svcunix_create (int sock, u_int sendsize, u_int recvsize, char *path)
+@@ -187,7 +187,7 @@
xprt_register (xprt);
return xprt;
}
@@ -1192,7 +1161,7 @@ index 2b02682e72..94507b2403 100644
/*
* Like svunix_create(), except the routine takes any *open* UNIX file
-@@ -195,7 +195,7 @@ svcunixfd_create (int fd, u_int sendsize, u_int recvsize)
+@@ -198,7 +198,7 @@
{
return makefd_xprt (fd, sendsize, recvsize);
}
@@ -1201,11 +1170,9 @@ index 2b02682e72..94507b2403 100644
static SVCXPRT *
internal_function
-diff --git a/sunrpc/svcauth_des.c b/sunrpc/svcauth_des.c
-index b9656e25da..9609734960 100644
--- a/sunrpc/svcauth_des.c
+++ b/sunrpc/svcauth_des.c
-@@ -583,7 +583,7 @@ authdes_getucred (const struct authdes_cred *adc, uid_t * uid, gid_t * gid,
+@@ -583,7 +583,7 @@
groups[i] = cred->groups[i];
return 1;
}
@@ -1214,11 +1181,9 @@ index b9656e25da..9609734960 100644
static void
internal_function
-diff --git a/sunrpc/xcrypt.c b/sunrpc/xcrypt.c
-index 8b7642b503..2e53f2d9e9 100644
--- a/sunrpc/xcrypt.c
+++ b/sunrpc/xcrypt.c
-@@ -127,7 +127,7 @@ xencrypt (char *secret, char *passwd)
+@@ -127,7 +127,7 @@
free (buf);
return 1;
}
@@ -1227,7 +1192,7 @@ index 8b7642b503..2e53f2d9e9 100644
/*
* Decrypt secret key using passwd
-@@ -163,7 +163,7 @@ xdecrypt (char *secret, char *passwd)
+@@ -163,7 +163,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdecrypt)
#else
@@ -1236,11 +1201,9 @@ index 8b7642b503..2e53f2d9e9 100644
#endif
/*
-diff --git a/sunrpc/xdr.c b/sunrpc/xdr.c
-index 4dd82ff044..7eac2d40f0 100644
--- a/sunrpc/xdr.c
+++ b/sunrpc/xdr.c
-@@ -72,7 +72,7 @@ xdr_free (xdrproc_t proc, char *objp)
+@@ -74,7 +74,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_free)
#else
@@ -1249,7 +1212,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -86,7 +86,7 @@ xdr_void (void)
+@@ -88,7 +88,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_void)
#else
@@ -1258,7 +1221,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -126,7 +126,7 @@ xdr_int (XDR *xdrs, int *ip)
+@@ -128,7 +128,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_int)
#else
@@ -1267,7 +1230,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -165,7 +165,7 @@ xdr_u_int (XDR *xdrs, u_int *up)
+@@ -167,7 +167,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_u_int)
#else
@@ -1276,7 +1239,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -193,7 +193,7 @@ xdr_long (XDR *xdrs, long *lp)
+@@ -195,7 +195,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_long)
#else
@@ -1285,7 +1248,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -232,7 +232,7 @@ xdr_u_long (XDR *xdrs, u_long *ulp)
+@@ -234,7 +234,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_u_long)
#else
@@ -1294,7 +1257,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -268,7 +268,7 @@ xdr_hyper (XDR *xdrs, quad_t *llp)
+@@ -270,7 +270,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_hyper)
#else
@@ -1303,7 +1266,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -304,7 +304,7 @@ xdr_u_hyper (XDR *xdrs, u_quad_t *ullp)
+@@ -306,7 +306,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_u_hyper)
#else
@@ -1312,7 +1275,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
bool_t
-@@ -315,7 +315,7 @@ xdr_longlong_t (XDR *xdrs, quad_t *llp)
+@@ -317,7 +317,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_longlong_t)
#else
@@ -1321,7 +1284,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
bool_t
-@@ -326,7 +326,7 @@ xdr_u_longlong_t (XDR *xdrs, u_quad_t *ullp)
+@@ -328,7 +328,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_u_longlong_t)
#else
@@ -1330,7 +1293,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -359,7 +359,7 @@ xdr_short (XDR *xdrs, short *sp)
+@@ -361,7 +361,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_short)
#else
@@ -1339,7 +1302,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -392,7 +392,7 @@ xdr_u_short (XDR *xdrs, u_short *usp)
+@@ -394,7 +394,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_u_short)
#else
@@ -1348,7 +1311,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
-@@ -415,7 +415,7 @@ xdr_char (XDR *xdrs, char *cp)
+@@ -417,7 +417,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_char)
#else
@@ -1357,7 +1320,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -437,7 +437,7 @@ xdr_u_char (XDR *xdrs, u_char *cp)
+@@ -439,7 +439,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_u_char)
#else
@@ -1366,7 +1329,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -470,7 +470,7 @@ xdr_bool (XDR *xdrs, bool_t *bp)
+@@ -472,7 +472,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_bool)
#else
@@ -1375,7 +1338,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -525,7 +525,7 @@ xdr_enum (XDR *xdrs, enum_t *ep)
+@@ -527,7 +527,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_enum)
#else
@@ -1384,7 +1347,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -580,7 +580,7 @@ xdr_opaque (XDR *xdrs, caddr_t cp, u_int cnt)
+@@ -582,7 +582,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_opaque)
#else
@@ -1393,7 +1356,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -648,7 +648,7 @@ xdr_bytes (xdrs, cpp, sizep, maxsize)
+@@ -650,7 +650,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_bytes)
#else
@@ -1402,7 +1365,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -665,7 +665,7 @@ xdr_netobj (xdrs, np)
+@@ -667,7 +667,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_netobj)
#else
@@ -1411,7 +1374,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -714,7 +714,7 @@ xdr_union (xdrs, dscmp, unp, choices, dfault)
+@@ -716,7 +716,7 @@
return ((dfault == NULL_xdrproc_t) ? FALSE :
(*dfault) (xdrs, unp, LASTUNSIGNED));
}
@@ -1420,7 +1383,7 @@ index 4dd82ff044..7eac2d40f0 100644
/*
-@@ -806,7 +806,7 @@ xdr_string (xdrs, cpp, maxsize)
+@@ -808,7 +808,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_string)
#else
@@ -1429,18 +1392,16 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -827,5 +827,5 @@ xdr_wrapstring (xdrs, cpp)
+@@ -829,5 +829,5 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_wrapstring)
#else
-libc_hidden_nolink (xdr_wrapstring, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_wrapstring, GLIBC_2_0)
#endif
-diff --git a/sunrpc/xdr_array.c b/sunrpc/xdr_array.c
-index b832078342..a634861278 100644
--- a/sunrpc/xdr_array.c
+++ b/sunrpc/xdr_array.c
-@@ -127,7 +127,7 @@ xdr_array (xdrs, addrp, sizep, maxsize, elsize, elproc)
+@@ -130,7 +130,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_array)
#else
@@ -1449,17 +1410,15 @@ index b832078342..a634861278 100644
#endif
/*
-@@ -162,4 +162,4 @@ xdr_vector (xdrs, basep, nelem, elemsize, xdr_elem)
+@@ -165,4 +165,4 @@
}
return TRUE;
}
-libc_hidden_nolink (xdr_vector, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_vector, GLIBC_2_0)
-diff --git a/sunrpc/xdr_float.c b/sunrpc/xdr_float.c
-index 1a9c260617..78e8f3bd2d 100644
--- a/sunrpc/xdr_float.c
+++ b/sunrpc/xdr_float.c
-@@ -158,7 +158,7 @@ xdr_float(xdrs, fp)
+@@ -158,7 +158,7 @@
}
return (FALSE);
}
@@ -1468,17 +1427,15 @@ index 1a9c260617..78e8f3bd2d 100644
/*
* This routine works on Suns (Sky / 68000's) and Vaxen.
-@@ -300,4 +300,4 @@ xdr_double(xdrs, dp)
+@@ -300,4 +300,4 @@
}
return (FALSE);
}
-libc_hidden_nolink (xdr_double, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_double, GLIBC_2_0)
-diff --git a/sunrpc/xdr_intXX_t.c b/sunrpc/xdr_intXX_t.c
-index fe06f45df3..02a0c09b5b 100644
--- a/sunrpc/xdr_intXX_t.c
+++ b/sunrpc/xdr_intXX_t.c
-@@ -46,14 +46,14 @@ xdr_int64_t (XDR *xdrs, int64_t *ip)
+@@ -47,14 +47,14 @@
return FALSE;
}
}
@@ -1495,7 +1452,7 @@ index fe06f45df3..02a0c09b5b 100644
/* XDR 64bit unsigned integers */
bool_t
-@@ -82,14 +82,14 @@ xdr_uint64_t (XDR *xdrs, uint64_t *uip)
+@@ -83,14 +83,14 @@
return FALSE;
}
}
@@ -1512,7 +1469,7 @@ index fe06f45df3..02a0c09b5b 100644
/* XDR 32bit integers */
bool_t
-@@ -107,7 +107,7 @@ xdr_int32_t (XDR *xdrs, int32_t *lp)
+@@ -108,7 +108,7 @@
return FALSE;
}
}
@@ -1521,7 +1478,7 @@ index fe06f45df3..02a0c09b5b 100644
/* XDR 32bit unsigned integers */
bool_t
-@@ -128,7 +128,7 @@ xdr_uint32_t (XDR *xdrs, uint32_t *ulp)
+@@ -129,7 +129,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_uint32_t)
#else
@@ -1530,7 +1487,7 @@ index fe06f45df3..02a0c09b5b 100644
#endif
/* XDR 16bit integers */
-@@ -153,7 +153,7 @@ xdr_int16_t (XDR *xdrs, int16_t *ip)
+@@ -154,7 +154,7 @@
return FALSE;
}
}
@@ -1539,7 +1496,7 @@ index fe06f45df3..02a0c09b5b 100644
/* XDR 16bit unsigned integers */
bool_t
-@@ -177,7 +177,7 @@ xdr_uint16_t (XDR *xdrs, uint16_t *uip)
+@@ -178,7 +178,7 @@
return FALSE;
}
}
@@ -1548,7 +1505,7 @@ index fe06f45df3..02a0c09b5b 100644
/* XDR 8bit integers */
bool_t
-@@ -201,7 +201,7 @@ xdr_int8_t (XDR *xdrs, int8_t *ip)
+@@ -202,7 +202,7 @@
return FALSE;
}
}
@@ -1557,17 +1514,15 @@ index fe06f45df3..02a0c09b5b 100644
/* XDR 8bit unsigned integers */
bool_t
-@@ -225,4 +225,4 @@ xdr_uint8_t (XDR *xdrs, uint8_t *uip)
+@@ -226,4 +226,4 @@
return FALSE;
}
}
-libc_hidden_nolink (xdr_uint8_t, GLIBC_2_1)
+libc_hidden_nolink_sunrpc (xdr_uint8_t, GLIBC_2_1)
-diff --git a/sunrpc/xdr_mem.c b/sunrpc/xdr_mem.c
-index 093a718739..ba7661aa54 100644
--- a/sunrpc/xdr_mem.c
+++ b/sunrpc/xdr_mem.c
-@@ -81,7 +81,7 @@ xdrmem_create (XDR *xdrs, const caddr_t addr, u_int size, enum xdr_op op)
+@@ -81,7 +81,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdrmem_create)
#else
@@ -1576,11 +1531,9 @@ index 093a718739..ba7661aa54 100644
#endif
/*
-diff --git a/sunrpc/xdr_rec.c b/sunrpc/xdr_rec.c
-index 556c6c4bc0..f5d6ef2af9 100644
--- a/sunrpc/xdr_rec.c
+++ b/sunrpc/xdr_rec.c
-@@ -189,7 +189,7 @@ xdrrec_create (XDR *xdrs, u_int sendsize,
+@@ -192,7 +192,7 @@
rstrm->fbtbc = 0;
rstrm->last_frag = TRUE;
}
@@ -1589,7 +1542,7 @@ index 556c6c4bc0..f5d6ef2af9 100644
/*
-@@ -477,7 +477,7 @@ xdrrec_skiprecord (XDR *xdrs)
+@@ -480,7 +480,7 @@
rstrm->last_frag = FALSE;
return TRUE;
}
@@ -1598,7 +1551,7 @@ index 556c6c4bc0..f5d6ef2af9 100644
/*
* Lookahead function.
-@@ -501,7 +501,7 @@ xdrrec_eof (XDR *xdrs)
+@@ -504,7 +504,7 @@
return TRUE;
return FALSE;
}
@@ -1607,7 +1560,7 @@ index 556c6c4bc0..f5d6ef2af9 100644
/*
* The client must tell the package when an end-of-record has occurred.
-@@ -528,7 +528,7 @@ xdrrec_endofrecord (XDR *xdrs, bool_t sendnow)
+@@ -531,7 +531,7 @@
rstrm->out_finger += BYTES_PER_XDR_UNIT;
return TRUE;
}
@@ -1616,11 +1569,9 @@ index 556c6c4bc0..f5d6ef2af9 100644
/*
-diff --git a/sunrpc/xdr_ref.c b/sunrpc/xdr_ref.c
-index 7510bed873..8fb4584a75 100644
--- a/sunrpc/xdr_ref.c
+++ b/sunrpc/xdr_ref.c
-@@ -90,7 +90,7 @@ xdr_reference (xdrs, pp, size, proc)
+@@ -93,7 +93,7 @@
}
return stat;
}
@@ -1629,29 +1580,25 @@ index 7510bed873..8fb4584a75 100644
/*
-@@ -137,5 +137,5 @@ xdr_pointer (xdrs, objpp, obj_size, xdr_obj)
+@@ -140,5 +140,5 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_pointer)
#else
-libc_hidden_nolink (xdr_pointer, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_pointer, GLIBC_2_0)
#endif
-diff --git a/sunrpc/xdr_sizeof.c b/sunrpc/xdr_sizeof.c
-index 0119486c3d..56e870a455 100644
--- a/sunrpc/xdr_sizeof.c
+++ b/sunrpc/xdr_sizeof.c
-@@ -161,5 +161,5 @@ xdr_sizeof (xdrproc_t func, void *data)
+@@ -161,5 +161,5 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_sizeof)
#else
-libc_hidden_nolink (xdr_sizeof, GLIBC_2_1)
+libc_hidden_nolink_sunrpc (xdr_sizeof, GLIBC_2_1)
#endif
-diff --git a/sunrpc/xdr_stdio.c b/sunrpc/xdr_stdio.c
-index d9866063f9..667515e0a6 100644
--- a/sunrpc/xdr_stdio.c
+++ b/sunrpc/xdr_stdio.c
-@@ -191,5 +191,5 @@ xdrstdio_putint32 (XDR *xdrs, const int32_t *ip)
+@@ -193,5 +193,5 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdrstdio_create)
#else
diff --git a/packages/glibc/2.12.2/998-obstack-common.patch b/packages/glibc/2.14.1/0042-obstack-common.patch
index 4b95f06..1993be2 100644
--- a/packages/glibc/2.12.2/998-obstack-common.patch
+++ b/packages/glibc/2.14.1/0042-obstack-common.patch
@@ -15,11 +15,13 @@ Date: Wed May 15 20:28:08 2013 +0200
* malloc/obstack.c (_obstack_compat): Add initializer.
-
-diff --git a/malloc/obstack.c b/malloc/obstack.c
-index 25a90514f7..c3c7db4a96 100644
+---
+ malloc/obstack.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
--- a/malloc/obstack.c
+++ b/malloc/obstack.c
-@@ -115,7 +115,7 @@ int obstack_exit_failure = EXIT_FAILURE;
+@@ -117,7 +117,7 @@
/* A looong time ago (before 1994, anyway; we're not sure) this global variable
was used by non-GNU-C macros to avoid multiple evaluation. The GNU C
library still exports it because somebody might use it. */
diff --git a/packages/glibc/2.15/999-new-tools.patch b/packages/glibc/2.14.1/0043-new-tools.patch
index e0632a3..2d89a0f 100644
--- a/packages/glibc/2.15/999-new-tools.patch
+++ b/packages/glibc/2.14.1/0043-new-tools.patch
@@ -1,7 +1,11 @@
-diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
---- glibc-2.15.orig/configure 2012-03-19 07:56:58.000000000 -0700
-+++ glibc-2.15/configure 2017-02-08 00:38:53.578049806 -0800
-@@ -4922,7 +4922,7 @@ $as_echo_n "checking version of $CC... "
+---
+ configure | 8 ++++----
+ configure.in | 8 ++++----
+ 2 files changed, 8 insertions(+), 8 deletions(-)
+
+--- a/configure
++++ b/configure
+@@ -4957,7 +4957,7 @@
ac_prog_version=`$CC -v 2>&1 | sed -n 's/^.*version \([egcygnustpi-]*[0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -10,7 +14,7 @@ diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -4985,7 +4985,7 @@ $as_echo_n "checking version of $MAKE...
+@@ -5020,7 +5020,7 @@
ac_prog_version=`$MAKE --version 2>&1 | sed -n 's/^.*GNU Make[^0-9]*\([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -19,7 +23,7 @@ diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5112,7 +5112,7 @@ $as_echo_n "checking version of $MAKEINF
+@@ -5147,7 +5147,7 @@
ac_prog_version=`$MAKEINFO --version 2>&1 | sed -n 's/^.*GNU texinfo.* \([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -28,7 +32,7 @@ diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5172,7 +5172,7 @@ else
+@@ -5207,7 +5207,7 @@
# Found it, now check the version.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking version of $SED" >&5
$as_echo_n "checking version of $SED... " >&6; }
@@ -37,10 +41,9 @@ diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
3.0[2-9]*|3.[1-9]*|[4-9]*)
-diff -urpN glibc-2.15.orig/configure.in glibc-2.15/configure.in
---- glibc-2.15.orig/configure.in 2012-01-01 04:16:32.000000000 -0800
-+++ glibc-2.15/configure.in 2017-02-08 00:30:47.440841480 -0800
-@@ -1000,11 +1000,11 @@ fi
+--- a/configure.in
++++ b/configure.in
+@@ -1037,11 +1037,11 @@
# These programs are version sensitive.
AC_CHECK_TOOL_PREFIX
AC_CHECK_PROG_VER(CC, ${ac_tool_prefix}gcc ${ac_tool_prefix}cc, -v,
@@ -54,7 +57,7 @@ diff -urpN glibc-2.15.orig/configure.in glibc-2.15/configure.in
AC_CHECK_PROG_VER(MSGFMT, gnumsgfmt gmsgfmt msgfmt, --version,
[GNU gettext.* \([0-9]*\.[0-9.]*\)],
-@@ -1012,10 +1012,10 @@ AC_CHECK_PROG_VER(MSGFMT, gnumsgfmt gmsg
+@@ -1049,10 +1049,10 @@
MSGFMT=: aux_missing="$aux_missing msgfmt")
AC_CHECK_PROG_VER(MAKEINFO, makeinfo, --version,
[GNU texinfo.* \([0-9][0-9.]*\)],
diff --git a/packages/glibc/2.14.1/430-alpha-creat.patch b/packages/glibc/2.14.1/430-alpha-creat.patch
deleted file mode 100644
index da6ddda..0000000
--- a/packages/glibc/2.14.1/430-alpha-creat.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-alpha does not have a __NR_creat
-
-http://bugs.gentoo.org/227275
-http://sourceware.org/bugzilla/show_bug.cgi?id=6650
-
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/wordsize-64/creat64.c glibc-2.13/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/wordsize-64/creat64.c 2007-11-10 20:34:26.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/wordsize-64/creat64.c 2009-11-13 00:50:51.000000000 +0100
-@@ -1 +1,5 @@
- /* Defined as alias for the syscall. */
-+#include <sysdep.h>
-+#ifndef __NR_creat
-+#include "../../../../../io/creat64.c"
-+#endif
diff --git a/packages/glibc/2.14.1/660-debug-readlink_chk-readklinkat_chk.patch b/packages/glibc/2.14.1/660-debug-readlink_chk-readklinkat_chk.patch
deleted file mode 100644
index a5a7052..0000000
--- a/packages/glibc/2.14.1/660-debug-readlink_chk-readklinkat_chk.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-diff -dur glibc-cvs-2.9.orig/debug/readlink_chk.c glibc-cvs-2.9/debug/readlink_chk.c
---- glibc-cvs-2.9.orig/debug/readlink_chk.c 2005-03-01 01:41:15.000000000 +0100
-+++ glibc-cvs-2.9/debug/readlink_chk.c 2009-06-01 10:59:37.000000000 +0200
-@@ -25,7 +25,7 @@
-
-
- ssize_t
--__readlink_chk (const char *path, void *buf, size_t len, size_t buflen)
-+__readlink_chk (const char *path, char *buf, size_t len, size_t buflen)
- {
- if (len > buflen)
- __chk_fail ();
-diff -dur glibc-cvs-2.9.orig/debug/readlinkat_chk.c glibc-cvs-2.9/debug/readlinkat_chk.c
---- glibc-cvs-2.9.orig/debug/readlinkat_chk.c 2006-04-24 18:56:12.000000000 +0200
-+++ glibc-cvs-2.9/debug/readlinkat_chk.c 2009-06-01 11:07:26.000000000 +0200
-@@ -21,7 +21,7 @@
-
-
- ssize_t
--__readlinkat_chk (int fd, const char *path, void *buf, size_t len,
-+__readlinkat_chk (int fd, const char *path, char *buf, size_t len,
- size_t buflen)
- {
- if (len > buflen)
diff --git a/packages/glibc/2.15/100-respect-env-CPPFLAGS.patch b/packages/glibc/2.15/0000-respect-env-CPPFLAGS.patch
index 3798cb2..4e08fd6 100644
--- a/packages/glibc/2.15/100-respect-env-CPPFLAGS.patch
+++ b/packages/glibc/2.15/0000-respect-env-CPPFLAGS.patch
@@ -1,10 +1,13 @@
Respect environment CPPFLAGS when we run ./configure so we can inject
random -D things without having to set CFLAGS/ASFLAGS
-diff -durN glibc-2.13.orig/Makeconfig glibc-2.13/Makeconfig
---- glibc-2.13.orig/Makeconfig 2009-05-09 23:57:56.000000000 +0200
-+++ glibc-2.13/Makeconfig 2009-11-13 00:49:41.000000000 +0100
-@@ -697,6 +697,7 @@
+---
+ Makeconfig | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/Makeconfig
++++ b/Makeconfig
+@@ -709,6 +709,7 @@
$(foreach lib,$(libof-$(basename $(@F))) \
$(libof-$(<F)) $(libof-$(@F)),$(CPPFLAGS-$(lib))) \
$(CPPFLAGS-$(<F)) $(CPPFLAGS-$(@F)) $(CPPFLAGS-$(basename $(@F)))
diff --git a/packages/glibc/2.15/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.15/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
index 6fd663a..30a70a2 100644
--- a/packages/glibc/2.15/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
+++ b/packages/glibc/2.15/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
@@ -5,16 +5,13 @@ Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
-Wparentheses
---
- ChangeLog | 5 +++++
- nis/nis_call.c | 20 +++++++++++---------
- stdlib/setenv.c | 26 ++++++++++++++------------
- 3 files changed, 30 insertions(+), 21 deletions(-)
+ nis/nis_call.c | 20 +++++++++++---------
+ stdlib/setenv.c | 24 +++++++++++++-----------
+ 2 files changed, 24 insertions(+), 20 deletions(-)
-diff --git a/nis/nis_call.c b/nis/nis_call.c
-index 3fa37e4..cb7839a 100644
--- a/nis/nis_call.c
+++ b/nis/nis_call.c
-@@ -680,16 +680,18 @@ nis_server_cache_add (const_nis_name name, int search_parent,
+@@ -682,16 +682,18 @@
/* Choose which entry should be evicted from the cache. */
loc = &nis_server_cache[0];
if (*loc != NULL)
@@ -42,11 +39,9 @@ index 3fa37e4..cb7839a 100644
old = *loc;
*loc = new;
-diff --git a/stdlib/setenv.c b/stdlib/setenv.c
-index da61ee0..e66045f 100644
--- a/stdlib/setenv.c
+++ b/stdlib/setenv.c
-@@ -278,18 +278,20 @@ unsetenv (const char *name)
+@@ -328,18 +328,20 @@
ep = __environ;
if (ep != NULL)
while (*ep != NULL)
@@ -54,7 +49,12 @@ index da61ee0..e66045f 100644
- {
- /* Found it. Remove this pointer by moving later ones back. */
- char **dp = ep;
--
++ {
++ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
++ {
++ /* Found it. Remove this pointer by moving later ones back. */
++ char **dp = ep;
+
- do
- dp[0] = dp[1];
- while (*dp++);
@@ -62,12 +62,6 @@ index da61ee0..e66045f 100644
- }
- else
- ++ep;
-+ {
-+ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-+ {
-+ /* Found it. Remove this pointer by moving later ones back. */
-+ char **dp = ep;
-+
+ do
+ dp[0] = dp[1];
+ while (*dp++);
@@ -79,6 +73,3 @@ index da61ee0..e66045f 100644
UNLOCK;
---
-2.7.4
-
diff --git a/packages/glibc/2.15/102-fix-signed-shift-overlow.patch b/packages/glibc/2.15/0002-fix-signed-shift-overlow.patch
index ef49f83..437818b 100644
--- a/packages/glibc/2.15/102-fix-signed-shift-overlow.patch
+++ b/packages/glibc/2.15/0002-fix-signed-shift-overlow.patch
@@ -12,11 +12,16 @@ Date: Tue Jul 21 22:50:29 2015 -0700
* string/strchrnul.c (STRCHRNUL):
Rewrite code to avoid issues with signed shift overflow.
-diff --git a/string/memrchr.c b/string/memrchr.c
-index 0c8fd84..86cd5b9 100644
+---
+ string/memrchr.c | 11 ++---------
+ string/rawmemchr.c | 11 ++---------
+ string/strchr.c | 9 ++-------
+ string/strchrnul.c | 9 ++-------
+ 4 files changed, 8 insertions(+), 32 deletions(-)
+
--- a/string/memrchr.c
+++ b/string/memrchr.c
-@@ -96,15 +96,8 @@ MEMRCHR
+@@ -103,15 +103,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
@@ -34,11 +39,9 @@ index 0c8fd84..86cd5b9 100644
/* Set up a longword, each of whose bytes is C. */
charmask = c | (c << 8);
-diff --git a/string/rawmemchr.c b/string/rawmemchr.c
-index 05b22be..228ca9d 100644
--- a/string/rawmemchr.c
+++ b/string/rawmemchr.c
-@@ -86,15 +86,8 @@ RAWMEMCHR (s, c_in)
+@@ -90,15 +90,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
@@ -56,11 +59,9 @@ index 05b22be..228ca9d 100644
/* Set up a longword, each of whose bytes is C. */
charmask = c | (c << 8);
-diff --git a/string/strchr.c b/string/strchr.c
-index 5f90075..f13b2b3 100644
--- a/string/strchr.c
+++ b/string/strchr.c
-@@ -60,13 +60,8 @@ strchr (const char *s, int c_in)
+@@ -65,13 +65,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
@@ -76,11 +77,9 @@ index 5f90075..f13b2b3 100644
/* Set up a longword, each of whose bytes is C. */
charmask = c | (c << 8);
-diff --git a/string/strchrnul.c b/string/strchrnul.c
-index 2678f1d..daf0b3f 100644
--- a/string/strchrnul.c
+++ b/string/strchrnul.c
-@@ -66,13 +66,8 @@ STRCHRNUL (s, c_in)
+@@ -63,13 +63,8 @@
The 1-bits make sure that carries propagate to the next 0-bit.
The 0-bits provide holes for carries to fall into. */
diff --git a/packages/glibc/2.15/0003-dl-openat64-variadic.patch b/packages/glibc/2.15/0003-dl-openat64-variadic.patch
new file mode 100644
index 0000000..e69bb17
--- /dev/null
+++ b/packages/glibc/2.15/0003-dl-openat64-variadic.patch
@@ -0,0 +1,197 @@
+commit 9dd346ff431fc761f1b748bd4da8bb59f7652094
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Tue Oct 20 11:54:09 2015 +0000
+
+ Convert 113 more function definitions to prototype style (files with assertions).
+
+ This mostly automatically-generated patch converts 113 function
+ definitions in glibc from old-style K&R to prototype-style. Following
+ my other recent such patches, this one deals with the case of function
+ definitions in files that either contain assertions or where grep
+ suggested they might contain assertions - and thus where it isn't
+ possible to use a simple object code comparison as a sanity check on
+ the correctness of the patch, because line numbers are changed.
+
+ A few such automatically-generated changes needed to be supplemented
+ by manual changes for the result to compile. openat64 had a prototype
+ declaration with "..." but an old-style definition in
+ sysdeps/unix/sysv/linux/dl-openat64.c, and "..." needed adding to the
+ generated prototype in the definition (I've filed
+ <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68024> for diagnosing
+ such cases in GCC; the old state was undefined behavior not requiring
+ a diagnostic, but one seems a good idea). In addition, as Florian has
+ noted regparm attribute mismatches between declaration and definition
+ are only diagnosed for prototype definitions, and five functions
+ needed internal_function added to their definitions (in the case of
+ __pthread_mutex_cond_lock, via the macro definition of
+ __pthread_mutex_lock) to compile on i386.
+
+ After this patch is in, remaining old-style definitions are probably
+ most readily fixed manually before we can turn on
+ -Wold-style-definition for all builds.
+
+ Tested for x86_64 and x86 (testsuite).
+
+ * crypt/md5-crypt.c (__md5_crypt_r): Convert to prototype-style
+ function definition.
+ * crypt/sha256-crypt.c (__sha256_crypt_r): Likewise.
+ * crypt/sha512-crypt.c (__sha512_crypt_r): Likewise.
+ * debug/backtracesyms.c (__backtrace_symbols): Likewise.
+ * elf/dl-minimal.c (_itoa): Likewise.
+ * hurd/hurdmalloc.c (malloc): Likewise.
+ (free): Likewise.
+ (realloc): Likewise.
+ * inet/inet6_option.c (inet6_option_space): Likewise.
+ (inet6_option_init): Likewise.
+ (inet6_option_append): Likewise.
+ (inet6_option_alloc): Likewise.
+ (inet6_option_next): Likewise.
+ (inet6_option_find): Likewise.
+ * io/ftw.c (FTW_NAME): Likewise.
+ (NFTW_NAME): Likewise.
+ (NFTW_NEW_NAME): Likewise.
+ (NFTW_OLD_NAME): Likewise.
+ * libio/iofwide.c (_IO_fwide): Likewise.
+ * libio/strops.c (_IO_str_init_static_internal): Likewise.
+ (_IO_str_init_static): Likewise.
+ (_IO_str_init_readonly): Likewise.
+ (_IO_str_overflow): Likewise.
+ (_IO_str_underflow): Likewise.
+ (_IO_str_count): Likewise.
+ (_IO_str_seekoff): Likewise.
+ (_IO_str_pbackfail): Likewise.
+ (_IO_str_finish): Likewise.
+ * libio/wstrops.c (_IO_wstr_init_static): Likewise.
+ (_IO_wstr_overflow): Likewise.
+ (_IO_wstr_underflow): Likewise.
+ (_IO_wstr_count): Likewise.
+ (_IO_wstr_seekoff): Likewise.
+ (_IO_wstr_pbackfail): Likewise.
+ (_IO_wstr_finish): Likewise.
+ * locale/programs/localedef.c (normalize_codeset): Likewise.
+ * locale/programs/locarchive.c (add_locale_to_archive): Likewise.
+ (add_locales_to_archive): Likewise.
+ (delete_locales_from_archive): Likewise.
+ * malloc/malloc.c (__libc_mallinfo): Likewise.
+ * math/gen-auto-libm-tests.c (init_fp_formats): Likewise.
+ * misc/tsearch.c (__tfind): Likewise.
+ * nptl/pthread_attr_destroy.c (__pthread_attr_destroy): Likewise.
+ * nptl/pthread_attr_getdetachstate.c
+ (__pthread_attr_getdetachstate): Likewise.
+ * nptl/pthread_attr_getguardsize.c (pthread_attr_getguardsize):
+ Likewise.
+ * nptl/pthread_attr_getinheritsched.c
+ (__pthread_attr_getinheritsched): Likewise.
+ * nptl/pthread_attr_getschedparam.c
+ (__pthread_attr_getschedparam): Likewise.
+ * nptl/pthread_attr_getschedpolicy.c
+ (__pthread_attr_getschedpolicy): Likewise.
+ * nptl/pthread_attr_getscope.c (__pthread_attr_getscope):
+ Likewise.
+ * nptl/pthread_attr_getstack.c (__pthread_attr_getstack):
+ Likewise.
+ * nptl/pthread_attr_getstackaddr.c (__pthread_attr_getstackaddr):
+ Likewise.
+ * nptl/pthread_attr_getstacksize.c (__pthread_attr_getstacksize):
+ Likewise.
+ * nptl/pthread_attr_init.c (__pthread_attr_init_2_1): Likewise.
+ (__pthread_attr_init_2_0): Likewise.
+ * nptl/pthread_attr_setdetachstate.c
+ (__pthread_attr_setdetachstate): Likewise.
+ * nptl/pthread_attr_setguardsize.c (pthread_attr_setguardsize):
+ Likewise.
+ * nptl/pthread_attr_setinheritsched.c
+ (__pthread_attr_setinheritsched): Likewise.
+ * nptl/pthread_attr_setschedparam.c
+ (__pthread_attr_setschedparam): Likewise.
+ * nptl/pthread_attr_setschedpolicy.c
+ (__pthread_attr_setschedpolicy): Likewise.
+ * nptl/pthread_attr_setscope.c (__pthread_attr_setscope):
+ Likewise.
+ * nptl/pthread_attr_setstack.c (__pthread_attr_setstack):
+ Likewise.
+ * nptl/pthread_attr_setstackaddr.c (__pthread_attr_setstackaddr):
+ Likewise.
+ * nptl/pthread_attr_setstacksize.c (__pthread_attr_setstacksize):
+ Likewise.
+ * nptl/pthread_condattr_setclock.c (pthread_condattr_setclock):
+ Likewise.
+ * nptl/pthread_create.c (__find_in_stack_list): Likewise.
+ * nptl/pthread_getattr_np.c (pthread_getattr_np): Likewise.
+ * nptl/pthread_mutex_cond_lock.c (__pthread_mutex_lock): Define to
+ use internal_function.
+ * nptl/pthread_mutex_init.c (__pthread_mutex_init): Convert to
+ prototype-style function definition.
+ * nptl/pthread_mutex_lock.c (__pthread_mutex_lock): Likewise.
+ (__pthread_mutex_cond_lock_adjust): Likewise. Use
+ internal_function.
+ * nptl/pthread_mutex_timedlock.c (pthread_mutex_timedlock):
+ Convert to prototype-style function definition.
+ * nptl/pthread_mutex_trylock.c (__pthread_mutex_trylock):
+ Likewise.
+ * nptl/pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt):
+ Likewise.
+ (__pthread_mutex_unlock): Likewise.
+ * nptl_db/td_ta_clear_event.c (td_ta_clear_event): Likewise.
+ * nptl_db/td_ta_set_event.c (td_ta_set_event): Likewise.
+ * nptl_db/td_thr_clear_event.c (td_thr_clear_event): Likewise.
+ * nptl_db/td_thr_event_enable.c (td_thr_event_enable): Likewise.
+ * nptl_db/td_thr_set_event.c (td_thr_set_event): Likewise.
+ * nss/makedb.c (process_input): Likewise.
+ * posix/fnmatch.c (__strchrnul): Likewise.
+ (__wcschrnul): Likewise.
+ (fnmatch): Likewise.
+ * posix/fnmatch_loop.c (FCT): Likewise.
+ * posix/glob.c (globfree): Likewise.
+ (__glob_pattern_type): Likewise.
+ (__glob_pattern_p): Likewise.
+ * posix/regcomp.c (re_compile_pattern): Likewise.
+ (re_set_syntax): Likewise.
+ (re_compile_fastmap): Likewise.
+ (regcomp): Likewise.
+ (regerror): Likewise.
+ (regfree): Likewise.
+ * posix/regexec.c (regexec): Likewise.
+ (re_match): Likewise.
+ (re_search): Likewise.
+ (re_match_2): Likewise.
+ (re_search_2): Likewise.
+ (re_search_stub): Likewise. Use internal_function
+ (re_copy_regs): Likewise.
+ (re_set_registers): Convert to prototype-style function
+ definition.
+ (prune_impossible_nodes): Likewise. Use internal_function.
+ * resolv/inet_net_pton.c (inet_net_pton): Convert to
+ prototype-style function definition.
+ (inet_net_pton_ipv4): Likewise.
+ * stdlib/strtod_l.c (____STRTOF_INTERNAL): Likewise.
+ * sysdeps/pthread/aio_cancel.c (aio_cancel): Likewise.
+ * sysdeps/pthread/aio_suspend.c (aio_suspend): Likewise.
+ * sysdeps/pthread/timer_delete.c (timer_delete): Likewise.
+ * sysdeps/unix/sysv/linux/dl-openat64.c (openat64): Likewise.
+ Make variadic.
+ * time/strptime_l.c (localtime_r): Convert to prototype-style
+ function definition.
+ * wcsmbs/mbsnrtowcs.c (__mbsnrtowcs): Likewise.
+ * wcsmbs/mbsrtowcs_l.c (__mbsrtowcs_l): Likewise.
+ * wcsmbs/wcsnrtombs.c (__wcsnrtombs): Likewise.
+ * wcsmbs/wcsrtombs.c (__wcsrtombs): Likewise.
+
+---
+ sysdeps/unix/sysv/linux/dl-openat64.c | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
+--- a/sysdeps/unix/sysv/linux/dl-openat64.c
++++ b/sysdeps/unix/sysv/linux/dl-openat64.c
+@@ -24,10 +24,7 @@
+
+
+ int
+-openat64 (dfd, file, oflag)
+- int dfd;
+- const char *file;
+- int oflag;
++openat64 (int dfd, const char *file, int oflag, ...)
+ {
+ assert ((oflag & O_CREAT) == 0);
+
diff --git a/packages/glibc/2.15/104-unused-variables.patch b/packages/glibc/2.15/0004-unused-variables.patch
index 63e4a40..65f9f58 100644
--- a/packages/glibc/2.15/104-unused-variables.patch
+++ b/packages/glibc/2.15/0004-unused-variables.patch
@@ -19,8 +19,18 @@ Date: Fri Sep 18 20:27:20 2015 +0100
* timezone/private.h (time_t_min): Likewise. (time_t_max):
Likewise.
-diff --git a/resolv/base64.c b/resolv/base64.c
-index ea584ed..519e5d2 100644
+---
+ resolv/base64.c | 4 ----
+ sysdeps/ieee754/dbl-64/atnat2.h | 4 ----
+ sysdeps/ieee754/dbl-64/uexp.h | 2 +-
+ sysdeps/ieee754/dbl-64/upow.h | 2 --
+ sysdeps/ieee754/flt-32/e_log10f.c | 2 --
+ sysdeps/ieee754/flt-32/s_cosf.c | 6 ------
+ sysdeps/ieee754/ldbl-128/e_lgammal_r.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_erfl.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_log1pl.c | 1 -
+ 9 files changed, 1 insertion(+), 22 deletions(-)
+
--- a/resolv/base64.c
+++ b/resolv/base64.c
@@ -40,10 +40,6 @@
@@ -34,11 +44,9 @@ index ea584ed..519e5d2 100644
#include <sys/types.h>
#include <sys/param.h>
#include <sys/socket.h>
-diff --git a/sysdeps/ieee754/dbl-64/atnat2.h b/sysdeps/ieee754/dbl-64/atnat2.h
-index e0d65af..82943f9 100644
--- a/sysdeps/ieee754/dbl-64/atnat2.h
+++ b/sysdeps/ieee754/dbl-64/atnat2.h
-@@ -65,10 +65,8 @@
+@@ -69,10 +69,8 @@
/**/ hpi1 = {{0x3c91a626, 0x33145c07} }, /* pi/2-hpi */
/**/ mhpi = {{0xbff921fb, 0x54442d18} }, /* -pi/2 */
/**/ qpi = {{0x3fe921fb, 0x54442d18} }, /* pi/4 */
@@ -49,7 +57,7 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0xc002d97c, 0x7f3321d2} }, /* -3pi/4 */
/**/ u1 = {{0x3c314c2a, 0x00000000} }, /* 9.377e-19 */
/**/ u2 = {{0x3bf955e4, 0x00000000} }, /* 8.584e-20 */
-@@ -129,10 +127,8 @@
+@@ -139,10 +137,8 @@
/**/ hpi1 = {{0x33145c07, 0x3c91a626} }, /* pi/2-hpi */
/**/ mhpi = {{0x54442d18, 0xbff921fb} }, /* -pi/2 */
/**/ qpi = {{0x54442d18, 0x3fe921fb} }, /* pi/4 */
@@ -60,11 +68,9 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0x7f3321d2, 0xc002d97c} }, /* -3pi/4 */
/**/ u1 = {{0x00000000, 0x3c314c2a} }, /* 9.377e-19 */
/**/ u2 = {{0x00000000, 0x3bf955e4} }, /* 8.584e-20 */
-diff --git a/sysdeps/ieee754/dbl-64/uexp.h b/sysdeps/ieee754/dbl-64/uexp.h
-index 6817eaf..42b21f2 100644
--- a/sysdeps/ieee754/dbl-64/uexp.h
+++ b/sysdeps/ieee754/dbl-64/uexp.h
-@@ -29,7 +29,7 @@
+@@ -30,7 +30,7 @@
#include "mydefs.h"
@@ -73,11 +79,9 @@ index 6817eaf..42b21f2 100644
err_0 = 1.000014, err_1 = 0.000016;
const static int4 bigint = 0x40862002,
badint = 0x40876000,smallint = 0x3C8fffff;
-diff --git a/sysdeps/ieee754/dbl-64/upow.h b/sysdeps/ieee754/dbl-64/upow.h
-index c8569a9..b4911e5 100644
--- a/sysdeps/ieee754/dbl-64/upow.h
+++ b/sysdeps/ieee754/dbl-64/upow.h
-@@ -34,7 +34,6 @@
+@@ -36,7 +36,6 @@
/**/ INF = {{0x7ff00000, 0x00000000}}, /* INF */
/**/ nINF = {{0xfff00000, 0x00000000}}, /* -INF */
/**/ NaNQ = {{0x7ff80000, 0x00000000}}, /* NaNQ */
@@ -85,7 +89,7 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0x3fe62e42, 0xfefa3800}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x3d2ef357, 0x93c76730}}, /* ln(2)-ln2a */
/**/ bigu = {{0x4297ffff, 0xfffffd2c}}, /* 1.5*2**42 -724*2**-10 */
-@@ -48,7 +47,6 @@
+@@ -51,7 +50,6 @@
/**/ INF = {{0x00000000, 0x7ff00000}}, /* INF */
/**/ nINF = {{0x00000000, 0xfff00000}}, /* -INF */
/**/ NaNQ = {{0x00000000, 0x7ff80000}}, /* NaNQ */
@@ -93,11 +97,9 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0xfefa3800, 0x3fe62e42}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x93c76730, 0x3d2ef357}}, /* ln(2)-ln2a */
/**/ bigu = {{0xfffffd2c, 0x4297ffff}}, /* 1.5*2**42 -724*2**-10 */
-diff --git a/sysdeps/ieee754/flt-32/e_log10f.c b/sysdeps/ieee754/flt-32/e_log10f.c
-index 96f0e81..1daeef7 100644
--- a/sysdeps/ieee754/flt-32/e_log10f.c
+++ b/sysdeps/ieee754/flt-32/e_log10f.c
-@@ -22,8 +22,6 @@ ivln10 = 4.3429449201e-01, /* 0x3ede5bd9 */
+@@ -22,8 +22,6 @@
log10_2hi = 3.0102920532e-01, /* 0x3e9a2080 */
log10_2lo = 7.9034151668e-07; /* 0x355427db */
@@ -106,28 +108,24 @@ index 96f0e81..1daeef7 100644
float
__ieee754_log10f(float x)
{
-diff --git a/sysdeps/ieee754/flt-32/s_cosf.c b/sysdeps/ieee754/flt-32/s_cosf.c
-index 864ab27..0affd40 100644
--- a/sysdeps/ieee754/flt-32/s_cosf.c
+++ b/sysdeps/ieee754/flt-32/s_cosf.c
-@@ -21,12 +21,6 @@ static char rcsid[] = "$NetBSD: s_cosf.c,v 1.4 1995/05/10 20:47:03 jtc Exp $";
- #include "math.h"
+@@ -22,12 +22,6 @@
#include "math_private.h"
--#ifdef __STDC__
+ #ifdef __STDC__
-static const float one=1.0;
-#else
-static float one=1.0;
-#endif
-
- #ifdef __STDC__
+-#ifdef __STDC__
float __cosf(float x)
#else
-diff --git a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-index 500aacc..ab5a96e 100644
+ float __cosf(x)
--- a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
+++ b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-@@ -82,7 +82,6 @@ DIAG_IGNORE_NEEDS_COMMENT (4.6, "-Woverflow");
+@@ -74,7 +74,6 @@
static const long double PIL = 3.1415926535897932384626433832795028841972E0L;
static const long double MAXLGM = 1.0485738685148938358098967157129705071571E4928L;
static const long double one = 1.0L;
@@ -135,11 +133,9 @@ index 500aacc..ab5a96e 100644
static const long double huge = 1.0e4000L;
/* log gamma(x) = ( x - 0.5 ) * log(x) - x + LS2PI + 1/x P(1/x^2)
-diff --git a/sysdeps/ieee754/ldbl-128/s_erfl.c b/sysdeps/ieee754/ldbl-128/s_erfl.c
-index fa4609f..08c80a3 100644
--- a/sysdeps/ieee754/ldbl-128/s_erfl.c
+++ b/sysdeps/ieee754/ldbl-128/s_erfl.c
-@@ -140,7 +140,6 @@ deval (long double x, const long double *p, int n)
+@@ -142,7 +142,6 @@
static long double
#endif
tiny = 1e-4931L,
@@ -147,11 +143,9 @@ index fa4609f..08c80a3 100644
one = 1.0L,
two = 2.0L,
/* 2/sqrt(pi) - 1 */
-diff --git a/sysdeps/ieee754/ldbl-128/s_log1pl.c b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-index ff759bc..9609550 100644
--- a/sysdeps/ieee754/ldbl-128/s_log1pl.c
+++ b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-@@ -117,7 +117,6 @@ static const long double C2 = 1.428606820309417232121458176568075500134E-6L;
+@@ -116,7 +116,6 @@
static const long double sqrth = 0.7071067811865475244008443621048490392848L;
/* ln (2^16384 * (1 - 2^-113)) */
diff --git a/packages/glibc/2.13/105-misleading-indentation.patch b/packages/glibc/2.15/0005-misleading-indentation.patch
index 1dd8d85..35bcb1b 100644
--- a/packages/glibc/2.13/105-misleading-indentation.patch
+++ b/packages/glibc/2.15/0005-misleading-indentation.patch
@@ -7,11 +7,13 @@ Date: Fri Dec 11 09:19:37 2015 -0800
* sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
Fix indentation.
-diff --git a/sysdeps/ieee754/flt-32/k_rem_pio2f.c b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-index 0c7685c..392afdb 100644
+---
+ sysdeps/ieee754/flt-32/k_rem_pio2f.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
--- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
+++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-@@ -65,7 +65,9 @@ int __kernel_rem_pio2f(float *x, float *y, int e0, int nx, int prec, const int32
+@@ -82,7 +82,9 @@
/* compute q[0],q[1],...q[jk] */
for (i=0;i<=jk;i++) {
diff --git a/packages/glibc/2.12.1/106-dl-open-array-bounds.patch b/packages/glibc/2.15/0006-dl-open-array-bounds.patch
index bdb5c19..2ad3817 100644
--- a/packages/glibc/2.12.1/106-dl-open-array-bounds.patch
+++ b/packages/glibc/2.15/0006-dl-open-array-bounds.patch
@@ -4,11 +4,13 @@ Date: Fri Apr 17 12:11:58 2015 -0700
Fuller check for invalid NSID in _dl_open.
-diff --git a/elf/dl-open.c b/elf/dl-open.c
-index 0dbe07f..2d0e082 100644
+---
+ elf/dl-open.c | 10 ++++++++--
+ 1 file changed, 8 insertions(+), 2 deletions(-)
+
--- a/elf/dl-open.c
+++ b/elf/dl-open.c
-@@ -619,8 +619,14 @@ no more namespaces available for dlmopen()"));
+@@ -546,8 +546,14 @@
/* Never allow loading a DSO in a namespace which is empty. Such
direct placements is only causing problems. Also don't allow
loading into a namespace used for auditing. */
diff --git a/packages/glibc/2.14.1/120-i386-x86_64-revert-clone-cfi.patch b/packages/glibc/2.15/0007-i386-x86_64-revert-clone-cfi.patch
index c7f6182..f872bac 100644
--- a/packages/glibc/2.14.1/120-i386-x86_64-revert-clone-cfi.patch
+++ b/packages/glibc/2.15/0007-i386-x86_64-revert-clone-cfi.patch
@@ -4,16 +4,13 @@ elsewhere. this cfi code does not gain us a whole lot anyways.
http://gcc.gnu.org/ml/gcc/2006-12/msg00293.html
-Index: sysdeps/unix/sysv/linux/i386/clone.S
-===================================================================
-RCS file: /cvs/glibc/libc/sysdeps/unix/sysv/linux/i386/clone.S,v
-retrieving revision 1.27
-retrieving revision 1.26
-diff -u -p -r1.27 -r1.26
+---
+ sysdeps/unix/sysv/linux/i386/clone.S | 4 ----
+ sysdeps/unix/sysv/linux/x86_64/clone.S | 4 ----
+ 2 files changed, 8 deletions(-)
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/i386/clone.S glibc-2.13/sysdeps/unix/sysv/linux/i386/clone.S
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/i386/clone.S 2006-12-04 00:12:36.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/i386/clone.S 2009-11-13 00:49:45.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/i386/clone.S
++++ b/sysdeps/unix/sysv/linux/i386/clone.S
@@ -120,9 +120,6 @@
ret
@@ -32,9 +29,8 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/i386/clone.S glibc-2.13/sysde
cfi_startproc
PSEUDO_END (BP_SYM (__clone))
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/x86_64/clone.S glibc-2.13/sysdeps/unix/sysv/linux/x86_64/clone.S
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/x86_64/clone.S 2006-12-04 00:12:36.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/x86_64/clone.S 2009-11-13 00:49:45.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/x86_64/clone.S
++++ b/sysdeps/unix/sysv/linux/x86_64/clone.S
@@ -89,9 +89,6 @@
ret
diff --git a/packages/glibc/2.14.1/140-disable-ldconfig.patch b/packages/glibc/2.15/0008-disable-ldconfig.patch
index 378e1df..4c5615d 100644
--- a/packages/glibc/2.14.1/140-disable-ldconfig.patch
+++ b/packages/glibc/2.15/0008-disable-ldconfig.patch
@@ -3,10 +3,13 @@ file outside of the chroot. doesnt matter anyways as we wont use the cache
results (portage will rebuild cache), so running ldconfig is simply a waste
of time.
-diff -durN glibc-2.13.orig/Makefile glibc-2.13/Makefile
---- glibc-2.13.orig/Makefile 2009-04-23 20:23:03.000000000 +0200
-+++ glibc-2.13/Makefile 2009-11-13 00:49:49.000000000 +0100
-@@ -116,6 +116,7 @@
+---
+ Makefile | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/Makefile
++++ b/Makefile
+@@ -107,6 +107,7 @@
rm -f $(symbolic-link-list)
install:
diff --git a/packages/glibc/2.15/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.15/0009-Fix-combreloc-test-BSD-grep.patch
index c36cdf4..ce16455 100644
--- a/packages/glibc/2.15/140-Fix-combreloc-test-BSD-grep.patch
+++ b/packages/glibc/2.15/0009-Fix-combreloc-test-BSD-grep.patch
@@ -13,15 +13,13 @@ by configure as "not found". As a result, support for "-z combreloc"
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
+ configure | 2 +-
+ configure.in | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
-diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
---- glibc-2.15.orig/configure 2012-03-19 07:56:58.000000000 -0700
-+++ glibc-2.15/configure 2017-03-08 21:02:21.000000000 -0800
-@@ -6566,7 +6566,7 @@ EOF
+--- a/configure
++++ b/configure
+@@ -6566,7 +6566,7 @@
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; }
then
@@ -30,10 +28,9 @@ diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
-diff -urpN glibc-2.15.orig/configure.in glibc-2.15/configure.in
---- glibc-2.15.orig/configure.in 2012-01-01 04:16:32.000000000 -0800
-+++ glibc-2.15/configure.in 2017-03-08 21:01:54.000000000 -0800
-@@ -1716,7 +1716,7 @@ dnl cross-platform since the gcc used ca
+--- a/configure.in
++++ b/configure.in
+@@ -1716,7 +1716,7 @@
dnl introducing new options this is not easily doable. Instead use a tool
dnl which always is cross-platform: readelf. To detect whether -z combreloc
dnl look for a section named .rel.dyn.
diff --git a/packages/glibc/2.16.0/150-queue-header-updates.patch b/packages/glibc/2.15/0010-queue-header-updates.patch
index 7cbe70e..f6515e2 100644
--- a/packages/glibc/2.16.0/150-queue-header-updates.patch
+++ b/packages/glibc/2.15/0010-queue-header-updates.patch
@@ -2,11 +2,12 @@ grab some updates from FreeBSD
http://bugs.gentoo.org/201979
-diff -durN glibc-2.13.orig/misc/sys/queue.h glibc-2.13/misc/sys/queue.h
+---
+ misc/sys/queue.h | 36 ++++++++++++++++++++++++++++++++++++
+ 1 file changed, 36 insertions(+)
-diff -durN glibc-2.13.orig/misc/sys/queue.h glibc-2.13/misc/sys/queue.h
---- glibc-2.13.orig/misc/sys/queue.h 2008-03-05 06:50:30.000000000 +0100
-+++ glibc-2.13/misc/sys/queue.h 2009-11-13 00:49:51.000000000 +0100
+--- a/misc/sys/queue.h
++++ b/misc/sys/queue.h
@@ -136,6 +136,11 @@
(var); \
(var) = ((var)->field.le_next))
diff --git a/packages/glibc/2.12.1/160-manual-no-perl.patch b/packages/glibc/2.15/0011-manual-no-perl.patch
index 2eb5414..7e232aa 100644
--- a/packages/glibc/2.12.1/160-manual-no-perl.patch
+++ b/packages/glibc/2.15/0011-manual-no-perl.patch
@@ -4,10 +4,13 @@ deal, so just whine a little and continue on our merry way.
http://bugs.gentoo.org/60132
-diff -durN glibc-2.12.1.orig/manual/Makefile glibc-2.12.1/manual/Makefile
---- glibc-2.12.1.orig/manual/Makefile 2006-01-08 07:43:47.000000000 +0100
-+++ glibc-2.12.1/manual/Makefile 2009-11-13 00:49:54.000000000 +0100
-@@ -104,9 +104,14 @@
+---
+ manual/Makefile | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/manual/Makefile
++++ b/manual/Makefile
+@@ -106,9 +106,14 @@
libm-err.texi: stamp-libm-err
stamp-libm-err: libm-err-tab.pl $(wildcard $(foreach dir,$(sysdirs),\
$(dir)/libm-test-ulps))
diff --git a/packages/glibc/2.16.0/170-localedef-fix-trampoline.patch b/packages/glibc/2.15/0012-localedef-fix-trampoline.patch
index 3cc6559..3b8fd6e 100644
--- a/packages/glibc/2.16.0/170-localedef-fix-trampoline.patch
+++ b/packages/glibc/2.15/0012-localedef-fix-trampoline.patch
@@ -5,9 +5,12 @@
# DP: Upstream status: Unknown
# DP: Status Details: Unknown
# DP: Date: 2004-03-16
-diff -durN glibc-2.13.orig/locale/programs/3level.h glibc-2.13/locale/programs/3level.h
---- glibc-2.13.orig/locale/programs/3level.h 2007-07-16 02:54:59.000000000 +0200
-+++ glibc-2.13/locale/programs/3level.h 2009-11-13 00:49:56.000000000 +0100
+---
+# locale/programs/3level.h | 36 ++++++++++++++++++++++++++++++++++++
+# 1 file changed, 36 insertions(+)
+#
+--- a/locale/programs/3level.h
++++ b/locale/programs/3level.h
@@ -203,6 +203,42 @@
}
}
diff --git a/packages/glibc/2.15/180-resolv-dynamic.patch b/packages/glibc/2.15/0013-resolv-dynamic.patch
index e916bce..fcc2f80 100644
--- a/packages/glibc/2.15/180-resolv-dynamic.patch
+++ b/packages/glibc/2.15/0013-resolv-dynamic.patch
@@ -5,9 +5,12 @@ already running get the updated information.
http://bugs.gentoo.org/177416
-diff -durN glibc-2.13.orig/resolv/res_libc.c glibc-2.13/resolv/res_libc.c
---- glibc-2.13.orig/resolv/res_libc.c 2009-02-07 05:27:42.000000000 +0100
-+++ glibc-2.13/resolv/res_libc.c 2009-11-13 00:49:59.000000000 +0100
+---
+ resolv/res_libc.c | 15 +++++++++++++++
+ 1 file changed, 15 insertions(+)
+
+--- a/resolv/res_libc.c
++++ b/resolv/res_libc.c
@@ -22,6 +22,7 @@
#include <arpa/nameser.h>
#include <resolv.h>
diff --git a/packages/glibc/2.15/200-fadvise64_64.patch b/packages/glibc/2.15/0014-fadvise64_64.patch
index 71bca38..191d833 100644
--- a/packages/glibc/2.15/200-fadvise64_64.patch
+++ b/packages/glibc/2.15/0014-fadvise64_64.patch
@@ -3,9 +3,8 @@ ripped from Debian
sysdeps/unix/sysv/linux/posix_fadvise.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/posix_fadvise.c glibc-2.13/sysdeps/unix/sysv/linux/posix_fadvise.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/posix_fadvise.c 2003-08-17 02:36:22.000000000 +0200
-+++ glibc-2.13/sysdeps/unix/sysv/linux/posix_fadvise.c 2009-11-13 00:50:03.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/posix_fadvise.c
++++ b/sysdeps/unix/sysv/linux/posix_fadvise.c
@@ -35,6 +35,19 @@
return INTERNAL_SYSCALL_ERRNO (ret, err);
return 0;
diff --git a/packages/glibc/2.12.1/220-section-comments.patch b/packages/glibc/2.15/0015-section-comments.patch
index 4d35535..75cb527 100644
--- a/packages/glibc/2.12.1/220-section-comments.patch
+++ b/packages/glibc/2.15/0015-section-comments.patch
@@ -3,10 +3,13 @@ http://sources.redhat.com/ml/binutils/2004-04/msg00665.html
fixes building on some architectures (like m68k/arm/cris/etc...) because
it does the right thing
-diff -durN glibc-2.12.1.orig/include/libc-symbols.h glibc-2.12.1/include/libc-symbols.h
---- glibc-2.12.1.orig/include/libc-symbols.h 2009-03-14 00:51:46.000000000 +0100
-+++ glibc-2.12.1/include/libc-symbols.h 2009-11-13 00:50:07.000000000 +0100
-@@ -239,12 +239,12 @@
+---
+ include/libc-symbols.h | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+--- a/include/libc-symbols.h
++++ b/include/libc-symbols.h
+@@ -235,12 +235,12 @@
# define __make_section_unallocated(section_string)
# endif
diff --git a/packages/glibc/2.12.1/230-no-inline-gmon.patch b/packages/glibc/2.15/0016-no-inline-gmon.patch
index 594fb79..ed02704 100644
--- a/packages/glibc/2.12.1/230-no-inline-gmon.patch
+++ b/packages/glibc/2.15/0016-no-inline-gmon.patch
@@ -19,12 +19,12 @@ Kazu Hirata
* sysdeps/generic/initfini.c (call_gmon_start): Add
__attribute__ ((noinline)).
-Index: sysdeps/generic/initfini.c
-===================================================================
+---
+ sysdeps/generic/initfini.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
-diff -durN glibc-2.12.1.orig/sysdeps/generic/initfini.c glibc-2.12.1/sysdeps/generic/initfini.c
---- glibc-2.12.1.orig/sysdeps/generic/initfini.c 2007-06-17 20:02:40.000000000 +0200
-+++ glibc-2.12.1/sysdeps/generic/initfini.c 2009-11-13 00:50:09.000000000 +0100
+--- a/sysdeps/generic/initfini.c
++++ b/sysdeps/generic/initfini.c
@@ -70,7 +70,7 @@
/* The beginning of _init: */
asm ("\n/*@_init_PROLOG_BEGINS*/");
diff --git a/packages/glibc/2.12.1/260-assume-pipe2.patch b/packages/glibc/2.15/0017-assume-pipe2.patch
index b84f882..0074ea6 100644
--- a/packages/glibc/2.12.1/260-assume-pipe2.patch
+++ b/packages/glibc/2.15/0017-assume-pipe2.patch
@@ -20,9 +20,12 @@ __have_sock_cloexec and __have_pipe2 to true. but if glibc was built against
older kernel headers where __NR_pipe2 does not exist, glibc will have a ENOSYS
stub for it. so popen() will always fail as glibc assumes pipe2() works.
-diff -durN glibc-2.12.1.orig/socket/have_sock_cloexec.c glibc-2.12.1/socket/have_sock_cloexec.c
---- glibc-2.12.1.orig/socket/have_sock_cloexec.c 2008-07-25 18:46:23.000000000 +0200
-+++ glibc-2.12.1/socket/have_sock_cloexec.c 2009-11-13 00:50:15.000000000 +0100
+---
+ socket/have_sock_cloexec.c | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/socket/have_sock_cloexec.c
++++ b/socket/have_sock_cloexec.c
@@ -16,9 +16,14 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
diff --git a/packages/glibc/2.16.0/270-china.patch b/packages/glibc/2.15/0018-china.patch
index 41d7759..b323cf6 100644
--- a/packages/glibc/2.16.0/270-china.patch
+++ b/packages/glibc/2.15/0018-china.patch
@@ -1,8 +1,11 @@
-diff -durN glibc-2.13.orig/localedata/locales/zh_TW glibc-2.13/localedata/locales/zh_TW
---- glibc-2.13.orig/localedata/locales/zh_TW 2004-11-01 00:42:28.000000000 +0100
-+++ glibc-2.13/localedata/locales/zh_TW 2009-11-13 00:50:17.000000000 +0100
+---
+ localedata/locales/zh_TW | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+--- a/localedata/locales/zh_TW
++++ b/localedata/locales/zh_TW
@@ -1,7 +1,7 @@
comment_char %
escape_char /
diff --git a/packages/glibc/2.16.0/280-new-valencian-locale.patch b/packages/glibc/2.15/0019-new-valencian-locale.patch
index 4cdd108..8f67711 100644
--- a/packages/glibc/2.16.0/280-new-valencian-locale.patch
+++ b/packages/glibc/2.15/0019-new-valencian-locale.patch
@@ -1,10 +1,14 @@
http://bugs.gentoo.org/show_bug.cgi?id=131815
http://sourceware.org/bugzilla/show_bug.cgi?id=2522
-diff -durN glibc-2.13.orig/localedata/SUPPORTED glibc-2.13/localedata/SUPPORTED
---- glibc-2.13.orig/localedata/SUPPORTED 2009-04-18 10:43:52.000000000 +0200
-+++ glibc-2.13/localedata/SUPPORTED 2009-11-13 00:50:20.000000000 +0100
-@@ -72,6 +72,8 @@
+---
+ localedata/SUPPORTED | 2
+ localedata/locales/ca_ES@valencia | 96 ++++++++++++++++++++++++++++++++++++++
+ 2 files changed, 98 insertions(+)
+
+--- a/localedata/SUPPORTED
++++ b/localedata/SUPPORTED
+@@ -75,6 +75,8 @@
ca_ES.UTF-8/UTF-8 \
ca_ES/ISO-8859-1 \
ca_ES@euro/ISO-8859-15 \
@@ -13,9 +17,8 @@ diff -durN glibc-2.13.orig/localedata/SUPPORTED glibc-2.13/localedata/SUPPORTED
ca_FR.UTF-8/UTF-8 \
ca_FR/ISO-8859-15 \
ca_IT.UTF-8/UTF-8 \
-diff -durN glibc-2.13.orig/localedata/locales/ca_ES@valencia glibc-2.13/localedata/locales/ca_ES@valencia
---- glibc-2.13.orig/localedata/locales/ca_ES@valencia 1970-01-01 01:00:00.000000000 +0100
-+++ glibc-2.13/localedata/locales/ca_ES@valencia 2009-11-13 00:50:20.000000000 +0100
+--- /dev/null
++++ b/localedata/locales/ca_ES@valencia
@@ -0,0 +1,96 @@
+comment_char %
+escape_char /
diff --git a/packages/glibc/2.15/0020-macos-cross-rpcgen.patch b/packages/glibc/2.15/0020-macos-cross-rpcgen.patch
new file mode 100644
index 0000000..b439b0f
--- /dev/null
+++ b/packages/glibc/2.15/0020-macos-cross-rpcgen.patch
@@ -0,0 +1,34 @@
+commit ae7080d30c68cfa0c81ce3422dca948f64a94f50
+Author: Jia Liu <proljc@gmail.com>
+Date: Sat Sep 7 00:01:08 2013 +0800
+
+ sunrpc/rpc/types.h: fix OS X and FreeBSD build problems
+
+ When I build arm-linux-gcc on OS X, I find glibc will get a build error
+ in sunrpc/rpc/types.h, so I add __APPLE_CC__ to make OS X build OK.
+ For FreeBSD, Add __FreeBSD__ to make it build OK, too.
+
+ URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00155.html
+ URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00217.html
+ URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00240.html
+ Signed-off-by: Jia Liu <proljc@gmail.com>
+ Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+
+---
+ sunrpc/rpc/types.h | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/sunrpc/rpc/types.h
++++ b/sunrpc/rpc/types.h
+@@ -69,6 +69,11 @@
+ #include <sys/types.h>
+ #endif
+
++#if defined __APPLE_CC__ || defined __FreeBSD__
++# define __u_char_defined
++# define __daddr_t_defined
++#endif
++
+ #ifndef __u_char_defined
+ typedef __u_char u_char;
+ typedef __u_short u_short;
diff --git a/packages/glibc/2.12.1/300-nscd-one-fork.patch b/packages/glibc/2.15/0021-nscd-one-fork.patch
index 27eae51..11861f5 100644
--- a/packages/glibc/2.12.1/300-nscd-one-fork.patch
+++ b/packages/glibc/2.15/0021-nscd-one-fork.patch
@@ -2,10 +2,13 @@ only fork one to assist in stop-start-daemon assumptions about daemon behavior
http://bugs.gentoo.org/190785
-diff -durN glibc-2.12.1.orig/nscd/nscd.c glibc-2.12.1/nscd/nscd.c
---- glibc-2.12.1.orig/nscd/nscd.c 2009-02-06 21:10:27.000000000 +0100
-+++ glibc-2.12.1/nscd/nscd.c 2009-11-13 00:50:24.000000000 +0100
-@@ -182,6 +182,9 @@
+---
+ nscd/nscd.c | 12 +++---------
+ 1 file changed, 3 insertions(+), 9 deletions(-)
+
+--- a/nscd/nscd.c
++++ b/nscd/nscd.c
+@@ -185,6 +185,9 @@
if (pid != 0)
exit (0);
@@ -15,7 +18,7 @@ diff -durN glibc-2.12.1.orig/nscd/nscd.c glibc-2.12.1/nscd/nscd.c
int nullfd = open (_PATH_DEVNULL, O_RDWR);
if (nullfd != -1)
{
-@@ -231,12 +234,6 @@
+@@ -234,12 +237,6 @@
for (i = min_close_fd; i < getdtablesize (); i++)
close (i);
@@ -28,7 +31,7 @@ diff -durN glibc-2.12.1.orig/nscd/nscd.c glibc-2.12.1/nscd/nscd.c
setsid ();
if (chdir ("/") != 0)
-@@ -245,9 +242,6 @@
+@@ -248,9 +245,6 @@
openlog ("nscd", LOG_CONS | LOG_ODELAY, LOG_DAEMON);
diff --git a/packages/glibc/2.14.1/310-hppa-nptl-carlos.patch b/packages/glibc/2.15/0022-hppa-nptl-carlos.patch
index 4c028b2..cad5797 100644
--- a/packages/glibc/2.14.1/310-hppa-nptl-carlos.patch
+++ b/packages/glibc/2.15/0022-hppa-nptl-carlos.patch
@@ -1,9 +1,18 @@
-diff -durN glibc-2.13.orig/elf/rtld.c glibc-2.13/elf/rtld.c
---- glibc-2.13.orig/elf/rtld.c 2009-04-17 02:00:08.000000000 +0200
-+++ glibc-2.13/elf/rtld.c 2009-11-13 00:50:26.000000000 +0100
-@@ -392,14 +392,14 @@
+---
+ elf/rtld.c | 10 +++++-----
+ include/atomic.h | 26 +++++++++++++-------------
+ nptl/Makefile | 35 ++++++++++++++++++++++++++++++++---
+ nptl/pthread_barrier_wait.c | 2 +-
+ nptl/sysdeps/pthread/Makefile | 2 ++
+ stdio-common/Makefile | 2 +-
+ sunrpc/clnt_udp.c | 2 +-
+ 7 files changed, 55 insertions(+), 24 deletions(-)
+
+--- a/elf/rtld.c
++++ b/elf/rtld.c
+@@ -393,14 +393,14 @@
know it is available. We do not have to clear the memory if we
do not have to use the temporary bootstrap_map. Global variables
are initialized to zero by default. */
@@ -23,9 +32,8 @@ diff -durN glibc-2.13.orig/elf/rtld.c glibc-2.13/elf/rtld.c
# endif
# if USE___THREAD
bootstrap_map.l_tls_modid = 0;
-diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
---- glibc-2.13.orig/include/atomic.h 2009-02-09 00:49:53.000000000 +0100
-+++ glibc-2.13/include/atomic.h 2009-11-13 00:50:26.000000000 +0100
+--- a/include/atomic.h
++++ b/include/atomic.h
@@ -185,7 +185,7 @@
__typeof (*(mem)) __atg5_value = (newvalue); \
\
@@ -143,9 +151,8 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
while (__builtin_expect \
(atomic_compare_and_exchange_bool_acq (__atg19_memp, \
__atg19_old | __atg19_mask,\
-diff -durN glibc-2.13.orig/nptl/Makefile glibc-2.13/nptl/Makefile
---- glibc-2.13.orig/nptl/Makefile 2008-11-12 14:38:23.000000000 +0100
-+++ glibc-2.13/nptl/Makefile 2009-11-13 00:50:26.000000000 +0100
+--- a/nptl/Makefile
++++ b/nptl/Makefile
@@ -265,9 +265,9 @@
# Files which must not be linked with libpthread.
tests-nolibpthread = tst-unload
@@ -195,9 +202,8 @@ diff -durN glibc-2.13.orig/nptl/Makefile glibc-2.13/nptl/Makefile
CFLAGS-tst-align.c += $(stack-align-test-flags)
CFLAGS-tst-align3.c += $(stack-align-test-flags)
CFLAGS-tst-initializers1.c = -W -Wall -Werror
-diff -durN glibc-2.13.orig/nptl/pthread_barrier_wait.c glibc-2.13/nptl/pthread_barrier_wait.c
---- glibc-2.13.orig/nptl/pthread_barrier_wait.c 2007-08-01 06:18:50.000000000 +0200
-+++ glibc-2.13/nptl/pthread_barrier_wait.c 2009-11-13 00:50:26.000000000 +0100
+--- a/nptl/pthread_barrier_wait.c
++++ b/nptl/pthread_barrier_wait.c
@@ -64,7 +64,7 @@
do
lll_futex_wait (&ibarrier->curr_event, event,
@@ -207,9 +213,8 @@ diff -durN glibc-2.13.orig/nptl/pthread_barrier_wait.c glibc-2.13/nptl/pthread_b
}
/* Make sure the init_count is stored locally or in a register. */
-diff -durN glibc-2.13.orig/nptl/sysdeps/pthread/Makefile glibc-2.13/nptl/sysdeps/pthread/Makefile
---- glibc-2.13.orig/nptl/sysdeps/pthread/Makefile 2006-02-28 08:09:41.000000000 +0100
-+++ glibc-2.13/nptl/sysdeps/pthread/Makefile 2009-11-13 00:50:26.000000000 +0100
+--- a/nptl/sysdeps/pthread/Makefile
++++ b/nptl/sysdeps/pthread/Makefile
@@ -33,7 +33,9 @@
ifeq ($(have-forced-unwind),yes)
@@ -220,9 +225,8 @@ diff -durN glibc-2.13.orig/nptl/sysdeps/pthread/Makefile glibc-2.13/nptl/sysdeps
endif
endif
-diff -durN glibc-2.13.orig/stdio-common/Makefile glibc-2.13/stdio-common/Makefile
---- glibc-2.13.orig/stdio-common/Makefile 2009-04-11 07:29:56.000000000 +0200
-+++ glibc-2.13/stdio-common/Makefile 2009-11-13 00:50:26.000000000 +0100
+--- a/stdio-common/Makefile
++++ b/stdio-common/Makefile
@@ -82,7 +82,7 @@
$(SHELL) -e tst-printf.sh $(common-objpfx) '$(run-program-prefix)'
endif
@@ -232,10 +236,9 @@ diff -durN glibc-2.13.orig/stdio-common/Makefile glibc-2.13/stdio-common/Makefil
CFLAGS-vfwprintf.c = -Wno-uninitialized
CFLAGS-tst-printf.c = -Wno-format
CFLAGS-tstdiomisc.c = -Wno-format
-diff -durN glibc-2.13.orig/sunrpc/clnt_udp.c glibc-2.13/sunrpc/clnt_udp.c
---- glibc-2.13.orig/sunrpc/clnt_udp.c 2008-07-26 10:42:44.000000000 +0200
-+++ glibc-2.13/sunrpc/clnt_udp.c 2009-11-13 00:50:26.000000000 +0100
-@@ -456,7 +456,7 @@
+--- a/sunrpc/clnt_udp.c
++++ b/sunrpc/clnt_udp.c
+@@ -462,7 +462,7 @@
while (inlen < 0 && errno == EINTR);
if (inlen < 0)
{
diff --git a/packages/glibc/2.15/340-dl_execstack-PaX-support.patch b/packages/glibc/2.15/0023-dl_execstack-PaX-support.patch
index 2402af0..7b56549 100644
--- a/packages/glibc/2.15/340-dl_execstack-PaX-support.patch
+++ b/packages/glibc/2.15/0023-dl_execstack-PaX-support.patch
@@ -8,10 +8,14 @@
Patch also NPTL. Bug #116086. <kevquinn@gentoo.org> (20 Dec 2005).
-diff -durN glibc-2.13.orig/nptl/allocatestack.c glibc-2.13/nptl/allocatestack.c
---- glibc-2.13.orig/nptl/allocatestack.c 2009-01-29 21:34:16.000000000 +0100
-+++ glibc-2.13/nptl/allocatestack.c 2009-11-13 00:50:33.000000000 +0100
-@@ -329,7 +329,8 @@
+---
+ nptl/allocatestack.c | 3 ++-
+ sysdeps/unix/sysv/linux/dl-execstack.c | 19 ++++++++++++++++---
+ 2 files changed, 18 insertions(+), 4 deletions(-)
+
+--- a/nptl/allocatestack.c
++++ b/nptl/allocatestack.c
+@@ -335,7 +335,8 @@
# error "Define either _STACK_GROWS_DOWN or _STACK_GROWS_UP"
#endif
if (mprotect (stack, len, PROT_READ | PROT_WRITE | PROT_EXEC) != 0)
@@ -21,9 +25,8 @@ diff -durN glibc-2.13.orig/nptl/allocatestack.c glibc-2.13/nptl/allocatestack.c
return 0;
}
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/dl-execstack.c glibc-2.13/sysdeps/unix/sysv/linux/dl-execstack.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/dl-execstack.c 2006-01-08 09:21:15.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/dl-execstack.c 2009-11-13 00:50:33.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/dl-execstack.c
++++ b/sysdeps/unix/sysv/linux/dl-execstack.c
@@ -63,7 +63,10 @@
else
# endif
diff --git a/packages/glibc/2.13/350-pre20040117-pt_pax.patch b/packages/glibc/2.15/0024-pre20040117-pt_pax.patch
index f8f6b83..544b3f6 100644
--- a/packages/glibc/2.13/350-pre20040117-pt_pax.patch
+++ b/packages/glibc/2.15/0024-pre20040117-pt_pax.patch
@@ -1,9 +1,12 @@
-diff -durN glibc-2.13.orig/elf/elf.h glibc-2.13/elf/elf.h
---- glibc-2.13.orig/elf/elf.h 2009-04-15 02:15:54.000000000 +0200
-+++ glibc-2.13/elf/elf.h 2009-11-13 00:50:35.000000000 +0100
-@@ -580,6 +580,7 @@
+---
+ elf/elf.h | 13 +++++++++++++
+ 1 file changed, 13 insertions(+)
+
+--- a/elf/elf.h
++++ b/elf/elf.h
+@@ -581,6 +581,7 @@
#define PT_GNU_EH_FRAME 0x6474e550 /* GCC .eh_frame_hdr segment */
#define PT_GNU_STACK 0x6474e551 /* Indicates stack executability */
#define PT_GNU_RELRO 0x6474e552 /* Read-only after relocation */
@@ -11,7 +14,7 @@ diff -durN glibc-2.13.orig/elf/elf.h glibc-2.13/elf/elf.h
#define PT_LOSUNW 0x6ffffffa
#define PT_SUNWBSS 0x6ffffffa /* Sun Specific segment */
#define PT_SUNWSTACK 0x6ffffffb /* Stack segment */
-@@ -593,6 +594,18 @@
+@@ -594,6 +595,18 @@
#define PF_X (1 << 0) /* Segment is executable */
#define PF_W (1 << 1) /* Segment is writable */
#define PF_R (1 << 2) /* Segment is readable */
diff --git a/packages/glibc/2.15/360-tests-sandbox-libdl-paths.patch b/packages/glibc/2.15/0025-tests-sandbox-libdl-paths.patch
index 9f78c52..1c4ee59 100644
--- a/packages/glibc/2.15/360-tests-sandbox-libdl-paths.patch
+++ b/packages/glibc/2.15/0025-tests-sandbox-libdl-paths.patch
@@ -15,9 +15,23 @@ Fix by Wormo
http://bugs.gentoo.org/56898
-diff -durN glibc-2.13.orig/grp/tst_fgetgrent.sh glibc-2.13/grp/tst_fgetgrent.sh
---- glibc-2.13.orig/grp/tst_fgetgrent.sh 2001-07-06 06:54:46.000000000 +0200
-+++ glibc-2.13/grp/tst_fgetgrent.sh 2009-11-13 00:50:37.000000000 +0100
+---
+ grp/tst_fgetgrent.sh | 3 ++-
+ iconvdata/run-iconv-test.sh | 2 +-
+ iconvdata/tst-table.sh | 5 ++++-
+ intl/tst-codeset.sh | 3 +++
+ intl/tst-gettext.sh | 5 ++++-
+ intl/tst-gettext2.sh | 5 ++++-
+ intl/tst-translit.sh | 5 ++++-
+ malloc/tst-mtrace.sh | 5 ++++-
+ nptl/tst-tls6.sh | 4 ++--
+ posix/globtest.sh | 2 +-
+ posix/tst-getconf.sh | 5 ++++-
+ posix/wordexp-tst.sh | 5 ++++-
+ 12 files changed, 37 insertions(+), 12 deletions(-)
+
+--- a/grp/tst_fgetgrent.sh
++++ b/grp/tst_fgetgrent.sh
@@ -24,7 +24,8 @@
rtld_installed_name=$1; shift
@@ -28,9 +42,8 @@ diff -durN glibc-2.13.orig/grp/tst_fgetgrent.sh glibc-2.13/grp/tst_fgetgrent.sh
result=0
-diff -durN glibc-2.13.orig/iconvdata/run-iconv-test.sh glibc-2.13/iconvdata/run-iconv-test.sh
---- glibc-2.13.orig/iconvdata/run-iconv-test.sh 2008-05-15 03:59:44.000000000 +0200
-+++ glibc-2.13/iconvdata/run-iconv-test.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/iconvdata/run-iconv-test.sh
++++ b/iconvdata/run-iconv-test.sh
@@ -34,7 +34,7 @@
export GCONV_PATH
@@ -40,9 +53,8 @@ diff -durN glibc-2.13.orig/iconvdata/run-iconv-test.sh glibc-2.13/iconvdata/run-
# How the start the iconv(1) program.
ICONV='$codir/elf/ld.so --library-path $LIBPATH --inhibit-rpath ${from}.so \
-diff -durN glibc-2.13.orig/iconvdata/tst-table.sh glibc-2.13/iconvdata/tst-table.sh
---- glibc-2.13.orig/iconvdata/tst-table.sh 2002-04-24 23:39:35.000000000 +0200
-+++ glibc-2.13/iconvdata/tst-table.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/iconvdata/tst-table.sh
++++ b/iconvdata/tst-table.sh
@@ -59,8 +59,11 @@
irreversible=${charset}.irreversible
fi
@@ -56,9 +68,8 @@ diff -durN glibc-2.13.orig/iconvdata/tst-table.sh glibc-2.13/iconvdata/tst-table
${objpfx}tst-table-from ${charset} \
> ${objpfx}tst-${charset}.table
-diff -durN glibc-2.13.orig/intl/tst-codeset.sh glibc-2.13/intl/tst-codeset.sh
---- glibc-2.13.orig/intl/tst-codeset.sh 2005-04-06 04:18:35.000000000 +0200
-+++ glibc-2.13/intl/tst-codeset.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-codeset.sh
++++ b/intl/tst-codeset.sh
@@ -37,6 +37,9 @@
LOCPATH=${common_objpfx}localedata
export LOCPATH
@@ -69,9 +80,8 @@ diff -durN glibc-2.13.orig/intl/tst-codeset.sh glibc-2.13/intl/tst-codeset.sh
${common_objpfx}elf/ld.so --library-path $common_objpfx \
${objpfx}tst-codeset > ${objpfx}tst-codeset.out
-diff -durN glibc-2.13.orig/intl/tst-gettext.sh glibc-2.13/intl/tst-gettext.sh
---- glibc-2.13.orig/intl/tst-gettext.sh 2004-08-15 21:28:18.000000000 +0200
-+++ glibc-2.13/intl/tst-gettext.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-gettext.sh
++++ b/intl/tst-gettext.sh
@@ -51,9 +51,12 @@
LOCPATH=${common_objpfx}localedata
export LOCPATH
@@ -86,9 +96,8 @@ diff -durN glibc-2.13.orig/intl/tst-gettext.sh glibc-2.13/intl/tst-gettext.sh
${objpfx}tst-gettext > ${objpfx}tst-gettext.out ${objpfx}domaindir
exit $?
-diff -durN glibc-2.13.orig/intl/tst-gettext2.sh glibc-2.13/intl/tst-gettext2.sh
---- glibc-2.13.orig/intl/tst-gettext2.sh 2005-05-04 19:54:48.000000000 +0200
-+++ glibc-2.13/intl/tst-gettext2.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-gettext2.sh
++++ b/intl/tst-gettext2.sh
@@ -65,8 +65,11 @@
LOCPATH=${objpfx}domaindir
export LOCPATH
@@ -102,9 +111,8 @@ diff -durN glibc-2.13.orig/intl/tst-gettext2.sh glibc-2.13/intl/tst-gettext2.sh
${objpfx}tst-gettext2 > ${objpfx}tst-gettext2.out ${objpfx}domaindir &&
cmp ${objpfx}tst-gettext2.out - <<EOF
String1 - Lang1: 1st string
-diff -durN glibc-2.13.orig/intl/tst-translit.sh glibc-2.13/intl/tst-translit.sh
---- glibc-2.13.orig/intl/tst-translit.sh 2005-05-04 19:56:10.000000000 +0200
-+++ glibc-2.13/intl/tst-translit.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/intl/tst-translit.sh
++++ b/intl/tst-translit.sh
@@ -36,7 +36,10 @@
LOCPATH=${common_objpfx}localedata
export LOCPATH
@@ -117,9 +125,8 @@ diff -durN glibc-2.13.orig/intl/tst-translit.sh glibc-2.13/intl/tst-translit.sh
${objpfx}tst-translit > ${objpfx}tst-translit.out ${objpfx}domaindir
exit $?
-diff -durN glibc-2.13.orig/malloc/tst-mtrace.sh glibc-2.13/malloc/tst-mtrace.sh
---- glibc-2.13.orig/malloc/tst-mtrace.sh 2005-10-15 01:40:35.000000000 +0200
-+++ glibc-2.13/malloc/tst-mtrace.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/malloc/tst-mtrace.sh
++++ b/malloc/tst-mtrace.sh
@@ -24,9 +24,12 @@
status=0
trap "rm -f ${common_objpfx}malloc/tst-mtrace.leak; exit 1" 1 2 15
@@ -134,9 +141,8 @@ diff -durN glibc-2.13.orig/malloc/tst-mtrace.sh glibc-2.13/malloc/tst-mtrace.sh
${common_objpfx}malloc/tst-mtrace || status=1
if test $status -eq 0 && test -f ${common_objpfx}malloc/mtrace; then
-diff -durN glibc-2.13.orig/nptl/tst-tls6.sh glibc-2.13/nptl/tst-tls6.sh
---- glibc-2.13.orig/nptl/tst-tls6.sh 2003-09-03 00:02:59.000000000 +0200
-+++ glibc-2.13/nptl/tst-tls6.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/nptl/tst-tls6.sh
++++ b/nptl/tst-tls6.sh
@@ -5,8 +5,8 @@
rtld_installed_name=$1; shift
logfile=$common_objpfx/nptl/tst-tls6.out
@@ -148,9 +154,8 @@ diff -durN glibc-2.13.orig/nptl/tst-tls6.sh glibc-2.13/nptl/tst-tls6.sh
tst_tls5="${elf_objpfx}${rtld_installed_name} --library-path ${library_path} \
${common_objpfx}/nptl/tst-tls5"
-diff -durN glibc-2.13.orig/posix/globtest.sh glibc-2.13/posix/globtest.sh
---- glibc-2.13.orig/posix/globtest.sh 2008-12-06 07:05:39.000000000 +0100
-+++ glibc-2.13/posix/globtest.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/posix/globtest.sh
++++ b/posix/globtest.sh
@@ -18,7 +18,7 @@
esac
@@ -160,9 +165,8 @@ diff -durN glibc-2.13.orig/posix/globtest.sh glibc-2.13/posix/globtest.sh
# Since we use `sort' we must make sure to use the same locale everywhere.
LC_ALL=C
-diff -durN glibc-2.13.orig/posix/tst-getconf.sh glibc-2.13/posix/tst-getconf.sh
---- glibc-2.13.orig/posix/tst-getconf.sh 2002-09-01 13:11:25.000000000 +0200
-+++ glibc-2.13/posix/tst-getconf.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/posix/tst-getconf.sh
++++ b/posix/tst-getconf.sh
@@ -10,7 +10,10 @@
else
rtld_installed_name=$1; shift
@@ -175,9 +179,8 @@ diff -durN glibc-2.13.orig/posix/tst-getconf.sh glibc-2.13/posix/tst-getconf.sh
}
fi
-diff -durN glibc-2.13.orig/posix/wordexp-tst.sh glibc-2.13/posix/wordexp-tst.sh
---- glibc-2.13.orig/posix/wordexp-tst.sh 2000-10-20 18:23:30.000000000 +0200
-+++ glibc-2.13/posix/wordexp-tst.sh 2009-11-13 00:50:37.000000000 +0100
+--- a/posix/wordexp-tst.sh
++++ b/posix/wordexp-tst.sh
@@ -19,8 +19,11 @@
"
export IFS
diff --git a/packages/glibc/2.15/380-dont-build-timezone.patch b/packages/glibc/2.15/0026-dont-build-timezone.patch
index 11c358e..a1442ab 100644
--- a/packages/glibc/2.15/380-dont-build-timezone.patch
+++ b/packages/glibc/2.15/0026-dont-build-timezone.patch
@@ -1,9 +1,12 @@
timezone data has been split into the package sys-libs/timezone-data
-diff -durN glibc-2.13.orig/Makeconfig glibc-2.13/Makeconfig
---- glibc-2.13.orig/Makeconfig 2009-11-13 00:50:13.000000000 +0100
-+++ glibc-2.13/Makeconfig 2009-11-13 00:50:41.000000000 +0100
-@@ -944,7 +944,7 @@
+---
+ Makeconfig | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/Makeconfig
++++ b/Makeconfig
+@@ -958,7 +958,7 @@
stdlib stdio-common libio malloc string wcsmbs time dirent \
grp pwd posix io termios resource misc socket sysvipc gmon \
gnulib iconv iconvdata wctype manual shadow gshadow po argp \
diff --git a/packages/glibc/2.15/400-alpha-xstat.patch b/packages/glibc/2.15/0027-alpha-xstat.patch
index 6e4ab8f..4fa9517 100644
--- a/packages/glibc/2.15/400-alpha-xstat.patch
+++ b/packages/glibc/2.15/0027-alpha-xstat.patch
@@ -1,6 +1,9 @@
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h 2009-05-09 08:54:20.000000000 +0200
-+++ glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:50:45.000000000 +0100
+---
+ sysdeps/unix/sysv/linux/kernel-features.h | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
@@ -386,6 +386,11 @@
# define __ASSUME_GETDENTS32_D_TYPE 1
#endif
diff --git a/packages/glibc/2.15/0028-alpha-creat.patch b/packages/glibc/2.15/0028-alpha-creat.patch
new file mode 100644
index 0000000..6ef5278
--- /dev/null
+++ b/packages/glibc/2.15/0028-alpha-creat.patch
@@ -0,0 +1,17 @@
+alpha does not have a __NR_creat
+
+http://bugs.gentoo.org/227275
+http://sourceware.org/bugzilla/show_bug.cgi?id=6650
+
+---
+ sysdeps/unix/sysv/linux/wordsize-64/creat64.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+--- a/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
++++ b/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
+@@ -1 +1,5 @@
+ /* Defined as alias for the syscall. */
++#include <sysdep.h>
++#ifndef __NR_creat
++#include "../../../../../io/creat64.c"
++#endif
diff --git a/packages/glibc/2.15/490-alpha_alpha-add-fdatasync-support.patch b/packages/glibc/2.15/0029-alpha_alpha-add-fdatasync-support.patch
index acf250d..9724d4e 100644
--- a/packages/glibc/2.15/490-alpha_alpha-add-fdatasync-support.patch
+++ b/packages/glibc/2.15/0029-alpha_alpha-add-fdatasync-support.patch
@@ -13,9 +13,8 @@
sysdeps/unix/sysv/linux/syscalls.list | 1
4 files changed, 76 insertions(+), 1 deletion(-)
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/Makefile glibc-2.13/sysdeps/unix/sysv/linux/Makefile
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/Makefile 2009-03-02 17:15:13.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/Makefile 2009-11-13 00:51:04.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/Makefile
++++ b/sysdeps/unix/sysv/linux/Makefile
@@ -21,6 +21,7 @@
setfsuid setfsgid makedev epoll_pwait signalfd \
eventfd eventfd_read eventfd_write prlimit
@@ -24,9 +23,8 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/Makefile glibc-2.13/sysdeps/u
CFLAGS-gethostid.c = -fexceptions
CFLAGS-tst-writev.c += "-DARTIFICIAL_LIMIT=0x80000000-__getpagesize()"
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/fdatasync.c glibc-2.13/sysdeps/unix/sysv/linux/fdatasync.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/fdatasync.c 1970-01-01 01:00:00.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/fdatasync.c 2009-11-13 00:51:04.000000000 +0100
+--- /dev/null
++++ b/sysdeps/unix/sysv/linux/fdatasync.c
@@ -0,0 +1,69 @@
+/* fdatasync -- synchronize at least the data part of a file with
+ the underlying media. Linux version.
@@ -97,9 +95,8 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/fdatasync.c glibc-2.13/sysdep
+
+weak_alias (__fdatasync, fdatasync)
+
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:50:45.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:51:04.000000000 +0100
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
@@ -459,6 +459,12 @@
# define __ASSUME_FUTEX_LOCK_PI 1
#endif
@@ -113,10 +110,9 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.13/
/* Support for utimensat syscall was added in 2.6.22, on SH
only after 2.6.22-rc1. */
#if __LINUX_KERNEL_VERSION >= 0x020616 \
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/syscalls.list glibc-2.13/sysdeps/unix/sysv/linux/syscalls.list
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/syscalls.list 2008-08-02 01:29:08.000000000 +0200
-+++ glibc-2.13/sysdeps/unix/sysv/linux/syscalls.list 2009-11-13 00:51:04.000000000 +0100
-@@ -11,7 +11,6 @@
+--- a/sysdeps/unix/sysv/linux/syscalls.list
++++ b/sysdeps/unix/sysv/linux/syscalls.list
+@@ -12,7 +12,6 @@
epoll_create1 EXTRA epoll_create1 i:i epoll_create1
epoll_ctl EXTRA epoll_ctl i:iiip epoll_ctl
epoll_wait EXTRA epoll_wait Ci:ipii epoll_wait
diff --git a/packages/glibc/2.14.1/560-ppc-atomic.patch b/packages/glibc/2.15/0030-ppc-atomic.patch
index ee1cb90..a38c1c5 100644
--- a/packages/glibc/2.14.1/560-ppc-atomic.patch
+++ b/packages/glibc/2.15/0030-ppc-atomic.patch
@@ -1,14 +1,13 @@
sniped from suse
-Index: sysdeps/powerpc/bits/atomic.h
-===================================================================
-RCS file: /cvs/glibc/libc/sysdeps/powerpc/bits/atomic.h,v
-retrieving revision 1.17
-diff -u -a -p -r1.17 atomic.h
+---
+ sysdeps/powerpc/bits/atomic.h | 66 ++++++++++-----------
+ sysdeps/powerpc/powerpc32/bits/atomic.h | 16 ++---
+ sysdeps/powerpc/powerpc64/bits/atomic.h | 98 ++++++++++++++++----------------
+ 3 files changed, 90 insertions(+), 90 deletions(-)
-diff -durN glibc-2.13.orig/sysdeps/powerpc/bits/atomic.h glibc-2.13/sysdeps/powerpc/bits/atomic.h
---- glibc-2.13.orig/sysdeps/powerpc/bits/atomic.h 2007-03-26 22:15:28.000000000 +0200
-+++ glibc-2.13/sysdeps/powerpc/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
+--- a/sysdeps/powerpc/bits/atomic.h
++++ b/sysdeps/powerpc/bits/atomic.h
@@ -85,14 +85,14 @@
__typeof (*(mem)) __tmp; \
__typeof (mem) __memp = (mem); \
@@ -151,9 +150,8 @@ diff -durN glibc-2.13.orig/sysdeps/powerpc/bits/atomic.h glibc-2.13/sysdeps/powe
: "cr0", "memory"); \
__val; \
})
-diff -durN glibc-2.13.orig/sysdeps/powerpc/powerpc32/bits/atomic.h glibc-2.13/sysdeps/powerpc/powerpc32/bits/atomic.h
---- glibc-2.13.orig/sysdeps/powerpc/powerpc32/bits/atomic.h 2007-03-26 22:15:45.000000000 +0200
-+++ glibc-2.13/sysdeps/powerpc/powerpc32/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
+--- a/sysdeps/powerpc/powerpc32/bits/atomic.h
++++ b/sysdeps/powerpc/powerpc32/bits/atomic.h
@@ -44,14 +44,14 @@
({ \
unsigned int __tmp; \
@@ -192,9 +190,8 @@ diff -durN glibc-2.13.orig/sysdeps/powerpc/powerpc32/bits/atomic.h glibc-2.13/sy
: "cr0", "memory"); \
__tmp != 0; \
})
-diff -durN glibc-2.13.orig/sysdeps/powerpc/powerpc64/bits/atomic.h glibc-2.13/sysdeps/powerpc/powerpc64/bits/atomic.h
---- glibc-2.13.orig/sysdeps/powerpc/powerpc64/bits/atomic.h 2007-03-26 22:16:03.000000000 +0200
-+++ glibc-2.13/sysdeps/powerpc/powerpc64/bits/atomic.h 2009-11-13 00:51:19.000000000 +0100
+--- a/sysdeps/powerpc/powerpc64/bits/atomic.h
++++ b/sysdeps/powerpc/powerpc64/bits/atomic.h
@@ -44,14 +44,14 @@
({ \
unsigned int __tmp, __tmp2; \
diff --git a/packages/glibc/2.15/630-mips_shn_undef-hack.patch b/packages/glibc/2.15/0031-mips_shn_undef-hack.patch
index 791d76c..a12c977 100644
--- a/packages/glibc/2.15/630-mips_shn_undef-hack.patch
+++ b/packages/glibc/2.15/0031-mips_shn_undef-hack.patch
@@ -1,10 +1,13 @@
-diff -durN glibc-2.13.orig/elf/dl-lookup.c glibc-2.13/elf/dl-lookup.c
---- glibc-2.13.orig/elf/dl-lookup.c 2009-03-30 23:14:32.000000000 +0200
-+++ glibc-2.13/elf/dl-lookup.c 2009-11-13 00:51:36.000000000 +0100
-@@ -301,6 +301,12 @@
+---
+ elf/dl-lookup.c | 6 ++++++
+ 1 file changed, 6 insertions(+)
+
+--- a/elf/dl-lookup.c
++++ b/elf/dl-lookup.c
+@@ -300,6 +300,12 @@
/* FALLTHROUGH */
case STB_GLOBAL:
- success:
+ success:
+#ifdef __mips__
+ /* HACK: MIPS marks its lazy evaluation stubs with SHN_UNDEF
+ symbols, we skip them. */
diff --git a/packages/glibc/2.13/640-alpha-atfcts.patch b/packages/glibc/2.15/0032-alpha-atfcts.patch
index 7a8a94a..2eff918 100644
--- a/packages/glibc/2.13/640-alpha-atfcts.patch
+++ b/packages/glibc/2.15/0032-alpha-atfcts.patch
@@ -1,5 +1,9 @@
---- glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h 2010-07-27 14:34:39.000000000 +0300
-+++ glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h.new 2011-03-10 18:54:37.686795979 +0200
+---
+ sysdeps/unix/sysv/linux/kernel-features.h | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
@@ -437,7 +437,8 @@
the code. On PPC they were introduced in 2.6.17-rc1,
on SH in 2.6.19-rc1. */
diff --git a/packages/glibc/2.12.1/650-syslog.patch b/packages/glibc/2.15/0033-syslog.patch
index c20cafc..a2d9722 100644
--- a/packages/glibc/2.12.1/650-syslog.patch
+++ b/packages/glibc/2.15/0033-syslog.patch
@@ -1,6 +1,9 @@
-diff -durN glibc-cvs-2.9.orig/misc/syslog.c glibc-cvs-2.9/misc/syslog.c
---- glibc-cvs-2.9.orig/misc/syslog.c 2009-06-01 10:16:50.000000000 +0200
-+++ glibc-cvs-2.9/misc/syslog.c 2009-06-01 10:17:20.000000000 +0200
+---
+ misc/syslog.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/misc/syslog.c
++++ b/misc/syslog.c
@@ -152,7 +152,7 @@
#define INTERNALLOG LOG_ERR|LOG_CONS|LOG_PERROR|LOG_PID
/* Check for invalid bits. */
diff --git a/packages/glibc/2.15/0034-debug-readlink_chk-readklinkat_chk.patch b/packages/glibc/2.15/0034-debug-readlink_chk-readklinkat_chk.patch
new file mode 100644
index 0000000..0b930f3
--- /dev/null
+++ b/packages/glibc/2.15/0034-debug-readlink_chk-readklinkat_chk.patch
@@ -0,0 +1,27 @@
+---
+ debug/readlink_chk.c | 2 +-
+ debug/readlinkat_chk.c | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+--- a/debug/readlink_chk.c
++++ b/debug/readlink_chk.c
+@@ -25,7 +25,7 @@
+
+
+ ssize_t
+-__readlink_chk (const char *path, void *buf, size_t len, size_t buflen)
++__readlink_chk (const char *path, char *buf, size_t len, size_t buflen)
+ {
+ if (len > buflen)
+ __chk_fail ();
+--- a/debug/readlinkat_chk.c
++++ b/debug/readlinkat_chk.c
+@@ -21,7 +21,7 @@
+
+
+ ssize_t
+-__readlinkat_chk (int fd, const char *path, void *buf, size_t len,
++__readlinkat_chk (int fd, const char *path, char *buf, size_t len,
+ size_t buflen)
+ {
+ if (len > buflen)
diff --git a/packages/glibc/2.15/900-cpuid-include.patch b/packages/glibc/2.15/0035-cpuid-include.patch
index 29edf7b..e6d656a 100644
--- a/packages/glibc/2.15/900-cpuid-include.patch
+++ b/packages/glibc/2.15/0035-cpuid-include.patch
@@ -19,10 +19,14 @@ Tested x86_64 (native).
Origin: http://sourceware.org/ml/libc-alpha/2012-03/msg00177.html
-diff -urpN '--exclude=autom4te.cache' glibc-2.15.orig/sysdeps/i386/configure glibc-2.15/sysdeps/i386/configure
---- glibc-2.15.orig/sysdeps/i386/configure 2017-02-08 14:28:19.947516097 -0800
-+++ glibc-2.15/sysdeps/i386/configure 2017-02-08 17:25:19.756462280 -0800
-@@ -16,23 +16,6 @@ as_fn_exit ()
+---
+ sysdeps/i386/configure | 480 ----------------------------------------------
+ sysdeps/i386/configure.in | 5
+ 2 files changed, 4 insertions(+), 481 deletions(-)
+
+--- a/sysdeps/i386/configure
++++ b/sysdeps/i386/configure
+@@ -16,23 +16,6 @@
as_fn_set_status $1
exit $1
} # as_fn_exit
@@ -46,7 +50,7 @@ diff -urpN '--exclude=autom4te.cache' glibc-2.15.orig/sysdeps/i386/configure gli
if expr a : '\(a\)' >/dev/null 2>&1 &&
test "X`expr 00001 : '.*\(...\)'`" = X001; then
as_expr=expr
-@@ -97,42 +80,6 @@ $as_echo X/"$0" |
+@@ -97,42 +80,6 @@
exit
}
@@ -89,7 +93,7 @@ diff -urpN '--exclude=autom4te.cache' glibc-2.15.orig/sysdeps/i386/configure gli
# ac_fn_c_try_compile LINENO
# --------------------------
-@@ -172,172 +119,6 @@ fi
+@@ -172,172 +119,6 @@
} # ac_fn_c_try_compile
@@ -262,7 +266,7 @@ diff -urpN '--exclude=autom4te.cache' glibc-2.15.orig/sysdeps/i386/configure gli
# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
# -------------------------------------------------------
# Tests whether HEADER exists and can be compiled using the include files in
-@@ -372,267 +153,8 @@ $as_echo "$ac_res" >&6; }
+@@ -372,267 +153,8 @@
# Local configure fragment for sysdeps/i386.
@@ -531,9 +535,8 @@ diff -urpN '--exclude=autom4te.cache' glibc-2.15.orig/sysdeps/i386/configure gli
if test "x$ac_cv_header_cpuid_h" = xyes; then :
else
-diff -urpN '--exclude=autom4te.cache' glibc-2.15.orig/sysdeps/i386/configure.in glibc-2.15/sysdeps/i386/configure.in
---- glibc-2.15.orig/sysdeps/i386/configure.in 2017-02-08 14:28:19.951516034 -0800
-+++ glibc-2.15/sysdeps/i386/configure.in 2017-02-08 17:24:29.995973278 -0800
+--- a/sysdeps/i386/configure.in
++++ b/sysdeps/i386/configure.in
@@ -1,8 +1,9 @@
GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
# Local configure fragment for sysdeps/i386.
diff --git a/packages/glibc/2.14.1/910-asm-i686.patch b/packages/glibc/2.15/0036-asm-i686.patch
index b049887..ea3c88a 100644
--- a/packages/glibc/2.14.1/910-asm-i686.patch
+++ b/packages/glibc/2.15/0036-asm-i686.patch
@@ -18,9 +18,13 @@ Description: Fixes the following build problem with GCC-4.5.0:
./sysdeps/i386/fpu/s_frexp.S:66: Error: junk `.get_pc_thunk.dx' after expression
make[2]: *** [/mnt/lfs/sources/libc-build/math/s_frexp.os] Error 1
-diff -Naur glibc-2.11.1.orig/nptl/sysdeps/pthread/pt-initfini.c glibc-2.11.1/nptl/sysdeps/pthread/pt-initfini.c
---- glibc-2.11.1.orig/nptl/sysdeps/pthread/pt-initfini.c 2009-12-08 20:10:20.000000000 +0000
-+++ glibc-2.11.1/nptl/sysdeps/pthread/pt-initfini.c 2010-04-17 11:34:06.882681001 +0000
+---
+ nptl/sysdeps/pthread/pt-initfini.c | 5 +++++
+ sysdeps/unix/sysv/linux/i386/sysdep.h | 4 ++++
+ 2 files changed, 9 insertions(+)
+
+--- a/nptl/sysdeps/pthread/pt-initfini.c
++++ b/nptl/sysdeps/pthread/pt-initfini.c
@@ -45,6 +45,11 @@
/* Embed an #include to pull in the alignment and .end directives. */
asm ("\n#include \"defs.h\"");
@@ -33,9 +37,8 @@ diff -Naur glibc-2.11.1.orig/nptl/sysdeps/pthread/pt-initfini.c glibc-2.11.1/npt
/* The initial common code ends here. */
asm ("\n/*@HEADER_ENDS*/");
-diff -Naur glibc-2.11.1.orig/sysdeps/unix/sysv/linux/i386/sysdep.h glibc-2.11.1/sysdeps/unix/sysv/linux/i386/sysdep.h
---- glibc-2.11.1.orig/sysdeps/unix/sysv/linux/i386/sysdep.h 2009-12-08 20:10:20.000000000 +0000
-+++ glibc-2.11.1/sysdeps/unix/sysv/linux/i386/sysdep.h 2010-04-17 11:34:06.882681001 +0000
+--- a/sysdeps/unix/sysv/linux/i386/sysdep.h
++++ b/sysdeps/unix/sysv/linux/i386/sysdep.h
@@ -29,6 +29,10 @@
#include <dl-sysdep.h>
#include <tls.h>
@@ -47,4 +50,3 @@ diff -Naur glibc-2.11.1.orig/sysdeps/unix/sysv/linux/i386/sysdep.h glibc-2.11.1/
/* For Linux we can use the system call table in the header file
/usr/include/asm/unistd.h
-
diff --git a/packages/glibc/2.15/0037-fix-rpc_parse-format.patch b/packages/glibc/2.15/0037-fix-rpc_parse-format.patch
new file mode 100644
index 0000000..341d541
--- /dev/null
+++ b/packages/glibc/2.15/0037-fix-rpc_parse-format.patch
@@ -0,0 +1,62 @@
+commit 5874510faaf3cbd0bb112aaacab9f225002beed1
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Tue Nov 8 23:44:51 2016 +0000
+
+ Fix rpcgen buffer overrun (bug 20790).
+
+ Building with GCC 7 produces an error building rpcgen:
+
+ rpc_parse.c: In function 'get_prog_declaration':
+ rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ~~~~^
+ rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+ That buffer overrun is for the case where the .x file declares a
+ program with a million arguments. The strcpy two lines above can
+ generate a buffer overrun much more simply for a long argument name.
+
+ The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
+ provides a bound on the buffer size needed, so this patch just changes
+ the buffer size to MAXLINESIZE to avoid both possible buffer
+ overruns. A testcase is added that rpcgen does not crash with a
+ 500-character argument name, where it previously crashed.
+
+ It would not at all surprise me if there are many other ways of
+ crashing rpcgen with either valid or invalid input; fuzz testing would
+ likely find various such bugs, though I don't think they are that
+ important to fix (rpcgen is not that likely to be used with untrusted
+ .x files as input). (As well as fuzz-findable bugs there are probably
+ also issues when various int variables get overflowed on very large
+ input.) The test infrastructure for rpcgen-not-crashing tests would
+ need extending if tests are to be added for cases where rpcgen should
+ produce an error, as opposed to cases where it should succeed.
+
+ Tested for x86_64 and x86.
+
+ [BZ #20790]
+ * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
+ to MAXLINESIZE.
+ * sunrpc/bug20790.x: New file.
+ * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
+ variable.
+ [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
+ [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
+
+---
+ sunrpc/rpc_parse.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/sunrpc/rpc_parse.c
++++ b/sunrpc/rpc_parse.c
+@@ -521,7 +521,7 @@
+ get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
+ {
+ token tok;
+- char name[10]; /* argument name */
++ char name[MAXLINESIZE]; /* argument name */
+
+ if (dkind == DEF_PROGRAM)
+ {
diff --git a/packages/glibc/2.15/0038-nis-bogus-conditional.patch b/packages/glibc/2.15/0038-nis-bogus-conditional.patch
new file mode 100644
index 0000000..732b859
--- /dev/null
+++ b/packages/glibc/2.15/0038-nis-bogus-conditional.patch
@@ -0,0 +1,64 @@
+commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Wed Dec 21 23:44:01 2016 +0000
+
+ Fix nss_nisplus build with mainline GCC (bug 20978).
+
+ glibc build with current mainline GCC fails because
+ nis/nss_nisplus/nisplus-alias.c contains code
+
+ if (name != NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
+ }
+
+ char buf[strlen (name) + 9 + tablename_len];
+
+ producing an error about strlen being called on a pointer that is
+ always NULL (and a subsequent use of that pointer with a %s format in
+ snprintf).
+
+ As Andreas noted, the bogus conditional comes from a 1997 change:
+
+ - if (name == NULL || strlen(name) > 8)
+ - return NSS_STATUS_NOTFOUND;
+ - else
+ + if (name != NULL || strlen(name) <= 8)
+
+ So the intention is clearly to return an error for NULL name.
+
+ This patch duly inverts the sense of the conditional. It fixes the
+ build with GCC mainline, and passes usual glibc testsuite testing for
+ x86_64. However, I have not tried any actual substantive nisplus
+ testing, do not have an environment for such testing, and do not know
+ whether it is possible that strlen (name) or tablename_len might be
+ large so that the VLA for buf is actually a security issue. However,
+ if it is a security issue, there are plenty of other similar instances
+ in the nisplus code (that haven't been hidden by a bogus comparison
+ with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
+ string passed to nis_list, so a local fix in the caller wouldn't
+ suffice anyway (see bug 20987). (Calls to strdupa and other such
+ macros that use alloca must be considered equally questionable
+ regarding stack overflow issues as direct calls to alloca and VLA
+ declarations.)
+
+ [BZ #20978]
+ * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
+ Compare name == NULL, not name != NULL.
+
+---
+ nis/nss_nisplus/nisplus-alias.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/nis/nss_nisplus/nisplus-alias.c
++++ b/nis/nss_nisplus/nisplus-alias.c
+@@ -293,7 +293,7 @@
+ return status;
+ }
+
+- if (name != NULL)
++ if (name == NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.15/990-try-link-static.patch b/packages/glibc/2.15/0039-try-link-static.patch
index a0ffadd..15d4d25 100644
--- a/packages/glibc/2.15/990-try-link-static.patch
+++ b/packages/glibc/2.15/0039-try-link-static.patch
@@ -6,10 +6,15 @@ Date: Thu Mar 8 00:17:27 2012 +0000
Fix .ctors/.dtors header configure test for bootstrapping.
-diff -urpN glibc-2.15.orig/aclocal.m4 glibc-2.15/aclocal.m4
---- glibc-2.15.orig/aclocal.m4 2017-02-08 11:27:28.445657746 -0800
-+++ glibc-2.15/aclocal.m4 2017-02-08 11:37:25.818463475 -0800
-@@ -114,3 +114,17 @@ AC_CACHE_CHECK(whether $LD is GNU ld, li
+---
+ aclocal.m4 | 14 ++++++++++++++
+ configure | 57 ++++++++++++++++++++++++++++++---------------------------
+ configure.in | 27 ++++++++++-----------------
+ 3 files changed, 54 insertions(+), 44 deletions(-)
+
+--- a/aclocal.m4
++++ b/aclocal.m4
+@@ -114,3 +114,17 @@
[LIBC_PROG_FOO_GNU($LD, libc_cv_prog_ld_gnu=yes, libc_cv_prog_ld_gnu=no)])
gnu_ld=$libc_cv_prog_ld_gnu
])
@@ -27,10 +32,9 @@ diff -urpN glibc-2.15.orig/aclocal.m4 glibc-2.15/aclocal.m4
+ 1>&AS_MESSAGE_LOG_FD])],
+ [$2], [$3])
+rm -f conftest*])
-diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
---- glibc-2.15.orig/configure 2017-02-08 11:27:28.453657802 -0800
-+++ glibc-2.15/configure 2017-02-08 11:47:36.184360147 -0800
-@@ -6147,29 +6147,32 @@ $as_echo_n "checking for .preinit_array/
+--- a/configure
++++ b/configure
+@@ -6147,29 +6147,32 @@
if ${libc_cv_initfini_array+:} false; then :
$as_echo_n "(cached) " >&6
else
@@ -74,7 +78,7 @@ diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_initfini_array" >&5
$as_echo "$libc_cv_initfini_array" >&6; }
-@@ -6183,21 +6186,22 @@ if ${libc_cv_ctors_header+:} false; then
+@@ -6183,21 +6186,22 @@
$as_echo_n "(cached) " >&6
else
libc_cv_ctors_header=yes
@@ -111,7 +115,7 @@ diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
if $READELF -WS conftest$ac_exeext | $AWK '
{ gsub(/\[ */, "[") }
$2 == ".ctors" || $2 == ".dtors" {
-@@ -6219,8 +6223,7 @@ else
+@@ -6219,8 +6223,7 @@
as_fn_error $? "missing __attribute__ ((constructor)) support??" "$LINENO" 5
fi
@@ -121,10 +125,9 @@ diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_ctors_header" >&5
-diff -urpN glibc-2.15.orig/configure.in glibc-2.15/configure.in
---- glibc-2.15.orig/configure.in 2017-02-08 11:27:28.433657663 -0800
-+++ glibc-2.15/configure.in 2017-02-08 11:46:58.994915812 -0800
-@@ -1439,24 +1439,17 @@ EOF
+--- a/configure.in
++++ b/configure.in
+@@ -1439,24 +1439,17 @@
AC_CACHE_CHECK(for .preinit_array/.init_array/.fini_array support,
libc_cv_initfini_array, [dnl
@@ -156,7 +159,7 @@ diff -urpN glibc-2.15.orig/configure.in glibc-2.15/configure.in
if test $libc_cv_initfini_array != yes; then
AC_MSG_ERROR([Need linker with .init_array/.fini_array support.])
fi
-@@ -1464,9 +1457,9 @@ EOF
+@@ -1464,9 +1457,9 @@
AC_CACHE_CHECK(whether to use .ctors/.dtors header and trailer,
libc_cv_ctors_header, [dnl
libc_cv_ctors_header=yes
diff --git a/packages/glibc/2.15/991-builtin_expect.patch b/packages/glibc/2.15/0040-builtin_expect.patch
index 8a327fa..4112bb9 100644
--- a/packages/glibc/2.15/991-builtin_expect.patch
+++ b/packages/glibc/2.15/0040-builtin_expect.patch
@@ -6,10 +6,14 @@ Date: Sun Jan 8 09:21:09 2012 -0500
No need for test for __builtin_expect
-diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
---- glibc-2.15.orig/configure 2017-02-08 12:47:52.580858002 -0800
-+++ glibc-2.15/configure 2017-02-08 13:01:40.682870318 -0800
-@@ -7185,38 +7185,6 @@ if test "$libc_cv_c_asmcr0_bug" != 'no';
+---
+ configure | 32 --------------------------------
+ configure.in | 22 ----------------------
+ 2 files changed, 54 deletions(-)
+
+--- a/configure
++++ b/configure
+@@ -7185,38 +7185,6 @@
fi
fi
@@ -48,10 +52,9 @@ diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_memset" >&5
$as_echo_n "checking for __builtin_memset... " >&6; }
if ${libc_cv_gcc_builtin_memset+:} false; then :
-diff -urpN glibc-2.15.orig/configure.in glibc-2.15/configure.in
---- glibc-2.15.orig/configure.in 2017-02-08 12:47:52.580858002 -0800
-+++ glibc-2.15/configure.in 2017-02-08 13:01:17.638580410 -0800
-@@ -2098,28 +2098,6 @@ if test "$libc_cv_c_asmcr0_bug" != 'no';
+--- a/configure.in
++++ b/configure.in
+@@ -2098,28 +2098,6 @@
fi
fi
diff --git a/packages/glibc/2.15/992-gcc_s-suffix.patch b/packages/glibc/2.15/0041-gcc_s-suffix.patch
index 6dbc70f..74f29d8 100644
--- a/packages/glibc/2.15/992-gcc_s-suffix.patch
+++ b/packages/glibc/2.15/0041-gcc_s-suffix.patch
@@ -5,10 +5,16 @@ Date: Tue Apr 24 10:22:45 2012 +0000
Don't handle libgcc_s suffixes.
-diff -urpN glibc-2.15.orig/config.make.in glibc-2.15/config.make.in
---- glibc-2.15.orig/config.make.in 2017-02-08 13:24:23.338055977 -0800
-+++ glibc-2.15/config.make.in 2017-02-08 13:25:21.810625337 -0800
-@@ -50,7 +50,6 @@ have-z-execstack = @libc_cv_z_execstack@
+---
+ Makeconfig | 2 +-
+ config.make.in | 1 -
+ configure | 21 +--------------------
+ configure.in | 16 +---------------
+ 4 files changed, 3 insertions(+), 37 deletions(-)
+
+--- a/config.make.in
++++ b/config.make.in
+@@ -50,7 +50,6 @@
have-initfini = @libc_cv_have_initfini@
have-Bgroup = @libc_cv_Bgroup@
have-as-needed = @libc_cv_as_needed@
@@ -16,10 +22,9 @@ diff -urpN glibc-2.15.orig/config.make.in glibc-2.15/config.make.in
need-nopic-initfini = @nopic_initfini@
with-fp = @with_fp@
old-glibc-headers = @old_glibc_headers@
-diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
---- glibc-2.15.orig/configure 2017-02-08 13:24:23.346056054 -0800
-+++ glibc-2.15/configure 2017-02-08 13:27:07.327670602 -0800
-@@ -654,7 +654,6 @@ libc_cv_z_execstack
+--- a/configure
++++ b/configure
+@@ -654,7 +654,6 @@
libc_cv_z_combreloc
ASFLAGS_config
libc_cv_as_needed
@@ -27,7 +32,7 @@ diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
libc_cv_Bgroup
libc_cv_cc_with_libunwind
VERSIONING
-@@ -6465,24 +6464,6 @@ fi
+@@ -6465,24 +6464,6 @@
$as_echo "$libc_cv_Bgroup" >&6; }
@@ -52,7 +57,7 @@ diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --as-needed option" >&5
$as_echo_n "checking for --as-needed option... " >&6; }
if ${libc_cv_as_needed+:} false; then :
-@@ -6493,7 +6474,7 @@ int main (void) { return 0; }
+@@ -6493,7 +6474,7 @@
EOF
if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
-fPIC -shared -o conftest.so conftest.c
@@ -61,10 +66,9 @@ diff -urpN glibc-2.15.orig/configure glibc-2.15/configure
-nostdlib 1>&5'
{ { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
(eval $ac_try) 2>&5
-diff -urpN glibc-2.15.orig/configure.in glibc-2.15/configure.in
---- glibc-2.15.orig/configure.in 2017-02-08 13:24:23.346056054 -0800
-+++ glibc-2.15/configure.in 2017-02-08 13:26:44.383441535 -0800
-@@ -1639,20 +1639,6 @@ EOF
+--- a/configure.in
++++ b/configure.in
+@@ -1639,20 +1639,6 @@
rm -f conftest*])
AC_SUBST(libc_cv_Bgroup)
@@ -85,7 +89,7 @@ diff -urpN glibc-2.15.orig/configure.in glibc-2.15/configure.in
AC_CACHE_CHECK(for --as-needed option,
libc_cv_as_needed, [dnl
cat > conftest.c <<EOF
-@@ -1660,7 +1646,7 @@ int main (void) { return 0; }
+@@ -1660,7 +1646,7 @@
EOF
if AC_TRY_COMMAND([${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
-fPIC -shared -o conftest.so conftest.c
@@ -94,10 +98,9 @@ diff -urpN glibc-2.15.orig/configure.in glibc-2.15/configure.in
-nostdlib 1>&AS_MESSAGE_LOG_FD])
then
libc_cv_as_needed=yes
-diff -urpN glibc-2.15.orig/Makeconfig glibc-2.15/Makeconfig
---- glibc-2.15.orig/Makeconfig 2017-02-08 13:24:23.338055977 -0800
-+++ glibc-2.15/Makeconfig 2017-02-08 13:24:31.262132679 -0800
-@@ -565,7 +565,7 @@ endif
+--- a/Makeconfig
++++ b/Makeconfig
+@@ -565,7 +565,7 @@
ifneq ($(have-as-needed),yes)
libgcc_eh := -lgcc_eh $(libunwind)
else
diff --git a/packages/glibc/2.15/996-obsolete-rpc.patch b/packages/glibc/2.15/0042-obsolete-rpc.patch
index 459be29..4e0f1cc 100644
--- a/packages/glibc/2.15/996-obsolete-rpc.patch
+++ b/packages/glibc/2.15/0042-obsolete-rpc.patch
@@ -10,11 +10,68 @@ Date: Thu May 10 20:16:53 2012 +0200
after the TI-RPC library becomes fully sufficient for the needs of
existing applications.
-diff --git a/config.h.in b/config.h.in
-index 787873b4c0..54952609ef 100644
+---
+ config.h.in | 3 +++
+ config.make.in | 1 +
+ configure | 18 ++++++++++++++++++
+ configure.in | 11 +++++++++++
+ include/libc-symbols.h | 7 ++++++-
+ nis/Makefile | 6 ++++++
+ sunrpc/Makefile | 6 ++++++
+ sunrpc/auth_des.c | 4 ++--
+ sunrpc/auth_none.c | 2 +-
+ sunrpc/auth_unix.c | 4 ++--
+ sunrpc/authdes_prot.c | 4 ++--
+ sunrpc/authuxprot.c | 2 +-
+ sunrpc/clnt_gen.c | 2 +-
+ sunrpc/clnt_perr.c | 10 +++++-----
+ sunrpc/clnt_raw.c | 2 +-
+ sunrpc/clnt_simp.c | 2 +-
+ sunrpc/clnt_tcp.c | 2 +-
+ sunrpc/clnt_udp.c | 6 +++---
+ sunrpc/clnt_unix.c | 2 +-
+ sunrpc/des_crypt.c | 4 ++--
+ sunrpc/des_soft.c | 2 +-
+ sunrpc/get_myaddr.c | 2 +-
+ sunrpc/key_call.c | 18 +++++++++---------
+ sunrpc/key_prot.c | 20 ++++++++++----------
+ sunrpc/netname.c | 10 +++++-----
+ sunrpc/pm_getmaps.c | 2 +-
+ sunrpc/pm_getport.c | 4 ++--
+ sunrpc/pmap_clnt.c | 4 ++--
+ sunrpc/pmap_prot.c | 2 +-
+ sunrpc/pmap_prot2.c | 2 +-
+ sunrpc/pmap_rmt.c | 8 ++++----
+ sunrpc/publickey.c | 4 ++--
+ sunrpc/rpc_cmsg.c | 2 +-
+ sunrpc/rpc_common.c | 2 +-
+ sunrpc/rpc_dtable.c | 2 +-
+ sunrpc/rpc_prot.c | 14 +++++++-------
+ sunrpc/rpc_thread.c | 8 ++++----
+ sunrpc/rtime.c | 2 +-
+ sunrpc/svc.c | 32 ++++++++++++++++----------------
+ sunrpc/svc_auth.c | 2 +-
+ sunrpc/svc_raw.c | 2 +-
+ sunrpc/svc_run.c | 4 ++--
+ sunrpc/svc_tcp.c | 4 ++--
+ sunrpc/svc_udp.c | 6 +++---
+ sunrpc/svc_unix.c | 4 ++--
+ sunrpc/svcauth_des.c | 2 +-
+ sunrpc/xcrypt.c | 4 ++--
+ sunrpc/xdr.c | 44 ++++++++++++++++++++++----------------------
+ sunrpc/xdr_array.c | 4 ++--
+ sunrpc/xdr_float.c | 4 ++--
+ sunrpc/xdr_intXX_t.c | 20 ++++++++++----------
+ sunrpc/xdr_mem.c | 2 +-
+ sunrpc/xdr_rec.c | 8 ++++----
+ sunrpc/xdr_ref.c | 4 ++--
+ sunrpc/xdr_sizeof.c | 2 +-
+ sunrpc/xdr_stdio.c | 2 +-
+ 56 files changed, 203 insertions(+), 153 deletions(-)
+
--- a/config.h.in
+++ b/config.h.in
-@@ -178,6 +178,9 @@
+@@ -187,6 +187,9 @@
/* Define if `.ctors' and `.dtors' sections shouldn't be used. */
#undef NO_CTORS_DTORS_SECTIONS
@@ -24,11 +81,9 @@ index 787873b4c0..54952609ef 100644
/*
*/
-diff --git a/config.make.in b/config.make.in
-index 5f6f9e281d..6c4d04ee33 100644
--- a/config.make.in
+++ b/config.make.in
-@@ -96,6 +96,7 @@ add-on-subdirs = @add_on_subdirs@
+@@ -100,6 +100,7 @@
sysdeps-add-ons = @sysdeps_add_ons@
cross-compiling = @cross_compiling@
force-install = @force_install@
@@ -36,11 +91,9 @@ index 5f6f9e281d..6c4d04ee33 100644
# Build tools.
CC = @CC@
-diff --git a/configure b/configure
-index 1c5f4adbea..c7cb47d0c2 100755
--- a/configure
+++ b/configure
-@@ -687,6 +687,7 @@ multi_arch
+@@ -692,6 +692,7 @@
base_machine
add_on_subdirs
add_ons
@@ -48,7 +101,7 @@ index 1c5f4adbea..c7cb47d0c2 100755
libc_cv_nss_crypt
all_warnings
force_install
-@@ -779,6 +780,7 @@ enable_kernel
+@@ -790,6 +791,7 @@
enable_all_warnings
enable_multi_arch
enable_nss_crypt
@@ -56,7 +109,7 @@ index 1c5f4adbea..c7cb47d0c2 100755
with_cpu
'
ac_precious_vars='build_alias
-@@ -1434,6 +1436,8 @@ Optional Features:
+@@ -1449,6 +1451,8 @@
--enable-multi-arch enable single DSO with optimizations for multiple
architectures
--enable-nss-crypt enable libcrypt to use nss
@@ -65,7 +118,7 @@ index 1c5f4adbea..c7cb47d0c2 100755
Optional Packages:
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
-@@ -3746,6 +3750,20 @@ else
+@@ -3803,6 +3807,20 @@
fi
@@ -86,11 +139,9 @@ index 1c5f4adbea..c7cb47d0c2 100755
# The way shlib-versions is used to generate soversions.mk uses a
# fairly simplistic model for name recognition that can't distinguish
# i486-pc-linux-gnu fully from i486-pc-gnu. So we mutate a $host_os
-diff --git a/configure.in b/configure.in
-index 19a2c1a0f0..4eb9277e8c 100644
--- a/configure.in
+++ b/configure.in
-@@ -252,6 +252,17 @@ else
+@@ -290,6 +290,17 @@
fi
AC_SUBST(libc_cv_nss_crypt)
@@ -108,11 +159,9 @@ index 19a2c1a0f0..4eb9277e8c 100644
# The way shlib-versions is used to generate soversions.mk uses a
# fairly simplistic model for name recognition that can't distinguish
# i486-pc-linux-gnu fully from i486-pc-gnu. So we mutate a $host_os
-diff --git a/include/libc-symbols.h b/include/libc-symbols.h
-index 951e46a6e3..0c3274e253 100644
--- a/include/libc-symbols.h
+++ b/include/libc-symbols.h
-@@ -556,7 +556,12 @@ for linking")
+@@ -626,7 +626,12 @@
# define libc_hidden_proto(name, attrs...) hidden_proto (name, ##attrs)
# define libc_hidden_def(name) hidden_def (name)
# define libc_hidden_weak(name) hidden_weak (name)
@@ -126,11 +175,9 @@ index 951e46a6e3..0c3274e253 100644
# define libc_hidden_ver(local, name) hidden_ver (local, name)
# define libc_hidden_data_def(name) hidden_data_def (name)
# define libc_hidden_data_weak(name) hidden_data_weak (name)
-diff --git a/nis/Makefile b/nis/Makefile
-index a48753f7a9..b412cee304 100644
--- a/nis/Makefile
+++ b/nis/Makefile
-@@ -23,6 +23,12 @@ subdir := nis
+@@ -23,6 +23,12 @@
aux := nis_hash
@@ -143,11 +190,9 @@ index a48753f7a9..b412cee304 100644
distribute := nss-nis.h nss-nisplus.h nis_intern.h Banner \
nisplus-parser.h nis_xdr.h nss \
$(wildcard rpcsvc/*.[hx])
-diff --git a/sunrpc/Makefile b/sunrpc/Makefile
-index e61efd02b3..3b79dcdb72 100644
--- a/sunrpc/Makefile
+++ b/sunrpc/Makefile
-@@ -60,6 +60,10 @@ generated-dirs := rpcsvc
+@@ -61,6 +61,10 @@
include ../Makeconfig
@@ -158,7 +203,7 @@ index e61efd02b3..3b79dcdb72 100644
ifeq ($(versioning),yes)
need-export-routines := auth_des auth_unix clnt_gen clnt_perr clnt_tcp \
clnt_udp get_myaddr key_call netname pm_getport \
-@@ -73,9 +77,11 @@ routines := auth_none authuxprot bindrsvprt clnt_raw clnt_simp \
+@@ -74,9 +78,11 @@
svc_simple xdr_float xdr_rec publickey authdes_prot \
des_crypt des_impl des_soft key_prot openchild rtime svcauth_des \
clnt_unix svc_unix create_xid $(need-export-routines)
@@ -170,11 +215,9 @@ index e61efd02b3..3b79dcdb72 100644
# We do not build rpcinfo anymore. It is not needed for a bootstrap
# and not wanted on complete systems.
-diff --git a/sunrpc/auth_des.c b/sunrpc/auth_des.c
-index 96bbcfc328..0408d60826 100644
--- a/sunrpc/auth_des.c
+++ b/sunrpc/auth_des.c
-@@ -117,7 +117,7 @@ authdes_create (const char *servername, u_int window,
+@@ -117,7 +117,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (authdes_create)
#else
@@ -183,7 +226,7 @@ index 96bbcfc328..0408d60826 100644
#endif
AUTH *
-@@ -211,7 +211,7 @@ failed:
+@@ -211,7 +211,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (authdes_pk_create)
#else
@@ -192,11 +235,9 @@ index 96bbcfc328..0408d60826 100644
#endif
/*
-diff --git a/sunrpc/auth_none.c b/sunrpc/auth_none.c
-index 5f252a9544..3af5966794 100644
--- a/sunrpc/auth_none.c
+++ b/sunrpc/auth_none.c
-@@ -95,7 +95,7 @@ authnone_create (void)
+@@ -95,7 +95,7 @@
__libc_once (authnone_private_guard, authnone_create_once);
return &authnone_private.no_client;
}
@@ -205,11 +246,9 @@ index 5f252a9544..3af5966794 100644
static bool_t
authnone_marshal (AUTH *client, XDR *xdrs)
-diff --git a/sunrpc/auth_unix.c b/sunrpc/auth_unix.c
-index d3b5dc7dee..68b42d7b1f 100644
--- a/sunrpc/auth_unix.c
+++ b/sunrpc/auth_unix.c
-@@ -149,7 +149,7 @@ no_memory:
+@@ -149,7 +149,7 @@
marshal_new_auth (auth);
return auth;
}
@@ -218,7 +257,7 @@ index d3b5dc7dee..68b42d7b1f 100644
/*
* Returns an auth handle with parameters determined by doing lots of
-@@ -216,7 +216,7 @@ authunix_create_default (void)
+@@ -216,7 +216,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (authunix_create_default)
#else
@@ -227,11 +266,9 @@ index d3b5dc7dee..68b42d7b1f 100644
#endif
/*
-diff --git a/sunrpc/authdes_prot.c b/sunrpc/authdes_prot.c
-index 0a25bac143..164c1223ca 100644
--- a/sunrpc/authdes_prot.c
+++ b/sunrpc/authdes_prot.c
-@@ -63,7 +63,7 @@ xdr_authdes_cred (XDR *xdrs, struct authdes_cred *cred)
+@@ -63,7 +63,7 @@
return FALSE;
}
}
@@ -240,38 +277,32 @@ index 0a25bac143..164c1223ca 100644
bool_t
-@@ -78,4 +78,4 @@ xdr_authdes_verf (register XDR *xdrs, register struct authdes_verf *verf)
+@@ -78,4 +78,4 @@
sizeof (verf->adv_int_u)));
return TRUE;
}
-libc_hidden_nolink (xdr_authdes_verf, GLIBC_2_1)
+libc_hidden_nolink_sunrpc (xdr_authdes_verf, GLIBC_2_1)
-diff --git a/sunrpc/authuxprot.c b/sunrpc/authuxprot.c
-index 64da1799e0..d37faee0c7 100644
--- a/sunrpc/authuxprot.c
+++ b/sunrpc/authuxprot.c
-@@ -63,4 +63,4 @@ xdr_authunix_parms (XDR * xdrs, struct authunix_parms *p)
+@@ -63,4 +63,4 @@
}
return FALSE;
}
-libc_hidden_nolink (xdr_authunix_parms, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_authunix_parms, GLIBC_2_0)
-diff --git a/sunrpc/clnt_gen.c b/sunrpc/clnt_gen.c
-index 2b7096cf20..df34672d72 100644
--- a/sunrpc/clnt_gen.c
+++ b/sunrpc/clnt_gen.c
-@@ -175,5 +175,5 @@ clnt_create (const char *hostname, u_long prog, u_long vers,
+@@ -175,5 +175,5 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (clnt_create)
#else
-libc_hidden_nolink (clnt_create, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (clnt_create, GLIBC_2_0)
#endif
-diff --git a/sunrpc/clnt_perr.c b/sunrpc/clnt_perr.c
-index 175370ebfc..b4f84c92e8 100644
--- a/sunrpc/clnt_perr.c
+++ b/sunrpc/clnt_perr.c
-@@ -127,7 +127,7 @@ clnt_sperror (CLIENT * rpch, const char *msg)
+@@ -127,7 +127,7 @@
return str;
}
@@ -280,7 +311,7 @@ index 175370ebfc..b4f84c92e8 100644
void
clnt_perror (CLIENT * rpch, const char *msg)
-@@ -137,7 +137,7 @@ clnt_perror (CLIENT * rpch, const char *msg)
+@@ -137,7 +137,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (clnt_perror)
#else
@@ -289,7 +320,7 @@ index 175370ebfc..b4f84c92e8 100644
#endif
-@@ -270,7 +270,7 @@ clnt_perrno (enum clnt_stat num)
+@@ -270,7 +270,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (clnt_perrno)
#else
@@ -298,7 +329,7 @@ index 175370ebfc..b4f84c92e8 100644
#endif
char *
-@@ -308,7 +308,7 @@ clnt_spcreateerror (const char *msg)
+@@ -308,7 +308,7 @@
return str;
}
@@ -307,7 +338,7 @@ index 175370ebfc..b4f84c92e8 100644
void
clnt_pcreateerror (const char *msg)
-@@ -318,7 +318,7 @@ clnt_pcreateerror (const char *msg)
+@@ -318,7 +318,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (clnt_pcreateerror)
#else
@@ -316,11 +347,9 @@ index 175370ebfc..b4f84c92e8 100644
#endif
struct auth_errtab
-diff --git a/sunrpc/clnt_raw.c b/sunrpc/clnt_raw.c
-index 95e3eae988..4004c6b6a8 100644
--- a/sunrpc/clnt_raw.c
+++ b/sunrpc/clnt_raw.c
-@@ -129,7 +129,7 @@ clntraw_create (u_long prog, u_long vers)
+@@ -129,7 +129,7 @@
client->cl_auth = authnone_create ();
return client;
}
@@ -329,11 +358,9 @@ index 95e3eae988..4004c6b6a8 100644
static enum clnt_stat
clntraw_call (h, proc, xargs, argsp, xresults, resultsp, timeout)
-diff --git a/sunrpc/clnt_simp.c b/sunrpc/clnt_simp.c
-index d2dd3b307a..d612df09a0 100644
--- a/sunrpc/clnt_simp.c
+++ b/sunrpc/clnt_simp.c
-@@ -139,7 +139,7 @@ callrpc (const char *host, u_long prognum, u_long versnum, u_long procnum,
+@@ -139,7 +139,7 @@
crp->valid = 0;
return (int) clnt_stat;
}
@@ -342,11 +369,9 @@ index d2dd3b307a..d612df09a0 100644
#ifdef _RPC_THREAD_SAFE_
void
-diff --git a/sunrpc/clnt_tcp.c b/sunrpc/clnt_tcp.c
-index d1fc43dbfd..6bd4c8c0cd 100644
--- a/sunrpc/clnt_tcp.c
+++ b/sunrpc/clnt_tcp.c
-@@ -220,7 +220,7 @@ fooy:
+@@ -220,7 +220,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (clnttcp_create)
#else
@@ -355,11 +380,9 @@ index d1fc43dbfd..6bd4c8c0cd 100644
#endif
static enum clnt_stat
-diff --git a/sunrpc/clnt_udp.c b/sunrpc/clnt_udp.c
-index 294e13a58c..7ecf2ef5a5 100644
--- a/sunrpc/clnt_udp.c
+++ b/sunrpc/clnt_udp.c
-@@ -239,7 +239,7 @@ fooy:
+@@ -239,7 +239,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (__libc_clntudp_bufcreate)
#else
@@ -368,7 +391,7 @@ index 294e13a58c..7ecf2ef5a5 100644
#endif
CLIENT *
-@@ -250,7 +250,7 @@ clntudp_bufcreate (struct sockaddr_in *raddr, u_long program, u_long version,
+@@ -250,7 +250,7 @@
return __libc_clntudp_bufcreate (raddr, program, version, wait,
sockp, sendsz, recvsz, 0);
}
@@ -377,7 +400,7 @@ index 294e13a58c..7ecf2ef5a5 100644
CLIENT *
clntudp_create (raddr, program, version, wait, sockp)
-@@ -266,7 +266,7 @@ clntudp_create (raddr, program, version, wait, sockp)
+@@ -266,7 +266,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (clntudp_create)
#else
@@ -386,11 +409,9 @@ index 294e13a58c..7ecf2ef5a5 100644
#endif
static int
-diff --git a/sunrpc/clnt_unix.c b/sunrpc/clnt_unix.c
-index 282127bb8b..776ceab484 100644
--- a/sunrpc/clnt_unix.c
+++ b/sunrpc/clnt_unix.c
-@@ -200,7 +200,7 @@ fooy:
+@@ -200,7 +200,7 @@
mem_free ((caddr_t) h, sizeof (CLIENT));
return (CLIENT *) NULL;
}
@@ -399,11 +420,9 @@ index 282127bb8b..776ceab484 100644
static enum clnt_stat
clntunix_call (h, proc, xdr_args, args_ptr, xdr_results, results_ptr, timeout)
-diff --git a/sunrpc/des_crypt.c b/sunrpc/des_crypt.c
-index 8745900b82..22a34b7f3a 100644
--- a/sunrpc/des_crypt.c
+++ b/sunrpc/des_crypt.c
-@@ -102,7 +102,7 @@ cbc_crypt (char *key, char *buf, unsigned int len, unsigned int mode,
+@@ -102,7 +102,7 @@
COPY8 (dp.des_ivec, ivec);
return err;
}
@@ -412,38 +431,32 @@ index 8745900b82..22a34b7f3a 100644
/*
* ECB mode encryption
-@@ -115,4 +115,4 @@ ecb_crypt (char *key, char *buf, unsigned int len, unsigned int mode)
+@@ -115,4 +115,4 @@
dp.des_mode = ECB;
return common_crypt (key, buf, len, mode, &dp);
}
-libc_hidden_nolink (ecb_crypt, GLIBC_2_1)
+libc_hidden_nolink_sunrpc (ecb_crypt, GLIBC_2_1)
-diff --git a/sunrpc/des_soft.c b/sunrpc/des_soft.c
-index 27d918c64d..cddef5d76b 100644
--- a/sunrpc/des_soft.c
+++ b/sunrpc/des_soft.c
-@@ -70,4 +70,4 @@ des_setparity (char *p)
+@@ -70,4 +70,4 @@
p++;
}
}
-libc_hidden_nolink (des_setparity, GLIBC_2_1)
+libc_hidden_nolink_sunrpc (des_setparity, GLIBC_2_1)
-diff --git a/sunrpc/get_myaddr.c b/sunrpc/get_myaddr.c
-index def5b7a74a..24407b53ec 100644
--- a/sunrpc/get_myaddr.c
+++ b/sunrpc/get_myaddr.c
-@@ -99,5 +99,5 @@ get_myaddress (struct sockaddr_in *addr)
+@@ -99,5 +99,5 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (get_myaddress)
#else
-libc_hidden_nolink (get_myaddress, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (get_myaddress, GLIBC_2_0)
#endif
-diff --git a/sunrpc/key_call.c b/sunrpc/key_call.c
-index 6d08bf8e80..e0a076b47f 100644
--- a/sunrpc/key_call.c
+++ b/sunrpc/key_call.c
-@@ -80,7 +80,7 @@ key_setsecret (char *secretkey)
+@@ -80,7 +80,7 @@
}
return 0;
}
@@ -452,7 +465,7 @@ index 6d08bf8e80..e0a076b47f 100644
/* key_secretkey_is_set() returns 1 if the keyserver has a secret key
* stored for the caller's effective uid; it returns 0 otherwise
-@@ -109,7 +109,7 @@ key_secretkey_is_set (void)
+@@ -109,7 +109,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (key_secretkey_is_set)
#else
@@ -461,7 +474,7 @@ index 6d08bf8e80..e0a076b47f 100644
#endif
int
-@@ -133,7 +133,7 @@ key_encryptsession (char *remotename, des_block *deskey)
+@@ -133,7 +133,7 @@
*deskey = res.cryptkeyres_u.deskey;
return 0;
}
@@ -470,7 +483,7 @@ index 6d08bf8e80..e0a076b47f 100644
int
key_decryptsession (char *remotename, des_block *deskey)
-@@ -155,7 +155,7 @@ key_decryptsession (char *remotename, des_block *deskey)
+@@ -155,7 +155,7 @@
*deskey = res.cryptkeyres_u.deskey;
return 0;
}
@@ -479,7 +492,7 @@ index 6d08bf8e80..e0a076b47f 100644
int
key_encryptsession_pk (char *remotename, netobj *remotekey,
-@@ -180,7 +180,7 @@ key_encryptsession_pk (char *remotename, netobj *remotekey,
+@@ -180,7 +180,7 @@
*deskey = res.cryptkeyres_u.deskey;
return 0;
}
@@ -488,7 +501,7 @@ index 6d08bf8e80..e0a076b47f 100644
int
key_decryptsession_pk (char *remotename, netobj *remotekey,
-@@ -205,7 +205,7 @@ key_decryptsession_pk (char *remotename, netobj *remotekey,
+@@ -205,7 +205,7 @@
*deskey = res.cryptkeyres_u.deskey;
return 0;
}
@@ -497,7 +510,7 @@ index 6d08bf8e80..e0a076b47f 100644
int
key_gendes (des_block *key)
-@@ -239,7 +239,7 @@ key_gendes (des_block *key)
+@@ -239,7 +239,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (key_gendes)
#else
@@ -506,7 +519,7 @@ index 6d08bf8e80..e0a076b47f 100644
#endif
int
-@@ -259,7 +259,7 @@ key_setnet (struct key_netstarg *arg)
+@@ -259,7 +259,7 @@
}
return 1;
}
@@ -515,7 +528,7 @@ index 6d08bf8e80..e0a076b47f 100644
int
key_get_conv (char *pkey, des_block *deskey)
-@@ -278,7 +278,7 @@ key_get_conv (char *pkey, des_block *deskey)
+@@ -278,7 +278,7 @@
*deskey = res.cryptkeyres_u.deskey;
return 0;
}
@@ -524,11 +537,9 @@ index 6d08bf8e80..e0a076b47f 100644
/*
* Hack to allow the keyserver to use AUTH_DES (for authenticated
-diff --git a/sunrpc/key_prot.c b/sunrpc/key_prot.c
-index dd73f5e3cb..2899c9a448 100644
--- a/sunrpc/key_prot.c
+++ b/sunrpc/key_prot.c
-@@ -38,7 +38,7 @@ xdr_keystatus (XDR * xdrs, keystatus * objp)
+@@ -38,7 +38,7 @@
return TRUE;
}
@@ -537,7 +548,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_keybuf (XDR * xdrs, keybuf objp)
-@@ -48,7 +48,7 @@ xdr_keybuf (XDR * xdrs, keybuf objp)
+@@ -48,7 +48,7 @@
return TRUE;
}
@@ -546,7 +557,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_netnamestr (XDR * xdrs, netnamestr * objp)
-@@ -58,7 +58,7 @@ xdr_netnamestr (XDR * xdrs, netnamestr * objp)
+@@ -58,7 +58,7 @@
return TRUE;
}
@@ -555,7 +566,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_cryptkeyarg (XDR * xdrs, cryptkeyarg * objp)
-@@ -71,7 +71,7 @@ xdr_cryptkeyarg (XDR * xdrs, cryptkeyarg * objp)
+@@ -71,7 +71,7 @@
return TRUE;
}
@@ -564,7 +575,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_cryptkeyarg2 (XDR * xdrs, cryptkeyarg2 * objp)
-@@ -84,7 +84,7 @@ xdr_cryptkeyarg2 (XDR * xdrs, cryptkeyarg2 * objp)
+@@ -84,7 +84,7 @@
return FALSE;
return TRUE;
}
@@ -573,7 +584,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_cryptkeyres (XDR * xdrs, cryptkeyres * objp)
-@@ -102,7 +102,7 @@ xdr_cryptkeyres (XDR * xdrs, cryptkeyres * objp)
+@@ -102,7 +102,7 @@
}
return TRUE;
}
@@ -582,7 +593,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_unixcred (XDR * xdrs, unixcred * objp)
-@@ -117,7 +117,7 @@ xdr_unixcred (XDR * xdrs, unixcred * objp)
+@@ -117,7 +117,7 @@
return FALSE;
return TRUE;
}
@@ -591,7 +602,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_getcredres (XDR * xdrs, getcredres * objp)
-@@ -135,7 +135,7 @@ xdr_getcredres (XDR * xdrs, getcredres * objp)
+@@ -135,7 +135,7 @@
}
return TRUE;
}
@@ -600,7 +611,7 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_key_netstarg (XDR * xdrs, key_netstarg * objp)
-@@ -148,7 +148,7 @@ xdr_key_netstarg (XDR * xdrs, key_netstarg * objp)
+@@ -148,7 +148,7 @@
return FALSE;
return TRUE;
}
@@ -609,17 +620,15 @@ index dd73f5e3cb..2899c9a448 100644
bool_t
xdr_key_netstres (XDR * xdrs, key_netstres * objp)
-@@ -166,4 +166,4 @@ xdr_key_netstres (XDR * xdrs, key_netstres * objp)
+@@ -166,4 +166,4 @@
}
return TRUE;
}
-libc_hidden_nolink (xdr_key_netstres, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_key_netstres, GLIBC_2_0)
-diff --git a/sunrpc/netname.c b/sunrpc/netname.c
-index 0b4980074c..197d503eae 100644
--- a/sunrpc/netname.c
+++ b/sunrpc/netname.c
-@@ -54,7 +54,7 @@ user2netname (char netname[MAXNETNAMELEN + 1], const uid_t uid,
+@@ -55,7 +55,7 @@
netname[i - 1] = '\0';
return 1;
}
@@ -628,7 +637,7 @@ index 0b4980074c..197d503eae 100644
int
host2netname (char netname[MAXNETNAMELEN + 1], const char *host,
-@@ -118,7 +118,7 @@ host2netname (char netname[MAXNETNAMELEN + 1], const char *host,
+@@ -119,7 +119,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (host2netname)
#else
@@ -637,7 +646,7 @@ index 0b4980074c..197d503eae 100644
#endif
int
-@@ -134,7 +134,7 @@ getnetname (char name[MAXNETNAMELEN + 1])
+@@ -135,7 +135,7 @@
dummy = user2netname (name, uid, NULL);
return (dummy);
}
@@ -646,7 +655,7 @@ index 0b4980074c..197d503eae 100644
/* Type of the lookup function for netname2user. */
typedef int (*netname2user_function) (const char netname[MAXNETNAMELEN + 1],
-@@ -187,7 +187,7 @@ netname2user (const char netname[MAXNETNAMELEN + 1], uid_t * uidp, gid_t * gidp,
+@@ -188,7 +188,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (netname2user)
#else
@@ -655,27 +664,23 @@ index 0b4980074c..197d503eae 100644
#endif
int
-@@ -214,4 +214,4 @@ netname2host (const char netname[MAXNETNAMELEN + 1], char *hostname,
+@@ -215,4 +215,4 @@
return 1;
}
-libc_hidden_nolink (netname2host, GLIBC_2_1)
+libc_hidden_nolink_sunrpc (netname2host, GLIBC_2_1)
-diff --git a/sunrpc/pm_getmaps.c b/sunrpc/pm_getmaps.c
-index 6b61d324f9..6f7ad10ef6 100644
--- a/sunrpc/pm_getmaps.c
+++ b/sunrpc/pm_getmaps.c
-@@ -84,4 +84,4 @@ pmap_getmaps (struct sockaddr_in *address)
+@@ -84,4 +84,4 @@
address->sin_port = 0;
return head;
}
-libc_hidden_nolink (pmap_getmaps, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (pmap_getmaps, GLIBC_2_0)
-diff --git a/sunrpc/pm_getport.c b/sunrpc/pm_getport.c
-index 58974a5661..f10f87250d 100644
--- a/sunrpc/pm_getport.c
+++ b/sunrpc/pm_getport.c
-@@ -142,7 +142,7 @@ __libc_rpc_getport (address, program, version, protocol, timeout_sec,
+@@ -142,7 +142,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (__libc_rpc_getport)
#else
@@ -684,17 +689,15 @@ index 58974a5661..f10f87250d 100644
#endif
-@@ -160,4 +160,4 @@ pmap_getport (address, program, version, protocol)
+@@ -160,4 +160,4 @@
{
return __libc_rpc_getport (address, program, version, protocol, 5, 60);
}
-libc_hidden_nolink (pmap_getport, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (pmap_getport, GLIBC_2_0)
-diff --git a/sunrpc/pmap_clnt.c b/sunrpc/pmap_clnt.c
-index 36479f0e5c..5d7d185766 100644
--- a/sunrpc/pmap_clnt.c
+++ b/sunrpc/pmap_clnt.c
-@@ -131,7 +131,7 @@ pmap_set (u_long program, u_long version, int protocol, u_short port)
+@@ -131,7 +131,7 @@
/* (void)close(socket); CLNT_DESTROY closes it */
return rslt;
}
@@ -703,37 +706,31 @@ index 36479f0e5c..5d7d185766 100644
/*
* Remove the mapping between program,version and port.
-@@ -162,4 +162,4 @@ pmap_unset (u_long program, u_long version)
+@@ -162,4 +162,4 @@
/* (void)close(socket); CLNT_DESTROY already closed it */
return rslt;
}
-libc_hidden_nolink (pmap_unset, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (pmap_unset, GLIBC_2_0)
-diff --git a/sunrpc/pmap_prot.c b/sunrpc/pmap_prot.c
-index 5a2e052728..8df41dc5f2 100644
--- a/sunrpc/pmap_prot.c
+++ b/sunrpc/pmap_prot.c
-@@ -49,4 +49,4 @@ xdr_pmap (xdrs, regs)
+@@ -49,4 +49,4 @@
return xdr_u_long (xdrs, &regs->pm_port);
return FALSE;
}
-libc_hidden_nolink (xdr_pmap, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_pmap, GLIBC_2_0)
-diff --git a/sunrpc/pmap_prot2.c b/sunrpc/pmap_prot2.c
-index 3213898ce8..57b0800178 100644
--- a/sunrpc/pmap_prot2.c
+++ b/sunrpc/pmap_prot2.c
-@@ -110,4 +110,4 @@ xdr_pmaplist (xdrs, rp)
+@@ -110,4 +110,4 @@
rp = freeing ? &next : &((*rp)->pml_next);
}
}
-libc_hidden_nolink (xdr_pmaplist, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_pmaplist, GLIBC_2_0)
-diff --git a/sunrpc/pmap_rmt.c b/sunrpc/pmap_rmt.c
-index 16f322773e..fd8de85589 100644
--- a/sunrpc/pmap_rmt.c
+++ b/sunrpc/pmap_rmt.c
-@@ -104,7 +104,7 @@ pmap_rmtcall (addr, prog, vers, proc, xdrargs, argsp, xdrres, resp, tout, port_p
+@@ -104,7 +104,7 @@
addr->sin_port = 0;
return stat;
}
@@ -742,7 +739,7 @@ index 16f322773e..fd8de85589 100644
/*
-@@ -137,7 +137,7 @@ xdr_rmtcall_args (XDR *xdrs, struct rmtcallargs *cap)
+@@ -137,7 +137,7 @@
}
return FALSE;
}
@@ -751,7 +748,7 @@ index 16f322773e..fd8de85589 100644
/*
* XDR remote call results
-@@ -160,7 +160,7 @@ xdr_rmtcallres (xdrs, crp)
+@@ -160,7 +160,7 @@
}
return FALSE;
}
@@ -760,17 +757,15 @@ index 16f322773e..fd8de85589 100644
/*
-@@ -388,4 +388,4 @@ done_broad:
+@@ -388,4 +388,4 @@
AUTH_DESTROY (unix_auth);
return stat;
}
-libc_hidden_nolink (clnt_broadcast, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (clnt_broadcast, GLIBC_2_0)
-diff --git a/sunrpc/publickey.c b/sunrpc/publickey.c
-index 4d0b09874c..089b544953 100644
--- a/sunrpc/publickey.c
+++ b/sunrpc/publickey.c
-@@ -75,7 +75,7 @@ getpublickey (const char *name, char *key)
+@@ -76,7 +76,7 @@
return status == NSS_STATUS_SUCCESS;
}
@@ -779,24 +774,20 @@ index 4d0b09874c..089b544953 100644
int
-@@ -118,4 +118,4 @@ getsecretkey (const char *name, char *key, const char *passwd)
+@@ -119,4 +119,4 @@
return status == NSS_STATUS_SUCCESS;
}
-libc_hidden_nolink (getsecretkey, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (getsecretkey, GLIBC_2_0)
-diff --git a/sunrpc/rpc_cmsg.c b/sunrpc/rpc_cmsg.c
-index ed70104b68..62d95fcc83 100644
--- a/sunrpc/rpc_cmsg.c
+++ b/sunrpc/rpc_cmsg.c
-@@ -194,4 +194,4 @@ xdr_callmsg (XDR *xdrs, struct rpc_msg *cmsg)
+@@ -194,4 +194,4 @@
return xdr_opaque_auth (xdrs, &(cmsg->rm_call.cb_verf));
return FALSE;
}
-libc_hidden_nolink (xdr_callmsg, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_callmsg, GLIBC_2_0)
-diff --git a/sunrpc/rpc_common.c b/sunrpc/rpc_common.c
-index 44b4b38f4d..710191163c 100644
--- a/sunrpc/rpc_common.c
+++ b/sunrpc/rpc_common.c
@@ -45,7 +45,7 @@
@@ -808,21 +799,17 @@ index 44b4b38f4d..710191163c 100644
fd_set svc_fdset;
struct rpc_createerr rpc_createerr;
struct pollfd *svc_pollfd;
-diff --git a/sunrpc/rpc_dtable.c b/sunrpc/rpc_dtable.c
-index 9bee215496..81ddf8f55a 100644
--- a/sunrpc/rpc_dtable.c
+++ b/sunrpc/rpc_dtable.c
-@@ -46,4 +46,4 @@ _rpc_dtablesize (void)
+@@ -46,4 +46,4 @@
return size;
}
-libc_hidden_nolink (_rpc_dtablesize, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (_rpc_dtablesize, GLIBC_2_0)
-diff --git a/sunrpc/rpc_prot.c b/sunrpc/rpc_prot.c
-index 9a23cc1b02..dc24f3673b 100644
--- a/sunrpc/rpc_prot.c
+++ b/sunrpc/rpc_prot.c
-@@ -57,7 +57,7 @@ xdr_opaque_auth (XDR *xdrs, struct opaque_auth *ap)
+@@ -57,7 +57,7 @@
&ap->oa_length, MAX_AUTH_BYTES);
return FALSE;
}
@@ -831,7 +818,7 @@ index 9a23cc1b02..dc24f3673b 100644
/*
* XDR a DES block
-@@ -67,7 +67,7 @@ xdr_des_block (XDR *xdrs, des_block *blkp)
+@@ -67,7 +67,7 @@
{
return xdr_opaque (xdrs, (caddr_t) blkp, sizeof (des_block));
}
@@ -840,7 +827,7 @@ index 9a23cc1b02..dc24f3673b 100644
/* * * * * * * * * * * * * * XDR RPC MESSAGE * * * * * * * * * * * * * * * */
-@@ -95,7 +95,7 @@ xdr_accepted_reply (XDR *xdrs, struct accepted_reply *ar)
+@@ -95,7 +95,7 @@
}
return TRUE; /* TRUE => open ended set of problems */
}
@@ -849,7 +836,7 @@ index 9a23cc1b02..dc24f3673b 100644
/*
* XDR the MSG_DENIED part of a reply message union
-@@ -118,7 +118,7 @@ xdr_rejected_reply (XDR *xdrs, struct rejected_reply *rr)
+@@ -118,7 +118,7 @@
}
return FALSE;
}
@@ -858,7 +845,7 @@ index 9a23cc1b02..dc24f3673b 100644
static const struct xdr_discrim reply_dscrm[3] =
{
-@@ -142,7 +142,7 @@ xdr_replymsg (xdrs, rmsg)
+@@ -142,7 +142,7 @@
NULL_xdrproc_t);
return FALSE;
}
@@ -867,7 +854,7 @@ index 9a23cc1b02..dc24f3673b 100644
/*
-@@ -167,7 +167,7 @@ xdr_callhdr (xdrs, cmsg)
+@@ -167,7 +167,7 @@
return xdr_u_long (xdrs, &(cmsg->rm_call.cb_vers));
return FALSE;
}
@@ -876,17 +863,15 @@ index 9a23cc1b02..dc24f3673b 100644
/* ************************** Client utility routine ************* */
-@@ -277,4 +277,4 @@ _seterr_reply (struct rpc_msg *msg,
+@@ -277,4 +277,4 @@
break;
}
}
-libc_hidden_nolink (_seterr_reply, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (_seterr_reply, GLIBC_2_0)
-diff --git a/sunrpc/rpc_thread.c b/sunrpc/rpc_thread.c
-index ac4c18fcee..94d9f1fd80 100644
--- a/sunrpc/rpc_thread.c
+++ b/sunrpc/rpc_thread.c
-@@ -97,7 +97,7 @@ __rpc_thread_svc_fdset (void)
+@@ -97,7 +97,7 @@
return &svc_fdset;
return &tvp->svc_fdset_s;
}
@@ -895,7 +880,7 @@ index ac4c18fcee..94d9f1fd80 100644
struct rpc_createerr *
__rpc_thread_createerr (void)
-@@ -109,7 +109,7 @@ __rpc_thread_createerr (void)
+@@ -109,7 +109,7 @@
return &rpc_createerr;
return &tvp->rpc_createerr_s;
}
@@ -904,7 +889,7 @@ index ac4c18fcee..94d9f1fd80 100644
struct pollfd **
__rpc_thread_svc_pollfd (void)
-@@ -124,7 +124,7 @@ __rpc_thread_svc_pollfd (void)
+@@ -124,7 +124,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (__rpc_thread_svc_pollfd)
#else
@@ -913,7 +898,7 @@ index ac4c18fcee..94d9f1fd80 100644
#endif
int *
-@@ -140,7 +140,7 @@ __rpc_thread_svc_max_pollfd (void)
+@@ -140,7 +140,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (__rpc_thread_svc_max_pollfd)
#else
@@ -922,21 +907,17 @@ index ac4c18fcee..94d9f1fd80 100644
#endif
#endif /* _RPC_THREAD_SAFE_ */
-diff --git a/sunrpc/rtime.c b/sunrpc/rtime.c
-index 8506df554c..bcb280b48f 100644
--- a/sunrpc/rtime.c
+++ b/sunrpc/rtime.c
-@@ -140,4 +140,4 @@ rtime (struct sockaddr_in *addrp, struct rpc_timeval *timep,
+@@ -140,4 +140,4 @@
timep->tv_usec = 0;
return 0;
}
-libc_hidden_nolink (rtime, GLIBC_2_1)
+libc_hidden_nolink_sunrpc (rtime, GLIBC_2_1)
-diff --git a/sunrpc/svc.c b/sunrpc/svc.c
-index e1f4a322e8..103770a42c 100644
--- a/sunrpc/svc.c
+++ b/sunrpc/svc.c
-@@ -115,7 +115,7 @@ xprt_register (SVCXPRT *xprt)
+@@ -115,7 +115,7 @@
POLLRDNORM | POLLRDBAND);
}
}
@@ -945,7 +926,7 @@ index e1f4a322e8..103770a42c 100644
/* De-activate a transport handle. */
void
-@@ -139,7 +139,7 @@ xprt_unregister (SVCXPRT *xprt)
+@@ -139,7 +139,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xprt_unregister)
#else
@@ -954,7 +935,7 @@ index e1f4a322e8..103770a42c 100644
#endif
-@@ -218,7 +218,7 @@ pmap_it:
+@@ -218,7 +218,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svc_register)
#else
@@ -963,7 +944,7 @@ index e1f4a322e8..103770a42c 100644
#endif
/* Remove a service program from the callout list. */
-@@ -242,7 +242,7 @@ svc_unregister (rpcprog_t prog, rpcvers_t vers)
+@@ -242,7 +242,7 @@
if (! svc_is_mapped (prog, vers))
pmap_unset (prog, vers);
}
@@ -972,7 +953,7 @@ index e1f4a322e8..103770a42c 100644
/* ******************* REPLY GENERATION ROUTINES ************ */
-@@ -264,7 +264,7 @@ svc_sendreply (register SVCXPRT *xprt, xdrproc_t xdr_results,
+@@ -264,7 +264,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svc_sendreply)
#else
@@ -981,7 +962,7 @@ index e1f4a322e8..103770a42c 100644
#endif
/* No procedure error reply */
-@@ -282,7 +282,7 @@ svcerr_noproc (register SVCXPRT *xprt)
+@@ -282,7 +282,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svcerr_noproc)
#else
@@ -990,7 +971,7 @@ index e1f4a322e8..103770a42c 100644
#endif
/* Can't decode args error reply */
-@@ -300,7 +300,7 @@ svcerr_decode (register SVCXPRT *xprt)
+@@ -300,7 +300,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svcerr_decode)
#else
@@ -999,7 +980,7 @@ index e1f4a322e8..103770a42c 100644
#endif
/* Some system error */
-@@ -318,7 +318,7 @@ svcerr_systemerr (register SVCXPRT *xprt)
+@@ -318,7 +318,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svcerr_systemerr)
#else
@@ -1008,7 +989,7 @@ index e1f4a322e8..103770a42c 100644
#endif
/* Authentication error reply */
-@@ -333,7 +333,7 @@ svcerr_auth (SVCXPRT *xprt, enum auth_stat why)
+@@ -333,7 +333,7 @@
rply.rjcted_rply.rj_why = why;
SVC_REPLY (xprt, &rply);
}
@@ -1017,7 +998,7 @@ index e1f4a322e8..103770a42c 100644
/* Auth too weak error reply */
void
-@@ -341,7 +341,7 @@ svcerr_weakauth (SVCXPRT *xprt)
+@@ -341,7 +341,7 @@
{
svcerr_auth (xprt, AUTH_TOOWEAK);
}
@@ -1026,7 +1007,7 @@ index e1f4a322e8..103770a42c 100644
/* Program unavailable error reply */
void
-@@ -355,7 +355,7 @@ svcerr_noprog (register SVCXPRT *xprt)
+@@ -355,7 +355,7 @@
rply.acpted_rply.ar_stat = PROG_UNAVAIL;
SVC_REPLY (xprt, &rply);
}
@@ -1035,7 +1016,7 @@ index e1f4a322e8..103770a42c 100644
/* Program version mismatch error reply */
void
-@@ -372,7 +372,7 @@ svcerr_progvers (register SVCXPRT *xprt, rpcvers_t low_vers,
+@@ -372,7 +372,7 @@
rply.acpted_rply.ar_vers.high = high_vers;
SVC_REPLY (xprt, &rply);
}
@@ -1044,7 +1025,7 @@ index e1f4a322e8..103770a42c 100644
/* ******************* SERVER INPUT STUFF ******************* */
-@@ -401,7 +401,7 @@ svc_getreq (int rdfds)
+@@ -401,7 +401,7 @@
readfds.fds_bits[0] = rdfds;
svc_getreqset (&readfds);
}
@@ -1053,7 +1034,7 @@ index e1f4a322e8..103770a42c 100644
void
svc_getreqset (fd_set *readfds)
-@@ -420,7 +420,7 @@ svc_getreqset (fd_set *readfds)
+@@ -420,7 +420,7 @@
for (mask = *maskp++; (bit = ffsl (mask)); mask ^= (1L << (bit - 1)))
svc_getreq_common (sock + bit - 1);
}
@@ -1062,7 +1043,7 @@ index e1f4a322e8..103770a42c 100644
void
svc_getreq_poll (struct pollfd *pfdp, int pollretval)
-@@ -449,7 +449,7 @@ svc_getreq_poll (struct pollfd *pfdp, int pollretval)
+@@ -449,7 +449,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svc_getreq_poll)
#else
@@ -1071,7 +1052,7 @@ index e1f4a322e8..103770a42c 100644
#endif
-@@ -542,7 +542,7 @@ svc_getreq_common (const int fd)
+@@ -542,7 +542,7 @@
}
while (stat == XPRT_MOREREQS);
}
@@ -1080,11 +1061,9 @@ index e1f4a322e8..103770a42c 100644
#ifdef _RPC_THREAD_SAFE_
-diff --git a/sunrpc/svc_auth.c b/sunrpc/svc_auth.c
-index facbb13982..f33bda2f20 100644
--- a/sunrpc/svc_auth.c
+++ b/sunrpc/svc_auth.c
-@@ -105,7 +105,7 @@ _authenticate (register struct svc_req *rqst, struct rpc_msg *msg)
+@@ -105,7 +105,7 @@
return AUTH_REJECTEDCRED;
}
@@ -1093,11 +1072,9 @@ index facbb13982..f33bda2f20 100644
static enum auth_stat
_svcauth_null (struct svc_req *rqst, struct rpc_msg *msg)
-diff --git a/sunrpc/svc_raw.c b/sunrpc/svc_raw.c
-index 90f5d96e63..7d885574af 100644
--- a/sunrpc/svc_raw.c
+++ b/sunrpc/svc_raw.c
-@@ -88,7 +88,7 @@ svcraw_create (void)
+@@ -88,7 +88,7 @@
xdrmem_create (&srp->xdr_stream, srp->_raw_buf, UDPMSGSIZE, XDR_FREE);
return &srp->server;
}
@@ -1106,11 +1083,9 @@ index 90f5d96e63..7d885574af 100644
static enum xprt_stat
svcraw_stat (SVCXPRT *xprt)
-diff --git a/sunrpc/svc_run.c b/sunrpc/svc_run.c
-index 09f40dd188..90dfc94056 100644
--- a/sunrpc/svc_run.c
+++ b/sunrpc/svc_run.c
-@@ -46,7 +46,7 @@ svc_exit (void)
+@@ -46,7 +46,7 @@
svc_pollfd = NULL;
svc_max_pollfd = 0;
}
@@ -1119,18 +1094,16 @@ index 09f40dd188..90dfc94056 100644
void
svc_run (void)
-@@ -104,5 +104,5 @@ svc_run (void)
+@@ -104,5 +104,5 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svc_run)
#else
-libc_hidden_nolink (svc_run, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (svc_run, GLIBC_2_0)
#endif
-diff --git a/sunrpc/svc_tcp.c b/sunrpc/svc_tcp.c
-index e0515322a5..eb615494d8 100644
--- a/sunrpc/svc_tcp.c
+++ b/sunrpc/svc_tcp.c
-@@ -187,7 +187,7 @@ svctcp_create (int sock, u_int sendsize, u_int recvsize)
+@@ -187,7 +187,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svctcp_create)
#else
@@ -1139,7 +1112,7 @@ index e0515322a5..eb615494d8 100644
#endif
/*
-@@ -199,7 +199,7 @@ svcfd_create (int fd, u_int sendsize, u_int recvsize)
+@@ -199,7 +199,7 @@
{
return makefd_xprt (fd, sendsize, recvsize);
}
@@ -1148,11 +1121,9 @@ index e0515322a5..eb615494d8 100644
static SVCXPRT *
internal_function
-diff --git a/sunrpc/svc_udp.c b/sunrpc/svc_udp.c
-index 04c8407e64..6c4d75a814 100644
--- a/sunrpc/svc_udp.c
+++ b/sunrpc/svc_udp.c
-@@ -184,7 +184,7 @@ svcudp_create: xp_pad is too small for IP_PKTINFO\n"));
+@@ -184,7 +184,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svcudp_bufcreate)
#else
@@ -1161,7 +1132,7 @@ index 04c8407e64..6c4d75a814 100644
#endif
SVCXPRT *
-@@ -196,7 +196,7 @@ svcudp_create (sock)
+@@ -196,7 +196,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (svcudp_create)
#else
@@ -1170,7 +1141,7 @@ index 04c8407e64..6c4d75a814 100644
#endif
static enum xprt_stat
-@@ -500,7 +500,7 @@ svcudp_enablecache (SVCXPRT *transp, u_long size)
+@@ -500,7 +500,7 @@
su->su_cache = (char *) uc;
return 1;
}
@@ -1179,11 +1150,9 @@ index 04c8407e64..6c4d75a814 100644
/*
-diff --git a/sunrpc/svc_unix.c b/sunrpc/svc_unix.c
-index 2b02682e72..94507b2403 100644
--- a/sunrpc/svc_unix.c
+++ b/sunrpc/svc_unix.c
-@@ -184,7 +184,7 @@ svcunix_create (int sock, u_int sendsize, u_int recvsize, char *path)
+@@ -184,7 +184,7 @@
xprt_register (xprt);
return xprt;
}
@@ -1192,7 +1161,7 @@ index 2b02682e72..94507b2403 100644
/*
* Like svunix_create(), except the routine takes any *open* UNIX file
-@@ -195,7 +195,7 @@ svcunixfd_create (int fd, u_int sendsize, u_int recvsize)
+@@ -195,7 +195,7 @@
{
return makefd_xprt (fd, sendsize, recvsize);
}
@@ -1201,11 +1170,9 @@ index 2b02682e72..94507b2403 100644
static SVCXPRT *
internal_function
-diff --git a/sunrpc/svcauth_des.c b/sunrpc/svcauth_des.c
-index b9656e25da..9609734960 100644
--- a/sunrpc/svcauth_des.c
+++ b/sunrpc/svcauth_des.c
-@@ -583,7 +583,7 @@ authdes_getucred (const struct authdes_cred *adc, uid_t * uid, gid_t * gid,
+@@ -583,7 +583,7 @@
groups[i] = cred->groups[i];
return 1;
}
@@ -1214,11 +1181,9 @@ index b9656e25da..9609734960 100644
static void
internal_function
-diff --git a/sunrpc/xcrypt.c b/sunrpc/xcrypt.c
-index 8b7642b503..2e53f2d9e9 100644
--- a/sunrpc/xcrypt.c
+++ b/sunrpc/xcrypt.c
-@@ -127,7 +127,7 @@ xencrypt (char *secret, char *passwd)
+@@ -127,7 +127,7 @@
free (buf);
return 1;
}
@@ -1227,7 +1192,7 @@ index 8b7642b503..2e53f2d9e9 100644
/*
* Decrypt secret key using passwd
-@@ -163,7 +163,7 @@ xdecrypt (char *secret, char *passwd)
+@@ -163,7 +163,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdecrypt)
#else
@@ -1236,11 +1201,9 @@ index 8b7642b503..2e53f2d9e9 100644
#endif
/*
-diff --git a/sunrpc/xdr.c b/sunrpc/xdr.c
-index 4dd82ff044..7eac2d40f0 100644
--- a/sunrpc/xdr.c
+++ b/sunrpc/xdr.c
-@@ -72,7 +72,7 @@ xdr_free (xdrproc_t proc, char *objp)
+@@ -72,7 +72,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_free)
#else
@@ -1249,7 +1212,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -86,7 +86,7 @@ xdr_void (void)
+@@ -86,7 +86,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_void)
#else
@@ -1258,7 +1221,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -126,7 +126,7 @@ xdr_int (XDR *xdrs, int *ip)
+@@ -126,7 +126,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_int)
#else
@@ -1267,7 +1230,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -165,7 +165,7 @@ xdr_u_int (XDR *xdrs, u_int *up)
+@@ -165,7 +165,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_u_int)
#else
@@ -1276,7 +1239,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -193,7 +193,7 @@ xdr_long (XDR *xdrs, long *lp)
+@@ -193,7 +193,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_long)
#else
@@ -1285,7 +1248,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -232,7 +232,7 @@ xdr_u_long (XDR *xdrs, u_long *ulp)
+@@ -232,7 +232,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_u_long)
#else
@@ -1294,7 +1257,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -268,7 +268,7 @@ xdr_hyper (XDR *xdrs, quad_t *llp)
+@@ -268,7 +268,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_hyper)
#else
@@ -1303,7 +1266,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -304,7 +304,7 @@ xdr_u_hyper (XDR *xdrs, u_quad_t *ullp)
+@@ -304,7 +304,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_u_hyper)
#else
@@ -1312,7 +1275,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
bool_t
-@@ -315,7 +315,7 @@ xdr_longlong_t (XDR *xdrs, quad_t *llp)
+@@ -315,7 +315,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_longlong_t)
#else
@@ -1321,7 +1284,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
bool_t
-@@ -326,7 +326,7 @@ xdr_u_longlong_t (XDR *xdrs, u_quad_t *ullp)
+@@ -326,7 +326,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_u_longlong_t)
#else
@@ -1330,7 +1293,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -359,7 +359,7 @@ xdr_short (XDR *xdrs, short *sp)
+@@ -359,7 +359,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_short)
#else
@@ -1339,7 +1302,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -392,7 +392,7 @@ xdr_u_short (XDR *xdrs, u_short *usp)
+@@ -392,7 +392,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_u_short)
#else
@@ -1348,7 +1311,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
-@@ -415,7 +415,7 @@ xdr_char (XDR *xdrs, char *cp)
+@@ -415,7 +415,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_char)
#else
@@ -1357,7 +1320,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -437,7 +437,7 @@ xdr_u_char (XDR *xdrs, u_char *cp)
+@@ -437,7 +437,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_u_char)
#else
@@ -1366,7 +1329,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -470,7 +470,7 @@ xdr_bool (XDR *xdrs, bool_t *bp)
+@@ -470,7 +470,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_bool)
#else
@@ -1375,7 +1338,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -525,7 +525,7 @@ xdr_enum (XDR *xdrs, enum_t *ep)
+@@ -525,7 +525,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_enum)
#else
@@ -1384,7 +1347,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -580,7 +580,7 @@ xdr_opaque (XDR *xdrs, caddr_t cp, u_int cnt)
+@@ -580,7 +580,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_opaque)
#else
@@ -1393,7 +1356,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -648,7 +648,7 @@ xdr_bytes (xdrs, cpp, sizep, maxsize)
+@@ -648,7 +648,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_bytes)
#else
@@ -1402,7 +1365,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -665,7 +665,7 @@ xdr_netobj (xdrs, np)
+@@ -665,7 +665,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_netobj)
#else
@@ -1411,7 +1374,7 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -714,7 +714,7 @@ xdr_union (xdrs, dscmp, unp, choices, dfault)
+@@ -714,7 +714,7 @@
return ((dfault == NULL_xdrproc_t) ? FALSE :
(*dfault) (xdrs, unp, LASTUNSIGNED));
}
@@ -1420,7 +1383,7 @@ index 4dd82ff044..7eac2d40f0 100644
/*
-@@ -806,7 +806,7 @@ xdr_string (xdrs, cpp, maxsize)
+@@ -806,7 +806,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_string)
#else
@@ -1429,18 +1392,16 @@ index 4dd82ff044..7eac2d40f0 100644
#endif
/*
-@@ -827,5 +827,5 @@ xdr_wrapstring (xdrs, cpp)
+@@ -827,5 +827,5 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_wrapstring)
#else
-libc_hidden_nolink (xdr_wrapstring, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_wrapstring, GLIBC_2_0)
#endif
-diff --git a/sunrpc/xdr_array.c b/sunrpc/xdr_array.c
-index b832078342..a634861278 100644
--- a/sunrpc/xdr_array.c
+++ b/sunrpc/xdr_array.c
-@@ -127,7 +127,7 @@ xdr_array (xdrs, addrp, sizep, maxsize, elsize, elproc)
+@@ -127,7 +127,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_array)
#else
@@ -1449,17 +1410,15 @@ index b832078342..a634861278 100644
#endif
/*
-@@ -162,4 +162,4 @@ xdr_vector (xdrs, basep, nelem, elemsize, xdr_elem)
+@@ -162,4 +162,4 @@
}
return TRUE;
}
-libc_hidden_nolink (xdr_vector, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_vector, GLIBC_2_0)
-diff --git a/sunrpc/xdr_float.c b/sunrpc/xdr_float.c
-index 1a9c260617..78e8f3bd2d 100644
--- a/sunrpc/xdr_float.c
+++ b/sunrpc/xdr_float.c
-@@ -158,7 +158,7 @@ xdr_float(xdrs, fp)
+@@ -158,7 +158,7 @@
}
return (FALSE);
}
@@ -1468,17 +1427,15 @@ index 1a9c260617..78e8f3bd2d 100644
/*
* This routine works on Suns (Sky / 68000's) and Vaxen.
-@@ -300,4 +300,4 @@ xdr_double(xdrs, dp)
+@@ -300,4 +300,4 @@
}
return (FALSE);
}
-libc_hidden_nolink (xdr_double, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_double, GLIBC_2_0)
-diff --git a/sunrpc/xdr_intXX_t.c b/sunrpc/xdr_intXX_t.c
-index fe06f45df3..02a0c09b5b 100644
--- a/sunrpc/xdr_intXX_t.c
+++ b/sunrpc/xdr_intXX_t.c
-@@ -46,14 +46,14 @@ xdr_int64_t (XDR *xdrs, int64_t *ip)
+@@ -47,14 +47,14 @@
return FALSE;
}
}
@@ -1495,7 +1452,7 @@ index fe06f45df3..02a0c09b5b 100644
/* XDR 64bit unsigned integers */
bool_t
-@@ -82,14 +82,14 @@ xdr_uint64_t (XDR *xdrs, uint64_t *uip)
+@@ -83,14 +83,14 @@
return FALSE;
}
}
@@ -1512,7 +1469,7 @@ index fe06f45df3..02a0c09b5b 100644
/* XDR 32bit integers */
bool_t
-@@ -107,7 +107,7 @@ xdr_int32_t (XDR *xdrs, int32_t *lp)
+@@ -108,7 +108,7 @@
return FALSE;
}
}
@@ -1521,7 +1478,7 @@ index fe06f45df3..02a0c09b5b 100644
/* XDR 32bit unsigned integers */
bool_t
-@@ -128,7 +128,7 @@ xdr_uint32_t (XDR *xdrs, uint32_t *ulp)
+@@ -129,7 +129,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_uint32_t)
#else
@@ -1530,7 +1487,7 @@ index fe06f45df3..02a0c09b5b 100644
#endif
/* XDR 16bit integers */
-@@ -153,7 +153,7 @@ xdr_int16_t (XDR *xdrs, int16_t *ip)
+@@ -154,7 +154,7 @@
return FALSE;
}
}
@@ -1539,7 +1496,7 @@ index fe06f45df3..02a0c09b5b 100644
/* XDR 16bit unsigned integers */
bool_t
-@@ -177,7 +177,7 @@ xdr_uint16_t (XDR *xdrs, uint16_t *uip)
+@@ -178,7 +178,7 @@
return FALSE;
}
}
@@ -1548,7 +1505,7 @@ index fe06f45df3..02a0c09b5b 100644
/* XDR 8bit integers */
bool_t
-@@ -201,7 +201,7 @@ xdr_int8_t (XDR *xdrs, int8_t *ip)
+@@ -202,7 +202,7 @@
return FALSE;
}
}
@@ -1557,17 +1514,15 @@ index fe06f45df3..02a0c09b5b 100644
/* XDR 8bit unsigned integers */
bool_t
-@@ -225,4 +225,4 @@ xdr_uint8_t (XDR *xdrs, uint8_t *uip)
+@@ -226,4 +226,4 @@
return FALSE;
}
}
-libc_hidden_nolink (xdr_uint8_t, GLIBC_2_1)
+libc_hidden_nolink_sunrpc (xdr_uint8_t, GLIBC_2_1)
-diff --git a/sunrpc/xdr_mem.c b/sunrpc/xdr_mem.c
-index 093a718739..ba7661aa54 100644
--- a/sunrpc/xdr_mem.c
+++ b/sunrpc/xdr_mem.c
-@@ -81,7 +81,7 @@ xdrmem_create (XDR *xdrs, const caddr_t addr, u_int size, enum xdr_op op)
+@@ -81,7 +81,7 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdrmem_create)
#else
@@ -1576,11 +1531,9 @@ index 093a718739..ba7661aa54 100644
#endif
/*
-diff --git a/sunrpc/xdr_rec.c b/sunrpc/xdr_rec.c
-index 556c6c4bc0..f5d6ef2af9 100644
--- a/sunrpc/xdr_rec.c
+++ b/sunrpc/xdr_rec.c
-@@ -189,7 +189,7 @@ xdrrec_create (XDR *xdrs, u_int sendsize,
+@@ -189,7 +189,7 @@
rstrm->fbtbc = 0;
rstrm->last_frag = TRUE;
}
@@ -1589,7 +1542,7 @@ index 556c6c4bc0..f5d6ef2af9 100644
/*
-@@ -477,7 +477,7 @@ xdrrec_skiprecord (XDR *xdrs)
+@@ -477,7 +477,7 @@
rstrm->last_frag = FALSE;
return TRUE;
}
@@ -1598,7 +1551,7 @@ index 556c6c4bc0..f5d6ef2af9 100644
/*
* Lookahead function.
-@@ -501,7 +501,7 @@ xdrrec_eof (XDR *xdrs)
+@@ -501,7 +501,7 @@
return TRUE;
return FALSE;
}
@@ -1607,7 +1560,7 @@ index 556c6c4bc0..f5d6ef2af9 100644
/*
* The client must tell the package when an end-of-record has occurred.
-@@ -528,7 +528,7 @@ xdrrec_endofrecord (XDR *xdrs, bool_t sendnow)
+@@ -528,7 +528,7 @@
rstrm->out_finger += BYTES_PER_XDR_UNIT;
return TRUE;
}
@@ -1616,11 +1569,9 @@ index 556c6c4bc0..f5d6ef2af9 100644
/*
-diff --git a/sunrpc/xdr_ref.c b/sunrpc/xdr_ref.c
-index 7510bed873..8fb4584a75 100644
--- a/sunrpc/xdr_ref.c
+++ b/sunrpc/xdr_ref.c
-@@ -90,7 +90,7 @@ xdr_reference (xdrs, pp, size, proc)
+@@ -90,7 +90,7 @@
}
return stat;
}
@@ -1629,29 +1580,25 @@ index 7510bed873..8fb4584a75 100644
/*
-@@ -137,5 +137,5 @@ xdr_pointer (xdrs, objpp, obj_size, xdr_obj)
+@@ -137,5 +137,5 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_pointer)
#else
-libc_hidden_nolink (xdr_pointer, GLIBC_2_0)
+libc_hidden_nolink_sunrpc (xdr_pointer, GLIBC_2_0)
#endif
-diff --git a/sunrpc/xdr_sizeof.c b/sunrpc/xdr_sizeof.c
-index 0119486c3d..56e870a455 100644
--- a/sunrpc/xdr_sizeof.c
+++ b/sunrpc/xdr_sizeof.c
-@@ -161,5 +161,5 @@ xdr_sizeof (xdrproc_t func, void *data)
+@@ -161,5 +161,5 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdr_sizeof)
#else
-libc_hidden_nolink (xdr_sizeof, GLIBC_2_1)
+libc_hidden_nolink_sunrpc (xdr_sizeof, GLIBC_2_1)
#endif
-diff --git a/sunrpc/xdr_stdio.c b/sunrpc/xdr_stdio.c
-index d9866063f9..667515e0a6 100644
--- a/sunrpc/xdr_stdio.c
+++ b/sunrpc/xdr_stdio.c
-@@ -191,5 +191,5 @@ xdrstdio_putint32 (XDR *xdrs, const int32_t *ip)
+@@ -191,5 +191,5 @@
#ifdef EXPORT_RPC_SYMBOLS
libc_hidden_def (xdrstdio_create)
#else
diff --git a/packages/glibc/2.15/0043-obstack-common.patch b/packages/glibc/2.15/0043-obstack-common.patch
new file mode 100644
index 0000000..1993be2
--- /dev/null
+++ b/packages/glibc/2.15/0043-obstack-common.patch
@@ -0,0 +1,32 @@
+commit 39b1f6172a2f9ddc74a8f82d6e84dd13b22dbaf2
+Author: Peter Collingbourne <pcc@google.com>
+Date: Wed May 15 20:28:08 2013 +0200
+
+ Move _obstack_compat out of common
+
+ it is impossible to create an alias of a common symbol (as
+ compat_symbol does), because common symbols do not have a section or
+ an offset until linked. GNU as tolerates aliases of common symbols by
+ simply creating another common symbol, but other assemblers (notably
+ LLVM's integrated assembler) are less tolerant.
+
+ 2013-05-15 Peter Collingbourne <pcc@google.com>
+
+ * malloc/obstack.c (_obstack_compat): Add initializer.
+ -
+
+---
+ malloc/obstack.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/malloc/obstack.c
++++ b/malloc/obstack.c
+@@ -117,7 +117,7 @@
+ /* A looong time ago (before 1994, anyway; we're not sure) this global variable
+ was used by non-GNU-C macros to avoid multiple evaluation. The GNU C
+ library still exports it because somebody might use it. */
+-struct obstack *_obstack_compat;
++struct obstack *_obstack_compat = 0;
+ compat_symbol (libc, _obstack_compat, _obstack, GLIBC_2_0);
+ # endif
+ # endif
diff --git a/packages/glibc/2.14.1/999-new-tools.patch b/packages/glibc/2.15/0044-new-tools.patch
index f335a54..5cd3398 100644
--- a/packages/glibc/2.14.1/999-new-tools.patch
+++ b/packages/glibc/2.15/0044-new-tools.patch
@@ -1,7 +1,11 @@
-diff -urpN glibc-2.14.1.orig/configure glibc-2.14.1/configure
---- glibc-2.14.1.orig/configure 2011-10-07 02:48:55.000000000 -0700
-+++ glibc-2.14.1/configure 2017-02-08 00:38:43.765952352 -0800
-@@ -4939,7 +4939,7 @@ $as_echo_n "checking version of $CC... "
+---
+ configure | 8 ++++----
+ configure.in | 8 ++++----
+ 2 files changed, 8 insertions(+), 8 deletions(-)
+
+--- a/configure
++++ b/configure
+@@ -4939,7 +4939,7 @@
ac_prog_version=`$CC -v 2>&1 | sed -n 's/^.*version \([egcygnustpi-]*[0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -10,7 +14,7 @@ diff -urpN glibc-2.14.1.orig/configure glibc-2.14.1/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5002,7 +5002,7 @@ $as_echo_n "checking version of $MAKE...
+@@ -5002,7 +5002,7 @@
ac_prog_version=`$MAKE --version 2>&1 | sed -n 's/^.*GNU Make[^0-9]*\([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -19,7 +23,7 @@ diff -urpN glibc-2.14.1.orig/configure glibc-2.14.1/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5129,7 +5129,7 @@ $as_echo_n "checking version of $MAKEINF
+@@ -5129,7 +5129,7 @@
ac_prog_version=`$MAKEINFO --version 2>&1 | sed -n 's/^.*GNU texinfo.* \([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -28,7 +32,7 @@ diff -urpN glibc-2.14.1.orig/configure glibc-2.14.1/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5189,7 +5189,7 @@ else
+@@ -5189,7 +5189,7 @@
# Found it, now check the version.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking version of $SED" >&5
$as_echo_n "checking version of $SED... " >&6; }
@@ -37,10 +41,9 @@ diff -urpN glibc-2.14.1.orig/configure glibc-2.14.1/configure
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
3.0[2-9]*|3.[1-9]*|[4-9]*)
-diff -urpN glibc-2.14.1.orig/configure.in glibc-2.14.1/configure.in
---- glibc-2.14.1.orig/configure.in 2011-10-07 02:48:55.000000000 -0700
-+++ glibc-2.14.1/configure.in 2017-02-08 00:30:13.660439376 -0800
-@@ -1026,11 +1026,11 @@ fi
+--- a/configure.in
++++ b/configure.in
+@@ -1011,11 +1011,11 @@
# These programs are version sensitive.
AC_CHECK_TOOL_PREFIX
AC_CHECK_PROG_VER(CC, ${ac_tool_prefix}gcc ${ac_tool_prefix}cc, -v,
@@ -54,7 +57,7 @@ diff -urpN glibc-2.14.1.orig/configure.in glibc-2.14.1/configure.in
AC_CHECK_PROG_VER(MSGFMT, gnumsgfmt gmsgfmt msgfmt, --version,
[GNU gettext.* \([0-9]*\.[0-9.]*\)],
-@@ -1038,10 +1038,10 @@ AC_CHECK_PROG_VER(MSGFMT, gnumsgfmt gmsg
+@@ -1023,10 +1023,10 @@
MSGFMT=: aux_missing="$aux_missing msgfmt")
AC_CHECK_PROG_VER(MAKEINFO, makeinfo, --version,
[GNU texinfo.* \([0-9][0-9.]*\)],
diff --git a/packages/glibc/2.15/300-macos-cross-rpcgen.patch b/packages/glibc/2.15/300-macos-cross-rpcgen.patch
deleted file mode 100644
index e654644..0000000
--- a/packages/glibc/2.15/300-macos-cross-rpcgen.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-commit ae7080d30c68cfa0c81ce3422dca948f64a94f50
-Author: Jia Liu <proljc@gmail.com>
-Date: Sat Sep 7 00:01:08 2013 +0800
-
- sunrpc/rpc/types.h: fix OS X and FreeBSD build problems
-
- When I build arm-linux-gcc on OS X, I find glibc will get a build error
- in sunrpc/rpc/types.h, so I add __APPLE_CC__ to make OS X build OK.
- For FreeBSD, Add __FreeBSD__ to make it build OK, too.
-
- URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00155.html
- URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00217.html
- URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00240.html
- Signed-off-by: Jia Liu <proljc@gmail.com>
- Signed-off-by: Mike Frysinger <vapier@gentoo.org>
-
-diff --git a/sunrpc/rpc/types.h b/sunrpc/rpc/types.h
-index 3dca5c4..beded52 100644
---- a/sunrpc/rpc/types.h
-+++ b/sunrpc/rpc/types.h
-@@ -69,6 +69,11 @@ typedef unsigned long rpcport_t;
- #include <sys/types.h>
- #endif
-
-+#if defined __APPLE_CC__ || defined __FreeBSD__
-+# define __u_char_defined
-+# define __daddr_t_defined
-+#endif
-+
- #ifndef __u_char_defined
- typedef __u_char u_char;
- typedef __u_short u_short;
diff --git a/packages/glibc/2.15/430-alpha-creat.patch b/packages/glibc/2.15/430-alpha-creat.patch
deleted file mode 100644
index da6ddda..0000000
--- a/packages/glibc/2.15/430-alpha-creat.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-alpha does not have a __NR_creat
-
-http://bugs.gentoo.org/227275
-http://sourceware.org/bugzilla/show_bug.cgi?id=6650
-
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/wordsize-64/creat64.c glibc-2.13/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/wordsize-64/creat64.c 2007-11-10 20:34:26.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/wordsize-64/creat64.c 2009-11-13 00:50:51.000000000 +0100
-@@ -1 +1,5 @@
- /* Defined as alias for the syscall. */
-+#include <sysdep.h>
-+#ifndef __NR_creat
-+#include "../../../../../io/creat64.c"
-+#endif
diff --git a/packages/glibc/2.15/660-debug-readlink_chk-readklinkat_chk.patch b/packages/glibc/2.15/660-debug-readlink_chk-readklinkat_chk.patch
deleted file mode 100644
index a5a7052..0000000
--- a/packages/glibc/2.15/660-debug-readlink_chk-readklinkat_chk.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-diff -dur glibc-cvs-2.9.orig/debug/readlink_chk.c glibc-cvs-2.9/debug/readlink_chk.c
---- glibc-cvs-2.9.orig/debug/readlink_chk.c 2005-03-01 01:41:15.000000000 +0100
-+++ glibc-cvs-2.9/debug/readlink_chk.c 2009-06-01 10:59:37.000000000 +0200
-@@ -25,7 +25,7 @@
-
-
- ssize_t
--__readlink_chk (const char *path, void *buf, size_t len, size_t buflen)
-+__readlink_chk (const char *path, char *buf, size_t len, size_t buflen)
- {
- if (len > buflen)
- __chk_fail ();
-diff -dur glibc-cvs-2.9.orig/debug/readlinkat_chk.c glibc-cvs-2.9/debug/readlinkat_chk.c
---- glibc-cvs-2.9.orig/debug/readlinkat_chk.c 2006-04-24 18:56:12.000000000 +0200
-+++ glibc-cvs-2.9/debug/readlinkat_chk.c 2009-06-01 11:07:26.000000000 +0200
-@@ -21,7 +21,7 @@
-
-
- ssize_t
--__readlinkat_chk (int fd, const char *path, void *buf, size_t len,
-+__readlinkat_chk (int fd, const char *path, char *buf, size_t len,
- size_t buflen)
- {
- if (len > buflen)
diff --git a/packages/glibc/2.15/920-fix-rpc_parse-format.patch b/packages/glibc/2.15/920-fix-rpc_parse-format.patch
deleted file mode 100644
index 37e58da..0000000
--- a/packages/glibc/2.15/920-fix-rpc_parse-format.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-commit 5874510faaf3cbd0bb112aaacab9f225002beed1
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Tue Nov 8 23:44:51 2016 +0000
-
- Fix rpcgen buffer overrun (bug 20790).
-
- Building with GCC 7 produces an error building rpcgen:
-
- rpc_parse.c: In function 'get_prog_declaration':
- rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ~~~~^
- rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
- That buffer overrun is for the case where the .x file declares a
- program with a million arguments. The strcpy two lines above can
- generate a buffer overrun much more simply for a long argument name.
-
- The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
- provides a bound on the buffer size needed, so this patch just changes
- the buffer size to MAXLINESIZE to avoid both possible buffer
- overruns. A testcase is added that rpcgen does not crash with a
- 500-character argument name, where it previously crashed.
-
- It would not at all surprise me if there are many other ways of
- crashing rpcgen with either valid or invalid input; fuzz testing would
- likely find various such bugs, though I don't think they are that
- important to fix (rpcgen is not that likely to be used with untrusted
- .x files as input). (As well as fuzz-findable bugs there are probably
- also issues when various int variables get overflowed on very large
- input.) The test infrastructure for rpcgen-not-crashing tests would
- need extending if tests are to be added for cases where rpcgen should
- produce an error, as opposed to cases where it should succeed.
-
- Tested for x86_64 and x86.
-
- [BZ #20790]
- * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
- to MAXLINESIZE.
- * sunrpc/bug20790.x: New file.
- * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
- variable.
- [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
- [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
-
-diff --git a/sunrpc/rpc_parse.c b/sunrpc/rpc_parse.c
-index 1a1df6d8c2..505a6554cf 100644
---- a/sunrpc/rpc_parse.c
-+++ b/sunrpc/rpc_parse.c
-@@ -521,7 +521,7 @@ static void
- get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
- {
- token tok;
-- char name[10]; /* argument name */
-+ char name[MAXLINESIZE]; /* argument name */
-
- if (dkind == DEF_PROGRAM)
- {
diff --git a/packages/glibc/2.15/940-nis-bogus-conditional.patch b/packages/glibc/2.15/940-nis-bogus-conditional.patch
deleted file mode 100644
index 09b38cf..0000000
--- a/packages/glibc/2.15/940-nis-bogus-conditional.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Wed Dec 21 23:44:01 2016 +0000
-
- Fix nss_nisplus build with mainline GCC (bug 20978).
-
- glibc build with current mainline GCC fails because
- nis/nss_nisplus/nisplus-alias.c contains code
-
- if (name != NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
- }
-
- char buf[strlen (name) + 9 + tablename_len];
-
- producing an error about strlen being called on a pointer that is
- always NULL (and a subsequent use of that pointer with a %s format in
- snprintf).
-
- As Andreas noted, the bogus conditional comes from a 1997 change:
-
- - if (name == NULL || strlen(name) > 8)
- - return NSS_STATUS_NOTFOUND;
- - else
- + if (name != NULL || strlen(name) <= 8)
-
- So the intention is clearly to return an error for NULL name.
-
- This patch duly inverts the sense of the conditional. It fixes the
- build with GCC mainline, and passes usual glibc testsuite testing for
- x86_64. However, I have not tried any actual substantive nisplus
- testing, do not have an environment for such testing, and do not know
- whether it is possible that strlen (name) or tablename_len might be
- large so that the VLA for buf is actually a security issue. However,
- if it is a security issue, there are plenty of other similar instances
- in the nisplus code (that haven't been hidden by a bogus comparison
- with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
- string passed to nis_list, so a local fix in the caller wouldn't
- suffice anyway (see bug 20987). (Calls to strdupa and other such
- macros that use alloca must be considered equally questionable
- regarding stack overflow issues as direct calls to alloca and VLA
- declarations.)
-
- [BZ #20978]
- * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
- Compare name == NULL, not name != NULL.
-
-diff --git a/nis/nss_nisplus/nisplus-alias.c b/nis/nss_nisplus/nisplus-alias.c
-index 7f698b4e6d..cb5acce01d 100644
---- a/nis/nss_nisplus/nisplus-alias.c
-+++ b/nis/nss_nisplus/nisplus-alias.c
-@@ -291,7 +291,7 @@ _nss_nisplus_getaliasbyname_r (const char *name, struct aliasent *alias,
- return status;
- }
-
-- if (name != NULL)
-+ if (name == NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.15/998-obstack-common.patch b/packages/glibc/2.15/998-obstack-common.patch
deleted file mode 100644
index 4b95f06..0000000
--- a/packages/glibc/2.15/998-obstack-common.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-commit 39b1f6172a2f9ddc74a8f82d6e84dd13b22dbaf2
-Author: Peter Collingbourne <pcc@google.com>
-Date: Wed May 15 20:28:08 2013 +0200
-
- Move _obstack_compat out of common
-
- it is impossible to create an alias of a common symbol (as
- compat_symbol does), because common symbols do not have a section or
- an offset until linked. GNU as tolerates aliases of common symbols by
- simply creating another common symbol, but other assemblers (notably
- LLVM's integrated assembler) are less tolerant.
-
- 2013-05-15 Peter Collingbourne <pcc@google.com>
-
- * malloc/obstack.c (_obstack_compat): Add initializer.
- -
-
-diff --git a/malloc/obstack.c b/malloc/obstack.c
-index 25a90514f7..c3c7db4a96 100644
---- a/malloc/obstack.c
-+++ b/malloc/obstack.c
-@@ -115,7 +115,7 @@ int obstack_exit_failure = EXIT_FAILURE;
- /* A looong time ago (before 1994, anyway; we're not sure) this global variable
- was used by non-GNU-C macros to avoid multiple evaluation. The GNU C
- library still exports it because somebody might use it. */
--struct obstack *_obstack_compat;
-+struct obstack *_obstack_compat = 0;
- compat_symbol (libc, _obstack_compat, _obstack, GLIBC_2_0);
- # endif
- # endif
diff --git a/packages/glibc/2.16.0/100-respect-env-CPPFLAGS.patch b/packages/glibc/2.16.0/0000-respect-env-CPPFLAGS.patch
index dce491c..be9d0bb 100644
--- a/packages/glibc/2.16.0/100-respect-env-CPPFLAGS.patch
+++ b/packages/glibc/2.16.0/0000-respect-env-CPPFLAGS.patch
@@ -1,9 +1,12 @@
Respect environment CPPFLAGS when we run ./configure so we can inject
random -D things without having to set CFLAGS/ASFLAGS
-diff -durN glibc-2.13.orig/Makeconfig glibc-2.13/Makeconfig
---- glibc-2.13.orig/Makeconfig 2009-05-09 23:57:56.000000000 +0200
-+++ glibc-2.13/Makeconfig 2009-11-13 00:49:41.000000000 +0100
+---
+ Makeconfig | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/Makeconfig
++++ b/Makeconfig
@@ -668,6 +668,7 @@
$(foreach lib,$(libof-$(basename $(@F))) \
$(libof-$(<F)) $(libof-$(@F)),$(CPPFLAGS-$(lib))) \
diff --git a/packages/glibc/2.16.0/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.16.0/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
new file mode 100644
index 0000000..31e9499
--- /dev/null
+++ b/packages/glibc/2.16.0/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
@@ -0,0 +1,75 @@
+From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
+From: Yvan Roux <yvan.roux@linaro.org>
+Date: Fri, 15 Apr 2016 13:29:26 +0200
+Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
+ -Wparentheses
+
+---
+ nis/nis_call.c | 20 +++++++++++---------
+ stdlib/setenv.c | 24 +++++++++++++-----------
+ 2 files changed, 24 insertions(+), 20 deletions(-)
+
+--- a/nis/nis_call.c
++++ b/nis/nis_call.c
+@@ -681,16 +681,18 @@
+ /* Choose which entry should be evicted from the cache. */
+ loc = &nis_server_cache[0];
+ if (*loc != NULL)
+- for (i = 1; i < 16; ++i)
+- if (nis_server_cache[i] == NULL)
+- {
++ {
++ for (i = 1; i < 16; ++i)
++ if (nis_server_cache[i] == NULL)
++ {
++ loc = &nis_server_cache[i];
++ break;
++ }
++ else if ((*loc)->uses > nis_server_cache[i]->uses
++ || ((*loc)->uses == nis_server_cache[i]->uses
++ && (*loc)->expires > nis_server_cache[i]->expires))
+ loc = &nis_server_cache[i];
+- break;
+- }
+- else if ((*loc)->uses > nis_server_cache[i]->uses
+- || ((*loc)->uses == nis_server_cache[i]->uses
+- && (*loc)->expires > nis_server_cache[i]->expires))
+- loc = &nis_server_cache[i];
++ }
+ old = *loc;
+ *loc = new;
+
+--- a/stdlib/setenv.c
++++ b/stdlib/setenv.c
+@@ -327,18 +327,20 @@
+ ep = __environ;
+ if (ep != NULL)
+ while (*ep != NULL)
+- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
+- {
+- /* Found it. Remove this pointer by moving later ones back. */
+- char **dp = ep;
++ {
++ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
++ {
++ /* Found it. Remove this pointer by moving later ones back. */
++ char **dp = ep;
+
+- do
+- dp[0] = dp[1];
+- while (*dp++);
+- /* Continue the loop in case NAME appears again. */
+- }
+- else
+- ++ep;
++ do
++ dp[0] = dp[1];
++ while (*dp++);
++ /* Continue the loop in case NAME appears again. */
++ }
++ else
++ ++ep;
++ }
+
+ UNLOCK;
+
diff --git a/packages/glibc/2.16.0/0002-fix-signed-shift-overlow.patch b/packages/glibc/2.16.0/0002-fix-signed-shift-overlow.patch
new file mode 100644
index 0000000..3b2ef40
--- /dev/null
+++ b/packages/glibc/2.16.0/0002-fix-signed-shift-overlow.patch
@@ -0,0 +1,97 @@
+commit 5542236837c5c41435f8282ec92799f480c36f18
+Author: Paul Eggert <eggert@cs.ucla.edu>
+Date: Tue Jul 21 22:50:29 2015 -0700
+
+ Port the 0x7efe...feff pattern to GCC 6.
+
+ See Steve Ellcey's bug report in:
+ https://sourceware.org/ml/libc-alpha/2015-07/msg00673.html
+ * string/memrchr.c (MEMRCHR):
+ * string/rawmemchr.c (RAWMEMCHR):
+ * string/strchr.c (strchr):
+ * string/strchrnul.c (STRCHRNUL):
+ Rewrite code to avoid issues with signed shift overflow.
+
+---
+ string/memrchr.c | 11 ++---------
+ string/rawmemchr.c | 11 ++---------
+ string/strchr.c | 9 ++-------
+ string/strchrnul.c | 9 ++-------
+ 4 files changed, 8 insertions(+), 32 deletions(-)
+
+--- a/string/memrchr.c
++++ b/string/memrchr.c
+@@ -96,15 +96,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+-
+- if (sizeof (longword) != 4 && sizeof (longword) != 8)
+- abort ();
+-
+-#if LONG_MAX <= LONG_MAX_32_BITS
+- magic_bits = 0x7efefeff;
+-#else
+- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
+-#endif
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/rawmemchr.c
++++ b/string/rawmemchr.c
+@@ -83,15 +83,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+-
+- if (sizeof (longword) != 4 && sizeof (longword) != 8)
+- abort ();
+-
+-#if LONG_MAX <= LONG_MAX_32_BITS
+- magic_bits = 0x7efefeff;
+-#else
+- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
+-#endif
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/strchr.c
++++ b/string/strchr.c
+@@ -64,13 +64,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+- switch (sizeof (longword))
+- {
+- case 4: magic_bits = 0x7efefeffL; break;
+- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
+- default:
+- abort ();
+- }
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/strchrnul.c
++++ b/string/strchrnul.c
+@@ -62,13 +62,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+- switch (sizeof (longword))
+- {
+- case 4: magic_bits = 0x7efefeffL; break;
+- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
+- default:
+- abort ();
+- }
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
diff --git a/packages/glibc/2.15/103-dl-openat64-variadic.patch b/packages/glibc/2.16.0/0003-dl-openat64-variadic.patch
index fe94b96..552db12 100644
--- a/packages/glibc/2.15/103-dl-openat64-variadic.patch
+++ b/packages/glibc/2.16.0/0003-dl-openat64-variadic.patch
@@ -177,8 +177,10 @@ Date: Tue Oct 20 11:54:09 2015 +0000
* wcsmbs/wcsnrtombs.c (__wcsnrtombs): Likewise.
* wcsmbs/wcsrtombs.c (__wcsrtombs): Likewise.
-diff --git a/sysdeps/unix/sysv/linux/dl-openat64.c b/sysdeps/unix/sysv/linux/dl-openat64.c
-index 7d100bb..7eea0ca 100644
+---
+ sysdeps/unix/sysv/linux/dl-openat64.c | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
--- a/sysdeps/unix/sysv/linux/dl-openat64.c
+++ b/sysdeps/unix/sysv/linux/dl-openat64.c
@@ -23,10 +23,7 @@
diff --git a/packages/glibc/2.16.0/104-unused-variables.patch b/packages/glibc/2.16.0/0004-unused-variables.patch
index 2a85a0c..db6f1b4 100644
--- a/packages/glibc/2.16.0/104-unused-variables.patch
+++ b/packages/glibc/2.16.0/0004-unused-variables.patch
@@ -19,8 +19,18 @@ Date: Fri Sep 18 20:27:20 2015 +0100
* timezone/private.h (time_t_min): Likewise. (time_t_max):
Likewise.
-diff --git a/resolv/base64.c b/resolv/base64.c
-index ea584ed..519e5d2 100644
+---
+ resolv/base64.c | 4 ----
+ sysdeps/ieee754/dbl-64/atnat2.h | 4 ----
+ sysdeps/ieee754/dbl-64/uexp.h | 2 +-
+ sysdeps/ieee754/dbl-64/upow.h | 2 --
+ sysdeps/ieee754/flt-32/e_log10f.c | 2 --
+ sysdeps/ieee754/flt-32/s_cosf.c | 2 --
+ sysdeps/ieee754/ldbl-128/e_lgammal_r.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_erfl.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_log1pl.c | 1 -
+ 9 files changed, 1 insertion(+), 18 deletions(-)
+
--- a/resolv/base64.c
+++ b/resolv/base64.c
@@ -40,10 +40,6 @@
@@ -34,11 +44,9 @@ index ea584ed..519e5d2 100644
#include <sys/types.h>
#include <sys/param.h>
#include <sys/socket.h>
-diff --git a/sysdeps/ieee754/dbl-64/atnat2.h b/sysdeps/ieee754/dbl-64/atnat2.h
-index e0d65af..82943f9 100644
--- a/sysdeps/ieee754/dbl-64/atnat2.h
+++ b/sysdeps/ieee754/dbl-64/atnat2.h
-@@ -65,10 +65,8 @@
+@@ -68,10 +68,8 @@
/**/ hpi1 = {{0x3c91a626, 0x33145c07} }, /* pi/2-hpi */
/**/ mhpi = {{0xbff921fb, 0x54442d18} }, /* -pi/2 */
/**/ qpi = {{0x3fe921fb, 0x54442d18} }, /* pi/4 */
@@ -49,7 +57,7 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0xc002d97c, 0x7f3321d2} }, /* -3pi/4 */
/**/ u1 = {{0x3c314c2a, 0x00000000} }, /* 9.377e-19 */
/**/ u2 = {{0x3bf955e4, 0x00000000} }, /* 8.584e-20 */
-@@ -129,10 +127,8 @@
+@@ -138,10 +136,8 @@
/**/ hpi1 = {{0x33145c07, 0x3c91a626} }, /* pi/2-hpi */
/**/ mhpi = {{0x54442d18, 0xbff921fb} }, /* -pi/2 */
/**/ qpi = {{0x54442d18, 0x3fe921fb} }, /* pi/4 */
@@ -60,8 +68,6 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0x7f3321d2, 0xc002d97c} }, /* -3pi/4 */
/**/ u1 = {{0x00000000, 0x3c314c2a} }, /* 9.377e-19 */
/**/ u2 = {{0x00000000, 0x3bf955e4} }, /* 8.584e-20 */
-diff --git a/sysdeps/ieee754/dbl-64/uexp.h b/sysdeps/ieee754/dbl-64/uexp.h
-index 6817eaf..42b21f2 100644
--- a/sysdeps/ieee754/dbl-64/uexp.h
+++ b/sysdeps/ieee754/dbl-64/uexp.h
@@ -29,7 +29,7 @@
@@ -73,11 +79,9 @@ index 6817eaf..42b21f2 100644
err_0 = 1.000014, err_1 = 0.000016;
const static int4 bigint = 0x40862002,
badint = 0x40876000,smallint = 0x3C8fffff;
-diff --git a/sysdeps/ieee754/dbl-64/upow.h b/sysdeps/ieee754/dbl-64/upow.h
-index c8569a9..b4911e5 100644
--- a/sysdeps/ieee754/dbl-64/upow.h
+++ b/sysdeps/ieee754/dbl-64/upow.h
-@@ -34,7 +34,6 @@
+@@ -35,7 +35,6 @@
/**/ INF = {{0x7ff00000, 0x00000000}}, /* INF */
/**/ nINF = {{0xfff00000, 0x00000000}}, /* -INF */
/**/ NaNQ = {{0x7ff80000, 0x00000000}}, /* NaNQ */
@@ -85,7 +89,7 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0x3fe62e42, 0xfefa3800}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x3d2ef357, 0x93c76730}}, /* ln(2)-ln2a */
/**/ bigu = {{0x4297ffff, 0xfffffd2c}}, /* 1.5*2**42 -724*2**-10 */
-@@ -48,7 +47,6 @@
+@@ -50,7 +49,6 @@
/**/ INF = {{0x00000000, 0x7ff00000}}, /* INF */
/**/ nINF = {{0x00000000, 0xfff00000}}, /* -INF */
/**/ NaNQ = {{0x00000000, 0x7ff80000}}, /* NaNQ */
@@ -93,11 +97,9 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0xfefa3800, 0x3fe62e42}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x93c76730, 0x3d2ef357}}, /* ln(2)-ln2a */
/**/ bigu = {{0xfffffd2c, 0x4297ffff}}, /* 1.5*2**42 -724*2**-10 */
-diff --git a/sysdeps/ieee754/flt-32/e_log10f.c b/sysdeps/ieee754/flt-32/e_log10f.c
-index 96f0e81..1daeef7 100644
--- a/sysdeps/ieee754/flt-32/e_log10f.c
+++ b/sysdeps/ieee754/flt-32/e_log10f.c
-@@ -22,8 +22,6 @@ ivln10 = 4.3429449201e-01, /* 0x3ede5bd9 */
+@@ -22,8 +22,6 @@
log10_2hi = 3.0102920532e-01, /* 0x3e9a2080 */
log10_2lo = 7.9034151668e-07; /* 0x355427db */
@@ -106,11 +108,9 @@ index 96f0e81..1daeef7 100644
float
__ieee754_log10f(float x)
{
-diff --git a/sysdeps/ieee754/flt-32/s_cosf.c b/sysdeps/ieee754/flt-32/s_cosf.c
-index 864ab27..0affd40 100644
--- a/sysdeps/ieee754/flt-32/s_cosf.c
+++ b/sysdeps/ieee754/flt-32/s_cosf.c
-@@ -21,8 +21,6 @@ static char rcsid[] = "$NetBSD: s_cosf.c,v 1.4 1995/05/10 20:47:03 jtc Exp $";
+@@ -21,8 +21,6 @@
#include <math.h>
#include <math_private.h>
@@ -119,11 +119,9 @@ index 864ab27..0affd40 100644
float __cosf(float x)
{
float y[2],z=0.0;
-diff --git a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-index 500aacc..ab5a96e 100644
--- a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
+++ b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-@@ -82,7 +82,6 @@ DIAG_IGNORE_NEEDS_COMMENT (4.6, "-Woverflow");
+@@ -74,7 +74,6 @@
static const long double PIL = 3.1415926535897932384626433832795028841972E0L;
static const long double MAXLGM = 1.0485738685148938358098967157129705071571E4928L;
static const long double one = 1.0L;
@@ -131,11 +129,9 @@ index 500aacc..ab5a96e 100644
static const long double huge = 1.0e4000L;
/* log gamma(x) = ( x - 0.5 ) * log(x) - x + LS2PI + 1/x P(1/x^2)
-diff --git a/sysdeps/ieee754/ldbl-128/s_erfl.c b/sysdeps/ieee754/ldbl-128/s_erfl.c
-index fa4609f..08c80a3 100644
--- a/sysdeps/ieee754/ldbl-128/s_erfl.c
+++ b/sysdeps/ieee754/ldbl-128/s_erfl.c
-@@ -140,7 +140,6 @@ deval (long double x, const long double *p, int n)
+@@ -138,7 +138,6 @@
static const long double
tiny = 1e-4931L,
@@ -143,11 +139,9 @@ index fa4609f..08c80a3 100644
one = 1.0L,
two = 2.0L,
/* 2/sqrt(pi) - 1 */
-diff --git a/sysdeps/ieee754/ldbl-128/s_log1pl.c b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-index ff759bc..9609550 100644
--- a/sysdeps/ieee754/ldbl-128/s_log1pl.c
+++ b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-@@ -117,7 +117,6 @@ static const long double C2 = 1.428606820309417232121458176568075500134E-6L;
+@@ -116,7 +116,6 @@
static const long double sqrth = 0.7071067811865475244008443621048490392848L;
/* ln (2^16384 * (1 - 2^-113)) */
diff --git a/packages/glibc/2.16.0/0005-misleading-indentation.patch b/packages/glibc/2.16.0/0005-misleading-indentation.patch
new file mode 100644
index 0000000..8e08259
--- /dev/null
+++ b/packages/glibc/2.16.0/0005-misleading-indentation.patch
@@ -0,0 +1,26 @@
+commit 976ef870542580cf5fed896c2c652b3e1a95f9da
+Author: Steve Ellcey <sellcey@mips.com>
+Date: Fri Dec 11 09:19:37 2015 -0800
+
+ Fix indentation.
+
+ * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
+ Fix indentation.
+
+---
+ sysdeps/ieee754/flt-32/k_rem_pio2f.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+--- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
++++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
+@@ -65,7 +65,9 @@
+
+ /* compute q[0],q[1],...q[jk] */
+ for (i=0;i<=jk;i++) {
+- for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw;
++ for(j=0,fw=0.0;j<=jx;j++)
++ fw += x[j]*f[jx+i-j];
++ q[i] = fw;
+ }
+
+ jz = jk;
diff --git a/packages/glibc/2.16.0/106-dl-open-array-bounds.patch b/packages/glibc/2.16.0/0006-dl-open-array-bounds.patch
index a8efe9a..4df8346 100644
--- a/packages/glibc/2.16.0/106-dl-open-array-bounds.patch
+++ b/packages/glibc/2.16.0/0006-dl-open-array-bounds.patch
@@ -4,11 +4,13 @@ Date: Fri Apr 17 12:11:58 2015 -0700
Fuller check for invalid NSID in _dl_open.
-diff --git a/elf/dl-open.c b/elf/dl-open.c
-index 0dbe07f..2d0e082 100644
+---
+ elf/dl-open.c | 10 ++++++++--
+ 1 file changed, 8 insertions(+), 2 deletions(-)
+
--- a/elf/dl-open.c
+++ b/elf/dl-open.c
-@@ -619,8 +619,14 @@ no more namespaces available for dlmopen()"));
+@@ -609,8 +609,14 @@
/* Never allow loading a DSO in a namespace which is empty. Such
direct placements is only causing problems. Also don't allow
loading into a namespace used for auditing. */
diff --git a/packages/glibc/2.16.0/0007-i386-x86_64-revert-clone-cfi.patch b/packages/glibc/2.16.0/0007-i386-x86_64-revert-clone-cfi.patch
new file mode 100644
index 0000000..30e8929
--- /dev/null
+++ b/packages/glibc/2.16.0/0007-i386-x86_64-revert-clone-cfi.patch
@@ -0,0 +1,51 @@
+revert cfi additions to clone on i386/x86_64 to workaround problems in
+gcc's unwinder code. this is not a bug in glibc, it triggers problems
+elsewhere. this cfi code does not gain us a whole lot anyways.
+
+http://gcc.gnu.org/ml/gcc/2006-12/msg00293.html
+
+---
+ sysdeps/unix/sysv/linux/i386/clone.S | 4 ----
+ sysdeps/unix/sysv/linux/x86_64/clone.S | 4 ----
+ 2 files changed, 8 deletions(-)
+
+--- a/sysdeps/unix/sysv/linux/i386/clone.S
++++ b/sysdeps/unix/sysv/linux/i386/clone.S
+@@ -119,9 +119,6 @@
+ ret
+
+ L(thread_start):
+- cfi_startproc;
+- /* Clearing frame pointer is insufficient, use CFI. */
+- cfi_undefined (eip);
+ /* Note: %esi is zero. */
+ movl %esi,%ebp /* terminate the stack frame */
+ #ifdef RESET_PID
+@@ -154,7 +151,6 @@
+ jmp L(haspid)
+ .previous
+ #endif
+- cfi_endproc;
+
+ cfi_startproc
+ PSEUDO_END (BP_SYM (__clone))
+--- a/sysdeps/unix/sysv/linux/x86_64/clone.S
++++ b/sysdeps/unix/sysv/linux/x86_64/clone.S
+@@ -88,9 +88,6 @@
+ ret
+
+ L(thread_start):
+- cfi_startproc;
+- /* Clearing frame pointer is insufficient, use CFI. */
+- cfi_undefined (rip);
+ /* Clear the frame pointer. The ABI suggests this be done, to mark
+ the outermost frame obviously. */
+ xorl %ebp, %ebp
+@@ -115,7 +112,6 @@
+ /* Call exit with return value from function call. */
+ movq %rax, %rdi
+ call HIDDEN_JUMPTARGET (_exit)
+- cfi_endproc;
+
+ cfi_startproc;
+ PSEUDO_END (BP_SYM (__clone))
diff --git a/packages/glibc/2.16.0/0008-disable-ldconfig.patch b/packages/glibc/2.16.0/0008-disable-ldconfig.patch
new file mode 100644
index 0000000..49f39b5
--- /dev/null
+++ b/packages/glibc/2.16.0/0008-disable-ldconfig.patch
@@ -0,0 +1,19 @@
+do not bother running ldconfig on DESTDIR. it wants to write the temp cache
+file outside of the chroot. doesnt matter anyways as we wont use the cache
+results (portage will rebuild cache), so running ldconfig is simply a waste
+of time.
+
+---
+ Makefile | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/Makefile
++++ b/Makefile
+@@ -105,6 +105,7 @@
+ rm -f $(symbolic-link-list)
+
+ install:
++dont-bother-with-destdir:
+ -test ! -x $(common-objpfx)elf/ldconfig || LC_ALL=C LANGUAGE=C \
+ $(common-objpfx)elf/ldconfig $(addprefix -r ,$(install_root)) \
+ $(slibdir) $(libdir)
diff --git a/packages/glibc/2.18/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.16.0/0009-Fix-combreloc-test-BSD-grep.patch
index 3c34e01..e1d7dec 100644
--- a/packages/glibc/2.18/140-Fix-combreloc-test-BSD-grep.patch
+++ b/packages/glibc/2.16.0/0009-Fix-combreloc-test-BSD-grep.patch
@@ -13,16 +13,13 @@ by configure as "not found". As a result, support for "-z combreloc"
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
+ configure | 2 +-
+ configure.in | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
-diff --git a/configure b/configure
-index eecd0ac..0118bd1 100755
--- a/configure
+++ b/configure
-@@ -5804,7 +5804,7 @@ if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
+@@ -6440,7 +6440,7 @@
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; }
then
@@ -31,11 +28,9 @@ index eecd0ac..0118bd1 100755
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
-diff --git a/configure.ac b/configure.ac
-index 4a77411..19f6d87 100644
--- a/configure.in
+++ b/configure.in
-@@ -1391,7 +1391,7 @@ dnl cross-platform since the gcc used can be a cross compiler. Without
+@@ -1586,7 +1586,7 @@
dnl introducing new options this is not easily doable. Instead use a tool
dnl which always is cross-platform: readelf. To detect whether -z combreloc
dnl look for a section named .rel.dyn.
@@ -44,6 +39,3 @@ index 4a77411..19f6d87 100644
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
---
-2.9.3
-
diff --git a/packages/glibc/2.16.0/0010-queue-header-updates.patch b/packages/glibc/2.16.0/0010-queue-header-updates.patch
new file mode 100644
index 0000000..f6515e2
--- /dev/null
+++ b/packages/glibc/2.16.0/0010-queue-header-updates.patch
@@ -0,0 +1,86 @@
+grab some updates from FreeBSD
+
+http://bugs.gentoo.org/201979
+
+---
+ misc/sys/queue.h | 36 ++++++++++++++++++++++++++++++++++++
+ 1 file changed, 36 insertions(+)
+
+--- a/misc/sys/queue.h
++++ b/misc/sys/queue.h
+@@ -136,6 +136,11 @@
+ (var); \
+ (var) = ((var)->field.le_next))
+
++#define LIST_FOREACH_SAFE(var, head, field, tvar) \
++ for ((var) = LIST_FIRST((head)); \
++ (var) && ((tvar) = LIST_NEXT((var), field), 1); \
++ (var) = (tvar))
++
+ /*
+ * List access methods.
+ */
+@@ -197,6 +202,16 @@
+ #define SLIST_FOREACH(var, head, field) \
+ for((var) = (head)->slh_first; (var); (var) = (var)->field.sle_next)
+
++#define SLIST_FOREACH_SAFE(var, head, field, tvar) \
++ for ((var) = SLIST_FIRST((head)); \
++ (var) && ((tvar) = SLIST_NEXT((var), field), 1); \
++ (var) = (tvar))
++
++#define SLIST_FOREACH_PREVPTR(var, varp, head, field) \
++ for ((varp) = &SLIST_FIRST((head)); \
++ ((var) = *(varp)) != NULL; \
++ (varp) = &SLIST_NEXT((var), field))
++
+ /*
+ * Singly-linked List access methods.
+ */
+@@ -242,6 +257,12 @@
+ (head)->stqh_last = &(elm)->field.stqe_next; \
+ } while (/*CONSTCOND*/0)
+
++#define STAILQ_LAST(head, type, field) \
++ (STAILQ_EMPTY((head)) ? \
++ NULL : \
++ ((struct type *)(void *) \
++ ((char *)((head)->stqh_last) - __offsetof(struct type, field))))
++
+ #define STAILQ_INSERT_AFTER(head, listelm, elm, field) do { \
+ if (((elm)->field.stqe_next = (listelm)->field.stqe_next) == NULL)\
+ (head)->stqh_last = &(elm)->field.stqe_next; \
+@@ -271,6 +292,11 @@
+ (var); \
+ (var) = ((var)->field.stqe_next))
+
++#define STAILQ_FOREACH_SAFE(var, head, field, tvar) \
++ for ((var) = STAILQ_FIRST((head)); \
++ (var) && ((tvar) = STAILQ_NEXT((var), field), 1); \
++ (var) = (tvar))
++
+ #define STAILQ_CONCAT(head1, head2) do { \
+ if (!STAILQ_EMPTY((head2))) { \
+ *(head1)->stqh_last = (head2)->stqh_first; \
+@@ -437,11 +463,21 @@
+ (var); \
+ (var) = ((var)->field.tqe_next))
+
++#define TAILQ_FOREACH_SAFE(var, head, field, tvar) \
++ for ((var) = TAILQ_FIRST((head)); \
++ (var) && ((tvar) = TAILQ_NEXT((var), field), 1); \
++ (var) = (tvar))
++
+ #define TAILQ_FOREACH_REVERSE(var, head, headname, field) \
+ for ((var) = (*(((struct headname *)((head)->tqh_last))->tqh_last)); \
+ (var); \
+ (var) = (*(((struct headname *)((var)->field.tqe_prev))->tqh_last)))
+
++#define TAILQ_FOREACH_REVERSE_SAFE(var, head, headname, field, tvar) \
++ for ((var) = TAILQ_LAST((head), headname); \
++ (var) && ((tvar) = TAILQ_PREV((var), headname, field), 1); \
++ (var) = (tvar))
++
+ #define TAILQ_CONCAT(head1, head2, field) do { \
+ if (!TAILQ_EMPTY(head2)) { \
+ *(head1)->tqh_last = (head2)->tqh_first; \
diff --git a/packages/glibc/2.16.0/0011-localedef-fix-trampoline.patch b/packages/glibc/2.16.0/0011-localedef-fix-trampoline.patch
new file mode 100644
index 0000000..e6392c1
--- /dev/null
+++ b/packages/glibc/2.16.0/0011-localedef-fix-trampoline.patch
@@ -0,0 +1,56 @@
+# DP: Description: Fix localedef segfault when run under exec-shield,
+# PaX or similar. (#231438, #198099)
+# DP: Dpatch Author: James Troup <james@nocrew.org>
+# DP: Patch Author: (probably) Jakub Jelinek <jakub@redhat.com>
+# DP: Upstream status: Unknown
+# DP: Status Details: Unknown
+# DP: Date: 2004-03-16
+---
+# locale/programs/3level.h | 36 ++++++++++++++++++++++++++++++++++++
+# 1 file changed, 36 insertions(+)
+#
+--- a/locale/programs/3level.h
++++ b/locale/programs/3level.h
+@@ -202,6 +202,42 @@
+ }
+ }
+ }
++
++/* GCC ATM seems to do a poor job with pointers to nested functions passed
++ to inlined functions. Help it a little bit with this hack. */
++#define wchead_table_iterate(tp, fn) \
++do \
++ { \
++ struct wchead_table *t = (tp); \
++ uint32_t index1; \
++ for (index1 = 0; index1 < t->level1_size; index1++) \
++ { \
++ uint32_t lookup1 = t->level1[index1]; \
++ if (lookup1 != ((uint32_t) ~0)) \
++ { \
++ uint32_t lookup1_shifted = lookup1 << t->q; \
++ uint32_t index2; \
++ for (index2 = 0; index2 < (1 << t->q); index2++) \
++ { \
++ uint32_t lookup2 = t->level2[index2 + lookup1_shifted]; \
++ if (lookup2 != ((uint32_t) ~0)) \
++ { \
++ uint32_t lookup2_shifted = lookup2 << t->p; \
++ uint32_t index3; \
++ for (index3 = 0; index3 < (1 << t->p); index3++) \
++ { \
++ struct element_t *lookup3 \
++ = t->level3[index3 + lookup2_shifted]; \
++ if (lookup3 != NULL) \
++ fn ((((index1 << t->q) + index2) << t->p) + index3, \
++ lookup3); \
++ } \
++ } \
++ } \
++ } \
++ } \
++ } while (0)
++
+ #endif
+
+ #ifndef NO_FINALIZE
diff --git a/packages/glibc/2.16.0/0012-resolv-dynamic.patch b/packages/glibc/2.16.0/0012-resolv-dynamic.patch
new file mode 100644
index 0000000..fcc2f80
--- /dev/null
+++ b/packages/glibc/2.16.0/0012-resolv-dynamic.patch
@@ -0,0 +1,42 @@
+ripped from SuSE
+
+if /etc/resolv.conf is updated, then make sure applications
+already running get the updated information.
+
+http://bugs.gentoo.org/177416
+
+---
+ resolv/res_libc.c | 15 +++++++++++++++
+ 1 file changed, 15 insertions(+)
+
+--- a/resolv/res_libc.c
++++ b/resolv/res_libc.c
+@@ -22,6 +22,7 @@
+ #include <arpa/nameser.h>
+ #include <resolv.h>
+ #include <bits/libc-lock.h>
++#include <sys/stat.h>
+
+
+ /* The following bit is copied from res_data.c (where it is #ifdef'ed
+@@ -95,6 +96,20 @@
+ __res_maybe_init (res_state resp, int preinit)
+ {
+ if (resp->options & RES_INIT) {
++ static time_t last_mtime, last_check;
++ time_t now;
++ struct stat statbuf;
++
++ time (&now);
++ if (now != last_check) {
++ last_check = now;
++ if (stat (_PATH_RESCONF, &statbuf) == 0 && last_mtime != statbuf.st_mtime) {
++ last_mtime = statbuf.st_mtime;
++ atomicinclock (lock);
++ atomicinc (__res_initstamp);
++ atomicincunlock (lock);
++ }
++ }
+ if (__res_initstamp != resp->_u._ext.initstamp) {
+ if (resp->nscount > 0)
+ __res_iclose (resp, true);
diff --git a/packages/glibc/2.16.0/0013-fadvise64_64.patch b/packages/glibc/2.16.0/0013-fadvise64_64.patch
new file mode 100644
index 0000000..3f827ab
--- /dev/null
+++ b/packages/glibc/2.16.0/0013-fadvise64_64.patch
@@ -0,0 +1,27 @@
+ripped from Debian
+
+ sysdeps/unix/sysv/linux/posix_fadvise.c | 13 +++++++++++++
+ 1 file changed, 13 insertions(+)
+
+--- a/sysdeps/unix/sysv/linux/posix_fadvise.c
++++ b/sysdeps/unix/sysv/linux/posix_fadvise.c
+@@ -34,6 +34,19 @@
+ return INTERNAL_SYSCALL_ERRNO (ret, err);
+ return 0;
+ #else
++# ifdef __NR_fadvise64_64
++ INTERNAL_SYSCALL_DECL (err);
++ int ret = INTERNAL_SYSCALL (fadvise64_64, err, 6, fd,
++ __LONG_LONG_PAIR ((long) (offset >> 31),
++ (long) offset),
++ __LONG_LONG_PAIR ((long) (len >> 31),
++ (long) len),
++ advise);
++ if (INTERNAL_SYSCALL_ERROR_P (ret, err))
++ return INTERNAL_SYSCALL_ERRNO (ret, err);
++ return 0;
++# else
+ return ENOSYS;
++# endif
+ #endif
+ }
diff --git a/packages/glibc/2.16.0/260-assume-pipe2.patch b/packages/glibc/2.16.0/0014-assume-pipe2.patch
index 54f0382..a36b602 100644
--- a/packages/glibc/2.16.0/260-assume-pipe2.patch
+++ b/packages/glibc/2.16.0/0014-assume-pipe2.patch
@@ -20,9 +20,12 @@ __have_sock_cloexec and __have_pipe2 to true. but if glibc was built against
older kernel headers where __NR_pipe2 does not exist, glibc will have a ENOSYS
stub for it. so popen() will always fail as glibc assumes pipe2() works.
-diff -durN glibc-2.16.0.orig/socket/have_sock_cloexec.c glibc-2.16.0/socket/have_sock_cloexec.c
---- glibc-2.16.0.orig/socket/have_sock_cloexec.c 2008-07-25 18:46:23.000000000 +0200
-+++ glibc-2.16.0/socket/have_sock_cloexec.c 2009-11-13 00:50:15.000000000 +0100
+---
+ socket/have_sock_cloexec.c | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/socket/have_sock_cloexec.c
++++ b/socket/have_sock_cloexec.c
@@ -15,9 +15,14 @@
License along with the GNU C Library; if not, see
<http://www.gnu.org/licenses/>. */
diff --git a/packages/glibc/2.16.0/0015-china.patch b/packages/glibc/2.16.0/0015-china.patch
new file mode 100644
index 0000000..b323cf6
--- /dev/null
+++ b/packages/glibc/2.16.0/0015-china.patch
@@ -0,0 +1,35 @@
+
+
+---
+ localedata/locales/zh_TW | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+--- a/localedata/locales/zh_TW
++++ b/localedata/locales/zh_TW
+@@ -1,7 +1,7 @@
+ comment_char %
+ escape_char /
+ %
+-% Chinese language locale for Taiwan R.O.C.
++% Chinese language locale for Taiwan
+ % charmap: BIG5-CP950
+ %
+ % Original Author:
+@@ -17,7 +17,7 @@
+ % Reference: http://wwwold.dkuug.dk/JTC1/SC22/WG20/docs/n690.pdf
+
+ LC_IDENTIFICATION
+-title "Chinese locale for Taiwan R.O.C."
++title "Chinese locale for Taiwan"
+ source ""
+ address ""
+ contact ""
+@@ -25,7 +25,7 @@
+ tel ""
+ fax ""
+ language "Chinese"
+-territory "Taiwan R.O.C."
++territory "Taiwan"
+ revision "0.2"
+ date "2000-08-02"
+ %
diff --git a/packages/glibc/2.16.0/0016-new-valencian-locale.patch b/packages/glibc/2.16.0/0016-new-valencian-locale.patch
new file mode 100644
index 0000000..8f67711
--- /dev/null
+++ b/packages/glibc/2.16.0/0016-new-valencian-locale.patch
@@ -0,0 +1,118 @@
+http://bugs.gentoo.org/show_bug.cgi?id=131815
+http://sourceware.org/bugzilla/show_bug.cgi?id=2522
+
+---
+ localedata/SUPPORTED | 2
+ localedata/locales/ca_ES@valencia | 96 ++++++++++++++++++++++++++++++++++++++
+ 2 files changed, 98 insertions(+)
+
+--- a/localedata/SUPPORTED
++++ b/localedata/SUPPORTED
+@@ -75,6 +75,8 @@
+ ca_ES.UTF-8/UTF-8 \
+ ca_ES/ISO-8859-1 \
+ ca_ES@euro/ISO-8859-15 \
++ca_ES.UTF-8@valencia/UTF-8 \
++ca_ES@valencia/ISO-8859-15 \
+ ca_FR.UTF-8/UTF-8 \
+ ca_FR/ISO-8859-15 \
+ ca_IT.UTF-8/UTF-8 \
+--- /dev/null
++++ b/localedata/locales/ca_ES@valencia
+@@ -0,0 +1,96 @@
++comment_char %
++escape_char /
++%
++% Valencian (southern Catalan) locale for Spain with Euro
++%
++% Note that this locale is almost the same as ca_ES@euro. The point of having
++% a separate locale is only for PO translations, which have a lot of social
++% support and are very appreciated by the Valencian-speaking community.
++%
++% Contact: Jordi Mallach
++% Email: jordi@gnu.org
++% Tel:
++% Fax:
++% Language: ca
++% Territory: ES
++% Option: euro
++% Revision: 1.0
++% Date: 2006-04-06
++% Application: general
++% Users: general
++% Repertoiremap: mnemonic,ds
++% Charset: ISO-8859-15
++% Distribution and use is free, also
++% for commercial purposes.
++
++LC_IDENTIFICATION
++title "Valencian (southern Catalan) locale for Spain with Euro"
++source ""
++address ""
++contact "Jordi Mallach"
++email "jordi@gnu.org"
++tel ""
++fax ""
++language "Catalan"
++territory "Spain"
++revision "1.0"
++date "2006-04-06"
++%
++category "ca_ES@valencia:2006";LC_IDENTIFICATION
++category "ca_ES@valencia:2006";LC_CTYPE
++category "ca_ES@valencia:2006";LC_COLLATE
++category "ca_ES@valencia:2006";LC_MONETARY
++category "ca_ES@valencia:2006";LC_NUMERIC
++category "ca_ES@valencia:2006";LC_TIME
++category "ca_ES@valencia:2006";LC_MESSAGES
++category "ca_ES@valencia:2006";LC_PAPER
++category "ca_ES@valencia:2006";LC_NAME
++category "ca_ES@valencia:2006";LC_ADDRESS
++category "ca_ES@valencia:2006";LC_TELEPHONE
++category "ca_ES@valencia:2006";LC_MEASUREMENT
++
++END LC_IDENTIFICATION
++
++LC_CTYPE
++copy "i18n"
++END LC_CTYPE
++
++LC_COLLATE
++copy "ca_ES"
++END LC_COLLATE
++
++LC_MONETARY
++copy "ca_ES"
++END LC_MONETARY
++
++LC_NUMERIC
++copy "ca_ES"
++END LC_NUMERIC
++
++LC_TIME
++copy "ca_ES"
++END LC_TIME
++
++LC_MESSAGES
++copy "ca_ES"
++END LC_MESSAGES
++
++LC_PAPER
++copy "ca_ES"
++END LC_PAPER
++
++LC_NAME
++copy "ca_ES"
++END LC_NAME
++
++LC_ADDRESS
++copy "ca_ES"
++END LC_ADDRESS
++
++LC_TELEPHONE
++copy "ca_ES"
++END LC_TELEPHONE
++
++LC_MEASUREMENT
++copy "ca_ES"
++END LC_MEASUREMENT
diff --git a/packages/glibc/2.16.0/0017-macos-cross-rpcgen.patch b/packages/glibc/2.16.0/0017-macos-cross-rpcgen.patch
new file mode 100644
index 0000000..b439b0f
--- /dev/null
+++ b/packages/glibc/2.16.0/0017-macos-cross-rpcgen.patch
@@ -0,0 +1,34 @@
+commit ae7080d30c68cfa0c81ce3422dca948f64a94f50
+Author: Jia Liu <proljc@gmail.com>
+Date: Sat Sep 7 00:01:08 2013 +0800
+
+ sunrpc/rpc/types.h: fix OS X and FreeBSD build problems
+
+ When I build arm-linux-gcc on OS X, I find glibc will get a build error
+ in sunrpc/rpc/types.h, so I add __APPLE_CC__ to make OS X build OK.
+ For FreeBSD, Add __FreeBSD__ to make it build OK, too.
+
+ URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00155.html
+ URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00217.html
+ URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00240.html
+ Signed-off-by: Jia Liu <proljc@gmail.com>
+ Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+
+---
+ sunrpc/rpc/types.h | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/sunrpc/rpc/types.h
++++ b/sunrpc/rpc/types.h
+@@ -69,6 +69,11 @@
+ #include <sys/types.h>
+ #endif
+
++#if defined __APPLE_CC__ || defined __FreeBSD__
++# define __u_char_defined
++# define __daddr_t_defined
++#endif
++
+ #ifndef __u_char_defined
+ typedef __u_char u_char;
+ typedef __u_short u_short;
diff --git a/packages/glibc/2.16.0/300-nscd-one-fork.patch b/packages/glibc/2.16.0/0018-nscd-one-fork.patch
index 13b2861..0d72f07 100644
--- a/packages/glibc/2.16.0/300-nscd-one-fork.patch
+++ b/packages/glibc/2.16.0/0018-nscd-one-fork.patch
@@ -2,9 +2,12 @@ only fork one to assist in stop-start-daemon assumptions about daemon behavior
http://bugs.gentoo.org/190785
-diff -durN glibc-2.13.orig/nscd/nscd.c glibc-2.13/nscd/nscd.c
---- glibc-2.13.orig/nscd/nscd.c 2009-02-06 21:10:27.000000000 +0100
-+++ glibc-2.13/nscd/nscd.c 2009-11-13 00:50:24.000000000 +0100
+---
+ nscd/nscd.c | 15 +++------------
+ 1 file changed, 3 insertions(+), 12 deletions(-)
+
+--- a/nscd/nscd.c
++++ b/nscd/nscd.c
@@ -203,6 +203,9 @@
exit (0);
}
@@ -31,7 +34,7 @@ diff -durN glibc-2.13.orig/nscd/nscd.c glibc-2.13/nscd/nscd.c
setsid ();
if (chdir ("/") != 0)
-@@ -245,9 +242,6 @@
+@@ -269,9 +263,6 @@
openlog ("nscd", LOG_CONS | LOG_ODELAY, LOG_DAEMON);
diff --git a/packages/glibc/2.16.0/310-hppa-nptl-carlos.patch b/packages/glibc/2.16.0/0019-hppa-nptl-carlos.patch
index 11e8a65..6c2ca8e 100644
--- a/packages/glibc/2.16.0/310-hppa-nptl-carlos.patch
+++ b/packages/glibc/2.16.0/0019-hppa-nptl-carlos.patch
@@ -1,9 +1,18 @@
-diff -durN glibc-2.13.orig/elf/rtld.c glibc-2.13/elf/rtld.c
---- glibc-2.13.orig/elf/rtld.c 2009-04-17 02:00:08.000000000 +0200
-+++ glibc-2.13/elf/rtld.c 2009-11-13 00:50:26.000000000 +0100
-@@ -392,14 +392,14 @@
+---
+ elf/rtld.c | 10 +++++-----
+ include/atomic.h | 26 +++++++++++++-------------
+ nptl/Makefile | 35 ++++++++++++++++++++++++++++++++---
+ nptl/pthread_barrier_wait.c | 2 +-
+ nptl/sysdeps/pthread/Makefile | 2 ++
+ stdio-common/Makefile | 2 +-
+ sunrpc/clnt_udp.c | 2 +-
+ 7 files changed, 55 insertions(+), 24 deletions(-)
+
+--- a/elf/rtld.c
++++ b/elf/rtld.c
+@@ -393,14 +393,14 @@
know it is available. We do not have to clear the memory if we
do not have to use the temporary bootstrap_map. Global variables
are initialized to zero by default. */
@@ -23,10 +32,9 @@ diff -durN glibc-2.13.orig/elf/rtld.c glibc-2.13/elf/rtld.c
# endif
# if USE___THREAD
bootstrap_map.l_tls_modid = 0;
-diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
---- glibc-2.13.orig/include/atomic.h 2009-02-09 00:49:53.000000000 +0100
-+++ glibc-2.13/include/atomic.h 2009-11-13 00:50:26.000000000 +0100
-@@ -185,7 +185,7 @@
+--- a/include/atomic.h
++++ b/include/atomic.h
+@@ -184,7 +184,7 @@
__typeof (*(mem)) __atg5_value = (newvalue); \
\
do \
@@ -35,7 +43,7 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
while (__builtin_expect \
(atomic_compare_and_exchange_bool_acq (__atg5_memp, __atg5_value, \
__atg5_oldval), 0)); \
-@@ -206,7 +206,7 @@
+@@ -205,7 +205,7 @@
__typeof (*(mem)) __atg6_value = (value); \
\
do \
@@ -44,7 +52,7 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
while (__builtin_expect \
(atomic_compare_and_exchange_bool_acq (__atg6_memp, \
__atg6_oldval \
-@@ -224,7 +224,7 @@
+@@ -223,7 +223,7 @@
__typeof (*(mem)) __atg7_value = (value); \
\
do \
@@ -53,7 +61,7 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
while (__builtin_expect \
(catomic_compare_and_exchange_bool_acq (__atg7_memp, \
__atg7_oldv \
-@@ -242,7 +242,7 @@
+@@ -241,7 +241,7 @@
__typeof (mem) __atg8_memp = (mem); \
__typeof (*(mem)) __atg8_value = (value); \
do { \
@@ -62,7 +70,7 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
if (__atg8_oldval >= __atg8_value) \
break; \
} while (__builtin_expect \
-@@ -259,7 +259,7 @@
+@@ -258,7 +258,7 @@
__typeof (mem) __atg9_memp = (mem); \
__typeof (*(mem)) __atg9_value = (value); \
do { \
@@ -71,7 +79,7 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
if (__atg9_oldv >= __atg9_value) \
break; \
} while (__builtin_expect \
-@@ -277,7 +277,7 @@
+@@ -276,7 +276,7 @@
__typeof (mem) __atg10_memp = (mem); \
__typeof (*(mem)) __atg10_value = (value); \
do { \
@@ -80,7 +88,7 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
if (__atg10_oldval <= __atg10_value) \
break; \
} while (__builtin_expect \
-@@ -361,7 +361,7 @@
+@@ -360,7 +360,7 @@
\
do \
{ \
@@ -89,7 +97,7 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
if (__builtin_expect (__atg11_oldval <= 0, 0)) \
break; \
} \
-@@ -400,7 +400,7 @@
+@@ -399,7 +399,7 @@
__typeof (*(mem)) __atg14_mask = ((__typeof (*(mem))) 1 << (bit)); \
\
do \
@@ -98,7 +106,7 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
while (__builtin_expect \
(atomic_compare_and_exchange_bool_acq (__atg14_memp, \
__atg14_old | __atg14_mask,\
-@@ -418,7 +418,7 @@
+@@ -417,7 +417,7 @@
__typeof (*(mem)) __atg15_mask = (mask); \
\
do \
@@ -107,7 +115,7 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
while (__builtin_expect \
(atomic_compare_and_exchange_bool_acq (__atg15_memp, \
__atg15_old & __atg15_mask, \
-@@ -450,7 +450,7 @@
+@@ -449,7 +449,7 @@
__typeof (*(mem)) __atg16_mask = (mask); \
\
do \
@@ -116,7 +124,7 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
while (__builtin_expect \
(atomic_compare_and_exchange_bool_acq (__atg16_memp, \
__atg16_old & __atg16_mask,\
-@@ -468,7 +468,7 @@
+@@ -467,7 +467,7 @@
__typeof (*(mem)) __atg17_mask = (mask); \
\
do \
@@ -125,7 +133,7 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
while (__builtin_expect \
(atomic_compare_and_exchange_bool_acq (__atg17_memp, \
__atg17_old | __atg17_mask, \
-@@ -484,7 +484,7 @@
+@@ -483,7 +483,7 @@
__typeof (*(mem)) __atg18_mask = (mask); \
\
do \
@@ -134,7 +142,7 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
while (__builtin_expect \
(catomic_compare_and_exchange_bool_acq (__atg18_memp, \
__atg18_old | __atg18_mask,\
-@@ -500,7 +500,7 @@
+@@ -499,7 +499,7 @@
__typeof (*(mem)) __atg19_mask = (mask); \
\
do \
@@ -143,9 +151,8 @@ diff -durN glibc-2.13.orig/include/atomic.h glibc-2.13/include/atomic.h
while (__builtin_expect \
(atomic_compare_and_exchange_bool_acq (__atg19_memp, \
__atg19_old | __atg19_mask,\
-diff -durN glibc-2.13.orig/nptl/Makefile glibc-2.13/nptl/Makefile
---- glibc-2.13.orig/nptl/Makefile 2008-11-12 14:38:23.000000000 +0100
-+++ glibc-2.13/nptl/Makefile 2009-11-13 00:50:26.000000000 +0100
+--- a/nptl/Makefile
++++ b/nptl/Makefile
@@ -266,9 +266,9 @@
# Files which must not be linked with libpthread.
tests-nolibpthread = tst-unload
@@ -159,7 +166,7 @@ diff -durN glibc-2.13.orig/nptl/Makefile glibc-2.13/nptl/Makefile
gen-as-const-headers = pthread-errnos.sym
-@@ -426,6 +426,35 @@
+@@ -421,6 +421,35 @@
CFLAGS-tst-cleanupx4.c += -fexceptions
CFLAGS-tst-oncex3.c += -fexceptions
CFLAGS-tst-oncex4.c += -fexceptions
@@ -195,10 +202,9 @@ diff -durN glibc-2.13.orig/nptl/Makefile glibc-2.13/nptl/Makefile
CFLAGS-tst-align.c += $(stack-align-test-flags)
CFLAGS-tst-align3.c += $(stack-align-test-flags)
CFLAGS-tst-initializers1.c = -W -Wall -Werror
-diff -durN glibc-2.13.orig/nptl/pthread_barrier_wait.c glibc-2.13/nptl/pthread_barrier_wait.c
---- glibc-2.13.orig/nptl/pthread_barrier_wait.c 2007-08-01 06:18:50.000000000 +0200
-+++ glibc-2.13/nptl/pthread_barrier_wait.c 2009-11-13 00:50:26.000000000 +0100
-@@ -64,7 +64,7 @@
+--- a/nptl/pthread_barrier_wait.c
++++ b/nptl/pthread_barrier_wait.c
+@@ -63,7 +63,7 @@
do
lll_futex_wait (&ibarrier->curr_event, event,
ibarrier->private ^ FUTEX_PRIVATE_FLAG);
@@ -207,10 +213,9 @@ diff -durN glibc-2.13.orig/nptl/pthread_barrier_wait.c glibc-2.13/nptl/pthread_b
}
/* Make sure the init_count is stored locally or in a register. */
-diff -durN glibc-2.13.orig/nptl/sysdeps/pthread/Makefile glibc-2.13/nptl/sysdeps/pthread/Makefile
---- glibc-2.13.orig/nptl/sysdeps/pthread/Makefile 2006-02-28 08:09:41.000000000 +0100
-+++ glibc-2.13/nptl/sysdeps/pthread/Makefile 2009-11-13 00:50:26.000000000 +0100
-@@ -33,7 +33,9 @@
+--- a/nptl/sysdeps/pthread/Makefile
++++ b/nptl/sysdeps/pthread/Makefile
+@@ -32,7 +32,9 @@
ifeq ($(have-forced-unwind),yes)
tests += tst-mqueue8x
@@ -220,10 +225,9 @@ diff -durN glibc-2.13.orig/nptl/sysdeps/pthread/Makefile glibc-2.13/nptl/sysdeps
endif
endif
-diff -durN glibc-2.13.orig/stdio-common/Makefile glibc-2.13/stdio-common/Makefile
---- glibc-2.13.orig/stdio-common/Makefile 2009-04-11 07:29:56.000000000 +0200
-+++ glibc-2.13/stdio-common/Makefile 2009-11-13 00:50:26.000000000 +0100
-@@ -82,7 +82,7 @@
+--- a/stdio-common/Makefile
++++ b/stdio-common/Makefile
+@@ -76,7 +76,7 @@
$(SHELL) -e tst-printf.sh $(common-objpfx) '$(run-program-prefix)'
endif
@@ -232,10 +236,9 @@ diff -durN glibc-2.13.orig/stdio-common/Makefile glibc-2.13/stdio-common/Makefil
CFLAGS-vfwprintf.c = -Wno-uninitialized
CFLAGS-tst-printf.c = -Wno-format
CFLAGS-tstdiomisc.c = -Wno-format
-diff -durN glibc-2.13.orig/sunrpc/clnt_udp.c glibc-2.13/sunrpc/clnt_udp.c
---- glibc-2.13.orig/sunrpc/clnt_udp.c 2008-07-26 10:42:44.000000000 +0200
-+++ glibc-2.13/sunrpc/clnt_udp.c 2009-11-13 00:50:26.000000000 +0100
-@@ -456,7 +456,7 @@
+--- a/sunrpc/clnt_udp.c
++++ b/sunrpc/clnt_udp.c
+@@ -462,7 +462,7 @@
while (inlen < 0 && errno == EINTR);
if (inlen < 0)
{
diff --git a/packages/glibc/2.16.0/0020-dl_execstack-PaX-support.patch b/packages/glibc/2.16.0/0020-dl_execstack-PaX-support.patch
new file mode 100644
index 0000000..cd60905
--- /dev/null
+++ b/packages/glibc/2.16.0/0020-dl_execstack-PaX-support.patch
@@ -0,0 +1,69 @@
+ With latest versions of glibc, a lot of apps failed on a PaX enabled
+ system with:
+ cannot enable executable stack as shared object requires: Permission denied
+
+ This is due to PaX 'exec-protecting' the stack, and ld.so then trying
+ to make the stack executable due to some libraries not containing the
+ PT_GNU_STACK section. Bug #32960. <azarah@gentoo.org> (12 Nov 2003).
+
+ Patch also NPTL. Bug #116086. <kevquinn@gentoo.org> (20 Dec 2005).
+
+---
+ nptl/allocatestack.c | 3 ++-
+ sysdeps/unix/sysv/linux/dl-execstack.c | 19 ++++++++++++++++---
+ 2 files changed, 18 insertions(+), 4 deletions(-)
+
+--- a/nptl/allocatestack.c
++++ b/nptl/allocatestack.c
+@@ -334,7 +334,8 @@
+ # error "Define either _STACK_GROWS_DOWN or _STACK_GROWS_UP"
+ #endif
+ if (mprotect (stack, len, PROT_READ | PROT_WRITE | PROT_EXEC) != 0)
+- return errno;
++ if (errno != EACCES) /* PAX is enabled */
++ return errno;
+
+ return 0;
+ }
+--- a/sysdeps/unix/sysv/linux/dl-execstack.c
++++ b/sysdeps/unix/sysv/linux/dl-execstack.c
+@@ -62,7 +62,10 @@
+ else
+ # endif
+ {
+- result = errno;
++ if (errno == EACCES) /* PAX is enabled */
++ result = 0;
++ else
++ result = errno;
+ goto out;
+ }
+ }
+@@ -88,7 +91,12 @@
+ page -= size;
+ else
+ {
+- if (errno != ENOMEM) /* Unexpected failure mode. */
++ if (errno == EACCES) /* PAX is enabled */
++ {
++ result = 0;
++ goto out;
++ }
++ else if (errno != ENOMEM) /* Unexpected failure mode. */
+ {
+ result = errno;
+ goto out;
+@@ -114,7 +122,12 @@
+ page += size;
+ else
+ {
+- if (errno != ENOMEM) /* Unexpected failure mode. */
++ if (errno == EACCES) /* PAX is enabled */
++ {
++ result = 0;
++ goto out;
++ }
++ else if (errno != ENOMEM) /* Unexpected failure mode. */
+ {
+ result = errno;
+ goto out;
diff --git a/packages/glibc/2.16.0/0021-pre20040117-pt_pax.patch b/packages/glibc/2.16.0/0021-pre20040117-pt_pax.patch
new file mode 100644
index 0000000..544b3f6
--- /dev/null
+++ b/packages/glibc/2.16.0/0021-pre20040117-pt_pax.patch
@@ -0,0 +1,35 @@
+
+
+---
+ elf/elf.h | 13 +++++++++++++
+ 1 file changed, 13 insertions(+)
+
+--- a/elf/elf.h
++++ b/elf/elf.h
+@@ -581,6 +581,7 @@
+ #define PT_GNU_EH_FRAME 0x6474e550 /* GCC .eh_frame_hdr segment */
+ #define PT_GNU_STACK 0x6474e551 /* Indicates stack executability */
+ #define PT_GNU_RELRO 0x6474e552 /* Read-only after relocation */
++#define PT_PAX_FLAGS 0x65041580 /* Indicates PaX flag markings */
+ #define PT_LOSUNW 0x6ffffffa
+ #define PT_SUNWBSS 0x6ffffffa /* Sun Specific segment */
+ #define PT_SUNWSTACK 0x6ffffffb /* Stack segment */
+@@ -594,6 +595,18 @@
+ #define PF_X (1 << 0) /* Segment is executable */
+ #define PF_W (1 << 1) /* Segment is writable */
+ #define PF_R (1 << 2) /* Segment is readable */
++#define PF_PAGEEXEC (1 << 4) /* Enable PAGEEXEC */
++#define PF_NOPAGEEXEC (1 << 5) /* Disable PAGEEXEC */
++#define PF_SEGMEXEC (1 << 6) /* Enable SEGMEXEC */
++#define PF_NOSEGMEXEC (1 << 7) /* Disable SEGMEXEC */
++#define PF_MPROTECT (1 << 8) /* Enable MPROTECT */
++#define PF_NOMPROTECT (1 << 9) /* Disable MPROTECT */
++#define PF_RANDEXEC (1 << 10) /* Enable RANDEXEC */
++#define PF_NORANDEXEC (1 << 11) /* Disable RANDEXEC */
++#define PF_EMUTRAMP (1 << 12) /* Enable EMUTRAMP */
++#define PF_NOEMUTRAMP (1 << 13) /* Disable EMUTRAMP */
++#define PF_RANDMMAP (1 << 14) /* Enable RANDMMAP */
++#define PF_NORANDMMAP (1 << 15) /* Disable RANDMMAP */
+ #define PF_MASKOS 0x0ff00000 /* OS-specific */
+ #define PF_MASKPROC 0xf0000000 /* Processor-specific */
+
diff --git a/packages/glibc/2.16.0/0022-tests-sandbox-libdl-paths.patch b/packages/glibc/2.16.0/0022-tests-sandbox-libdl-paths.patch
new file mode 100644
index 0000000..0c51c88
--- /dev/null
+++ b/packages/glibc/2.16.0/0022-tests-sandbox-libdl-paths.patch
@@ -0,0 +1,196 @@
+when glibc runs its tests, it does so by invoking the local library loader.
+in Gentoo, we build/run inside of our "sandbox" which itself is linked against
+libdl (so that it can load libraries and pull out symbols). the trouble
+is that when you upgrade from an older glibc to the new one, often times
+internal symbols change name or abi. this is normally OK as you cannot use
+libc.so from say version 2.3.6 but libpthread.so from say version 2.5, so
+we always say "keep all of the glibc libraries from the same build". but
+when glibc runs its tests, it uses dynamic paths to point to its new local
+copies of libraries. if the test doesnt use libdl, then glibc doesnt add
+its path, and when sandbox triggers the loading of libdl, glibc does so
+from the host system system. this gets us into the case of all libraries
+are from the locally compiled version of glibc except for libdl.so.
+
+Fix by Wormo
+
+http://bugs.gentoo.org/56898
+
+---
+ grp/tst_fgetgrent.sh | 3 ++-
+ iconvdata/run-iconv-test.sh | 2 +-
+ iconvdata/tst-table.sh | 5 ++++-
+ intl/tst-codeset.sh | 3 +++
+ intl/tst-gettext.sh | 5 ++++-
+ intl/tst-gettext2.sh | 5 ++++-
+ intl/tst-translit.sh | 5 ++++-
+ malloc/tst-mtrace.sh | 5 ++++-
+ nptl/tst-tls6.sh | 4 ++--
+ posix/globtest.sh | 2 +-
+ posix/tst-getconf.sh | 5 ++++-
+ posix/wordexp-tst.sh | 5 ++++-
+ 12 files changed, 37 insertions(+), 12 deletions(-)
+
+--- a/grp/tst_fgetgrent.sh
++++ b/grp/tst_fgetgrent.sh
+@@ -23,7 +23,8 @@
+ rtld_installed_name=$1; shift
+
+ testout=${common_objpfx}/grp/tst_fgetgrent.out
+-library_path=${common_objpfx}
++# make sure libdl is also in path in case sandbox is in use
++library_path=${common_objpfx}:${common_objpfx}/dlfcn
+
+ result=0
+
+--- a/iconvdata/run-iconv-test.sh
++++ b/iconvdata/run-iconv-test.sh
+@@ -33,7 +33,7 @@
+ export GCONV_PATH
+
+ # We have to have some directories in the library path.
+-LIBPATH=$codir:$codir/iconvdata
++LIBPATH=$codir:$codir/iconvdata:$codir/dlfcn
+
+ # How the start the iconv(1) program.
+ ICONV='$codir/elf/ld.so --library-path $LIBPATH --inhibit-rpath ${from}.so \
+--- a/iconvdata/tst-table.sh
++++ b/iconvdata/tst-table.sh
+@@ -58,8 +58,11 @@
+ irreversible=${charset}.irreversible
+ fi
+
++# make sure libdl is also in path in case sandbox is in use
++library_path=${common_objpfx}:${common_objpfx}/dlfcn
++
+ # iconv in one direction.
+-${common_objpfx}elf/ld.so --library-path $common_objpfx \
++${common_objpfx}elf/ld.so --library-path $library_path \
+ ${objpfx}tst-table-from ${charset} \
+ > ${objpfx}tst-${charset}.table
+
+--- a/intl/tst-codeset.sh
++++ b/intl/tst-codeset.sh
+@@ -36,6 +36,9 @@
+ LOCPATH=${common_objpfx}localedata
+ export LOCPATH
+
++# make sure libdl is also in path in case sandbox is in use
++library_path=${common_objpfx}:${common_objpfx}/dlfcn
++
+ ${common_objpfx}elf/ld.so --library-path $common_objpfx \
+ ${objpfx}tst-codeset > ${objpfx}tst-codeset.out
+
+--- a/intl/tst-gettext.sh
++++ b/intl/tst-gettext.sh
+@@ -50,9 +50,12 @@
+ LOCPATH=${common_objpfx}localedata
+ export LOCPATH
+
++# make sure libdl is also in path in case sandbox is in use
++library_path=${common_objpfx}:${common_objpfx}/dlfcn
++
+ # Now run the test.
+ MALLOC_TRACE=$malloc_trace LOCPATH=${objpfx}localedir:$LOCPATH \
+-${common_objpfx}elf/ld.so --library-path $common_objpfx \
++${common_objpfx}elf/ld.so --library-path $library_path \
+ ${objpfx}tst-gettext > ${objpfx}tst-gettext.out ${objpfx}domaindir
+
+ exit $?
+--- a/intl/tst-gettext2.sh
++++ b/intl/tst-gettext2.sh
+@@ -64,8 +64,11 @@
+ LOCPATH=${objpfx}domaindir
+ export LOCPATH
+
++# make sure libdl is also in path in case sandbox is in use
++library_path=${common_objpfx}:${common_objpfx}/dlfcn
++
+ # Now run the test.
+-${common_objpfx}elf/ld.so --library-path $common_objpfx \
++${common_objpfx}elf/ld.so --library-path $library_path \
+ ${objpfx}tst-gettext2 > ${objpfx}tst-gettext2.out ${objpfx}domaindir &&
+ cmp ${objpfx}tst-gettext2.out - <<EOF
+ String1 - Lang1: 1st string
+--- a/intl/tst-translit.sh
++++ b/intl/tst-translit.sh
+@@ -35,7 +35,10 @@
+ LOCPATH=${common_objpfx}localedata
+ export LOCPATH
+
+-${common_objpfx}elf/ld.so --library-path $common_objpfx \
++# make sure libdl is also in path in case sandbox is in use
++library_path=${common_objpfx}:${common_objpfx}/dlfcn
++
++${common_objpfx}elf/ld.so --library-path $library_path \
+ ${objpfx}tst-translit > ${objpfx}tst-translit.out ${objpfx}domaindir
+
+ exit $?
+--- a/malloc/tst-mtrace.sh
++++ b/malloc/tst-mtrace.sh
+@@ -23,9 +23,12 @@
+ status=0
+ trap "rm -f ${common_objpfx}malloc/tst-mtrace.leak; exit 1" 1 2 15
+
++# make sure libdl is also in path in case sandbox is in use
++library_path=${common_objpfx}:${common_objpfx}/dlfcn
++
+ MALLOC_TRACE=${common_objpfx}malloc/tst-mtrace.leak \
+ LOCPATH=${common_objpfx}localedata GCONV_PATH=${common_objpfx}iconvdata \
+-${common_objpfx}elf/ld.so --library-path $common_objpfx \
++${common_objpfx}elf/ld.so --library-path $library_path \
+ ${common_objpfx}malloc/tst-mtrace || status=1
+
+ if test $status -eq 0 && test -f ${common_objpfx}malloc/mtrace; then
+--- a/nptl/tst-tls6.sh
++++ b/nptl/tst-tls6.sh
+@@ -5,8 +5,8 @@
+ rtld_installed_name=$1; shift
+ logfile=$common_objpfx/nptl/tst-tls6.out
+
+-# We have to find libc and nptl
+-library_path=${common_objpfx}:${common_objpfx}nptl
++# We have to find libc and nptl (also libdl in case sandbox is in use)
++library_path=${common_objpfx}:${common_objpfx}nptl:${common_objpfx}/dlfcn
+ tst_tls5="${elf_objpfx}${rtld_installed_name} --library-path ${library_path} \
+ ${common_objpfx}/nptl/tst-tls5"
+
+--- a/posix/globtest.sh
++++ b/posix/globtest.sh
+@@ -18,7 +18,7 @@
+ esac
+
+ # We have to find the libc and the NSS modules.
+-library_path=${common_objpfx}:${common_objpfx}nss:${common_objpfx}nis:${common_objpfx}db2:${common_objpfx}hesiod
++library_path=${common_objpfx}:${common_objpfx}nss:${common_objpfx}nis:${common_objpfx}db2:${common_objpfx}hesiod:${common_objpfx}/dlfcn
+
+ # Since we use `sort' we must make sure to use the same locale everywhere.
+ LC_ALL=C
+--- a/posix/tst-getconf.sh
++++ b/posix/tst-getconf.sh
+@@ -10,7 +10,10 @@
+ else
+ rtld_installed_name=$1; shift
+ runit() {
+- ${elf_objpfx}${rtld_installed_name} --library-path ${common_objpfx} "$@"
++
++ # make sure libdl is also in path in case sandbox is in use
++ library_path=${common_objpfx}:${common_objpfx}/dlfcn
++ ${elf_objpfx}${rtld_installed_name} --library-path ${library_path} "$@"
+ }
+ fi
+
+--- a/posix/wordexp-tst.sh
++++ b/posix/wordexp-tst.sh
+@@ -19,8 +19,11 @@
+ "
+ export IFS
+
++# make sure libdl is also in path in case sandbox is in use
++library_path=${common_objpfx}:${common_objpfx}/dlfcn
++
+ failed=0
+-${elf_objpfx}${rtld_installed_name} --library-path ${common_objpfx} \
++${elf_objpfx}${rtld_installed_name} --library-path ${library_path} \
+ ${common_objpfx}posix/wordexp-test '$*' > ${testout}1
+ cat <<"EOF" | cmp - ${testout}1 >> $logfile || failed=1
+ wordexp returned 0
diff --git a/packages/glibc/2.16.0/0023-dont-build-timezone.patch b/packages/glibc/2.16.0/0023-dont-build-timezone.patch
new file mode 100644
index 0000000..dca2a27
--- /dev/null
+++ b/packages/glibc/2.16.0/0023-dont-build-timezone.patch
@@ -0,0 +1,17 @@
+timezone data has been split into the package sys-libs/timezone-data
+
+---
+ Makeconfig | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/Makeconfig
++++ b/Makeconfig
+@@ -926,7 +926,7 @@
+ stdlib stdio-common libio malloc string wcsmbs time dirent \
+ grp pwd posix io termios resource misc socket sysvipc gmon \
+ gnulib iconv iconvdata wctype manual shadow gshadow po argp \
+- crypt nss localedata timezone rt conform debug \
++ crypt nss localedata rt conform debug \
+ $(add-on-subdirs) $(dlfcn) $(binfmt-subdir)
+
+ ifndef avoid-generated
diff --git a/packages/glibc/2.16.0/0024-alpha-xstat.patch b/packages/glibc/2.16.0/0024-alpha-xstat.patch
new file mode 100644
index 0000000..a329214
--- /dev/null
+++ b/packages/glibc/2.16.0/0024-alpha-xstat.patch
@@ -0,0 +1,18 @@
+---
+ sysdeps/unix/sysv/linux/kernel-features.h | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
+@@ -285,6 +285,11 @@
+ # define __ASSUME_GETDENTS32_D_TYPE 1
+ #endif
+
++/* Starting with version 2.6.4, alpha stat64 syscalls are available. */
++#if __LINUX_KERNEL_VERSION >= 0x020604 && defined __alpha__
++# define __ASSUME_STAT64_SYSCALL 1
++#endif
++
+ /* Starting with version 2.5.3, the initial location returned by `brk'
+ after exec is always rounded up to the next page. */
+ #if __LINUX_KERNEL_VERSION >= 132355
diff --git a/packages/glibc/2.16.0/0025-alpha-creat.patch b/packages/glibc/2.16.0/0025-alpha-creat.patch
new file mode 100644
index 0000000..6ef5278
--- /dev/null
+++ b/packages/glibc/2.16.0/0025-alpha-creat.patch
@@ -0,0 +1,17 @@
+alpha does not have a __NR_creat
+
+http://bugs.gentoo.org/227275
+http://sourceware.org/bugzilla/show_bug.cgi?id=6650
+
+---
+ sysdeps/unix/sysv/linux/wordsize-64/creat64.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+--- a/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
++++ b/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
+@@ -1 +1,5 @@
+ /* Defined as alias for the syscall. */
++#include <sysdep.h>
++#ifndef __NR_creat
++#include "../../../../../io/creat64.c"
++#endif
diff --git a/packages/glibc/2.16.0/490-alpha_alpha-add-fdatasync-support.patch b/packages/glibc/2.16.0/0026-alpha_alpha-add-fdatasync-support.patch
index acf250d..159d8d0 100644
--- a/packages/glibc/2.16.0/490-alpha_alpha-add-fdatasync-support.patch
+++ b/packages/glibc/2.16.0/0026-alpha_alpha-add-fdatasync-support.patch
@@ -13,10 +13,9 @@
sysdeps/unix/sysv/linux/syscalls.list | 1
4 files changed, 76 insertions(+), 1 deletion(-)
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/Makefile glibc-2.13/sysdeps/unix/sysv/linux/Makefile
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/Makefile 2009-03-02 17:15:13.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/Makefile 2009-11-13 00:51:04.000000000 +0100
-@@ -21,6 +21,7 @@
+--- a/sysdeps/unix/sysv/linux/Makefile
++++ b/sysdeps/unix/sysv/linux/Makefile
+@@ -23,6 +23,7 @@
setfsuid setfsgid makedev epoll_pwait signalfd \
eventfd eventfd_read eventfd_write prlimit
@@ -24,9 +23,8 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/Makefile glibc-2.13/sysdeps/u
CFLAGS-gethostid.c = -fexceptions
CFLAGS-tst-writev.c += "-DARTIFICIAL_LIMIT=0x80000000-__getpagesize()"
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/fdatasync.c glibc-2.13/sysdeps/unix/sysv/linux/fdatasync.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/fdatasync.c 1970-01-01 01:00:00.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/fdatasync.c 2009-11-13 00:51:04.000000000 +0100
+--- /dev/null
++++ b/sysdeps/unix/sysv/linux/fdatasync.c
@@ -0,0 +1,69 @@
+/* fdatasync -- synchronize at least the data part of a file with
+ the underlying media. Linux version.
@@ -97,10 +95,9 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/fdatasync.c glibc-2.13/sysdep
+
+weak_alias (__fdatasync, fdatasync)
+
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:50:45.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h 2009-11-13 00:51:04.000000000 +0100
-@@ -459,6 +459,12 @@
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
+@@ -357,6 +357,12 @@
# define __ASSUME_FUTEX_LOCK_PI 1
#endif
@@ -113,10 +110,9 @@ diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/kernel-features.h glibc-2.13/
/* Support for utimensat syscall was added in 2.6.22, on SH
only after 2.6.22-rc1. */
#if __LINUX_KERNEL_VERSION >= 0x020616 \
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/syscalls.list glibc-2.13/sysdeps/unix/sysv/linux/syscalls.list
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/syscalls.list 2008-08-02 01:29:08.000000000 +0200
-+++ glibc-2.13/sysdeps/unix/sysv/linux/syscalls.list 2009-11-13 00:51:04.000000000 +0100
-@@ -11,7 +11,6 @@
+--- a/sysdeps/unix/sysv/linux/syscalls.list
++++ b/sysdeps/unix/sysv/linux/syscalls.list
+@@ -13,7 +13,6 @@
epoll_create1 EXTRA epoll_create1 i:i epoll_create1
epoll_ctl EXTRA epoll_ctl i:iiip epoll_ctl
epoll_wait EXTRA epoll_wait Ci:ipii epoll_wait
diff --git a/packages/glibc/2.16.0/500-fix-parsing-of-numeric-hosts-in-gethostbyname_r.patch b/packages/glibc/2.16.0/0027-fix-parsing-of-numeric-hosts-in-gethostbyname_r.patch
index 803ac6f..b366805 100644
--- a/packages/glibc/2.16.0/500-fix-parsing-of-numeric-hosts-in-gethostbyname_r.patch
+++ b/packages/glibc/2.16.0/0027-fix-parsing-of-numeric-hosts-in-gethostbyname_r.patch
@@ -14,7 +14,7 @@ Ported from master, fixes CVE-2015-0235.
--- a/nss/Makefile
+++ b/nss/Makefile
-@@ -38,7 +38,7 @@ install-bin := getent makedb
+@@ -38,7 +38,7 @@
makedb-modules = xmalloc hash-string
extra-objs += $(makedb-modules:=.o)
@@ -25,7 +25,7 @@ Ported from master, fixes CVE-2015-0235.
include ../Makeconfig
--- a/nss/digits_dots.c
+++ b/nss/digits_dots.c
-@@ -46,7 +46,10 @@ __nss_hostname_digits_dots (const char *
+@@ -46,7 +46,10 @@
{
if (h_errnop)
*h_errnop = NETDB_INTERNAL;
@@ -37,7 +37,7 @@ Ported from master, fixes CVE-2015-0235.
return -1;
}
-@@ -83,14 +86,16 @@ __nss_hostname_digits_dots (const char *
+@@ -83,14 +86,16 @@
}
size_needed = (sizeof (*host_addr)
@@ -56,7 +56,7 @@ Ported from master, fixes CVE-2015-0235.
__set_errno (ERANGE);
goto done;
}
-@@ -109,7 +114,7 @@ __nss_hostname_digits_dots (const char *
+@@ -109,7 +114,7 @@
*buffer_size = 0;
__set_errno (save);
if (h_errnop != NULL)
@@ -65,7 +65,7 @@ Ported from master, fixes CVE-2015-0235.
*result = NULL;
goto done;
}
-@@ -149,7 +154,9 @@ __nss_hostname_digits_dots (const char *
+@@ -149,7 +154,9 @@
if (! ok)
{
*h_errnop = HOST_NOT_FOUND;
@@ -76,7 +76,7 @@ Ported from master, fixes CVE-2015-0235.
*result = NULL;
goto done;
}
-@@ -190,7 +197,7 @@ __nss_hostname_digits_dots (const char *
+@@ -190,7 +197,7 @@
if (buffer_size == NULL)
*status = NSS_STATUS_SUCCESS;
else
@@ -85,7 +85,7 @@ Ported from master, fixes CVE-2015-0235.
goto done;
}
-@@ -201,15 +208,6 @@ __nss_hostname_digits_dots (const char *
+@@ -201,15 +208,6 @@
if ((isxdigit (name[0]) && strchr (name, ':') != NULL) || name[0] == ':')
{
@@ -101,7 +101,7 @@ Ported from master, fixes CVE-2015-0235.
switch (af)
{
default:
-@@ -225,7 +223,10 @@ __nss_hostname_digits_dots (const char *
+@@ -225,7 +223,10 @@
/* This is not possible. We cannot represent an IPv6 address
in an `struct in_addr' variable. */
*h_errnop = HOST_NOT_FOUND;
@@ -113,7 +113,7 @@ Ported from master, fixes CVE-2015-0235.
goto done;
case AF_INET6:
-@@ -233,42 +234,6 @@ __nss_hostname_digits_dots (const char *
+@@ -233,42 +234,6 @@
break;
}
@@ -156,7 +156,7 @@ Ported from master, fixes CVE-2015-0235.
for (cp = name;; ++cp)
{
if (!*cp)
-@@ -281,7 +246,9 @@ __nss_hostname_digits_dots (const char *
+@@ -281,7 +246,9 @@
if (inet_pton (AF_INET6, name, host_addr) <= 0)
{
*h_errnop = HOST_NOT_FOUND;
@@ -210,7 +210,7 @@ Ported from master, fixes CVE-2015-0235.
+#include "../test-skeleton.c"
--- a/nss/getXXbyYY_r.c
+++ b/nss/getXXbyYY_r.c
-@@ -179,6 +179,9 @@ INTERNAL (REENTRANT_NAME) (ADD_PARAMS, L
+@@ -179,6 +179,9 @@
case -1:
return errno;
case 1:
diff --git a/packages/glibc/2.16.0/0028-ppc-atomic.patch b/packages/glibc/2.16.0/0028-ppc-atomic.patch
new file mode 100644
index 0000000..5340937
--- /dev/null
+++ b/packages/glibc/2.16.0/0028-ppc-atomic.patch
@@ -0,0 +1,412 @@
+sniped from suse
+
+---
+ sysdeps/powerpc/bits/atomic.h | 66 ++++++++++-----------
+ sysdeps/powerpc/powerpc32/bits/atomic.h | 16 ++---
+ sysdeps/powerpc/powerpc64/bits/atomic.h | 98 ++++++++++++++++----------------
+ 3 files changed, 90 insertions(+), 90 deletions(-)
+
+--- a/sysdeps/powerpc/bits/atomic.h
++++ b/sysdeps/powerpc/bits/atomic.h
+@@ -84,14 +84,14 @@
+ __typeof (*(mem)) __tmp; \
+ __typeof (mem) __memp = (mem); \
+ __asm __volatile ( \
+- "1: lwarx %0,0,%1" MUTEX_HINT_ACQ "\n" \
++ "1: lwarx %0,%y1" MUTEX_HINT_ACQ "\n" \
+ " cmpw %0,%2\n" \
+ " bne 2f\n" \
+- " stwcx. %3,0,%1\n" \
++ " stwcx. %3,%y1\n" \
+ " bne- 1b\n" \
+ "2: " __ARCH_ACQ_INSTR \
+- : "=&r" (__tmp) \
+- : "b" (__memp), "r" (oldval), "r" (newval) \
++ : "=&r" (__tmp), "+Z" (*__memp) \
++ : "r" (oldval), "r" (newval) \
+ : "cr0", "memory"); \
+ __tmp; \
+ })
+@@ -101,14 +101,14 @@
+ __typeof (*(mem)) __tmp; \
+ __typeof (mem) __memp = (mem); \
+ __asm __volatile (__ARCH_REL_INSTR "\n" \
+- "1: lwarx %0,0,%1" MUTEX_HINT_REL "\n" \
++ "1: lwarx %0,%y1" MUTEX_HINT_REL "\n" \
+ " cmpw %0,%2\n" \
+ " bne 2f\n" \
+- " stwcx. %3,0,%1\n" \
++ " stwcx. %3,%y1\n" \
+ " bne- 1b\n" \
+ "2: " \
+- : "=&r" (__tmp) \
+- : "b" (__memp), "r" (oldval), "r" (newval) \
++ : "=&r" (__tmp), "+Z" (__memp) \
++ : "r" (oldval), "r" (newval) \
+ : "cr0", "memory"); \
+ __tmp; \
+ })
+@@ -117,12 +117,12 @@
+ ({ \
+ __typeof (*mem) __val; \
+ __asm __volatile ( \
+- "1: lwarx %0,0,%2" MUTEX_HINT_ACQ "\n" \
+- " stwcx. %3,0,%2\n" \
++ "1: lwarx %0,%y1" MUTEX_HINT_ACQ "\n" \
++ " stwcx. %2,%y1\n" \
+ " bne- 1b\n" \
+ " " __ARCH_ACQ_INSTR \
+- : "=&r" (__val), "=m" (*mem) \
+- : "b" (mem), "r" (value), "m" (*mem) \
++ : "=&r" (__val), "+Z" (*mem) \
++ : "r" (value) \
+ : "cr0", "memory"); \
+ __val; \
+ })
+@@ -131,11 +131,11 @@
+ ({ \
+ __typeof (*mem) __val; \
+ __asm __volatile (__ARCH_REL_INSTR "\n" \
+- "1: lwarx %0,0,%2" MUTEX_HINT_REL "\n" \
+- " stwcx. %3,0,%2\n" \
++ "1: lwarx %0,%y1" MUTEX_HINT_REL "\n" \
++ " stwcx. %2,%y1\n" \
+ " bne- 1b" \
+- : "=&r" (__val), "=m" (*mem) \
+- : "b" (mem), "r" (value), "m" (*mem) \
++ : "=&r" (__val), "+Z" (*mem) \
++ : "r" (value) \
+ : "cr0", "memory"); \
+ __val; \
+ })
+@@ -143,12 +143,12 @@
+ #define __arch_atomic_exchange_and_add_32(mem, value) \
+ ({ \
+ __typeof (*mem) __val, __tmp; \
+- __asm __volatile ("1: lwarx %0,0,%3\n" \
+- " add %1,%0,%4\n" \
+- " stwcx. %1,0,%3\n" \
++ __asm __volatile ("1: lwarx %0,%y2\n" \
++ " add %1,%0,%3\n" \
++ " stwcx. %1,%y2\n" \
+ " bne- 1b" \
+- : "=&b" (__val), "=&r" (__tmp), "=m" (*mem) \
+- : "b" (mem), "r" (value), "m" (*mem) \
++ : "=&b" (__val), "=&r" (__tmp), "+Z" (*mem) \
++ : "r" (value) \
+ : "cr0", "memory"); \
+ __val; \
+ })
+@@ -156,12 +156,12 @@
+ #define __arch_atomic_increment_val_32(mem) \
+ ({ \
+ __typeof (*(mem)) __val; \
+- __asm __volatile ("1: lwarx %0,0,%2\n" \
++ __asm __volatile ("1: lwarx %0,%y1\n" \
+ " addi %0,%0,1\n" \
+- " stwcx. %0,0,%2\n" \
++ " stwcx. %0,%y1\n" \
+ " bne- 1b" \
+- : "=&b" (__val), "=m" (*mem) \
+- : "b" (mem), "m" (*mem) \
++ : "=&b" (__val), "+Z" (*mem) \
++ : \
+ : "cr0", "memory"); \
+ __val; \
+ })
+@@ -169,27 +169,27 @@
+ #define __arch_atomic_decrement_val_32(mem) \
+ ({ \
+ __typeof (*(mem)) __val; \
+- __asm __volatile ("1: lwarx %0,0,%2\n" \
++ __asm __volatile ("1: lwarx %0,%y1\n" \
+ " subi %0,%0,1\n" \
+- " stwcx. %0,0,%2\n" \
++ " stwcx. %0,%y1\n" \
+ " bne- 1b" \
+- : "=&b" (__val), "=m" (*mem) \
+- : "b" (mem), "m" (*mem) \
++ : "=&b" (__val), "+Z" (*mem) \
++ : \
+ : "cr0", "memory"); \
+ __val; \
+ })
+
+ #define __arch_atomic_decrement_if_positive_32(mem) \
+ ({ int __val, __tmp; \
+- __asm __volatile ("1: lwarx %0,0,%3\n" \
++ __asm __volatile ("1: lwarx %0,%y2\n" \
+ " cmpwi 0,%0,0\n" \
+ " addi %1,%0,-1\n" \
+ " ble 2f\n" \
+- " stwcx. %1,0,%3\n" \
++ " stwcx. %1,%y2\n" \
+ " bne- 1b\n" \
+ "2: " __ARCH_ACQ_INSTR \
+- : "=&b" (__val), "=&r" (__tmp), "=m" (*mem) \
+- : "b" (mem), "m" (*mem) \
++ : "=&b" (__val), "=&r" (__tmp), "+Z" (*mem) \
++ : \
+ : "cr0", "memory"); \
+ __val; \
+ })
+--- a/sysdeps/powerpc/powerpc32/bits/atomic.h
++++ b/sysdeps/powerpc/powerpc32/bits/atomic.h
+@@ -43,14 +43,14 @@
+ ({ \
+ unsigned int __tmp; \
+ __asm __volatile ( \
+- "1: lwarx %0,0,%1" MUTEX_HINT_ACQ "\n" \
++ "1: lwarx %0,%y1" MUTEX_HINT_ACQ "\n" \
+ " subf. %0,%2,%0\n" \
+ " bne 2f\n" \
+- " stwcx. %3,0,%1\n" \
++ " stwcx. %3,%y1\n" \
+ " bne- 1b\n" \
+ "2: " __ARCH_ACQ_INSTR \
+- : "=&r" (__tmp) \
+- : "b" (mem), "r" (oldval), "r" (newval) \
++ : "=&r" (__tmp), "+Z" (*(mem)) \
++ : "r" (oldval), "r" (newval) \
+ : "cr0", "memory"); \
+ __tmp != 0; \
+ })
+@@ -59,14 +59,14 @@
+ ({ \
+ unsigned int __tmp; \
+ __asm __volatile (__ARCH_REL_INSTR "\n" \
+- "1: lwarx %0,0,%1" MUTEX_HINT_REL "\n" \
++ "1: lwarx %0,%y1" MUTEX_HINT_REL "\n" \
+ " subf. %0,%2,%0\n" \
+ " bne 2f\n" \
+- " stwcx. %3,0,%1\n" \
++ " stwcx. %3,%y1\n" \
+ " bne- 1b\n" \
+ "2: " \
+- : "=&r" (__tmp) \
+- : "b" (mem), "r" (oldval), "r" (newval) \
++ : "=&r" (__tmp), "+Z" (*(mem)) \
++ : "r" (oldval), "r" (newval) \
+ : "cr0", "memory"); \
+ __tmp != 0; \
+ })
+--- a/sysdeps/powerpc/powerpc64/bits/atomic.h
++++ b/sysdeps/powerpc/powerpc64/bits/atomic.h
+@@ -43,14 +43,14 @@
+ ({ \
+ unsigned int __tmp, __tmp2; \
+ __asm __volatile (" clrldi %1,%1,32\n" \
+- "1: lwarx %0,0,%2" MUTEX_HINT_ACQ "\n" \
++ "1: lwarx %0,%y2" MUTEX_HINT_ACQ "\n" \
+ " subf. %0,%1,%0\n" \
+ " bne 2f\n" \
+- " stwcx. %4,0,%2\n" \
++ " stwcx. %4,%y2\n" \
+ " bne- 1b\n" \
+ "2: " __ARCH_ACQ_INSTR \
+- : "=&r" (__tmp), "=r" (__tmp2) \
+- : "b" (mem), "1" (oldval), "r" (newval) \
++ : "=&r" (__tmp), "=r" (__tmp2), "+Z" (*(mem)) \
++ : "1" (oldval), "r" (newval) \
+ : "cr0", "memory"); \
+ __tmp != 0; \
+ })
+@@ -60,14 +60,14 @@
+ unsigned int __tmp, __tmp2; \
+ __asm __volatile (__ARCH_REL_INSTR "\n" \
+ " clrldi %1,%1,32\n" \
+- "1: lwarx %0,0,%2" MUTEX_HINT_REL "\n" \
++ "1: lwarx %0,%y2" MUTEX_HINT_REL "\n" \
+ " subf. %0,%1,%0\n" \
+ " bne 2f\n" \
+- " stwcx. %4,0,%2\n" \
++ " stwcx. %4,%y2\n" \
+ " bne- 1b\n" \
+ "2: " \
+- : "=&r" (__tmp), "=r" (__tmp2) \
+- : "b" (mem), "1" (oldval), "r" (newval) \
++ : "=&r" (__tmp), "=r" (__tmp2), "+Z" (*(mem)) \
++ : "1" (oldval), "r" (newval) \
+ : "cr0", "memory"); \
+ __tmp != 0; \
+ })
+@@ -81,14 +81,14 @@
+ ({ \
+ unsigned long __tmp; \
+ __asm __volatile ( \
+- "1: ldarx %0,0,%1" MUTEX_HINT_ACQ "\n" \
++ "1: ldarx %0,%y1" MUTEX_HINT_ACQ "\n" \
+ " subf. %0,%2,%0\n" \
+ " bne 2f\n" \
+- " stdcx. %3,0,%1\n" \
++ " stdcx. %3,%y1\n" \
+ " bne- 1b\n" \
+ "2: " __ARCH_ACQ_INSTR \
+- : "=&r" (__tmp) \
+- : "b" (mem), "r" (oldval), "r" (newval) \
++ : "=&r" (__tmp), "+Z" (*(mem)) \
++ : "r" (oldval), "r" (newval) \
+ : "cr0", "memory"); \
+ __tmp != 0; \
+ })
+@@ -97,14 +97,14 @@
+ ({ \
+ unsigned long __tmp; \
+ __asm __volatile (__ARCH_REL_INSTR "\n" \
+- "1: ldarx %0,0,%2" MUTEX_HINT_REL "\n" \
++ "1: ldarx %0,%y1" MUTEX_HINT_REL "\n" \
+ " subf. %0,%2,%0\n" \
+ " bne 2f\n" \
+- " stdcx. %3,0,%1\n" \
++ " stdcx. %3,%y1\n" \
+ " bne- 1b\n" \
+ "2: " \
+- : "=&r" (__tmp) \
+- : "b" (mem), "r" (oldval), "r" (newval) \
++ : "=&r" (__tmp), "+Z" (*(mem)) \
++ : "r" (oldval), "r" (newval) \
+ : "cr0", "memory"); \
+ __tmp != 0; \
+ })
+@@ -114,14 +114,14 @@
+ __typeof (*(mem)) __tmp; \
+ __typeof (mem) __memp = (mem); \
+ __asm __volatile ( \
+- "1: ldarx %0,0,%1" MUTEX_HINT_ACQ "\n" \
++ "1: ldarx %0,%y1" MUTEX_HINT_ACQ "\n" \
+ " cmpd %0,%2\n" \
+ " bne 2f\n" \
+- " stdcx. %3,0,%1\n" \
++ " stdcx. %3,%y1\n" \
+ " bne- 1b\n" \
+ "2: " __ARCH_ACQ_INSTR \
+- : "=&r" (__tmp) \
+- : "b" (__memp), "r" (oldval), "r" (newval) \
++ : "=&r" (__tmp), "+Z" (*__memp) \
++ : "r" (oldval), "r" (newval) \
+ : "cr0", "memory"); \
+ __tmp; \
+ })
+@@ -131,14 +131,14 @@
+ __typeof (*(mem)) __tmp; \
+ __typeof (mem) __memp = (mem); \
+ __asm __volatile (__ARCH_REL_INSTR "\n" \
+- "1: ldarx %0,0,%1" MUTEX_HINT_REL "\n" \
++ "1: ldarx %0,%y1" MUTEX_HINT_REL "\n" \
+ " cmpd %0,%2\n" \
+ " bne 2f\n" \
+- " stdcx. %3,0,%1\n" \
++ " stdcx. %3,%y1\n" \
+ " bne- 1b\n" \
+ "2: " \
+- : "=&r" (__tmp) \
+- : "b" (__memp), "r" (oldval), "r" (newval) \
++ : "=&r" (__tmp), "+Z" (*__memp) \
++ : "r" (oldval), "r" (newval) \
+ : "cr0", "memory"); \
+ __tmp; \
+ })
+@@ -147,12 +147,12 @@
+ ({ \
+ __typeof (*mem) __val; \
+ __asm __volatile (__ARCH_REL_INSTR "\n" \
+- "1: ldarx %0,0,%2" MUTEX_HINT_ACQ "\n" \
+- " stdcx. %3,0,%2\n" \
++ "1: ldarx %0,%y1" MUTEX_HINT_ACQ "\n" \
++ " stdcx. %2,%y1\n" \
+ " bne- 1b\n" \
+ " " __ARCH_ACQ_INSTR \
+- : "=&r" (__val), "=m" (*mem) \
+- : "b" (mem), "r" (value), "m" (*mem) \
++ : "=&r" (__val), "+Z" (*(mem)) \
++ : "r" (value) \
+ : "cr0", "memory"); \
+ __val; \
+ })
+@@ -161,11 +161,11 @@
+ ({ \
+ __typeof (*mem) __val; \
+ __asm __volatile (__ARCH_REL_INSTR "\n" \
+- "1: ldarx %0,0,%2" MUTEX_HINT_REL "\n" \
+- " stdcx. %3,0,%2\n" \
++ "1: ldarx %0,%y1" MUTEX_HINT_REL "\n" \
++ " stdcx. %2,%y1\n" \
+ " bne- 1b" \
+- : "=&r" (__val), "=m" (*mem) \
+- : "b" (mem), "r" (value), "m" (*mem) \
++ : "=&r" (__val), "+Z" (*(mem)) \
++ : "r" (value) \
+ : "cr0", "memory"); \
+ __val; \
+ })
+@@ -173,12 +173,12 @@
+ #define __arch_atomic_exchange_and_add_64(mem, value) \
+ ({ \
+ __typeof (*mem) __val, __tmp; \
+- __asm __volatile ("1: ldarx %0,0,%3\n" \
+- " add %1,%0,%4\n" \
+- " stdcx. %1,0,%3\n" \
++ __asm __volatile ("1: ldarx %0,%y2\n" \
++ " add %1,%0,%3\n" \
++ " stdcx. %1,%y2\n" \
+ " bne- 1b" \
+- : "=&b" (__val), "=&r" (__tmp), "=m" (*mem) \
+- : "b" (mem), "r" (value), "m" (*mem) \
++ : "=&b" (__val), "=&r" (__tmp), "+Z" (*(mem)) \
++ : "r" (value) \
+ : "cr0", "memory"); \
+ __val; \
+ })
+@@ -186,12 +186,12 @@
+ #define __arch_atomic_increment_val_64(mem) \
+ ({ \
+ __typeof (*(mem)) __val; \
+- __asm __volatile ("1: ldarx %0,0,%2\n" \
++ __asm __volatile ("1: ldarx %0,%y1\n" \
+ " addi %0,%0,1\n" \
+- " stdcx. %0,0,%2\n" \
++ " stdcx. %0,%y1\n" \
+ " bne- 1b" \
+- : "=&b" (__val), "=m" (*mem) \
+- : "b" (mem), "m" (*mem) \
++ : "=&b" (__val), "+Z" (*(mem)) \
++ : \
+ : "cr0", "memory"); \
+ __val; \
+ })
+@@ -199,27 +199,27 @@
+ #define __arch_atomic_decrement_val_64(mem) \
+ ({ \
+ __typeof (*(mem)) __val; \
+- __asm __volatile ("1: ldarx %0,0,%2\n" \
++ __asm __volatile ("1: ldarx %0,%y1\n" \
+ " subi %0,%0,1\n" \
+- " stdcx. %0,0,%2\n" \
++ " stdcx. %0,%y1\n" \
+ " bne- 1b" \
+- : "=&b" (__val), "=m" (*mem) \
+- : "b" (mem), "m" (*mem) \
++ : "=&b" (__val), "+Z" (*(mem)) \
++ : \
+ : "cr0", "memory"); \
+ __val; \
+ })
+
+ #define __arch_atomic_decrement_if_positive_64(mem) \
+ ({ int __val, __tmp; \
+- __asm __volatile ("1: ldarx %0,0,%3\n" \
++ __asm __volatile ("1: ldarx %0,%y2\n" \
+ " cmpdi 0,%0,0\n" \
+ " addi %1,%0,-1\n" \
+ " ble 2f\n" \
+- " stdcx. %1,0,%3\n" \
++ " stdcx. %1,%y2\n" \
+ " bne- 1b\n" \
+ "2: " __ARCH_ACQ_INSTR \
+- : "=&b" (__val), "=&r" (__tmp), "=m" (*mem) \
+- : "b" (mem), "m" (*mem) \
++ : "=&b" (__val), "=&r" (__tmp), "+Z" (*(mem)) \
++ : \
+ : "cr0", "memory"); \
+ __val; \
+ })
diff --git a/packages/glibc/2.16.0/0029-mips_shn_undef-hack.patch b/packages/glibc/2.16.0/0029-mips_shn_undef-hack.patch
new file mode 100644
index 0000000..5b82f13
--- /dev/null
+++ b/packages/glibc/2.16.0/0029-mips_shn_undef-hack.patch
@@ -0,0 +1,19 @@
+---
+ elf/dl-lookup.c | 6 ++++++
+ 1 file changed, 6 insertions(+)
+
+--- a/elf/dl-lookup.c
++++ b/elf/dl-lookup.c
+@@ -299,6 +299,12 @@
+ /* FALLTHROUGH */
+ case STB_GLOBAL:
+ success:
++#ifdef __mips__
++ /* HACK: MIPS marks its lazy evaluation stubs with SHN_UNDEF
++ symbols, we skip them. */
++ if (sym->st_shndx == SHN_UNDEF)
++ break;
++#endif
+ /* Global definition. Just what we need. */
+ result->s = sym;
+ result->m = (struct link_map *) map;
diff --git a/packages/glibc/2.16.0/0030-alpha-atfcts.patch b/packages/glibc/2.16.0/0030-alpha-atfcts.patch
new file mode 100644
index 0000000..5f138a9
--- /dev/null
+++ b/packages/glibc/2.16.0/0030-alpha-atfcts.patch
@@ -0,0 +1,16 @@
+---
+ sysdeps/unix/sysv/linux/kernel-features.h | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+--- a/sysdeps/unix/sysv/linux/kernel-features.h
++++ b/sysdeps/unix/sysv/linux/kernel-features.h
+@@ -335,7 +335,8 @@
+ the code. On PPC they were introduced in 2.6.17-rc1,
+ on SH in 2.6.19-rc1. */
+ #if __LINUX_KERNEL_VERSION >= 0x020611 \
+- && (!defined __sh__ || __LINUX_KERNEL_VERSION >= 0x020613)
++ && (!defined __sh__ || __LINUX_KERNEL_VERSION >= 0x020613) \
++ && (!defined __alpha__)
+ # define __ASSUME_ATFCTS 1
+ #endif
+
diff --git a/packages/glibc/2.16.0/0031-syslog.patch b/packages/glibc/2.16.0/0031-syslog.patch
new file mode 100644
index 0000000..cd3c426
--- /dev/null
+++ b/packages/glibc/2.16.0/0031-syslog.patch
@@ -0,0 +1,15 @@
+---
+ misc/syslog.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/misc/syslog.c
++++ b/misc/syslog.c
+@@ -150,7 +150,7 @@
+ #define INTERNALLOG LOG_ERR|LOG_CONS|LOG_PERROR|LOG_PID
+ /* Check for invalid bits. */
+ if (pri & ~(LOG_PRIMASK|LOG_FACMASK)) {
+- syslog(INTERNALLOG,
++ __syslog(INTERNALLOG,
+ "syslog: unknown facility/priority: %x", pri);
+ pri &= LOG_PRIMASK|LOG_FACMASK;
+ }
diff --git a/packages/glibc/2.16.0/0032-debug-readlink_chk-readklinkat_chk.patch b/packages/glibc/2.16.0/0032-debug-readlink_chk-readklinkat_chk.patch
new file mode 100644
index 0000000..44d596a
--- /dev/null
+++ b/packages/glibc/2.16.0/0032-debug-readlink_chk-readklinkat_chk.patch
@@ -0,0 +1,27 @@
+---
+ debug/readlink_chk.c | 2 +-
+ debug/readlinkat_chk.c | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+--- a/debug/readlink_chk.c
++++ b/debug/readlink_chk.c
+@@ -24,7 +24,7 @@
+
+
+ ssize_t
+-__readlink_chk (const char *path, void *buf, size_t len, size_t buflen)
++__readlink_chk (const char *path, char *buf, size_t len, size_t buflen)
+ {
+ if (len > buflen)
+ __chk_fail ();
+--- a/debug/readlinkat_chk.c
++++ b/debug/readlinkat_chk.c
+@@ -20,7 +20,7 @@
+
+
+ ssize_t
+-__readlinkat_chk (int fd, const char *path, void *buf, size_t len,
++__readlinkat_chk (int fd, const char *path, char *buf, size_t len,
+ size_t buflen)
+ {
+ if (len > buflen)
diff --git a/packages/glibc/2.16.0/0033-fix-rpc_parse-format.patch b/packages/glibc/2.16.0/0033-fix-rpc_parse-format.patch
new file mode 100644
index 0000000..341d541
--- /dev/null
+++ b/packages/glibc/2.16.0/0033-fix-rpc_parse-format.patch
@@ -0,0 +1,62 @@
+commit 5874510faaf3cbd0bb112aaacab9f225002beed1
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Tue Nov 8 23:44:51 2016 +0000
+
+ Fix rpcgen buffer overrun (bug 20790).
+
+ Building with GCC 7 produces an error building rpcgen:
+
+ rpc_parse.c: In function 'get_prog_declaration':
+ rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ~~~~^
+ rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+ That buffer overrun is for the case where the .x file declares a
+ program with a million arguments. The strcpy two lines above can
+ generate a buffer overrun much more simply for a long argument name.
+
+ The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
+ provides a bound on the buffer size needed, so this patch just changes
+ the buffer size to MAXLINESIZE to avoid both possible buffer
+ overruns. A testcase is added that rpcgen does not crash with a
+ 500-character argument name, where it previously crashed.
+
+ It would not at all surprise me if there are many other ways of
+ crashing rpcgen with either valid or invalid input; fuzz testing would
+ likely find various such bugs, though I don't think they are that
+ important to fix (rpcgen is not that likely to be used with untrusted
+ .x files as input). (As well as fuzz-findable bugs there are probably
+ also issues when various int variables get overflowed on very large
+ input.) The test infrastructure for rpcgen-not-crashing tests would
+ need extending if tests are to be added for cases where rpcgen should
+ produce an error, as opposed to cases where it should succeed.
+
+ Tested for x86_64 and x86.
+
+ [BZ #20790]
+ * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
+ to MAXLINESIZE.
+ * sunrpc/bug20790.x: New file.
+ * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
+ variable.
+ [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
+ [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
+
+---
+ sunrpc/rpc_parse.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/sunrpc/rpc_parse.c
++++ b/sunrpc/rpc_parse.c
+@@ -521,7 +521,7 @@
+ get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
+ {
+ token tok;
+- char name[10]; /* argument name */
++ char name[MAXLINESIZE]; /* argument name */
+
+ if (dkind == DEF_PROGRAM)
+ {
diff --git a/packages/glibc/2.16.0/0034-nis-bogus-conditional.patch b/packages/glibc/2.16.0/0034-nis-bogus-conditional.patch
new file mode 100644
index 0000000..b8b806c
--- /dev/null
+++ b/packages/glibc/2.16.0/0034-nis-bogus-conditional.patch
@@ -0,0 +1,64 @@
+commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Wed Dec 21 23:44:01 2016 +0000
+
+ Fix nss_nisplus build with mainline GCC (bug 20978).
+
+ glibc build with current mainline GCC fails because
+ nis/nss_nisplus/nisplus-alias.c contains code
+
+ if (name != NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
+ }
+
+ char buf[strlen (name) + 9 + tablename_len];
+
+ producing an error about strlen being called on a pointer that is
+ always NULL (and a subsequent use of that pointer with a %s format in
+ snprintf).
+
+ As Andreas noted, the bogus conditional comes from a 1997 change:
+
+ - if (name == NULL || strlen(name) > 8)
+ - return NSS_STATUS_NOTFOUND;
+ - else
+ + if (name != NULL || strlen(name) <= 8)
+
+ So the intention is clearly to return an error for NULL name.
+
+ This patch duly inverts the sense of the conditional. It fixes the
+ build with GCC mainline, and passes usual glibc testsuite testing for
+ x86_64. However, I have not tried any actual substantive nisplus
+ testing, do not have an environment for such testing, and do not know
+ whether it is possible that strlen (name) or tablename_len might be
+ large so that the VLA for buf is actually a security issue. However,
+ if it is a security issue, there are plenty of other similar instances
+ in the nisplus code (that haven't been hidden by a bogus comparison
+ with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
+ string passed to nis_list, so a local fix in the caller wouldn't
+ suffice anyway (see bug 20987). (Calls to strdupa and other such
+ macros that use alloca must be considered equally questionable
+ regarding stack overflow issues as direct calls to alloca and VLA
+ declarations.)
+
+ [BZ #20978]
+ * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
+ Compare name == NULL, not name != NULL.
+
+---
+ nis/nss_nisplus/nisplus-alias.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/nis/nss_nisplus/nisplus-alias.c
++++ b/nis/nss_nisplus/nisplus-alias.c
+@@ -292,7 +292,7 @@
+ return status;
+ }
+
+- if (name != NULL)
++ if (name == NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.16.0/0035-obstack-common.patch b/packages/glibc/2.16.0/0035-obstack-common.patch
new file mode 100644
index 0000000..ad1f8eb
--- /dev/null
+++ b/packages/glibc/2.16.0/0035-obstack-common.patch
@@ -0,0 +1,32 @@
+commit 39b1f6172a2f9ddc74a8f82d6e84dd13b22dbaf2
+Author: Peter Collingbourne <pcc@google.com>
+Date: Wed May 15 20:28:08 2013 +0200
+
+ Move _obstack_compat out of common
+
+ it is impossible to create an alias of a common symbol (as
+ compat_symbol does), because common symbols do not have a section or
+ an offset until linked. GNU as tolerates aliases of common symbols by
+ simply creating another common symbol, but other assemblers (notably
+ LLVM's integrated assembler) are less tolerant.
+
+ 2013-05-15 Peter Collingbourne <pcc@google.com>
+
+ * malloc/obstack.c (_obstack_compat): Add initializer.
+ -
+
+---
+ malloc/obstack.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/malloc/obstack.c
++++ b/malloc/obstack.c
+@@ -116,7 +116,7 @@
+ /* A looong time ago (before 1994, anyway; we're not sure) this global variable
+ was used by non-GNU-C macros to avoid multiple evaluation. The GNU C
+ library still exports it because somebody might use it. */
+-struct obstack *_obstack_compat;
++struct obstack *_obstack_compat = 0;
+ compat_symbol (libc, _obstack_compat, _obstack, GLIBC_2_0);
+ # endif
+ # endif
diff --git a/packages/glibc/2.16.0/999-new-tools.patch b/packages/glibc/2.16.0/0036-new-tools.patch
index e753365..8805a3e 100644
--- a/packages/glibc/2.16.0/999-new-tools.patch
+++ b/packages/glibc/2.16.0/0036-new-tools.patch
@@ -1,7 +1,11 @@
-diff -urpN glibc-2.16.0.orig/configure glibc-2.16.0/configure
---- glibc-2.16.0.orig/configure 2012-06-30 12:12:34.000000000 -0700
-+++ glibc-2.16.0/configure 2017-02-08 00:39:03.778150878 -0800
-@@ -4845,7 +4845,7 @@ $as_echo_n "checking version of $MAKE...
+---
+ configure | 4 ++--
+ configure.in | 2 +-
+ 2 files changed, 3 insertions(+), 3 deletions(-)
+
+--- a/configure
++++ b/configure
+@@ -4845,7 +4845,7 @@
ac_prog_version=`$MAKE --version 2>&1 | sed -n 's/^.*GNU Make[^0-9]*\([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -10,7 +14,7 @@ diff -urpN glibc-2.16.0.orig/configure glibc-2.16.0/configure
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-@@ -5032,7 +5032,7 @@ else
+@@ -5032,7 +5032,7 @@
# Found it, now check the version.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking version of $SED" >&5
$as_echo_n "checking version of $SED... " >&6; }
@@ -19,10 +23,9 @@ diff -urpN glibc-2.16.0.orig/configure glibc-2.16.0/configure
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
3.0[2-9]*|3.[1-9]*|[4-9]*)
-diff -urpN glibc-2.16.0.orig/configure.in glibc-2.16.0/configure.in
---- glibc-2.16.0.orig/configure.in 2012-06-30 12:12:34.000000000 -0700
-+++ glibc-2.16.0/configure.in 2017-02-08 00:14:07.996446792 -0800
-@@ -940,7 +940,7 @@ AC_CHECK_PROG_VER(CC, ${ac_tool_prefix}g
+--- a/configure.in
++++ b/configure.in
+@@ -940,7 +940,7 @@
critic_missing="$critic_missing gcc")
AC_CHECK_PROG_VER(MAKE, gnumake gmake make, --version,
[GNU Make[^0-9]*\([0-9][0-9.]*\)],
diff --git a/packages/glibc/2.16.0/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.16.0/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
deleted file mode 100644
index 6fd663a..0000000
--- a/packages/glibc/2.16.0/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
-From: Yvan Roux <yvan.roux@linaro.org>
-Date: Fri, 15 Apr 2016 13:29:26 +0200
-Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
- -Wparentheses
-
----
- ChangeLog | 5 +++++
- nis/nis_call.c | 20 +++++++++++---------
- stdlib/setenv.c | 26 ++++++++++++++------------
- 3 files changed, 30 insertions(+), 21 deletions(-)
-
-diff --git a/nis/nis_call.c b/nis/nis_call.c
-index 3fa37e4..cb7839a 100644
---- a/nis/nis_call.c
-+++ b/nis/nis_call.c
-@@ -680,16 +680,18 @@ nis_server_cache_add (const_nis_name name, int search_parent,
- /* Choose which entry should be evicted from the cache. */
- loc = &nis_server_cache[0];
- if (*loc != NULL)
-- for (i = 1; i < 16; ++i)
-- if (nis_server_cache[i] == NULL)
-- {
-+ {
-+ for (i = 1; i < 16; ++i)
-+ if (nis_server_cache[i] == NULL)
-+ {
-+ loc = &nis_server_cache[i];
-+ break;
-+ }
-+ else if ((*loc)->uses > nis_server_cache[i]->uses
-+ || ((*loc)->uses == nis_server_cache[i]->uses
-+ && (*loc)->expires > nis_server_cache[i]->expires))
- loc = &nis_server_cache[i];
-- break;
-- }
-- else if ((*loc)->uses > nis_server_cache[i]->uses
-- || ((*loc)->uses == nis_server_cache[i]->uses
-- && (*loc)->expires > nis_server_cache[i]->expires))
-- loc = &nis_server_cache[i];
-+ }
- old = *loc;
- *loc = new;
-
-diff --git a/stdlib/setenv.c b/stdlib/setenv.c
-index da61ee0..e66045f 100644
---- a/stdlib/setenv.c
-+++ b/stdlib/setenv.c
-@@ -278,18 +278,20 @@ unsetenv (const char *name)
- ep = __environ;
- if (ep != NULL)
- while (*ep != NULL)
-- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-- {
-- /* Found it. Remove this pointer by moving later ones back. */
-- char **dp = ep;
--
-- do
-- dp[0] = dp[1];
-- while (*dp++);
-- /* Continue the loop in case NAME appears again. */
-- }
-- else
-- ++ep;
-+ {
-+ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-+ {
-+ /* Found it. Remove this pointer by moving later ones back. */
-+ char **dp = ep;
-+
-+ do
-+ dp[0] = dp[1];
-+ while (*dp++);
-+ /* Continue the loop in case NAME appears again. */
-+ }
-+ else
-+ ++ep;
-+ }
-
- UNLOCK;
-
---
-2.7.4
-
diff --git a/packages/glibc/2.16.0/102-fix-signed-shift-overlow.patch b/packages/glibc/2.16.0/102-fix-signed-shift-overlow.patch
deleted file mode 100644
index ef49f83..0000000
--- a/packages/glibc/2.16.0/102-fix-signed-shift-overlow.patch
+++ /dev/null
@@ -1,98 +0,0 @@
-commit 5542236837c5c41435f8282ec92799f480c36f18
-Author: Paul Eggert <eggert@cs.ucla.edu>
-Date: Tue Jul 21 22:50:29 2015 -0700
-
- Port the 0x7efe...feff pattern to GCC 6.
-
- See Steve Ellcey's bug report in:
- https://sourceware.org/ml/libc-alpha/2015-07/msg00673.html
- * string/memrchr.c (MEMRCHR):
- * string/rawmemchr.c (RAWMEMCHR):
- * string/strchr.c (strchr):
- * string/strchrnul.c (STRCHRNUL):
- Rewrite code to avoid issues with signed shift overflow.
-
-diff --git a/string/memrchr.c b/string/memrchr.c
-index 0c8fd84..86cd5b9 100644
---- a/string/memrchr.c
-+++ b/string/memrchr.c
-@@ -96,15 +96,8 @@ MEMRCHR
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
--
-- if (sizeof (longword) != 4 && sizeof (longword) != 8)
-- abort ();
--
--#if LONG_MAX <= LONG_MAX_32_BITS
-- magic_bits = 0x7efefeff;
--#else
-- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
--#endif
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/rawmemchr.c b/string/rawmemchr.c
-index 05b22be..228ca9d 100644
---- a/string/rawmemchr.c
-+++ b/string/rawmemchr.c
-@@ -86,15 +86,8 @@ RAWMEMCHR (s, c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
--
-- if (sizeof (longword) != 4 && sizeof (longword) != 8)
-- abort ();
--
--#if LONG_MAX <= LONG_MAX_32_BITS
-- magic_bits = 0x7efefeff;
--#else
-- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
--#endif
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/strchr.c b/string/strchr.c
-index 5f90075..f13b2b3 100644
---- a/string/strchr.c
-+++ b/string/strchr.c
-@@ -60,13 +60,8 @@ strchr (const char *s, int c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
-- switch (sizeof (longword))
-- {
-- case 4: magic_bits = 0x7efefeffL; break;
-- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
-- default:
-- abort ();
-- }
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/strchrnul.c b/string/strchrnul.c
-index 2678f1d..daf0b3f 100644
---- a/string/strchrnul.c
-+++ b/string/strchrnul.c
-@@ -66,13 +66,8 @@ STRCHRNUL (s, c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
-- switch (sizeof (longword))
-- {
-- case 4: magic_bits = 0x7efefeffL; break;
-- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
-- default:
-- abort ();
-- }
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
diff --git a/packages/glibc/2.16.0/105-misleading-indentation.patch b/packages/glibc/2.16.0/105-misleading-indentation.patch
deleted file mode 100644
index 1dd8d85..0000000
--- a/packages/glibc/2.16.0/105-misleading-indentation.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-commit 976ef870542580cf5fed896c2c652b3e1a95f9da
-Author: Steve Ellcey <sellcey@mips.com>
-Date: Fri Dec 11 09:19:37 2015 -0800
-
- Fix indentation.
-
- * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
- Fix indentation.
-
-diff --git a/sysdeps/ieee754/flt-32/k_rem_pio2f.c b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-index 0c7685c..392afdb 100644
---- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-+++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-@@ -65,7 +65,9 @@ int __kernel_rem_pio2f(float *x, float *y, int e0, int nx, int prec, const int32
-
- /* compute q[0],q[1],...q[jk] */
- for (i=0;i<=jk;i++) {
-- for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw;
-+ for(j=0,fw=0.0;j<=jx;j++)
-+ fw += x[j]*f[jx+i-j];
-+ q[i] = fw;
- }
-
- jz = jk;
diff --git a/packages/glibc/2.16.0/300-macos-cross-rpcgen.patch b/packages/glibc/2.16.0/300-macos-cross-rpcgen.patch
deleted file mode 100644
index e654644..0000000
--- a/packages/glibc/2.16.0/300-macos-cross-rpcgen.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-commit ae7080d30c68cfa0c81ce3422dca948f64a94f50
-Author: Jia Liu <proljc@gmail.com>
-Date: Sat Sep 7 00:01:08 2013 +0800
-
- sunrpc/rpc/types.h: fix OS X and FreeBSD build problems
-
- When I build arm-linux-gcc on OS X, I find glibc will get a build error
- in sunrpc/rpc/types.h, so I add __APPLE_CC__ to make OS X build OK.
- For FreeBSD, Add __FreeBSD__ to make it build OK, too.
-
- URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00155.html
- URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00217.html
- URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00240.html
- Signed-off-by: Jia Liu <proljc@gmail.com>
- Signed-off-by: Mike Frysinger <vapier@gentoo.org>
-
-diff --git a/sunrpc/rpc/types.h b/sunrpc/rpc/types.h
-index 3dca5c4..beded52 100644
---- a/sunrpc/rpc/types.h
-+++ b/sunrpc/rpc/types.h
-@@ -69,6 +69,11 @@ typedef unsigned long rpcport_t;
- #include <sys/types.h>
- #endif
-
-+#if defined __APPLE_CC__ || defined __FreeBSD__
-+# define __u_char_defined
-+# define __daddr_t_defined
-+#endif
-+
- #ifndef __u_char_defined
- typedef __u_char u_char;
- typedef __u_short u_short;
diff --git a/packages/glibc/2.16.0/430-alpha-creat.patch b/packages/glibc/2.16.0/430-alpha-creat.patch
deleted file mode 100644
index da6ddda..0000000
--- a/packages/glibc/2.16.0/430-alpha-creat.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-alpha does not have a __NR_creat
-
-http://bugs.gentoo.org/227275
-http://sourceware.org/bugzilla/show_bug.cgi?id=6650
-
-diff -durN glibc-2.13.orig/sysdeps/unix/sysv/linux/wordsize-64/creat64.c glibc-2.13/sysdeps/unix/sysv/linux/wordsize-64/creat64.c
---- glibc-2.13.orig/sysdeps/unix/sysv/linux/wordsize-64/creat64.c 2007-11-10 20:34:26.000000000 +0100
-+++ glibc-2.13/sysdeps/unix/sysv/linux/wordsize-64/creat64.c 2009-11-13 00:50:51.000000000 +0100
-@@ -1 +1,5 @@
- /* Defined as alias for the syscall. */
-+#include <sysdep.h>
-+#ifndef __NR_creat
-+#include "../../../../../io/creat64.c"
-+#endif
diff --git a/packages/glibc/2.16.0/640-alpha-atfcts.patch b/packages/glibc/2.16.0/640-alpha-atfcts.patch
deleted file mode 100644
index 7a8a94a..0000000
--- a/packages/glibc/2.16.0/640-alpha-atfcts.patch
+++ /dev/null
@@ -1,12 +0,0 @@
---- glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h 2010-07-27 14:34:39.000000000 +0300
-+++ glibc-2.13/sysdeps/unix/sysv/linux/kernel-features.h.new 2011-03-10 18:54:37.686795979 +0200
-@@ -437,7 +437,8 @@
- the code. On PPC they were introduced in 2.6.17-rc1,
- on SH in 2.6.19-rc1. */
- #if __LINUX_KERNEL_VERSION >= 0x020611 \
-- && (!defined __sh__ || __LINUX_KERNEL_VERSION >= 0x020613)
-+ && (!defined __sh__ || __LINUX_KERNEL_VERSION >= 0x020613) \
-+ && (!defined __alpha__)
- # define __ASSUME_ATFCTS 1
- #endif
-
diff --git a/packages/glibc/2.16.0/650-syslog.patch b/packages/glibc/2.16.0/650-syslog.patch
deleted file mode 100644
index c20cafc..0000000
--- a/packages/glibc/2.16.0/650-syslog.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-diff -durN glibc-cvs-2.9.orig/misc/syslog.c glibc-cvs-2.9/misc/syslog.c
---- glibc-cvs-2.9.orig/misc/syslog.c 2009-06-01 10:16:50.000000000 +0200
-+++ glibc-cvs-2.9/misc/syslog.c 2009-06-01 10:17:20.000000000 +0200
-@@ -152,7 +152,7 @@
- #define INTERNALLOG LOG_ERR|LOG_CONS|LOG_PERROR|LOG_PID
- /* Check for invalid bits. */
- if (pri & ~(LOG_PRIMASK|LOG_FACMASK)) {
-- syslog(INTERNALLOG,
-+ __syslog(INTERNALLOG,
- "syslog: unknown facility/priority: %x", pri);
- pri &= LOG_PRIMASK|LOG_FACMASK;
- }
diff --git a/packages/glibc/2.16.0/660-debug-readlink_chk-readklinkat_chk.patch b/packages/glibc/2.16.0/660-debug-readlink_chk-readklinkat_chk.patch
deleted file mode 100644
index a5a7052..0000000
--- a/packages/glibc/2.16.0/660-debug-readlink_chk-readklinkat_chk.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-diff -dur glibc-cvs-2.9.orig/debug/readlink_chk.c glibc-cvs-2.9/debug/readlink_chk.c
---- glibc-cvs-2.9.orig/debug/readlink_chk.c 2005-03-01 01:41:15.000000000 +0100
-+++ glibc-cvs-2.9/debug/readlink_chk.c 2009-06-01 10:59:37.000000000 +0200
-@@ -25,7 +25,7 @@
-
-
- ssize_t
--__readlink_chk (const char *path, void *buf, size_t len, size_t buflen)
-+__readlink_chk (const char *path, char *buf, size_t len, size_t buflen)
- {
- if (len > buflen)
- __chk_fail ();
-diff -dur glibc-cvs-2.9.orig/debug/readlinkat_chk.c glibc-cvs-2.9/debug/readlinkat_chk.c
---- glibc-cvs-2.9.orig/debug/readlinkat_chk.c 2006-04-24 18:56:12.000000000 +0200
-+++ glibc-cvs-2.9/debug/readlinkat_chk.c 2009-06-01 11:07:26.000000000 +0200
-@@ -21,7 +21,7 @@
-
-
- ssize_t
--__readlinkat_chk (int fd, const char *path, void *buf, size_t len,
-+__readlinkat_chk (int fd, const char *path, char *buf, size_t len,
- size_t buflen)
- {
- if (len > buflen)
diff --git a/packages/glibc/2.16.0/920-fix-rpc_parse-format.patch b/packages/glibc/2.16.0/920-fix-rpc_parse-format.patch
deleted file mode 100644
index 37e58da..0000000
--- a/packages/glibc/2.16.0/920-fix-rpc_parse-format.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-commit 5874510faaf3cbd0bb112aaacab9f225002beed1
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Tue Nov 8 23:44:51 2016 +0000
-
- Fix rpcgen buffer overrun (bug 20790).
-
- Building with GCC 7 produces an error building rpcgen:
-
- rpc_parse.c: In function 'get_prog_declaration':
- rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ~~~~^
- rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
- That buffer overrun is for the case where the .x file declares a
- program with a million arguments. The strcpy two lines above can
- generate a buffer overrun much more simply for a long argument name.
-
- The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
- provides a bound on the buffer size needed, so this patch just changes
- the buffer size to MAXLINESIZE to avoid both possible buffer
- overruns. A testcase is added that rpcgen does not crash with a
- 500-character argument name, where it previously crashed.
-
- It would not at all surprise me if there are many other ways of
- crashing rpcgen with either valid or invalid input; fuzz testing would
- likely find various such bugs, though I don't think they are that
- important to fix (rpcgen is not that likely to be used with untrusted
- .x files as input). (As well as fuzz-findable bugs there are probably
- also issues when various int variables get overflowed on very large
- input.) The test infrastructure for rpcgen-not-crashing tests would
- need extending if tests are to be added for cases where rpcgen should
- produce an error, as opposed to cases where it should succeed.
-
- Tested for x86_64 and x86.
-
- [BZ #20790]
- * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
- to MAXLINESIZE.
- * sunrpc/bug20790.x: New file.
- * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
- variable.
- [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
- [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
-
-diff --git a/sunrpc/rpc_parse.c b/sunrpc/rpc_parse.c
-index 1a1df6d8c2..505a6554cf 100644
---- a/sunrpc/rpc_parse.c
-+++ b/sunrpc/rpc_parse.c
-@@ -521,7 +521,7 @@ static void
- get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
- {
- token tok;
-- char name[10]; /* argument name */
-+ char name[MAXLINESIZE]; /* argument name */
-
- if (dkind == DEF_PROGRAM)
- {
diff --git a/packages/glibc/2.16.0/940-nis-bogus-conditional.patch b/packages/glibc/2.16.0/940-nis-bogus-conditional.patch
deleted file mode 100644
index 09b38cf..0000000
--- a/packages/glibc/2.16.0/940-nis-bogus-conditional.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Wed Dec 21 23:44:01 2016 +0000
-
- Fix nss_nisplus build with mainline GCC (bug 20978).
-
- glibc build with current mainline GCC fails because
- nis/nss_nisplus/nisplus-alias.c contains code
-
- if (name != NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
- }
-
- char buf[strlen (name) + 9 + tablename_len];
-
- producing an error about strlen being called on a pointer that is
- always NULL (and a subsequent use of that pointer with a %s format in
- snprintf).
-
- As Andreas noted, the bogus conditional comes from a 1997 change:
-
- - if (name == NULL || strlen(name) > 8)
- - return NSS_STATUS_NOTFOUND;
- - else
- + if (name != NULL || strlen(name) <= 8)
-
- So the intention is clearly to return an error for NULL name.
-
- This patch duly inverts the sense of the conditional. It fixes the
- build with GCC mainline, and passes usual glibc testsuite testing for
- x86_64. However, I have not tried any actual substantive nisplus
- testing, do not have an environment for such testing, and do not know
- whether it is possible that strlen (name) or tablename_len might be
- large so that the VLA for buf is actually a security issue. However,
- if it is a security issue, there are plenty of other similar instances
- in the nisplus code (that haven't been hidden by a bogus comparison
- with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
- string passed to nis_list, so a local fix in the caller wouldn't
- suffice anyway (see bug 20987). (Calls to strdupa and other such
- macros that use alloca must be considered equally questionable
- regarding stack overflow issues as direct calls to alloca and VLA
- declarations.)
-
- [BZ #20978]
- * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
- Compare name == NULL, not name != NULL.
-
-diff --git a/nis/nss_nisplus/nisplus-alias.c b/nis/nss_nisplus/nisplus-alias.c
-index 7f698b4e6d..cb5acce01d 100644
---- a/nis/nss_nisplus/nisplus-alias.c
-+++ b/nis/nss_nisplus/nisplus-alias.c
-@@ -291,7 +291,7 @@ _nss_nisplus_getaliasbyname_r (const char *name, struct aliasent *alias,
- return status;
- }
-
-- if (name != NULL)
-+ if (name == NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.16.0/998-obstack-common.patch b/packages/glibc/2.16.0/998-obstack-common.patch
deleted file mode 100644
index 4b95f06..0000000
--- a/packages/glibc/2.16.0/998-obstack-common.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-commit 39b1f6172a2f9ddc74a8f82d6e84dd13b22dbaf2
-Author: Peter Collingbourne <pcc@google.com>
-Date: Wed May 15 20:28:08 2013 +0200
-
- Move _obstack_compat out of common
-
- it is impossible to create an alias of a common symbol (as
- compat_symbol does), because common symbols do not have a section or
- an offset until linked. GNU as tolerates aliases of common symbols by
- simply creating another common symbol, but other assemblers (notably
- LLVM's integrated assembler) are less tolerant.
-
- 2013-05-15 Peter Collingbourne <pcc@google.com>
-
- * malloc/obstack.c (_obstack_compat): Add initializer.
- -
-
-diff --git a/malloc/obstack.c b/malloc/obstack.c
-index 25a90514f7..c3c7db4a96 100644
---- a/malloc/obstack.c
-+++ b/malloc/obstack.c
-@@ -115,7 +115,7 @@ int obstack_exit_failure = EXIT_FAILURE;
- /* A looong time ago (before 1994, anyway; we're not sure) this global variable
- was used by non-GNU-C macros to avoid multiple evaluation. The GNU C
- library still exports it because somebody might use it. */
--struct obstack *_obstack_compat;
-+struct obstack *_obstack_compat = 0;
- compat_symbol (libc, _obstack_compat, _obstack, GLIBC_2_0);
- # endif
- # endif
diff --git a/packages/glibc/2.17/100-Fix-ARM-build-with-GCC-trunk.patch b/packages/glibc/2.17/0000-Fix-ARM-build-with-GCC-trunk.patch
index 59f95aa..7be1454 100644
--- a/packages/glibc/2.17/100-Fix-ARM-build-with-GCC-trunk.patch
+++ b/packages/glibc/2.17/0000-Fix-ARM-build-with-GCC-trunk.patch
@@ -17,12 +17,10 @@ Tested that this fixes the build for ARM.
* sysdeps/unix/sysv/linux/arm/unwind-resume.c (libgcc_s_resume):
Likewise.
---
- sysdeps/unix/sysv/linux/arm/unwind-forcedunwind.c | 3 ++-
- sysdeps/unix/sysv/linux/arm/unwind-resume.c | 3 ++-
- 3 files changed, 11 insertions(+), 2 deletions(-)
+ ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c | 3 ++-
+ ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c | 3 ++-
+ 2 files changed, 4 insertions(+), 2 deletions(-)
-diff --git a/sysdeps/unix/sysv/linux/arm/unwind-forcedunwind.c b/sysdeps/unix/sysv/linux/arm/unwind-forcedunwind.c
-index 6ccd9b4..660d148 100644
--- a/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c
+++ b/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c
@@ -22,7 +22,8 @@
@@ -35,8 +33,6 @@ index 6ccd9b4..660d148 100644
static _Unwind_Reason_Code (*libgcc_s_personality)
(_Unwind_State, struct _Unwind_Exception *, struct _Unwind_Context *);
static _Unwind_Reason_Code (*libgcc_s_forcedunwind)
-diff --git a/sysdeps/unix/sysv/linux/arm/unwind-resume.c b/sysdeps/unix/sysv/linux/arm/unwind-resume.c
-index bff3e2b..1f1eb71 100644
--- a/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c
+++ b/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c
@@ -20,7 +20,8 @@
@@ -49,6 +45,3 @@ index bff3e2b..1f1eb71 100644
static _Unwind_Reason_Code (*libgcc_s_personality)
(_Unwind_State, struct _Unwind_Exception *, struct _Unwind_Context *);
---
-1.9.4
-
diff --git a/packages/glibc/2.17/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.17/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
new file mode 100644
index 0000000..31e9499
--- /dev/null
+++ b/packages/glibc/2.17/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
@@ -0,0 +1,75 @@
+From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
+From: Yvan Roux <yvan.roux@linaro.org>
+Date: Fri, 15 Apr 2016 13:29:26 +0200
+Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
+ -Wparentheses
+
+---
+ nis/nis_call.c | 20 +++++++++++---------
+ stdlib/setenv.c | 24 +++++++++++++-----------
+ 2 files changed, 24 insertions(+), 20 deletions(-)
+
+--- a/nis/nis_call.c
++++ b/nis/nis_call.c
+@@ -681,16 +681,18 @@
+ /* Choose which entry should be evicted from the cache. */
+ loc = &nis_server_cache[0];
+ if (*loc != NULL)
+- for (i = 1; i < 16; ++i)
+- if (nis_server_cache[i] == NULL)
+- {
++ {
++ for (i = 1; i < 16; ++i)
++ if (nis_server_cache[i] == NULL)
++ {
++ loc = &nis_server_cache[i];
++ break;
++ }
++ else if ((*loc)->uses > nis_server_cache[i]->uses
++ || ((*loc)->uses == nis_server_cache[i]->uses
++ && (*loc)->expires > nis_server_cache[i]->expires))
+ loc = &nis_server_cache[i];
+- break;
+- }
+- else if ((*loc)->uses > nis_server_cache[i]->uses
+- || ((*loc)->uses == nis_server_cache[i]->uses
+- && (*loc)->expires > nis_server_cache[i]->expires))
+- loc = &nis_server_cache[i];
++ }
+ old = *loc;
+ *loc = new;
+
+--- a/stdlib/setenv.c
++++ b/stdlib/setenv.c
+@@ -327,18 +327,20 @@
+ ep = __environ;
+ if (ep != NULL)
+ while (*ep != NULL)
+- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
+- {
+- /* Found it. Remove this pointer by moving later ones back. */
+- char **dp = ep;
++ {
++ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
++ {
++ /* Found it. Remove this pointer by moving later ones back. */
++ char **dp = ep;
+
+- do
+- dp[0] = dp[1];
+- while (*dp++);
+- /* Continue the loop in case NAME appears again. */
+- }
+- else
+- ++ep;
++ do
++ dp[0] = dp[1];
++ while (*dp++);
++ /* Continue the loop in case NAME appears again. */
++ }
++ else
++ ++ep;
++ }
+
+ UNLOCK;
+
diff --git a/packages/glibc/2.17/0002-fix-signed-shift-overlow.patch b/packages/glibc/2.17/0002-fix-signed-shift-overlow.patch
new file mode 100644
index 0000000..3b2ef40
--- /dev/null
+++ b/packages/glibc/2.17/0002-fix-signed-shift-overlow.patch
@@ -0,0 +1,97 @@
+commit 5542236837c5c41435f8282ec92799f480c36f18
+Author: Paul Eggert <eggert@cs.ucla.edu>
+Date: Tue Jul 21 22:50:29 2015 -0700
+
+ Port the 0x7efe...feff pattern to GCC 6.
+
+ See Steve Ellcey's bug report in:
+ https://sourceware.org/ml/libc-alpha/2015-07/msg00673.html
+ * string/memrchr.c (MEMRCHR):
+ * string/rawmemchr.c (RAWMEMCHR):
+ * string/strchr.c (strchr):
+ * string/strchrnul.c (STRCHRNUL):
+ Rewrite code to avoid issues with signed shift overflow.
+
+---
+ string/memrchr.c | 11 ++---------
+ string/rawmemchr.c | 11 ++---------
+ string/strchr.c | 9 ++-------
+ string/strchrnul.c | 9 ++-------
+ 4 files changed, 8 insertions(+), 32 deletions(-)
+
+--- a/string/memrchr.c
++++ b/string/memrchr.c
+@@ -96,15 +96,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+-
+- if (sizeof (longword) != 4 && sizeof (longword) != 8)
+- abort ();
+-
+-#if LONG_MAX <= LONG_MAX_32_BITS
+- magic_bits = 0x7efefeff;
+-#else
+- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
+-#endif
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/rawmemchr.c
++++ b/string/rawmemchr.c
+@@ -83,15 +83,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+-
+- if (sizeof (longword) != 4 && sizeof (longword) != 8)
+- abort ();
+-
+-#if LONG_MAX <= LONG_MAX_32_BITS
+- magic_bits = 0x7efefeff;
+-#else
+- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
+-#endif
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/strchr.c
++++ b/string/strchr.c
+@@ -64,13 +64,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+- switch (sizeof (longword))
+- {
+- case 4: magic_bits = 0x7efefeffL; break;
+- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
+- default:
+- abort ();
+- }
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/strchrnul.c
++++ b/string/strchrnul.c
+@@ -62,13 +62,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+- switch (sizeof (longword))
+- {
+- case 4: magic_bits = 0x7efefeffL; break;
+- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
+- default:
+- abort ();
+- }
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
diff --git a/packages/glibc/2.16.0/103-dl-openat64-variadic.patch b/packages/glibc/2.17/0003-dl-openat64-variadic.patch
index fe94b96..552db12 100644
--- a/packages/glibc/2.16.0/103-dl-openat64-variadic.patch
+++ b/packages/glibc/2.17/0003-dl-openat64-variadic.patch
@@ -177,8 +177,10 @@ Date: Tue Oct 20 11:54:09 2015 +0000
* wcsmbs/wcsnrtombs.c (__wcsnrtombs): Likewise.
* wcsmbs/wcsrtombs.c (__wcsrtombs): Likewise.
-diff --git a/sysdeps/unix/sysv/linux/dl-openat64.c b/sysdeps/unix/sysv/linux/dl-openat64.c
-index 7d100bb..7eea0ca 100644
+---
+ sysdeps/unix/sysv/linux/dl-openat64.c | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
--- a/sysdeps/unix/sysv/linux/dl-openat64.c
+++ b/sysdeps/unix/sysv/linux/dl-openat64.c
@@ -23,10 +23,7 @@
diff --git a/packages/glibc/2.17/104-unused-variables.patch b/packages/glibc/2.17/0004-unused-variables.patch
index 80e0ff2..bebd96a 100644
--- a/packages/glibc/2.17/104-unused-variables.patch
+++ b/packages/glibc/2.17/0004-unused-variables.patch
@@ -19,8 +19,18 @@ Date: Fri Sep 18 20:27:20 2015 +0100
* timezone/private.h (time_t_min): Likewise. (time_t_max):
Likewise.
-diff --git a/resolv/base64.c b/resolv/base64.c
-index ea584ed..519e5d2 100644
+---
+ resolv/base64.c | 4 ----
+ sysdeps/ieee754/dbl-64/atnat2.h | 4 ----
+ sysdeps/ieee754/dbl-64/uexp.h | 2 +-
+ sysdeps/ieee754/dbl-64/upow.h | 2 --
+ sysdeps/ieee754/flt-32/e_log10f.c | 2 --
+ sysdeps/ieee754/flt-32/s_cosf.c | 2 --
+ sysdeps/ieee754/ldbl-128/e_lgammal_r.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_erfl.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_log1pl.c | 1 -
+ 9 files changed, 1 insertion(+), 18 deletions(-)
+
--- a/resolv/base64.c
+++ b/resolv/base64.c
@@ -40,10 +40,6 @@
@@ -34,11 +44,9 @@ index ea584ed..519e5d2 100644
#include <sys/types.h>
#include <sys/param.h>
#include <sys/socket.h>
-diff --git a/sysdeps/ieee754/dbl-64/atnat2.h b/sysdeps/ieee754/dbl-64/atnat2.h
-index e0d65af..82943f9 100644
--- a/sysdeps/ieee754/dbl-64/atnat2.h
+++ b/sysdeps/ieee754/dbl-64/atnat2.h
-@@ -65,10 +65,8 @@
+@@ -68,10 +68,8 @@
/**/ hpi1 = {{0x3c91a626, 0x33145c07} }, /* pi/2-hpi */
/**/ mhpi = {{0xbff921fb, 0x54442d18} }, /* -pi/2 */
/**/ qpi = {{0x3fe921fb, 0x54442d18} }, /* pi/4 */
@@ -49,7 +57,7 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0xc002d97c, 0x7f3321d2} }, /* -3pi/4 */
/**/ u1 = {{0x3c314c2a, 0x00000000} }, /* 9.377e-19 */
/**/ u2 = {{0x3bf955e4, 0x00000000} }, /* 8.584e-20 */
-@@ -129,10 +127,8 @@
+@@ -138,10 +136,8 @@
/**/ hpi1 = {{0x33145c07, 0x3c91a626} }, /* pi/2-hpi */
/**/ mhpi = {{0x54442d18, 0xbff921fb} }, /* -pi/2 */
/**/ qpi = {{0x54442d18, 0x3fe921fb} }, /* pi/4 */
@@ -60,8 +68,6 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0x7f3321d2, 0xc002d97c} }, /* -3pi/4 */
/**/ u1 = {{0x00000000, 0x3c314c2a} }, /* 9.377e-19 */
/**/ u2 = {{0x00000000, 0x3bf955e4} }, /* 8.584e-20 */
-diff --git a/sysdeps/ieee754/dbl-64/uexp.h b/sysdeps/ieee754/dbl-64/uexp.h
-index 6817eaf..42b21f2 100644
--- a/sysdeps/ieee754/dbl-64/uexp.h
+++ b/sysdeps/ieee754/dbl-64/uexp.h
@@ -29,7 +29,7 @@
@@ -73,11 +79,9 @@ index 6817eaf..42b21f2 100644
err_0 = 1.000014, err_1 = 0.000016;
const static int4 bigint = 0x40862002,
badint = 0x40876000,smallint = 0x3C8fffff;
-diff --git a/sysdeps/ieee754/dbl-64/upow.h b/sysdeps/ieee754/dbl-64/upow.h
-index c8569a9..b4911e5 100644
--- a/sysdeps/ieee754/dbl-64/upow.h
+++ b/sysdeps/ieee754/dbl-64/upow.h
-@@ -34,7 +34,6 @@
+@@ -35,7 +35,6 @@
/**/ INF = {{0x7ff00000, 0x00000000}}, /* INF */
/**/ nINF = {{0xfff00000, 0x00000000}}, /* -INF */
/**/ NaNQ = {{0x7ff80000, 0x00000000}}, /* NaNQ */
@@ -85,7 +89,7 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0x3fe62e42, 0xfefa3800}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x3d2ef357, 0x93c76730}}, /* ln(2)-ln2a */
/**/ bigu = {{0x4297ffff, 0xfffffd2c}}, /* 1.5*2**42 -724*2**-10 */
-@@ -48,7 +47,6 @@
+@@ -50,7 +49,6 @@
/**/ INF = {{0x00000000, 0x7ff00000}}, /* INF */
/**/ nINF = {{0x00000000, 0xfff00000}}, /* -INF */
/**/ NaNQ = {{0x00000000, 0x7ff80000}}, /* NaNQ */
@@ -93,11 +97,9 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0xfefa3800, 0x3fe62e42}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x93c76730, 0x3d2ef357}}, /* ln(2)-ln2a */
/**/ bigu = {{0xfffffd2c, 0x4297ffff}}, /* 1.5*2**42 -724*2**-10 */
-diff --git a/sysdeps/ieee754/flt-32/e_log10f.c b/sysdeps/ieee754/flt-32/e_log10f.c
-index 96f0e81..1daeef7 100644
--- a/sysdeps/ieee754/flt-32/e_log10f.c
+++ b/sysdeps/ieee754/flt-32/e_log10f.c
-@@ -22,8 +22,6 @@ ivln10 = 4.3429449201e-01, /* 0x3ede5bd9 */
+@@ -22,8 +22,6 @@
log10_2hi = 3.0102920532e-01, /* 0x3e9a2080 */
log10_2lo = 7.9034151668e-07; /* 0x355427db */
@@ -106,11 +108,9 @@ index 96f0e81..1daeef7 100644
float
__ieee754_log10f(float x)
{
-diff --git a/sysdeps/ieee754/flt-32/s_cosf.c b/sysdeps/ieee754/flt-32/s_cosf.c
-index 864ab27..0affd40 100644
--- a/sysdeps/ieee754/flt-32/s_cosf.c
+++ b/sysdeps/ieee754/flt-32/s_cosf.c
-@@ -21,8 +21,6 @@ static char rcsid[] = "$NetBSD: s_cosf.c,v 1.4 1995/05/10 20:47:03 jtc Exp $";
+@@ -21,8 +21,6 @@
#include <math.h>
#include <math_private.h>
@@ -119,11 +119,9 @@ index 864ab27..0affd40 100644
#ifndef COSF
# define COSF_FUNC __cosf
#else
-diff --git a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-index 500aacc..ab5a96e 100644
--- a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
+++ b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-@@ -82,7 +82,6 @@ DIAG_IGNORE_NEEDS_COMMENT (4.6, "-Woverflow");
+@@ -74,7 +74,6 @@
static const long double PIL = 3.1415926535897932384626433832795028841972E0L;
static const long double MAXLGM = 1.0485738685148938358098967157129705071571E4928L;
static const long double one = 1.0L;
@@ -131,11 +129,9 @@ index 500aacc..ab5a96e 100644
static const long double huge = 1.0e4000L;
/* log gamma(x) = ( x - 0.5 ) * log(x) - x + LS2PI + 1/x P(1/x^2)
-diff --git a/sysdeps/ieee754/ldbl-128/s_erfl.c b/sysdeps/ieee754/ldbl-128/s_erfl.c
-index fa4609f..08c80a3 100644
--- a/sysdeps/ieee754/ldbl-128/s_erfl.c
+++ b/sysdeps/ieee754/ldbl-128/s_erfl.c
-@@ -140,7 +140,6 @@ deval (long double x, const long double *p, int n)
+@@ -138,7 +138,6 @@
static const long double
tiny = 1e-4931L,
@@ -143,11 +139,9 @@ index fa4609f..08c80a3 100644
one = 1.0L,
two = 2.0L,
/* 2/sqrt(pi) - 1 */
-diff --git a/sysdeps/ieee754/ldbl-128/s_log1pl.c b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-index ff759bc..9609550 100644
--- a/sysdeps/ieee754/ldbl-128/s_log1pl.c
+++ b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-@@ -117,7 +117,6 @@ static const long double C2 = 1.428606820309417232121458176568075500134E-6L;
+@@ -116,7 +116,6 @@
static const long double sqrth = 0.7071067811865475244008443621048490392848L;
/* ln (2^16384 * (1 - 2^-113)) */
diff --git a/packages/glibc/2.17/0005-misleading-indentation.patch b/packages/glibc/2.17/0005-misleading-indentation.patch
new file mode 100644
index 0000000..8e08259
--- /dev/null
+++ b/packages/glibc/2.17/0005-misleading-indentation.patch
@@ -0,0 +1,26 @@
+commit 976ef870542580cf5fed896c2c652b3e1a95f9da
+Author: Steve Ellcey <sellcey@mips.com>
+Date: Fri Dec 11 09:19:37 2015 -0800
+
+ Fix indentation.
+
+ * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
+ Fix indentation.
+
+---
+ sysdeps/ieee754/flt-32/k_rem_pio2f.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+--- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
++++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
+@@ -65,7 +65,9 @@
+
+ /* compute q[0],q[1],...q[jk] */
+ for (i=0;i<=jk;i++) {
+- for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw;
++ for(j=0,fw=0.0;j<=jx;j++)
++ fw += x[j]*f[jx+i-j];
++ q[i] = fw;
+ }
+
+ jz = jk;
diff --git a/packages/glibc/2.17/106-dl-open-array-bounds.patch b/packages/glibc/2.17/0006-dl-open-array-bounds.patch
index a8efe9a..d4ce7e8 100644
--- a/packages/glibc/2.17/106-dl-open-array-bounds.patch
+++ b/packages/glibc/2.17/0006-dl-open-array-bounds.patch
@@ -4,11 +4,13 @@ Date: Fri Apr 17 12:11:58 2015 -0700
Fuller check for invalid NSID in _dl_open.
-diff --git a/elf/dl-open.c b/elf/dl-open.c
-index 0dbe07f..2d0e082 100644
+---
+ elf/dl-open.c | 10 ++++++++--
+ 1 file changed, 8 insertions(+), 2 deletions(-)
+
--- a/elf/dl-open.c
+++ b/elf/dl-open.c
-@@ -619,8 +619,14 @@ no more namespaces available for dlmopen()"));
+@@ -627,8 +627,14 @@
/* Never allow loading a DSO in a namespace which is empty. Such
direct placements is only causing problems. Also don't allow
loading into a namespace used for auditing. */
diff --git a/packages/glibc/2.18/120-support-make4.patch b/packages/glibc/2.17/0007-support-make4.patch
index ca2bae0..81b6c47 100644
--- a/packages/glibc/2.18/120-support-make4.patch
+++ b/packages/glibc/2.17/0007-support-make4.patch
@@ -10,11 +10,14 @@ X-Git-Url: https://sourceware.org/git/?p=glibc.git;a=commitdiff_plain;h=28d708c4
Accept make versions 4.0 and greater
---
-diff --git a/configure b/configure
-index f382138..5e61abd 100755
+---
+ configure | 2 +-
+ configure.in | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
--- a/configure
+++ b/configure
-@@ -4761,7 +4761,7 @@ $as_echo_n "checking version of $MAKE... " >&6; }
+@@ -4972,7 +4972,7 @@
ac_prog_version=`$MAKE --version 2>&1 | sed -n 's/^.*GNU Make[^0-9]*\([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -23,11 +26,9 @@ index f382138..5e61abd 100755
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-diff --git a/configure.in b/configure.in
-index 49b70fd..6da8efd 100644
--- a/configure.in
+++ b/configure.in
-@@ -984,7 +984,7 @@ AC_CHECK_PROG_VER(CC, ${ac_tool_prefix}gcc ${ac_tool_prefix}cc, -v,
+@@ -935,7 +935,7 @@
critic_missing="$critic_missing gcc")
AC_CHECK_PROG_VER(MAKE, gnumake gmake make, --version,
[GNU Make[^0-9]*\([0-9][0-9.]*\)],
diff --git a/packages/glibc/2.17/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.17/0008-Fix-combreloc-test-BSD-grep.patch
index 3c34e01..20f0ea3 100644
--- a/packages/glibc/2.17/140-Fix-combreloc-test-BSD-grep.patch
+++ b/packages/glibc/2.17/0008-Fix-combreloc-test-BSD-grep.patch
@@ -13,16 +13,13 @@ by configure as "not found". As a result, support for "-z combreloc"
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
+ configure | 2 +-
+ configure.in | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
-diff --git a/configure b/configure
-index eecd0ac..0118bd1 100755
--- a/configure
+++ b/configure
-@@ -5804,7 +5804,7 @@ if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
+@@ -6507,7 +6507,7 @@
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; }
then
@@ -31,11 +28,9 @@ index eecd0ac..0118bd1 100755
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
-diff --git a/configure.ac b/configure.ac
-index 4a77411..19f6d87 100644
--- a/configure.in
+++ b/configure.in
-@@ -1391,7 +1391,7 @@ dnl cross-platform since the gcc used can be a cross compiler. Without
+@@ -1542,7 +1542,7 @@
dnl introducing new options this is not easily doable. Instead use a tool
dnl which always is cross-platform: readelf. To detect whether -z combreloc
dnl look for a section named .rel.dyn.
@@ -44,6 +39,3 @@ index 4a77411..19f6d87 100644
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
---
-2.9.3
-
diff --git a/packages/glibc/2.17/0009-macos-cross-rpcgen.patch b/packages/glibc/2.17/0009-macos-cross-rpcgen.patch
new file mode 100644
index 0000000..b439b0f
--- /dev/null
+++ b/packages/glibc/2.17/0009-macos-cross-rpcgen.patch
@@ -0,0 +1,34 @@
+commit ae7080d30c68cfa0c81ce3422dca948f64a94f50
+Author: Jia Liu <proljc@gmail.com>
+Date: Sat Sep 7 00:01:08 2013 +0800
+
+ sunrpc/rpc/types.h: fix OS X and FreeBSD build problems
+
+ When I build arm-linux-gcc on OS X, I find glibc will get a build error
+ in sunrpc/rpc/types.h, so I add __APPLE_CC__ to make OS X build OK.
+ For FreeBSD, Add __FreeBSD__ to make it build OK, too.
+
+ URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00155.html
+ URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00217.html
+ URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00240.html
+ Signed-off-by: Jia Liu <proljc@gmail.com>
+ Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+
+---
+ sunrpc/rpc/types.h | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/sunrpc/rpc/types.h
++++ b/sunrpc/rpc/types.h
+@@ -69,6 +69,11 @@
+ #include <sys/types.h>
+ #endif
+
++#if defined __APPLE_CC__ || defined __FreeBSD__
++# define __u_char_defined
++# define __daddr_t_defined
++#endif
++
+ #ifndef __u_char_defined
+ typedef __u_char u_char;
+ typedef __u_short u_short;
diff --git a/packages/glibc/2.17/0010-fix-rpc_parse-format.patch b/packages/glibc/2.17/0010-fix-rpc_parse-format.patch
new file mode 100644
index 0000000..341d541
--- /dev/null
+++ b/packages/glibc/2.17/0010-fix-rpc_parse-format.patch
@@ -0,0 +1,62 @@
+commit 5874510faaf3cbd0bb112aaacab9f225002beed1
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Tue Nov 8 23:44:51 2016 +0000
+
+ Fix rpcgen buffer overrun (bug 20790).
+
+ Building with GCC 7 produces an error building rpcgen:
+
+ rpc_parse.c: In function 'get_prog_declaration':
+ rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ~~~~^
+ rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+ That buffer overrun is for the case where the .x file declares a
+ program with a million arguments. The strcpy two lines above can
+ generate a buffer overrun much more simply for a long argument name.
+
+ The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
+ provides a bound on the buffer size needed, so this patch just changes
+ the buffer size to MAXLINESIZE to avoid both possible buffer
+ overruns. A testcase is added that rpcgen does not crash with a
+ 500-character argument name, where it previously crashed.
+
+ It would not at all surprise me if there are many other ways of
+ crashing rpcgen with either valid or invalid input; fuzz testing would
+ likely find various such bugs, though I don't think they are that
+ important to fix (rpcgen is not that likely to be used with untrusted
+ .x files as input). (As well as fuzz-findable bugs there are probably
+ also issues when various int variables get overflowed on very large
+ input.) The test infrastructure for rpcgen-not-crashing tests would
+ need extending if tests are to be added for cases where rpcgen should
+ produce an error, as opposed to cases where it should succeed.
+
+ Tested for x86_64 and x86.
+
+ [BZ #20790]
+ * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
+ to MAXLINESIZE.
+ * sunrpc/bug20790.x: New file.
+ * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
+ variable.
+ [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
+ [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
+
+---
+ sunrpc/rpc_parse.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/sunrpc/rpc_parse.c
++++ b/sunrpc/rpc_parse.c
+@@ -521,7 +521,7 @@
+ get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
+ {
+ token tok;
+- char name[10]; /* argument name */
++ char name[MAXLINESIZE]; /* argument name */
+
+ if (dkind == DEF_PROGRAM)
+ {
diff --git a/packages/glibc/2.17/0011-nis-bogus-conditional.patch b/packages/glibc/2.17/0011-nis-bogus-conditional.patch
new file mode 100644
index 0000000..b8b806c
--- /dev/null
+++ b/packages/glibc/2.17/0011-nis-bogus-conditional.patch
@@ -0,0 +1,64 @@
+commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Wed Dec 21 23:44:01 2016 +0000
+
+ Fix nss_nisplus build with mainline GCC (bug 20978).
+
+ glibc build with current mainline GCC fails because
+ nis/nss_nisplus/nisplus-alias.c contains code
+
+ if (name != NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
+ }
+
+ char buf[strlen (name) + 9 + tablename_len];
+
+ producing an error about strlen being called on a pointer that is
+ always NULL (and a subsequent use of that pointer with a %s format in
+ snprintf).
+
+ As Andreas noted, the bogus conditional comes from a 1997 change:
+
+ - if (name == NULL || strlen(name) > 8)
+ - return NSS_STATUS_NOTFOUND;
+ - else
+ + if (name != NULL || strlen(name) <= 8)
+
+ So the intention is clearly to return an error for NULL name.
+
+ This patch duly inverts the sense of the conditional. It fixes the
+ build with GCC mainline, and passes usual glibc testsuite testing for
+ x86_64. However, I have not tried any actual substantive nisplus
+ testing, do not have an environment for such testing, and do not know
+ whether it is possible that strlen (name) or tablename_len might be
+ large so that the VLA for buf is actually a security issue. However,
+ if it is a security issue, there are plenty of other similar instances
+ in the nisplus code (that haven't been hidden by a bogus comparison
+ with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
+ string passed to nis_list, so a local fix in the caller wouldn't
+ suffice anyway (see bug 20987). (Calls to strdupa and other such
+ macros that use alloca must be considered equally questionable
+ regarding stack overflow issues as direct calls to alloca and VLA
+ declarations.)
+
+ [BZ #20978]
+ * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
+ Compare name == NULL, not name != NULL.
+
+---
+ nis/nss_nisplus/nisplus-alias.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/nis/nss_nisplus/nisplus-alias.c
++++ b/nis/nss_nisplus/nisplus-alias.c
+@@ -292,7 +292,7 @@
+ return status;
+ }
+
+- if (name != NULL)
++ if (name == NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.17/0012-obstack-common.patch b/packages/glibc/2.17/0012-obstack-common.patch
new file mode 100644
index 0000000..ad1f8eb
--- /dev/null
+++ b/packages/glibc/2.17/0012-obstack-common.patch
@@ -0,0 +1,32 @@
+commit 39b1f6172a2f9ddc74a8f82d6e84dd13b22dbaf2
+Author: Peter Collingbourne <pcc@google.com>
+Date: Wed May 15 20:28:08 2013 +0200
+
+ Move _obstack_compat out of common
+
+ it is impossible to create an alias of a common symbol (as
+ compat_symbol does), because common symbols do not have a section or
+ an offset until linked. GNU as tolerates aliases of common symbols by
+ simply creating another common symbol, but other assemblers (notably
+ LLVM's integrated assembler) are less tolerant.
+
+ 2013-05-15 Peter Collingbourne <pcc@google.com>
+
+ * malloc/obstack.c (_obstack_compat): Add initializer.
+ -
+
+---
+ malloc/obstack.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/malloc/obstack.c
++++ b/malloc/obstack.c
+@@ -116,7 +116,7 @@
+ /* A looong time ago (before 1994, anyway; we're not sure) this global variable
+ was used by non-GNU-C macros to avoid multiple evaluation. The GNU C
+ library still exports it because somebody might use it. */
+-struct obstack *_obstack_compat;
++struct obstack *_obstack_compat = 0;
+ compat_symbol (libc, _obstack_compat, _obstack, GLIBC_2_0);
+ # endif
+ # endif
diff --git a/packages/glibc/2.17/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.17/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
deleted file mode 100644
index 6fd663a..0000000
--- a/packages/glibc/2.17/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
-From: Yvan Roux <yvan.roux@linaro.org>
-Date: Fri, 15 Apr 2016 13:29:26 +0200
-Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
- -Wparentheses
-
----
- ChangeLog | 5 +++++
- nis/nis_call.c | 20 +++++++++++---------
- stdlib/setenv.c | 26 ++++++++++++++------------
- 3 files changed, 30 insertions(+), 21 deletions(-)
-
-diff --git a/nis/nis_call.c b/nis/nis_call.c
-index 3fa37e4..cb7839a 100644
---- a/nis/nis_call.c
-+++ b/nis/nis_call.c
-@@ -680,16 +680,18 @@ nis_server_cache_add (const_nis_name name, int search_parent,
- /* Choose which entry should be evicted from the cache. */
- loc = &nis_server_cache[0];
- if (*loc != NULL)
-- for (i = 1; i < 16; ++i)
-- if (nis_server_cache[i] == NULL)
-- {
-+ {
-+ for (i = 1; i < 16; ++i)
-+ if (nis_server_cache[i] == NULL)
-+ {
-+ loc = &nis_server_cache[i];
-+ break;
-+ }
-+ else if ((*loc)->uses > nis_server_cache[i]->uses
-+ || ((*loc)->uses == nis_server_cache[i]->uses
-+ && (*loc)->expires > nis_server_cache[i]->expires))
- loc = &nis_server_cache[i];
-- break;
-- }
-- else if ((*loc)->uses > nis_server_cache[i]->uses
-- || ((*loc)->uses == nis_server_cache[i]->uses
-- && (*loc)->expires > nis_server_cache[i]->expires))
-- loc = &nis_server_cache[i];
-+ }
- old = *loc;
- *loc = new;
-
-diff --git a/stdlib/setenv.c b/stdlib/setenv.c
-index da61ee0..e66045f 100644
---- a/stdlib/setenv.c
-+++ b/stdlib/setenv.c
-@@ -278,18 +278,20 @@ unsetenv (const char *name)
- ep = __environ;
- if (ep != NULL)
- while (*ep != NULL)
-- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-- {
-- /* Found it. Remove this pointer by moving later ones back. */
-- char **dp = ep;
--
-- do
-- dp[0] = dp[1];
-- while (*dp++);
-- /* Continue the loop in case NAME appears again. */
-- }
-- else
-- ++ep;
-+ {
-+ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-+ {
-+ /* Found it. Remove this pointer by moving later ones back. */
-+ char **dp = ep;
-+
-+ do
-+ dp[0] = dp[1];
-+ while (*dp++);
-+ /* Continue the loop in case NAME appears again. */
-+ }
-+ else
-+ ++ep;
-+ }
-
- UNLOCK;
-
---
-2.7.4
-
diff --git a/packages/glibc/2.17/102-fix-signed-shift-overlow.patch b/packages/glibc/2.17/102-fix-signed-shift-overlow.patch
deleted file mode 100644
index ef49f83..0000000
--- a/packages/glibc/2.17/102-fix-signed-shift-overlow.patch
+++ /dev/null
@@ -1,98 +0,0 @@
-commit 5542236837c5c41435f8282ec92799f480c36f18
-Author: Paul Eggert <eggert@cs.ucla.edu>
-Date: Tue Jul 21 22:50:29 2015 -0700
-
- Port the 0x7efe...feff pattern to GCC 6.
-
- See Steve Ellcey's bug report in:
- https://sourceware.org/ml/libc-alpha/2015-07/msg00673.html
- * string/memrchr.c (MEMRCHR):
- * string/rawmemchr.c (RAWMEMCHR):
- * string/strchr.c (strchr):
- * string/strchrnul.c (STRCHRNUL):
- Rewrite code to avoid issues with signed shift overflow.
-
-diff --git a/string/memrchr.c b/string/memrchr.c
-index 0c8fd84..86cd5b9 100644
---- a/string/memrchr.c
-+++ b/string/memrchr.c
-@@ -96,15 +96,8 @@ MEMRCHR
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
--
-- if (sizeof (longword) != 4 && sizeof (longword) != 8)
-- abort ();
--
--#if LONG_MAX <= LONG_MAX_32_BITS
-- magic_bits = 0x7efefeff;
--#else
-- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
--#endif
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/rawmemchr.c b/string/rawmemchr.c
-index 05b22be..228ca9d 100644
---- a/string/rawmemchr.c
-+++ b/string/rawmemchr.c
-@@ -86,15 +86,8 @@ RAWMEMCHR (s, c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
--
-- if (sizeof (longword) != 4 && sizeof (longword) != 8)
-- abort ();
--
--#if LONG_MAX <= LONG_MAX_32_BITS
-- magic_bits = 0x7efefeff;
--#else
-- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
--#endif
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/strchr.c b/string/strchr.c
-index 5f90075..f13b2b3 100644
---- a/string/strchr.c
-+++ b/string/strchr.c
-@@ -60,13 +60,8 @@ strchr (const char *s, int c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
-- switch (sizeof (longword))
-- {
-- case 4: magic_bits = 0x7efefeffL; break;
-- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
-- default:
-- abort ();
-- }
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/strchrnul.c b/string/strchrnul.c
-index 2678f1d..daf0b3f 100644
---- a/string/strchrnul.c
-+++ b/string/strchrnul.c
-@@ -66,13 +66,8 @@ STRCHRNUL (s, c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
-- switch (sizeof (longword))
-- {
-- case 4: magic_bits = 0x7efefeffL; break;
-- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
-- default:
-- abort ();
-- }
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
diff --git a/packages/glibc/2.17/105-misleading-indentation.patch b/packages/glibc/2.17/105-misleading-indentation.patch
deleted file mode 100644
index 1dd8d85..0000000
--- a/packages/glibc/2.17/105-misleading-indentation.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-commit 976ef870542580cf5fed896c2c652b3e1a95f9da
-Author: Steve Ellcey <sellcey@mips.com>
-Date: Fri Dec 11 09:19:37 2015 -0800
-
- Fix indentation.
-
- * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
- Fix indentation.
-
-diff --git a/sysdeps/ieee754/flt-32/k_rem_pio2f.c b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-index 0c7685c..392afdb 100644
---- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-+++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-@@ -65,7 +65,9 @@ int __kernel_rem_pio2f(float *x, float *y, int e0, int nx, int prec, const int32
-
- /* compute q[0],q[1],...q[jk] */
- for (i=0;i<=jk;i++) {
-- for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw;
-+ for(j=0,fw=0.0;j<=jx;j++)
-+ fw += x[j]*f[jx+i-j];
-+ q[i] = fw;
- }
-
- jz = jk;
diff --git a/packages/glibc/2.17/300-macos-cross-rpcgen.patch b/packages/glibc/2.17/300-macos-cross-rpcgen.patch
deleted file mode 100644
index e654644..0000000
--- a/packages/glibc/2.17/300-macos-cross-rpcgen.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-commit ae7080d30c68cfa0c81ce3422dca948f64a94f50
-Author: Jia Liu <proljc@gmail.com>
-Date: Sat Sep 7 00:01:08 2013 +0800
-
- sunrpc/rpc/types.h: fix OS X and FreeBSD build problems
-
- When I build arm-linux-gcc on OS X, I find glibc will get a build error
- in sunrpc/rpc/types.h, so I add __APPLE_CC__ to make OS X build OK.
- For FreeBSD, Add __FreeBSD__ to make it build OK, too.
-
- URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00155.html
- URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00217.html
- URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00240.html
- Signed-off-by: Jia Liu <proljc@gmail.com>
- Signed-off-by: Mike Frysinger <vapier@gentoo.org>
-
-diff --git a/sunrpc/rpc/types.h b/sunrpc/rpc/types.h
-index 3dca5c4..beded52 100644
---- a/sunrpc/rpc/types.h
-+++ b/sunrpc/rpc/types.h
-@@ -69,6 +69,11 @@ typedef unsigned long rpcport_t;
- #include <sys/types.h>
- #endif
-
-+#if defined __APPLE_CC__ || defined __FreeBSD__
-+# define __u_char_defined
-+# define __daddr_t_defined
-+#endif
-+
- #ifndef __u_char_defined
- typedef __u_char u_char;
- typedef __u_short u_short;
diff --git a/packages/glibc/2.17/920-fix-rpc_parse-format.patch b/packages/glibc/2.17/920-fix-rpc_parse-format.patch
deleted file mode 100644
index 37e58da..0000000
--- a/packages/glibc/2.17/920-fix-rpc_parse-format.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-commit 5874510faaf3cbd0bb112aaacab9f225002beed1
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Tue Nov 8 23:44:51 2016 +0000
-
- Fix rpcgen buffer overrun (bug 20790).
-
- Building with GCC 7 produces an error building rpcgen:
-
- rpc_parse.c: In function 'get_prog_declaration':
- rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ~~~~^
- rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
- That buffer overrun is for the case where the .x file declares a
- program with a million arguments. The strcpy two lines above can
- generate a buffer overrun much more simply for a long argument name.
-
- The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
- provides a bound on the buffer size needed, so this patch just changes
- the buffer size to MAXLINESIZE to avoid both possible buffer
- overruns. A testcase is added that rpcgen does not crash with a
- 500-character argument name, where it previously crashed.
-
- It would not at all surprise me if there are many other ways of
- crashing rpcgen with either valid or invalid input; fuzz testing would
- likely find various such bugs, though I don't think they are that
- important to fix (rpcgen is not that likely to be used with untrusted
- .x files as input). (As well as fuzz-findable bugs there are probably
- also issues when various int variables get overflowed on very large
- input.) The test infrastructure for rpcgen-not-crashing tests would
- need extending if tests are to be added for cases where rpcgen should
- produce an error, as opposed to cases where it should succeed.
-
- Tested for x86_64 and x86.
-
- [BZ #20790]
- * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
- to MAXLINESIZE.
- * sunrpc/bug20790.x: New file.
- * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
- variable.
- [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
- [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
-
-diff --git a/sunrpc/rpc_parse.c b/sunrpc/rpc_parse.c
-index 1a1df6d8c2..505a6554cf 100644
---- a/sunrpc/rpc_parse.c
-+++ b/sunrpc/rpc_parse.c
-@@ -521,7 +521,7 @@ static void
- get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
- {
- token tok;
-- char name[10]; /* argument name */
-+ char name[MAXLINESIZE]; /* argument name */
-
- if (dkind == DEF_PROGRAM)
- {
diff --git a/packages/glibc/2.17/940-nis-bogus-conditional.patch b/packages/glibc/2.17/940-nis-bogus-conditional.patch
deleted file mode 100644
index 09b38cf..0000000
--- a/packages/glibc/2.17/940-nis-bogus-conditional.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Wed Dec 21 23:44:01 2016 +0000
-
- Fix nss_nisplus build with mainline GCC (bug 20978).
-
- glibc build with current mainline GCC fails because
- nis/nss_nisplus/nisplus-alias.c contains code
-
- if (name != NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
- }
-
- char buf[strlen (name) + 9 + tablename_len];
-
- producing an error about strlen being called on a pointer that is
- always NULL (and a subsequent use of that pointer with a %s format in
- snprintf).
-
- As Andreas noted, the bogus conditional comes from a 1997 change:
-
- - if (name == NULL || strlen(name) > 8)
- - return NSS_STATUS_NOTFOUND;
- - else
- + if (name != NULL || strlen(name) <= 8)
-
- So the intention is clearly to return an error for NULL name.
-
- This patch duly inverts the sense of the conditional. It fixes the
- build with GCC mainline, and passes usual glibc testsuite testing for
- x86_64. However, I have not tried any actual substantive nisplus
- testing, do not have an environment for such testing, and do not know
- whether it is possible that strlen (name) or tablename_len might be
- large so that the VLA for buf is actually a security issue. However,
- if it is a security issue, there are plenty of other similar instances
- in the nisplus code (that haven't been hidden by a bogus comparison
- with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
- string passed to nis_list, so a local fix in the caller wouldn't
- suffice anyway (see bug 20987). (Calls to strdupa and other such
- macros that use alloca must be considered equally questionable
- regarding stack overflow issues as direct calls to alloca and VLA
- declarations.)
-
- [BZ #20978]
- * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
- Compare name == NULL, not name != NULL.
-
-diff --git a/nis/nss_nisplus/nisplus-alias.c b/nis/nss_nisplus/nisplus-alias.c
-index 7f698b4e6d..cb5acce01d 100644
---- a/nis/nss_nisplus/nisplus-alias.c
-+++ b/nis/nss_nisplus/nisplus-alias.c
-@@ -291,7 +291,7 @@ _nss_nisplus_getaliasbyname_r (const char *name, struct aliasent *alias,
- return status;
- }
-
-- if (name != NULL)
-+ if (name == NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.17/998-obstack-common.patch b/packages/glibc/2.17/998-obstack-common.patch
deleted file mode 100644
index 4b95f06..0000000
--- a/packages/glibc/2.17/998-obstack-common.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-commit 39b1f6172a2f9ddc74a8f82d6e84dd13b22dbaf2
-Author: Peter Collingbourne <pcc@google.com>
-Date: Wed May 15 20:28:08 2013 +0200
-
- Move _obstack_compat out of common
-
- it is impossible to create an alias of a common symbol (as
- compat_symbol does), because common symbols do not have a section or
- an offset until linked. GNU as tolerates aliases of common symbols by
- simply creating another common symbol, but other assemblers (notably
- LLVM's integrated assembler) are less tolerant.
-
- 2013-05-15 Peter Collingbourne <pcc@google.com>
-
- * malloc/obstack.c (_obstack_compat): Add initializer.
- -
-
-diff --git a/malloc/obstack.c b/malloc/obstack.c
-index 25a90514f7..c3c7db4a96 100644
---- a/malloc/obstack.c
-+++ b/malloc/obstack.c
-@@ -115,7 +115,7 @@ int obstack_exit_failure = EXIT_FAILURE;
- /* A looong time ago (before 1994, anyway; we're not sure) this global variable
- was used by non-GNU-C macros to avoid multiple evaluation. The GNU C
- library still exports it because somebody might use it. */
--struct obstack *_obstack_compat;
-+struct obstack *_obstack_compat = 0;
- compat_symbol (libc, _obstack_compat, _obstack, GLIBC_2_0);
- # endif
- # endif
diff --git a/packages/glibc/2.18/100-4f2bcda-ARM-Fix-clone-code-when-built-for-Thumb.patch b/packages/glibc/2.18/0000-4f2bcda-ARM-Fix-clone-code-when-built-for-Thumb.patch
index 40e3632..d441b0c 100644
--- a/packages/glibc/2.18/100-4f2bcda-ARM-Fix-clone-code-when-built-for-Thumb.patch
+++ b/packages/glibc/2.18/0000-4f2bcda-ARM-Fix-clone-code-when-built-for-Thumb.patch
@@ -17,11 +17,15 @@ Date: Thu Aug 29 20:10:26 2013 +0100
(cherry picked from commit 6b06ac56cdfc9293908724e51e827534e97819aa)
-diff --git a/NEWS b/NEWS
-index b023c30..f64fb82 100644
+---
+ NEWS | 6 ++++++
+ ports/ChangeLog.arm | 6 ++++++
+ ports/sysdeps/unix/sysv/linux/arm/clone.S | 4 ++--
+ 3 files changed, 14 insertions(+), 2 deletions(-)
+
--- a/NEWS
+++ b/NEWS
-@@ -5,6 +5,12 @@ See the end for copying conditions.
+@@ -5,6 +5,12 @@
Please send GNU C library bug reports via <http://sourceware.org/bugzilla/>
using `glibc' in the "product" field.
@@ -34,8 +38,6 @@ index b023c30..f64fb82 100644
Version 2.18
* The following bugs are resolved with this release:
-diff --git a/ports/ChangeLog.arm b/ports/ChangeLog.arm
-index 1e7a35c..54debd7 100644
--- a/ports/ChangeLog.arm
+++ b/ports/ChangeLog.arm
@@ -1,3 +1,9 @@
@@ -48,11 +50,9 @@ index 1e7a35c..54debd7 100644
2013-07-03 Joseph Myers <joseph@codesourcery.com>
* sysdeps/arm/include/bits/setjmp.h [_ISOMAC] (JMP_BUF_REGLIST):
-diff --git a/ports/sysdeps/unix/sysv/linux/arm/clone.S b/ports/sysdeps/unix/sysv/linux/arm/clone.S
-index ce9c2a5..6e74fa7 100644
--- a/ports/sysdeps/unix/sysv/linux/arm/clone.S
+++ b/ports/sysdeps/unix/sysv/linux/arm/clone.S
-@@ -93,8 +93,8 @@ PSEUDO_END (__clone)
+@@ -93,8 +93,8 @@
mov lr, pc
bx ip
#else
diff --git a/packages/glibc/2.18/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.18/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
new file mode 100644
index 0000000..5d724b2
--- /dev/null
+++ b/packages/glibc/2.18/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
@@ -0,0 +1,75 @@
+From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
+From: Yvan Roux <yvan.roux@linaro.org>
+Date: Fri, 15 Apr 2016 13:29:26 +0200
+Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
+ -Wparentheses
+
+---
+ nis/nis_call.c | 20 +++++++++++---------
+ stdlib/setenv.c | 24 +++++++++++++-----------
+ 2 files changed, 24 insertions(+), 20 deletions(-)
+
+--- a/nis/nis_call.c
++++ b/nis/nis_call.c
+@@ -680,16 +680,18 @@
+ /* Choose which entry should be evicted from the cache. */
+ loc = &nis_server_cache[0];
+ if (*loc != NULL)
+- for (i = 1; i < 16; ++i)
+- if (nis_server_cache[i] == NULL)
+- {
++ {
++ for (i = 1; i < 16; ++i)
++ if (nis_server_cache[i] == NULL)
++ {
++ loc = &nis_server_cache[i];
++ break;
++ }
++ else if ((*loc)->uses > nis_server_cache[i]->uses
++ || ((*loc)->uses == nis_server_cache[i]->uses
++ && (*loc)->expires > nis_server_cache[i]->expires))
+ loc = &nis_server_cache[i];
+- break;
+- }
+- else if ((*loc)->uses > nis_server_cache[i]->uses
+- || ((*loc)->uses == nis_server_cache[i]->uses
+- && (*loc)->expires > nis_server_cache[i]->expires))
+- loc = &nis_server_cache[i];
++ }
+ old = *loc;
+ *loc = new;
+
+--- a/stdlib/setenv.c
++++ b/stdlib/setenv.c
+@@ -327,18 +327,20 @@
+ ep = __environ;
+ if (ep != NULL)
+ while (*ep != NULL)
+- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
+- {
+- /* Found it. Remove this pointer by moving later ones back. */
+- char **dp = ep;
++ {
++ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
++ {
++ /* Found it. Remove this pointer by moving later ones back. */
++ char **dp = ep;
+
+- do
+- dp[0] = dp[1];
+- while (*dp++);
+- /* Continue the loop in case NAME appears again. */
+- }
+- else
+- ++ep;
++ do
++ dp[0] = dp[1];
++ while (*dp++);
++ /* Continue the loop in case NAME appears again. */
++ }
++ else
++ ++ep;
++ }
+
+ UNLOCK;
+
diff --git a/packages/glibc/2.18/0002-fix-signed-shift-overlow.patch b/packages/glibc/2.18/0002-fix-signed-shift-overlow.patch
new file mode 100644
index 0000000..cf36780
--- /dev/null
+++ b/packages/glibc/2.18/0002-fix-signed-shift-overlow.patch
@@ -0,0 +1,97 @@
+commit 5542236837c5c41435f8282ec92799f480c36f18
+Author: Paul Eggert <eggert@cs.ucla.edu>
+Date: Tue Jul 21 22:50:29 2015 -0700
+
+ Port the 0x7efe...feff pattern to GCC 6.
+
+ See Steve Ellcey's bug report in:
+ https://sourceware.org/ml/libc-alpha/2015-07/msg00673.html
+ * string/memrchr.c (MEMRCHR):
+ * string/rawmemchr.c (RAWMEMCHR):
+ * string/strchr.c (strchr):
+ * string/strchrnul.c (STRCHRNUL):
+ Rewrite code to avoid issues with signed shift overflow.
+
+---
+ string/memrchr.c | 11 ++---------
+ string/rawmemchr.c | 11 ++---------
+ string/strchr.c | 9 ++-------
+ string/strchrnul.c | 9 ++-------
+ 4 files changed, 8 insertions(+), 32 deletions(-)
+
+--- a/string/memrchr.c
++++ b/string/memrchr.c
+@@ -96,15 +96,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+-
+- if (sizeof (longword) != 4 && sizeof (longword) != 8)
+- abort ();
+-
+-#if LONG_MAX <= LONG_MAX_32_BITS
+- magic_bits = 0x7efefeff;
+-#else
+- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
+-#endif
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/rawmemchr.c
++++ b/string/rawmemchr.c
+@@ -83,15 +83,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+-
+- if (sizeof (longword) != 4 && sizeof (longword) != 8)
+- abort ();
+-
+-#if LONG_MAX <= LONG_MAX_32_BITS
+- magic_bits = 0x7efefeff;
+-#else
+- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
+-#endif
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/strchr.c
++++ b/string/strchr.c
+@@ -63,13 +63,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+- switch (sizeof (longword))
+- {
+- case 4: magic_bits = 0x7efefeffL; break;
+- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
+- default:
+- abort ();
+- }
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/strchrnul.c
++++ b/string/strchrnul.c
+@@ -62,13 +62,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+- switch (sizeof (longword))
+- {
+- case 4: magic_bits = 0x7efefeffL; break;
+- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
+- default:
+- abort ();
+- }
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
diff --git a/packages/glibc/2.17/103-dl-openat64-variadic.patch b/packages/glibc/2.18/0003-dl-openat64-variadic.patch
index fe94b96..552db12 100644
--- a/packages/glibc/2.17/103-dl-openat64-variadic.patch
+++ b/packages/glibc/2.18/0003-dl-openat64-variadic.patch
@@ -177,8 +177,10 @@ Date: Tue Oct 20 11:54:09 2015 +0000
* wcsmbs/wcsnrtombs.c (__wcsnrtombs): Likewise.
* wcsmbs/wcsrtombs.c (__wcsrtombs): Likewise.
-diff --git a/sysdeps/unix/sysv/linux/dl-openat64.c b/sysdeps/unix/sysv/linux/dl-openat64.c
-index 7d100bb..7eea0ca 100644
+---
+ sysdeps/unix/sysv/linux/dl-openat64.c | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
--- a/sysdeps/unix/sysv/linux/dl-openat64.c
+++ b/sysdeps/unix/sysv/linux/dl-openat64.c
@@ -23,10 +23,7 @@
diff --git a/packages/glibc/2.18/104-unused-variables.patch b/packages/glibc/2.18/0004-unused-variables.patch
index 642edb1..0f17740 100644
--- a/packages/glibc/2.18/104-unused-variables.patch
+++ b/packages/glibc/2.18/0004-unused-variables.patch
@@ -19,8 +19,18 @@ Date: Fri Sep 18 20:27:20 2015 +0100
* timezone/private.h (time_t_min): Likewise. (time_t_max):
Likewise.
-diff --git a/resolv/base64.c b/resolv/base64.c
-index ea584ed..519e5d2 100644
+---
+ resolv/base64.c | 4 ----
+ sysdeps/ieee754/dbl-64/atnat2.h | 4 ----
+ sysdeps/ieee754/dbl-64/uexp.h | 2 +-
+ sysdeps/ieee754/dbl-64/upow.h | 2 --
+ sysdeps/ieee754/flt-32/e_log10f.c | 2 --
+ sysdeps/ieee754/flt-32/s_cosf.c | 2 --
+ sysdeps/ieee754/ldbl-128/e_lgammal_r.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_erfl.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_log1pl.c | 1 -
+ 9 files changed, 1 insertion(+), 18 deletions(-)
+
--- a/resolv/base64.c
+++ b/resolv/base64.c
@@ -40,10 +40,6 @@
@@ -34,8 +44,6 @@ index ea584ed..519e5d2 100644
#include <sys/types.h>
#include <sys/param.h>
#include <sys/socket.h>
-diff --git a/sysdeps/ieee754/dbl-64/atnat2.h b/sysdeps/ieee754/dbl-64/atnat2.h
-index e0d65af..82943f9 100644
--- a/sysdeps/ieee754/dbl-64/atnat2.h
+++ b/sysdeps/ieee754/dbl-64/atnat2.h
@@ -65,10 +65,8 @@
@@ -60,8 +68,6 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0x7f3321d2, 0xc002d97c} }, /* -3pi/4 */
/**/ u1 = {{0x00000000, 0x3c314c2a} }, /* 9.377e-19 */
/**/ u2 = {{0x00000000, 0x3bf955e4} }, /* 8.584e-20 */
-diff --git a/sysdeps/ieee754/dbl-64/uexp.h b/sysdeps/ieee754/dbl-64/uexp.h
-index 6817eaf..42b21f2 100644
--- a/sysdeps/ieee754/dbl-64/uexp.h
+++ b/sysdeps/ieee754/dbl-64/uexp.h
@@ -29,7 +29,7 @@
@@ -73,8 +79,6 @@ index 6817eaf..42b21f2 100644
err_0 = 1.000014, err_1 = 0.000016;
const static int4 bigint = 0x40862002,
badint = 0x40876000,smallint = 0x3C8fffff;
-diff --git a/sysdeps/ieee754/dbl-64/upow.h b/sysdeps/ieee754/dbl-64/upow.h
-index c8569a9..b4911e5 100644
--- a/sysdeps/ieee754/dbl-64/upow.h
+++ b/sysdeps/ieee754/dbl-64/upow.h
@@ -34,7 +34,6 @@
@@ -93,11 +97,9 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0xfefa3800, 0x3fe62e42}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x93c76730, 0x3d2ef357}}, /* ln(2)-ln2a */
/**/ bigu = {{0xfffffd2c, 0x4297ffff}}, /* 1.5*2**42 -724*2**-10 */
-diff --git a/sysdeps/ieee754/flt-32/e_log10f.c b/sysdeps/ieee754/flt-32/e_log10f.c
-index 96f0e81..1daeef7 100644
--- a/sysdeps/ieee754/flt-32/e_log10f.c
+++ b/sysdeps/ieee754/flt-32/e_log10f.c
-@@ -22,8 +22,6 @@ ivln10 = 4.3429449201e-01, /* 0x3ede5bd9 */
+@@ -22,8 +22,6 @@
log10_2hi = 3.0102920532e-01, /* 0x3e9a2080 */
log10_2lo = 7.9034151668e-07; /* 0x355427db */
@@ -106,11 +108,9 @@ index 96f0e81..1daeef7 100644
float
__ieee754_log10f(float x)
{
-diff --git a/sysdeps/ieee754/flt-32/s_cosf.c b/sysdeps/ieee754/flt-32/s_cosf.c
-index 864ab27..0affd40 100644
--- a/sysdeps/ieee754/flt-32/s_cosf.c
+++ b/sysdeps/ieee754/flt-32/s_cosf.c
-@@ -21,8 +21,6 @@ static char rcsid[] = "$NetBSD: s_cosf.c,v 1.4 1995/05/10 20:47:03 jtc Exp $";
+@@ -21,8 +21,6 @@
#include <math.h>
#include <math_private.h>
@@ -119,11 +119,9 @@ index 864ab27..0affd40 100644
#ifndef COSF
# define COSF_FUNC __cosf
#else
-diff --git a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-index 500aacc..ab5a96e 100644
--- a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
+++ b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-@@ -82,7 +82,6 @@ DIAG_IGNORE_NEEDS_COMMENT (4.6, "-Woverflow");
+@@ -74,7 +74,6 @@
static const long double PIL = 3.1415926535897932384626433832795028841972E0L;
static const long double MAXLGM = 1.0485738685148938358098967157129705071571E4928L;
static const long double one = 1.0L;
@@ -131,11 +129,9 @@ index 500aacc..ab5a96e 100644
static const long double huge = 1.0e4000L;
/* log gamma(x) = ( x - 0.5 ) * log(x) - x + LS2PI + 1/x P(1/x^2)
-diff --git a/sysdeps/ieee754/ldbl-128/s_erfl.c b/sysdeps/ieee754/ldbl-128/s_erfl.c
-index fa4609f..08c80a3 100644
--- a/sysdeps/ieee754/ldbl-128/s_erfl.c
+++ b/sysdeps/ieee754/ldbl-128/s_erfl.c
-@@ -140,7 +140,6 @@ deval (long double x, const long double *p, int n)
+@@ -138,7 +138,6 @@
static const long double
tiny = 1e-4931L,
@@ -143,11 +139,9 @@ index fa4609f..08c80a3 100644
one = 1.0L,
two = 2.0L,
/* 2/sqrt(pi) - 1 */
-diff --git a/sysdeps/ieee754/ldbl-128/s_log1pl.c b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-index ff759bc..9609550 100644
--- a/sysdeps/ieee754/ldbl-128/s_log1pl.c
+++ b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-@@ -117,7 +117,6 @@ static const long double C2 = 1.428606820309417232121458176568075500134E-6L;
+@@ -116,7 +116,6 @@
static const long double sqrth = 0.7071067811865475244008443621048490392848L;
/* ln (2^16384 * (1 - 2^-113)) */
diff --git a/packages/glibc/2.18/0005-misleading-indentation.patch b/packages/glibc/2.18/0005-misleading-indentation.patch
new file mode 100644
index 0000000..8e08259
--- /dev/null
+++ b/packages/glibc/2.18/0005-misleading-indentation.patch
@@ -0,0 +1,26 @@
+commit 976ef870542580cf5fed896c2c652b3e1a95f9da
+Author: Steve Ellcey <sellcey@mips.com>
+Date: Fri Dec 11 09:19:37 2015 -0800
+
+ Fix indentation.
+
+ * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
+ Fix indentation.
+
+---
+ sysdeps/ieee754/flt-32/k_rem_pio2f.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+--- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
++++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
+@@ -65,7 +65,9 @@
+
+ /* compute q[0],q[1],...q[jk] */
+ for (i=0;i<=jk;i++) {
+- for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw;
++ for(j=0,fw=0.0;j<=jx;j++)
++ fw += x[j]*f[jx+i-j];
++ q[i] = fw;
+ }
+
+ jz = jk;
diff --git a/packages/glibc/2.20/106-dl-open-array-bounds.patch b/packages/glibc/2.18/0006-dl-open-array-bounds.patch
index 08a9076..83eb0b3 100644
--- a/packages/glibc/2.20/106-dl-open-array-bounds.patch
+++ b/packages/glibc/2.18/0006-dl-open-array-bounds.patch
@@ -4,11 +4,13 @@ Date: Fri Apr 17 12:11:58 2015 -0700
Fuller check for invalid NSID in _dl_open.
-diff --git a/elf/dl-open.c b/elf/dl-open.c
-index 0dbe07f..2d0e082 100644
+---
+ elf/dl-open.c | 12 +++++++++---
+ 1 file changed, 9 insertions(+), 3 deletions(-)
+
--- a/elf/dl-open.c
+++ b/elf/dl-open.c
-@@ -211,7 +211,7 @@ dl_open_worker (void *a)
+@@ -211,7 +211,7 @@
struct link_map *l = _dl_find_dso_for_object ((ElfW(Addr)) caller_dlopen);
if (l)
@@ -17,7 +19,7 @@ index 0dbe07f..2d0e082 100644
if (args->nsid == __LM_ID_CALLER)
args->nsid = call_map->l_ns;
-@@ -619,8 +619,14 @@ no more namespaces available for dlmopen()"));
+@@ -627,8 +627,14 @@
/* Never allow loading a DSO in a namespace which is empty. Such
direct placements is only causing problems. Also don't allow
loading into a namespace used for auditing. */
diff --git a/packages/glibc/2.18/110-2770d15-Fix-PI-mutex-check-in-pthread_cond_broadcast-and-pthread_cond_signal.patch b/packages/glibc/2.18/0007-2770d15-Fix-PI-mutex-check-in-pthread_cond_broadcast-and-pthread_cond_signal.patch
index 7ad9fdf..5249bf3 100644
--- a/packages/glibc/2.18/110-2770d15-Fix-PI-mutex-check-in-pthread_cond_broadcast-and-pthread_cond_signal.patch
+++ b/packages/glibc/2.18/0007-2770d15-Fix-PI-mutex-check-in-pthread_cond_broadcast-and-pthread_cond_signal.patch
@@ -10,11 +10,16 @@ Date: Thu Oct 3 08:26:21 2013 +0530
of PTHREAD_MUTEX_ROBUST_NORMAL_NP. It has now been replaced by the
already existing convenience macro USE_REQUEUE_PI.
-diff --git a/NEWS b/NEWS
-index f64fb82..fb6069d 100644
+---
+ NEWS | 2 +-
+ nptl/ChangeLog | 9 +++++++++
+ nptl/pthread_cond_broadcast.c | 5 +----
+ nptl/pthread_cond_signal.c | 7 +------
+ 4 files changed, 12 insertions(+), 11 deletions(-)
+
--- a/NEWS
+++ b/NEWS
-@@ -9,7 +9,7 @@ Version 2.18.1
+@@ -9,7 +9,7 @@
* The following bugs are resolved with this release:
@@ -23,8 +28,6 @@ index f64fb82..fb6069d 100644
Version 2.18
-diff --git a/nptl/ChangeLog b/nptl/ChangeLog
-index eae5079..2d78490 100644
--- a/nptl/ChangeLog
+++ b/nptl/ChangeLog
@@ -1,3 +1,12 @@
@@ -40,11 +43,9 @@ index eae5079..2d78490 100644
2013-07-23 David S. Miller <davem@davemloft.net>
* tst-cancel4.c (WRITE_BUFFER_SIZE): Adjust comment.
-diff --git a/nptl/pthread_cond_broadcast.c b/nptl/pthread_cond_broadcast.c
-index 0702ec0..7ba9efa 100644
--- a/nptl/pthread_cond_broadcast.c
+++ b/nptl/pthread_cond_broadcast.c
-@@ -63,10 +63,7 @@ __pthread_cond_broadcast (cond)
+@@ -63,10 +63,7 @@
#if (defined lll_futex_cmp_requeue_pi \
&& defined __ASSUME_REQUEUE_PI)
@@ -56,11 +57,9 @@ index 0702ec0..7ba9efa 100644
{
if (lll_futex_cmp_requeue_pi (&cond->__data.__futex, 1, INT_MAX,
&mut->__data.__lock, futex_val,
-diff --git a/nptl/pthread_cond_signal.c b/nptl/pthread_cond_signal.c
-index 102d0b3..ffc35dc 100644
--- a/nptl/pthread_cond_signal.c
+++ b/nptl/pthread_cond_signal.c
-@@ -49,14 +49,9 @@ __pthread_cond_signal (cond)
+@@ -49,14 +49,9 @@
#if (defined lll_futex_cmp_requeue_pi \
&& defined __ASSUME_REQUEUE_PI)
diff --git a/packages/glibc/2.17/120-support-make4.patch b/packages/glibc/2.18/0008-support-make4.patch
index ca2bae0..a9be159 100644
--- a/packages/glibc/2.17/120-support-make4.patch
+++ b/packages/glibc/2.18/0008-support-make4.patch
@@ -10,11 +10,14 @@ X-Git-Url: https://sourceware.org/git/?p=glibc.git;a=commitdiff_plain;h=28d708c4
Accept make versions 4.0 and greater
---
-diff --git a/configure b/configure
-index f382138..5e61abd 100755
+---
+ configure | 2 +-
+ configure.in | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
--- a/configure
+++ b/configure
-@@ -4761,7 +4761,7 @@ $as_echo_n "checking version of $MAKE... " >&6; }
+@@ -4772,7 +4772,7 @@
ac_prog_version=`$MAKE --version 2>&1 | sed -n 's/^.*GNU Make[^0-9]*\([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -23,11 +26,9 @@ index f382138..5e61abd 100755
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
-diff --git a/configure.in b/configure.in
-index 49b70fd..6da8efd 100644
--- a/configure.in
+++ b/configure.in
-@@ -984,7 +984,7 @@ AC_CHECK_PROG_VER(CC, ${ac_tool_prefix}gcc ${ac_tool_prefix}cc, -v,
+@@ -989,7 +989,7 @@
critic_missing="$critic_missing gcc")
AC_CHECK_PROG_VER(MAKE, gnumake gmake make, --version,
[GNU Make[^0-9]*\([0-9][0-9.]*\)],
diff --git a/packages/glibc/2.18/130-arm-unwind.patch b/packages/glibc/2.18/0009-arm-unwind.patch
index 69cc07a..85288d0 100644
--- a/packages/glibc/2.18/130-arm-unwind.patch
+++ b/packages/glibc/2.18/0009-arm-unwind.patch
@@ -1,6 +1,12 @@
-diff -urN glibc-2.18.orig/nptl/sysdeps/pthread/unwind-forcedunwind.c glibc-2.18/nptl/sysdeps/pthread/unwind-forcedunwind.c
---- glibc-2.18.orig/nptl/sysdeps/pthread/unwind-forcedunwind.c 2013-08-11 02:52:55.000000000 +0400
-+++ glibc-2.18/nptl/sysdeps/pthread/unwind-forcedunwind.c 2016-09-15 02:30:09.199939478 +0300
+---
+ nptl/sysdeps/pthread/unwind-forcedunwind.c | 2 +-
+ ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c | 2 +-
+ ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c | 2 +-
+ sysdeps/gnu/unwind-resume.c | 2 +-
+ 4 files changed, 4 insertions(+), 4 deletions(-)
+
+--- a/nptl/sysdeps/pthread/unwind-forcedunwind.c
++++ b/nptl/sysdeps/pthread/unwind-forcedunwind.c
@@ -24,7 +24,7 @@
#include <gnu/lib-names.h>
@@ -10,9 +16,8 @@ diff -urN glibc-2.18.orig/nptl/sysdeps/pthread/unwind-forcedunwind.c glibc-2.18/
static _Unwind_Reason_Code (*libgcc_s_personality)
(int, _Unwind_Action, _Unwind_Exception_Class, struct _Unwind_Exception *,
struct _Unwind_Context *);
-diff -urN glibc-2.18.orig/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c glibc-2.18/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c
---- glibc-2.18.orig/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c 2013-08-11 02:52:55.000000000 +0400
-+++ glibc-2.18/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c 2016-09-15 02:29:07.096945862 +0300
+--- a/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c
++++ b/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c
@@ -22,7 +22,7 @@
#include <pthreadP.h>
@@ -22,9 +27,8 @@ diff -urN glibc-2.18.orig/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedun
static _Unwind_Reason_Code (*libgcc_s_personality)
(_Unwind_State, struct _Unwind_Exception *, struct _Unwind_Context *);
static _Unwind_Reason_Code (*libgcc_s_forcedunwind)
-diff -urN glibc-2.18.orig/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c glibc-2.18/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c
---- glibc-2.18.orig/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c 2013-08-11 02:52:55.000000000 +0400
-+++ glibc-2.18/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c 2016-09-15 02:29:37.352917115 +0300
+--- a/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c
++++ b/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c
@@ -20,7 +20,7 @@
#include <stdio.h>
#include <unwind.h>
@@ -34,9 +38,8 @@ diff -urN glibc-2.18.orig/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c
static _Unwind_Reason_Code (*libgcc_s_personality)
(_Unwind_State, struct _Unwind_Exception *, struct _Unwind_Context *);
-diff -urN glibc-2.18.orig/sysdeps/gnu/unwind-resume.c glibc-2.18/sysdeps/gnu/unwind-resume.c
---- glibc-2.18.orig/sysdeps/gnu/unwind-resume.c 2013-08-11 02:52:55.000000000 +0400
-+++ glibc-2.18/sysdeps/gnu/unwind-resume.c 2016-09-15 02:29:53.376431503 +0300
+--- a/sysdeps/gnu/unwind-resume.c
++++ b/sysdeps/gnu/unwind-resume.c
@@ -21,7 +21,7 @@
#include <unwind.h>
#include <gnu/lib-names.h>
diff --git a/packages/glibc/2.16.0/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.18/0010-Fix-combreloc-test-BSD-grep.patch
index 3c34e01..e457c3c 100644
--- a/packages/glibc/2.16.0/140-Fix-combreloc-test-BSD-grep.patch
+++ b/packages/glibc/2.18/0010-Fix-combreloc-test-BSD-grep.patch
@@ -13,16 +13,13 @@ by configure as "not found". As a result, support for "-z combreloc"
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
+ configure | 2 +-
+ configure.in | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
-diff --git a/configure b/configure
-index eecd0ac..0118bd1 100755
--- a/configure
+++ b/configure
-@@ -5804,7 +5804,7 @@ if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
+@@ -6307,7 +6307,7 @@
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; }
then
@@ -31,11 +28,9 @@ index eecd0ac..0118bd1 100755
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
-diff --git a/configure.ac b/configure.ac
-index 4a77411..19f6d87 100644
--- a/configure.in
+++ b/configure.in
-@@ -1391,7 +1391,7 @@ dnl cross-platform since the gcc used can be a cross compiler. Without
+@@ -1596,7 +1596,7 @@
dnl introducing new options this is not easily doable. Instead use a tool
dnl which always is cross-platform: readelf. To detect whether -z combreloc
dnl look for a section named .rel.dyn.
@@ -44,6 +39,3 @@ index 4a77411..19f6d87 100644
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
---
-2.9.3
-
diff --git a/packages/glibc/2.18/0011-macos-cross-rpcgen.patch b/packages/glibc/2.18/0011-macos-cross-rpcgen.patch
new file mode 100644
index 0000000..b439b0f
--- /dev/null
+++ b/packages/glibc/2.18/0011-macos-cross-rpcgen.patch
@@ -0,0 +1,34 @@
+commit ae7080d30c68cfa0c81ce3422dca948f64a94f50
+Author: Jia Liu <proljc@gmail.com>
+Date: Sat Sep 7 00:01:08 2013 +0800
+
+ sunrpc/rpc/types.h: fix OS X and FreeBSD build problems
+
+ When I build arm-linux-gcc on OS X, I find glibc will get a build error
+ in sunrpc/rpc/types.h, so I add __APPLE_CC__ to make OS X build OK.
+ For FreeBSD, Add __FreeBSD__ to make it build OK, too.
+
+ URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00155.html
+ URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00217.html
+ URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00240.html
+ Signed-off-by: Jia Liu <proljc@gmail.com>
+ Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+
+---
+ sunrpc/rpc/types.h | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/sunrpc/rpc/types.h
++++ b/sunrpc/rpc/types.h
+@@ -69,6 +69,11 @@
+ #include <sys/types.h>
+ #endif
+
++#if defined __APPLE_CC__ || defined __FreeBSD__
++# define __u_char_defined
++# define __daddr_t_defined
++#endif
++
+ #ifndef __u_char_defined
+ typedef __u_char u_char;
+ typedef __u_short u_short;
diff --git a/packages/glibc/2.18/0012-fix-rpc_parse-format.patch b/packages/glibc/2.18/0012-fix-rpc_parse-format.patch
new file mode 100644
index 0000000..341d541
--- /dev/null
+++ b/packages/glibc/2.18/0012-fix-rpc_parse-format.patch
@@ -0,0 +1,62 @@
+commit 5874510faaf3cbd0bb112aaacab9f225002beed1
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Tue Nov 8 23:44:51 2016 +0000
+
+ Fix rpcgen buffer overrun (bug 20790).
+
+ Building with GCC 7 produces an error building rpcgen:
+
+ rpc_parse.c: In function 'get_prog_declaration':
+ rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ~~~~^
+ rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+ That buffer overrun is for the case where the .x file declares a
+ program with a million arguments. The strcpy two lines above can
+ generate a buffer overrun much more simply for a long argument name.
+
+ The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
+ provides a bound on the buffer size needed, so this patch just changes
+ the buffer size to MAXLINESIZE to avoid both possible buffer
+ overruns. A testcase is added that rpcgen does not crash with a
+ 500-character argument name, where it previously crashed.
+
+ It would not at all surprise me if there are many other ways of
+ crashing rpcgen with either valid or invalid input; fuzz testing would
+ likely find various such bugs, though I don't think they are that
+ important to fix (rpcgen is not that likely to be used with untrusted
+ .x files as input). (As well as fuzz-findable bugs there are probably
+ also issues when various int variables get overflowed on very large
+ input.) The test infrastructure for rpcgen-not-crashing tests would
+ need extending if tests are to be added for cases where rpcgen should
+ produce an error, as opposed to cases where it should succeed.
+
+ Tested for x86_64 and x86.
+
+ [BZ #20790]
+ * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
+ to MAXLINESIZE.
+ * sunrpc/bug20790.x: New file.
+ * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
+ variable.
+ [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
+ [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
+
+---
+ sunrpc/rpc_parse.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/sunrpc/rpc_parse.c
++++ b/sunrpc/rpc_parse.c
+@@ -521,7 +521,7 @@
+ get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
+ {
+ token tok;
+- char name[10]; /* argument name */
++ char name[MAXLINESIZE]; /* argument name */
+
+ if (dkind == DEF_PROGRAM)
+ {
diff --git a/packages/glibc/2.18/0013-nis-bogus-conditional.patch b/packages/glibc/2.18/0013-nis-bogus-conditional.patch
new file mode 100644
index 0000000..e728368
--- /dev/null
+++ b/packages/glibc/2.18/0013-nis-bogus-conditional.patch
@@ -0,0 +1,64 @@
+commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Wed Dec 21 23:44:01 2016 +0000
+
+ Fix nss_nisplus build with mainline GCC (bug 20978).
+
+ glibc build with current mainline GCC fails because
+ nis/nss_nisplus/nisplus-alias.c contains code
+
+ if (name != NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
+ }
+
+ char buf[strlen (name) + 9 + tablename_len];
+
+ producing an error about strlen being called on a pointer that is
+ always NULL (and a subsequent use of that pointer with a %s format in
+ snprintf).
+
+ As Andreas noted, the bogus conditional comes from a 1997 change:
+
+ - if (name == NULL || strlen(name) > 8)
+ - return NSS_STATUS_NOTFOUND;
+ - else
+ + if (name != NULL || strlen(name) <= 8)
+
+ So the intention is clearly to return an error for NULL name.
+
+ This patch duly inverts the sense of the conditional. It fixes the
+ build with GCC mainline, and passes usual glibc testsuite testing for
+ x86_64. However, I have not tried any actual substantive nisplus
+ testing, do not have an environment for such testing, and do not know
+ whether it is possible that strlen (name) or tablename_len might be
+ large so that the VLA for buf is actually a security issue. However,
+ if it is a security issue, there are plenty of other similar instances
+ in the nisplus code (that haven't been hidden by a bogus comparison
+ with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
+ string passed to nis_list, so a local fix in the caller wouldn't
+ suffice anyway (see bug 20987). (Calls to strdupa and other such
+ macros that use alloca must be considered equally questionable
+ regarding stack overflow issues as direct calls to alloca and VLA
+ declarations.)
+
+ [BZ #20978]
+ * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
+ Compare name == NULL, not name != NULL.
+
+---
+ nis/nss_nisplus/nisplus-alias.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/nis/nss_nisplus/nisplus-alias.c
++++ b/nis/nss_nisplus/nisplus-alias.c
+@@ -291,7 +291,7 @@
+ return status;
+ }
+
+- if (name != NULL)
++ if (name == NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.18/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.18/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
deleted file mode 100644
index 6fd663a..0000000
--- a/packages/glibc/2.18/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
-From: Yvan Roux <yvan.roux@linaro.org>
-Date: Fri, 15 Apr 2016 13:29:26 +0200
-Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
- -Wparentheses
-
----
- ChangeLog | 5 +++++
- nis/nis_call.c | 20 +++++++++++---------
- stdlib/setenv.c | 26 ++++++++++++++------------
- 3 files changed, 30 insertions(+), 21 deletions(-)
-
-diff --git a/nis/nis_call.c b/nis/nis_call.c
-index 3fa37e4..cb7839a 100644
---- a/nis/nis_call.c
-+++ b/nis/nis_call.c
-@@ -680,16 +680,18 @@ nis_server_cache_add (const_nis_name name, int search_parent,
- /* Choose which entry should be evicted from the cache. */
- loc = &nis_server_cache[0];
- if (*loc != NULL)
-- for (i = 1; i < 16; ++i)
-- if (nis_server_cache[i] == NULL)
-- {
-+ {
-+ for (i = 1; i < 16; ++i)
-+ if (nis_server_cache[i] == NULL)
-+ {
-+ loc = &nis_server_cache[i];
-+ break;
-+ }
-+ else if ((*loc)->uses > nis_server_cache[i]->uses
-+ || ((*loc)->uses == nis_server_cache[i]->uses
-+ && (*loc)->expires > nis_server_cache[i]->expires))
- loc = &nis_server_cache[i];
-- break;
-- }
-- else if ((*loc)->uses > nis_server_cache[i]->uses
-- || ((*loc)->uses == nis_server_cache[i]->uses
-- && (*loc)->expires > nis_server_cache[i]->expires))
-- loc = &nis_server_cache[i];
-+ }
- old = *loc;
- *loc = new;
-
-diff --git a/stdlib/setenv.c b/stdlib/setenv.c
-index da61ee0..e66045f 100644
---- a/stdlib/setenv.c
-+++ b/stdlib/setenv.c
-@@ -278,18 +278,20 @@ unsetenv (const char *name)
- ep = __environ;
- if (ep != NULL)
- while (*ep != NULL)
-- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-- {
-- /* Found it. Remove this pointer by moving later ones back. */
-- char **dp = ep;
--
-- do
-- dp[0] = dp[1];
-- while (*dp++);
-- /* Continue the loop in case NAME appears again. */
-- }
-- else
-- ++ep;
-+ {
-+ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-+ {
-+ /* Found it. Remove this pointer by moving later ones back. */
-+ char **dp = ep;
-+
-+ do
-+ dp[0] = dp[1];
-+ while (*dp++);
-+ /* Continue the loop in case NAME appears again. */
-+ }
-+ else
-+ ++ep;
-+ }
-
- UNLOCK;
-
---
-2.7.4
-
diff --git a/packages/glibc/2.18/102-fix-signed-shift-overlow.patch b/packages/glibc/2.18/102-fix-signed-shift-overlow.patch
deleted file mode 100644
index ef49f83..0000000
--- a/packages/glibc/2.18/102-fix-signed-shift-overlow.patch
+++ /dev/null
@@ -1,98 +0,0 @@
-commit 5542236837c5c41435f8282ec92799f480c36f18
-Author: Paul Eggert <eggert@cs.ucla.edu>
-Date: Tue Jul 21 22:50:29 2015 -0700
-
- Port the 0x7efe...feff pattern to GCC 6.
-
- See Steve Ellcey's bug report in:
- https://sourceware.org/ml/libc-alpha/2015-07/msg00673.html
- * string/memrchr.c (MEMRCHR):
- * string/rawmemchr.c (RAWMEMCHR):
- * string/strchr.c (strchr):
- * string/strchrnul.c (STRCHRNUL):
- Rewrite code to avoid issues with signed shift overflow.
-
-diff --git a/string/memrchr.c b/string/memrchr.c
-index 0c8fd84..86cd5b9 100644
---- a/string/memrchr.c
-+++ b/string/memrchr.c
-@@ -96,15 +96,8 @@ MEMRCHR
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
--
-- if (sizeof (longword) != 4 && sizeof (longword) != 8)
-- abort ();
--
--#if LONG_MAX <= LONG_MAX_32_BITS
-- magic_bits = 0x7efefeff;
--#else
-- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
--#endif
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/rawmemchr.c b/string/rawmemchr.c
-index 05b22be..228ca9d 100644
---- a/string/rawmemchr.c
-+++ b/string/rawmemchr.c
-@@ -86,15 +86,8 @@ RAWMEMCHR (s, c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
--
-- if (sizeof (longword) != 4 && sizeof (longword) != 8)
-- abort ();
--
--#if LONG_MAX <= LONG_MAX_32_BITS
-- magic_bits = 0x7efefeff;
--#else
-- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
--#endif
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/strchr.c b/string/strchr.c
-index 5f90075..f13b2b3 100644
---- a/string/strchr.c
-+++ b/string/strchr.c
-@@ -60,13 +60,8 @@ strchr (const char *s, int c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
-- switch (sizeof (longword))
-- {
-- case 4: magic_bits = 0x7efefeffL; break;
-- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
-- default:
-- abort ();
-- }
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/strchrnul.c b/string/strchrnul.c
-index 2678f1d..daf0b3f 100644
---- a/string/strchrnul.c
-+++ b/string/strchrnul.c
-@@ -66,13 +66,8 @@ STRCHRNUL (s, c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
-- switch (sizeof (longword))
-- {
-- case 4: magic_bits = 0x7efefeffL; break;
-- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
-- default:
-- abort ();
-- }
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
diff --git a/packages/glibc/2.18/103-dl-openat64-variadic.patch b/packages/glibc/2.18/103-dl-openat64-variadic.patch
deleted file mode 100644
index fe94b96..0000000
--- a/packages/glibc/2.18/103-dl-openat64-variadic.patch
+++ /dev/null
@@ -1,195 +0,0 @@
-commit 9dd346ff431fc761f1b748bd4da8bb59f7652094
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Tue Oct 20 11:54:09 2015 +0000
-
- Convert 113 more function definitions to prototype style (files with assertions).
-
- This mostly automatically-generated patch converts 113 function
- definitions in glibc from old-style K&R to prototype-style. Following
- my other recent such patches, this one deals with the case of function
- definitions in files that either contain assertions or where grep
- suggested they might contain assertions - and thus where it isn't
- possible to use a simple object code comparison as a sanity check on
- the correctness of the patch, because line numbers are changed.
-
- A few such automatically-generated changes needed to be supplemented
- by manual changes for the result to compile. openat64 had a prototype
- declaration with "..." but an old-style definition in
- sysdeps/unix/sysv/linux/dl-openat64.c, and "..." needed adding to the
- generated prototype in the definition (I've filed
- <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68024> for diagnosing
- such cases in GCC; the old state was undefined behavior not requiring
- a diagnostic, but one seems a good idea). In addition, as Florian has
- noted regparm attribute mismatches between declaration and definition
- are only diagnosed for prototype definitions, and five functions
- needed internal_function added to their definitions (in the case of
- __pthread_mutex_cond_lock, via the macro definition of
- __pthread_mutex_lock) to compile on i386.
-
- After this patch is in, remaining old-style definitions are probably
- most readily fixed manually before we can turn on
- -Wold-style-definition for all builds.
-
- Tested for x86_64 and x86 (testsuite).
-
- * crypt/md5-crypt.c (__md5_crypt_r): Convert to prototype-style
- function definition.
- * crypt/sha256-crypt.c (__sha256_crypt_r): Likewise.
- * crypt/sha512-crypt.c (__sha512_crypt_r): Likewise.
- * debug/backtracesyms.c (__backtrace_symbols): Likewise.
- * elf/dl-minimal.c (_itoa): Likewise.
- * hurd/hurdmalloc.c (malloc): Likewise.
- (free): Likewise.
- (realloc): Likewise.
- * inet/inet6_option.c (inet6_option_space): Likewise.
- (inet6_option_init): Likewise.
- (inet6_option_append): Likewise.
- (inet6_option_alloc): Likewise.
- (inet6_option_next): Likewise.
- (inet6_option_find): Likewise.
- * io/ftw.c (FTW_NAME): Likewise.
- (NFTW_NAME): Likewise.
- (NFTW_NEW_NAME): Likewise.
- (NFTW_OLD_NAME): Likewise.
- * libio/iofwide.c (_IO_fwide): Likewise.
- * libio/strops.c (_IO_str_init_static_internal): Likewise.
- (_IO_str_init_static): Likewise.
- (_IO_str_init_readonly): Likewise.
- (_IO_str_overflow): Likewise.
- (_IO_str_underflow): Likewise.
- (_IO_str_count): Likewise.
- (_IO_str_seekoff): Likewise.
- (_IO_str_pbackfail): Likewise.
- (_IO_str_finish): Likewise.
- * libio/wstrops.c (_IO_wstr_init_static): Likewise.
- (_IO_wstr_overflow): Likewise.
- (_IO_wstr_underflow): Likewise.
- (_IO_wstr_count): Likewise.
- (_IO_wstr_seekoff): Likewise.
- (_IO_wstr_pbackfail): Likewise.
- (_IO_wstr_finish): Likewise.
- * locale/programs/localedef.c (normalize_codeset): Likewise.
- * locale/programs/locarchive.c (add_locale_to_archive): Likewise.
- (add_locales_to_archive): Likewise.
- (delete_locales_from_archive): Likewise.
- * malloc/malloc.c (__libc_mallinfo): Likewise.
- * math/gen-auto-libm-tests.c (init_fp_formats): Likewise.
- * misc/tsearch.c (__tfind): Likewise.
- * nptl/pthread_attr_destroy.c (__pthread_attr_destroy): Likewise.
- * nptl/pthread_attr_getdetachstate.c
- (__pthread_attr_getdetachstate): Likewise.
- * nptl/pthread_attr_getguardsize.c (pthread_attr_getguardsize):
- Likewise.
- * nptl/pthread_attr_getinheritsched.c
- (__pthread_attr_getinheritsched): Likewise.
- * nptl/pthread_attr_getschedparam.c
- (__pthread_attr_getschedparam): Likewise.
- * nptl/pthread_attr_getschedpolicy.c
- (__pthread_attr_getschedpolicy): Likewise.
- * nptl/pthread_attr_getscope.c (__pthread_attr_getscope):
- Likewise.
- * nptl/pthread_attr_getstack.c (__pthread_attr_getstack):
- Likewise.
- * nptl/pthread_attr_getstackaddr.c (__pthread_attr_getstackaddr):
- Likewise.
- * nptl/pthread_attr_getstacksize.c (__pthread_attr_getstacksize):
- Likewise.
- * nptl/pthread_attr_init.c (__pthread_attr_init_2_1): Likewise.
- (__pthread_attr_init_2_0): Likewise.
- * nptl/pthread_attr_setdetachstate.c
- (__pthread_attr_setdetachstate): Likewise.
- * nptl/pthread_attr_setguardsize.c (pthread_attr_setguardsize):
- Likewise.
- * nptl/pthread_attr_setinheritsched.c
- (__pthread_attr_setinheritsched): Likewise.
- * nptl/pthread_attr_setschedparam.c
- (__pthread_attr_setschedparam): Likewise.
- * nptl/pthread_attr_setschedpolicy.c
- (__pthread_attr_setschedpolicy): Likewise.
- * nptl/pthread_attr_setscope.c (__pthread_attr_setscope):
- Likewise.
- * nptl/pthread_attr_setstack.c (__pthread_attr_setstack):
- Likewise.
- * nptl/pthread_attr_setstackaddr.c (__pthread_attr_setstackaddr):
- Likewise.
- * nptl/pthread_attr_setstacksize.c (__pthread_attr_setstacksize):
- Likewise.
- * nptl/pthread_condattr_setclock.c (pthread_condattr_setclock):
- Likewise.
- * nptl/pthread_create.c (__find_in_stack_list): Likewise.
- * nptl/pthread_getattr_np.c (pthread_getattr_np): Likewise.
- * nptl/pthread_mutex_cond_lock.c (__pthread_mutex_lock): Define to
- use internal_function.
- * nptl/pthread_mutex_init.c (__pthread_mutex_init): Convert to
- prototype-style function definition.
- * nptl/pthread_mutex_lock.c (__pthread_mutex_lock): Likewise.
- (__pthread_mutex_cond_lock_adjust): Likewise. Use
- internal_function.
- * nptl/pthread_mutex_timedlock.c (pthread_mutex_timedlock):
- Convert to prototype-style function definition.
- * nptl/pthread_mutex_trylock.c (__pthread_mutex_trylock):
- Likewise.
- * nptl/pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt):
- Likewise.
- (__pthread_mutex_unlock): Likewise.
- * nptl_db/td_ta_clear_event.c (td_ta_clear_event): Likewise.
- * nptl_db/td_ta_set_event.c (td_ta_set_event): Likewise.
- * nptl_db/td_thr_clear_event.c (td_thr_clear_event): Likewise.
- * nptl_db/td_thr_event_enable.c (td_thr_event_enable): Likewise.
- * nptl_db/td_thr_set_event.c (td_thr_set_event): Likewise.
- * nss/makedb.c (process_input): Likewise.
- * posix/fnmatch.c (__strchrnul): Likewise.
- (__wcschrnul): Likewise.
- (fnmatch): Likewise.
- * posix/fnmatch_loop.c (FCT): Likewise.
- * posix/glob.c (globfree): Likewise.
- (__glob_pattern_type): Likewise.
- (__glob_pattern_p): Likewise.
- * posix/regcomp.c (re_compile_pattern): Likewise.
- (re_set_syntax): Likewise.
- (re_compile_fastmap): Likewise.
- (regcomp): Likewise.
- (regerror): Likewise.
- (regfree): Likewise.
- * posix/regexec.c (regexec): Likewise.
- (re_match): Likewise.
- (re_search): Likewise.
- (re_match_2): Likewise.
- (re_search_2): Likewise.
- (re_search_stub): Likewise. Use internal_function
- (re_copy_regs): Likewise.
- (re_set_registers): Convert to prototype-style function
- definition.
- (prune_impossible_nodes): Likewise. Use internal_function.
- * resolv/inet_net_pton.c (inet_net_pton): Convert to
- prototype-style function definition.
- (inet_net_pton_ipv4): Likewise.
- * stdlib/strtod_l.c (____STRTOF_INTERNAL): Likewise.
- * sysdeps/pthread/aio_cancel.c (aio_cancel): Likewise.
- * sysdeps/pthread/aio_suspend.c (aio_suspend): Likewise.
- * sysdeps/pthread/timer_delete.c (timer_delete): Likewise.
- * sysdeps/unix/sysv/linux/dl-openat64.c (openat64): Likewise.
- Make variadic.
- * time/strptime_l.c (localtime_r): Convert to prototype-style
- function definition.
- * wcsmbs/mbsnrtowcs.c (__mbsnrtowcs): Likewise.
- * wcsmbs/mbsrtowcs_l.c (__mbsrtowcs_l): Likewise.
- * wcsmbs/wcsnrtombs.c (__wcsnrtombs): Likewise.
- * wcsmbs/wcsrtombs.c (__wcsrtombs): Likewise.
-
-diff --git a/sysdeps/unix/sysv/linux/dl-openat64.c b/sysdeps/unix/sysv/linux/dl-openat64.c
-index 7d100bb..7eea0ca 100644
---- a/sysdeps/unix/sysv/linux/dl-openat64.c
-+++ b/sysdeps/unix/sysv/linux/dl-openat64.c
-@@ -23,10 +23,7 @@
-
-
- int
--openat64 (dfd, file, oflag)
-- int dfd;
-- const char *file;
-- int oflag;
-+openat64 (int dfd, const char *file, int oflag, ...)
- {
- assert ((oflag & O_CREAT) == 0);
-
diff --git a/packages/glibc/2.18/105-misleading-indentation.patch b/packages/glibc/2.18/105-misleading-indentation.patch
deleted file mode 100644
index 1dd8d85..0000000
--- a/packages/glibc/2.18/105-misleading-indentation.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-commit 976ef870542580cf5fed896c2c652b3e1a95f9da
-Author: Steve Ellcey <sellcey@mips.com>
-Date: Fri Dec 11 09:19:37 2015 -0800
-
- Fix indentation.
-
- * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
- Fix indentation.
-
-diff --git a/sysdeps/ieee754/flt-32/k_rem_pio2f.c b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-index 0c7685c..392afdb 100644
---- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-+++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-@@ -65,7 +65,9 @@ int __kernel_rem_pio2f(float *x, float *y, int e0, int nx, int prec, const int32
-
- /* compute q[0],q[1],...q[jk] */
- for (i=0;i<=jk;i++) {
-- for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw;
-+ for(j=0,fw=0.0;j<=jx;j++)
-+ fw += x[j]*f[jx+i-j];
-+ q[i] = fw;
- }
-
- jz = jk;
diff --git a/packages/glibc/2.18/300-macos-cross-rpcgen.patch b/packages/glibc/2.18/300-macos-cross-rpcgen.patch
deleted file mode 100644
index e654644..0000000
--- a/packages/glibc/2.18/300-macos-cross-rpcgen.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-commit ae7080d30c68cfa0c81ce3422dca948f64a94f50
-Author: Jia Liu <proljc@gmail.com>
-Date: Sat Sep 7 00:01:08 2013 +0800
-
- sunrpc/rpc/types.h: fix OS X and FreeBSD build problems
-
- When I build arm-linux-gcc on OS X, I find glibc will get a build error
- in sunrpc/rpc/types.h, so I add __APPLE_CC__ to make OS X build OK.
- For FreeBSD, Add __FreeBSD__ to make it build OK, too.
-
- URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00155.html
- URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00217.html
- URL: http://sourceware.org/ml/libc-alpha/2013-09/msg00240.html
- Signed-off-by: Jia Liu <proljc@gmail.com>
- Signed-off-by: Mike Frysinger <vapier@gentoo.org>
-
-diff --git a/sunrpc/rpc/types.h b/sunrpc/rpc/types.h
-index 3dca5c4..beded52 100644
---- a/sunrpc/rpc/types.h
-+++ b/sunrpc/rpc/types.h
-@@ -69,6 +69,11 @@ typedef unsigned long rpcport_t;
- #include <sys/types.h>
- #endif
-
-+#if defined __APPLE_CC__ || defined __FreeBSD__
-+# define __u_char_defined
-+# define __daddr_t_defined
-+#endif
-+
- #ifndef __u_char_defined
- typedef __u_char u_char;
- typedef __u_short u_short;
diff --git a/packages/glibc/2.18/920-fix-rpc_parse-format.patch b/packages/glibc/2.18/920-fix-rpc_parse-format.patch
deleted file mode 100644
index 37e58da..0000000
--- a/packages/glibc/2.18/920-fix-rpc_parse-format.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-commit 5874510faaf3cbd0bb112aaacab9f225002beed1
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Tue Nov 8 23:44:51 2016 +0000
-
- Fix rpcgen buffer overrun (bug 20790).
-
- Building with GCC 7 produces an error building rpcgen:
-
- rpc_parse.c: In function 'get_prog_declaration':
- rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ~~~~^
- rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
- That buffer overrun is for the case where the .x file declares a
- program with a million arguments. The strcpy two lines above can
- generate a buffer overrun much more simply for a long argument name.
-
- The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
- provides a bound on the buffer size needed, so this patch just changes
- the buffer size to MAXLINESIZE to avoid both possible buffer
- overruns. A testcase is added that rpcgen does not crash with a
- 500-character argument name, where it previously crashed.
-
- It would not at all surprise me if there are many other ways of
- crashing rpcgen with either valid or invalid input; fuzz testing would
- likely find various such bugs, though I don't think they are that
- important to fix (rpcgen is not that likely to be used with untrusted
- .x files as input). (As well as fuzz-findable bugs there are probably
- also issues when various int variables get overflowed on very large
- input.) The test infrastructure for rpcgen-not-crashing tests would
- need extending if tests are to be added for cases where rpcgen should
- produce an error, as opposed to cases where it should succeed.
-
- Tested for x86_64 and x86.
-
- [BZ #20790]
- * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
- to MAXLINESIZE.
- * sunrpc/bug20790.x: New file.
- * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
- variable.
- [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
- [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
-
-diff --git a/sunrpc/rpc_parse.c b/sunrpc/rpc_parse.c
-index 1a1df6d8c2..505a6554cf 100644
---- a/sunrpc/rpc_parse.c
-+++ b/sunrpc/rpc_parse.c
-@@ -521,7 +521,7 @@ static void
- get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
- {
- token tok;
-- char name[10]; /* argument name */
-+ char name[MAXLINESIZE]; /* argument name */
-
- if (dkind == DEF_PROGRAM)
- {
diff --git a/packages/glibc/2.18/940-nis-bogus-conditional.patch b/packages/glibc/2.18/940-nis-bogus-conditional.patch
deleted file mode 100644
index 09b38cf..0000000
--- a/packages/glibc/2.18/940-nis-bogus-conditional.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Wed Dec 21 23:44:01 2016 +0000
-
- Fix nss_nisplus build with mainline GCC (bug 20978).
-
- glibc build with current mainline GCC fails because
- nis/nss_nisplus/nisplus-alias.c contains code
-
- if (name != NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
- }
-
- char buf[strlen (name) + 9 + tablename_len];
-
- producing an error about strlen being called on a pointer that is
- always NULL (and a subsequent use of that pointer with a %s format in
- snprintf).
-
- As Andreas noted, the bogus conditional comes from a 1997 change:
-
- - if (name == NULL || strlen(name) > 8)
- - return NSS_STATUS_NOTFOUND;
- - else
- + if (name != NULL || strlen(name) <= 8)
-
- So the intention is clearly to return an error for NULL name.
-
- This patch duly inverts the sense of the conditional. It fixes the
- build with GCC mainline, and passes usual glibc testsuite testing for
- x86_64. However, I have not tried any actual substantive nisplus
- testing, do not have an environment for such testing, and do not know
- whether it is possible that strlen (name) or tablename_len might be
- large so that the VLA for buf is actually a security issue. However,
- if it is a security issue, there are plenty of other similar instances
- in the nisplus code (that haven't been hidden by a bogus comparison
- with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
- string passed to nis_list, so a local fix in the caller wouldn't
- suffice anyway (see bug 20987). (Calls to strdupa and other such
- macros that use alloca must be considered equally questionable
- regarding stack overflow issues as direct calls to alloca and VLA
- declarations.)
-
- [BZ #20978]
- * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
- Compare name == NULL, not name != NULL.
-
-diff --git a/nis/nss_nisplus/nisplus-alias.c b/nis/nss_nisplus/nisplus-alias.c
-index 7f698b4e6d..cb5acce01d 100644
---- a/nis/nss_nisplus/nisplus-alias.c
-+++ b/nis/nss_nisplus/nisplus-alias.c
-@@ -291,7 +291,7 @@ _nss_nisplus_getaliasbyname_r (const char *name, struct aliasent *alias,
- return status;
- }
-
-- if (name != NULL)
-+ if (name == NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.19/0000-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.19/0000-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
new file mode 100644
index 0000000..5d724b2
--- /dev/null
+++ b/packages/glibc/2.19/0000-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
@@ -0,0 +1,75 @@
+From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
+From: Yvan Roux <yvan.roux@linaro.org>
+Date: Fri, 15 Apr 2016 13:29:26 +0200
+Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
+ -Wparentheses
+
+---
+ nis/nis_call.c | 20 +++++++++++---------
+ stdlib/setenv.c | 24 +++++++++++++-----------
+ 2 files changed, 24 insertions(+), 20 deletions(-)
+
+--- a/nis/nis_call.c
++++ b/nis/nis_call.c
+@@ -680,16 +680,18 @@
+ /* Choose which entry should be evicted from the cache. */
+ loc = &nis_server_cache[0];
+ if (*loc != NULL)
+- for (i = 1; i < 16; ++i)
+- if (nis_server_cache[i] == NULL)
+- {
++ {
++ for (i = 1; i < 16; ++i)
++ if (nis_server_cache[i] == NULL)
++ {
++ loc = &nis_server_cache[i];
++ break;
++ }
++ else if ((*loc)->uses > nis_server_cache[i]->uses
++ || ((*loc)->uses == nis_server_cache[i]->uses
++ && (*loc)->expires > nis_server_cache[i]->expires))
+ loc = &nis_server_cache[i];
+- break;
+- }
+- else if ((*loc)->uses > nis_server_cache[i]->uses
+- || ((*loc)->uses == nis_server_cache[i]->uses
+- && (*loc)->expires > nis_server_cache[i]->expires))
+- loc = &nis_server_cache[i];
++ }
+ old = *loc;
+ *loc = new;
+
+--- a/stdlib/setenv.c
++++ b/stdlib/setenv.c
+@@ -327,18 +327,20 @@
+ ep = __environ;
+ if (ep != NULL)
+ while (*ep != NULL)
+- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
+- {
+- /* Found it. Remove this pointer by moving later ones back. */
+- char **dp = ep;
++ {
++ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
++ {
++ /* Found it. Remove this pointer by moving later ones back. */
++ char **dp = ep;
+
+- do
+- dp[0] = dp[1];
+- while (*dp++);
+- /* Continue the loop in case NAME appears again. */
+- }
+- else
+- ++ep;
++ do
++ dp[0] = dp[1];
++ while (*dp++);
++ /* Continue the loop in case NAME appears again. */
++ }
++ else
++ ++ep;
++ }
+
+ UNLOCK;
+
diff --git a/packages/glibc/2.19/0001-fix-signed-shift-overlow.patch b/packages/glibc/2.19/0001-fix-signed-shift-overlow.patch
new file mode 100644
index 0000000..1e291a5
--- /dev/null
+++ b/packages/glibc/2.19/0001-fix-signed-shift-overlow.patch
@@ -0,0 +1,97 @@
+commit 5542236837c5c41435f8282ec92799f480c36f18
+Author: Paul Eggert <eggert@cs.ucla.edu>
+Date: Tue Jul 21 22:50:29 2015 -0700
+
+ Port the 0x7efe...feff pattern to GCC 6.
+
+ See Steve Ellcey's bug report in:
+ https://sourceware.org/ml/libc-alpha/2015-07/msg00673.html
+ * string/memrchr.c (MEMRCHR):
+ * string/rawmemchr.c (RAWMEMCHR):
+ * string/strchr.c (strchr):
+ * string/strchrnul.c (STRCHRNUL):
+ Rewrite code to avoid issues with signed shift overflow.
+
+---
+ string/memrchr.c | 11 ++---------
+ string/rawmemchr.c | 11 ++---------
+ string/strchr.c | 9 ++-------
+ string/strchrnul.c | 9 ++-------
+ 4 files changed, 8 insertions(+), 32 deletions(-)
+
+--- a/string/memrchr.c
++++ b/string/memrchr.c
+@@ -96,15 +96,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+-
+- if (sizeof (longword) != 4 && sizeof (longword) != 8)
+- abort ();
+-
+-#if LONG_MAX <= LONG_MAX_32_BITS
+- magic_bits = 0x7efefeff;
+-#else
+- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
+-#endif
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/rawmemchr.c
++++ b/string/rawmemchr.c
+@@ -86,15 +86,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+-
+- if (sizeof (longword) != 4 && sizeof (longword) != 8)
+- abort ();
+-
+-#if LONG_MAX <= LONG_MAX_32_BITS
+- magic_bits = 0x7efefeff;
+-#else
+- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
+-#endif
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/strchr.c
++++ b/string/strchr.c
+@@ -63,13 +63,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+- switch (sizeof (longword))
+- {
+- case 4: magic_bits = 0x7efefeffL; break;
+- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
+- default:
+- abort ();
+- }
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/strchrnul.c
++++ b/string/strchrnul.c
+@@ -66,13 +66,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+- switch (sizeof (longword))
+- {
+- case 4: magic_bits = 0x7efefeffL; break;
+- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
+- default:
+- abort ();
+- }
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
diff --git a/packages/glibc/2.14.1/103-dl-openat64-variadic.patch b/packages/glibc/2.19/0002-dl-openat64-variadic.patch
index fe94b96..552db12 100644
--- a/packages/glibc/2.14.1/103-dl-openat64-variadic.patch
+++ b/packages/glibc/2.19/0002-dl-openat64-variadic.patch
@@ -177,8 +177,10 @@ Date: Tue Oct 20 11:54:09 2015 +0000
* wcsmbs/wcsnrtombs.c (__wcsnrtombs): Likewise.
* wcsmbs/wcsrtombs.c (__wcsrtombs): Likewise.
-diff --git a/sysdeps/unix/sysv/linux/dl-openat64.c b/sysdeps/unix/sysv/linux/dl-openat64.c
-index 7d100bb..7eea0ca 100644
+---
+ sysdeps/unix/sysv/linux/dl-openat64.c | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
--- a/sysdeps/unix/sysv/linux/dl-openat64.c
+++ b/sysdeps/unix/sysv/linux/dl-openat64.c
@@ -23,10 +23,7 @@
diff --git a/packages/glibc/2.20/104-unused-variables.patch b/packages/glibc/2.19/0003-unused-variables.patch
index 889c9bb..c09e420 100644
--- a/packages/glibc/2.20/104-unused-variables.patch
+++ b/packages/glibc/2.19/0003-unused-variables.patch
@@ -19,8 +19,19 @@ Date: Fri Sep 18 20:27:20 2015 +0100
* timezone/private.h (time_t_min): Likewise. (time_t_max):
Likewise.
-diff --git a/resolv/base64.c b/resolv/base64.c
-index ea584ed..519e5d2 100644
+---
+ resolv/base64.c | 4 ----
+ sysdeps/ieee754/dbl-64/atnat2.h | 4 ----
+ sysdeps/ieee754/dbl-64/uexp.h | 2 +-
+ sysdeps/ieee754/dbl-64/upow.h | 2 --
+ sysdeps/ieee754/flt-32/e_log10f.c | 2 --
+ sysdeps/ieee754/flt-32/s_cosf.c | 2 --
+ sysdeps/ieee754/ldbl-128/e_lgammal_r.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_erfl.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_log1pl.c | 1 -
+ timezone/private.h | 10 ----------
+ 10 files changed, 1 insertion(+), 28 deletions(-)
+
--- a/resolv/base64.c
+++ b/resolv/base64.c
@@ -40,10 +40,6 @@
@@ -34,8 +45,6 @@ index ea584ed..519e5d2 100644
#include <sys/types.h>
#include <sys/param.h>
#include <sys/socket.h>
-diff --git a/sysdeps/ieee754/dbl-64/atnat2.h b/sysdeps/ieee754/dbl-64/atnat2.h
-index e0d65af..82943f9 100644
--- a/sysdeps/ieee754/dbl-64/atnat2.h
+++ b/sysdeps/ieee754/dbl-64/atnat2.h
@@ -65,10 +65,8 @@
@@ -60,8 +69,6 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0x7f3321d2, 0xc002d97c} }, /* -3pi/4 */
/**/ u1 = {{0x00000000, 0x3c314c2a} }, /* 9.377e-19 */
/**/ u2 = {{0x00000000, 0x3bf955e4} }, /* 8.584e-20 */
-diff --git a/sysdeps/ieee754/dbl-64/uexp.h b/sysdeps/ieee754/dbl-64/uexp.h
-index 6817eaf..42b21f2 100644
--- a/sysdeps/ieee754/dbl-64/uexp.h
+++ b/sysdeps/ieee754/dbl-64/uexp.h
@@ -29,7 +29,7 @@
@@ -73,8 +80,6 @@ index 6817eaf..42b21f2 100644
err_0 = 1.000014, err_1 = 0.000016;
const static int4 bigint = 0x40862002,
badint = 0x40876000,smallint = 0x3C8fffff;
-diff --git a/sysdeps/ieee754/dbl-64/upow.h b/sysdeps/ieee754/dbl-64/upow.h
-index c8569a9..b4911e5 100644
--- a/sysdeps/ieee754/dbl-64/upow.h
+++ b/sysdeps/ieee754/dbl-64/upow.h
@@ -34,7 +34,6 @@
@@ -93,11 +98,9 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0xfefa3800, 0x3fe62e42}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x93c76730, 0x3d2ef357}}, /* ln(2)-ln2a */
/**/ bigu = {{0xfffffd2c, 0x4297ffff}}, /* 1.5*2**42 -724*2**-10 */
-diff --git a/sysdeps/ieee754/flt-32/e_log10f.c b/sysdeps/ieee754/flt-32/e_log10f.c
-index 96f0e81..1daeef7 100644
--- a/sysdeps/ieee754/flt-32/e_log10f.c
+++ b/sysdeps/ieee754/flt-32/e_log10f.c
-@@ -22,8 +22,6 @@ ivln10 = 4.3429449201e-01, /* 0x3ede5bd9 */
+@@ -22,8 +22,6 @@
log10_2hi = 3.0102920532e-01, /* 0x3e9a2080 */
log10_2lo = 7.9034151668e-07; /* 0x355427db */
@@ -106,11 +109,9 @@ index 96f0e81..1daeef7 100644
float
__ieee754_log10f(float x)
{
-diff --git a/sysdeps/ieee754/flt-32/s_cosf.c b/sysdeps/ieee754/flt-32/s_cosf.c
-index 864ab27..0affd40 100644
--- a/sysdeps/ieee754/flt-32/s_cosf.c
+++ b/sysdeps/ieee754/flt-32/s_cosf.c
-@@ -21,8 +21,6 @@ static char rcsid[] = "$NetBSD: s_cosf.c,v 1.4 1995/05/10 20:47:03 jtc Exp $";
+@@ -21,8 +21,6 @@
#include <math.h>
#include <math_private.h>
@@ -119,11 +120,9 @@ index 864ab27..0affd40 100644
#ifndef COSF
# define COSF_FUNC __cosf
#else
-diff --git a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-index 500aacc..ab5a96e 100644
--- a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
+++ b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-@@ -82,7 +82,6 @@ DIAG_IGNORE_NEEDS_COMMENT (4.6, "-Woverflow");
+@@ -74,7 +74,6 @@
static const long double PIL = 3.1415926535897932384626433832795028841972E0L;
static const long double MAXLGM = 1.0485738685148938358098967157129705071571E4928L;
static const long double one = 1.0L;
@@ -131,11 +130,9 @@ index 500aacc..ab5a96e 100644
static const long double huge = 1.0e4000L;
/* log gamma(x) = ( x - 0.5 ) * log(x) - x + LS2PI + 1/x P(1/x^2)
-diff --git a/sysdeps/ieee754/ldbl-128/s_erfl.c b/sysdeps/ieee754/ldbl-128/s_erfl.c
-index fa4609f..08c80a3 100644
--- a/sysdeps/ieee754/ldbl-128/s_erfl.c
+++ b/sysdeps/ieee754/ldbl-128/s_erfl.c
-@@ -140,7 +140,6 @@ deval (long double x, const long double *p, int n)
+@@ -139,7 +139,6 @@
static const long double
tiny = 1e-4931L,
@@ -143,11 +140,9 @@ index fa4609f..08c80a3 100644
one = 1.0L,
two = 2.0L,
/* 2/sqrt(pi) - 1 */
-diff --git a/sysdeps/ieee754/ldbl-128/s_log1pl.c b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-index ff759bc..9609550 100644
--- a/sysdeps/ieee754/ldbl-128/s_log1pl.c
+++ b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-@@ -117,7 +117,6 @@ static const long double C2 = 1.428606820309417232121458176568075500134E-6L;
+@@ -116,7 +116,6 @@
static const long double sqrth = 0.7071067811865475244008443621048490392848L;
/* ln (2^16384 * (1 - 2^-113)) */
@@ -155,11 +150,9 @@ index ff759bc..9609550 100644
static const long double zero = 0.0L;
long double
-diff --git a/timezone/private.h b/timezone/private.h
-index 4e8f4ae..ed19e06 100644
--- a/timezone/private.h
+++ b/timezone/private.h
-@@ -326,16 +326,6 @@ const char * scheck(const char * string, const char * format);
+@@ -321,16 +321,6 @@
#define TYPE_SIGNED(type) (((type) -1) < 0)
#endif /* !defined TYPE_SIGNED */
diff --git a/packages/glibc/2.19/0004-misleading-indentation.patch b/packages/glibc/2.19/0004-misleading-indentation.patch
new file mode 100644
index 0000000..8e08259
--- /dev/null
+++ b/packages/glibc/2.19/0004-misleading-indentation.patch
@@ -0,0 +1,26 @@
+commit 976ef870542580cf5fed896c2c652b3e1a95f9da
+Author: Steve Ellcey <sellcey@mips.com>
+Date: Fri Dec 11 09:19:37 2015 -0800
+
+ Fix indentation.
+
+ * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
+ Fix indentation.
+
+---
+ sysdeps/ieee754/flt-32/k_rem_pio2f.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+--- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
++++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
+@@ -65,7 +65,9 @@
+
+ /* compute q[0],q[1],...q[jk] */
+ for (i=0;i<=jk;i++) {
+- for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw;
++ for(j=0,fw=0.0;j<=jx;j++)
++ fw += x[j]*f[jx+i-j];
++ q[i] = fw;
+ }
+
+ jz = jk;
diff --git a/packages/glibc/2.21/106-dl-open-array-bounds.patch b/packages/glibc/2.19/0005-dl-open-array-bounds.patch
index 08a9076..83eb0b3 100644
--- a/packages/glibc/2.21/106-dl-open-array-bounds.patch
+++ b/packages/glibc/2.19/0005-dl-open-array-bounds.patch
@@ -4,11 +4,13 @@ Date: Fri Apr 17 12:11:58 2015 -0700
Fuller check for invalid NSID in _dl_open.
-diff --git a/elf/dl-open.c b/elf/dl-open.c
-index 0dbe07f..2d0e082 100644
+---
+ elf/dl-open.c | 12 +++++++++---
+ 1 file changed, 9 insertions(+), 3 deletions(-)
+
--- a/elf/dl-open.c
+++ b/elf/dl-open.c
-@@ -211,7 +211,7 @@ dl_open_worker (void *a)
+@@ -211,7 +211,7 @@
struct link_map *l = _dl_find_dso_for_object ((ElfW(Addr)) caller_dlopen);
if (l)
@@ -17,7 +19,7 @@ index 0dbe07f..2d0e082 100644
if (args->nsid == __LM_ID_CALLER)
args->nsid = call_map->l_ns;
-@@ -619,8 +619,14 @@ no more namespaces available for dlmopen()"));
+@@ -627,8 +627,14 @@
/* Never allow loading a DSO in a namespace which is empty. Such
direct placements is only causing problems. Also don't allow
loading into a namespace used for auditing. */
diff --git a/packages/glibc/2.19/130-arm-unwind.patch b/packages/glibc/2.19/0006-arm-unwind.patch
index 69cc07a..85288d0 100644
--- a/packages/glibc/2.19/130-arm-unwind.patch
+++ b/packages/glibc/2.19/0006-arm-unwind.patch
@@ -1,6 +1,12 @@
-diff -urN glibc-2.18.orig/nptl/sysdeps/pthread/unwind-forcedunwind.c glibc-2.18/nptl/sysdeps/pthread/unwind-forcedunwind.c
---- glibc-2.18.orig/nptl/sysdeps/pthread/unwind-forcedunwind.c 2013-08-11 02:52:55.000000000 +0400
-+++ glibc-2.18/nptl/sysdeps/pthread/unwind-forcedunwind.c 2016-09-15 02:30:09.199939478 +0300
+---
+ nptl/sysdeps/pthread/unwind-forcedunwind.c | 2 +-
+ ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c | 2 +-
+ ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c | 2 +-
+ sysdeps/gnu/unwind-resume.c | 2 +-
+ 4 files changed, 4 insertions(+), 4 deletions(-)
+
+--- a/nptl/sysdeps/pthread/unwind-forcedunwind.c
++++ b/nptl/sysdeps/pthread/unwind-forcedunwind.c
@@ -24,7 +24,7 @@
#include <gnu/lib-names.h>
@@ -10,9 +16,8 @@ diff -urN glibc-2.18.orig/nptl/sysdeps/pthread/unwind-forcedunwind.c glibc-2.18/
static _Unwind_Reason_Code (*libgcc_s_personality)
(int, _Unwind_Action, _Unwind_Exception_Class, struct _Unwind_Exception *,
struct _Unwind_Context *);
-diff -urN glibc-2.18.orig/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c glibc-2.18/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c
---- glibc-2.18.orig/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c 2013-08-11 02:52:55.000000000 +0400
-+++ glibc-2.18/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c 2016-09-15 02:29:07.096945862 +0300
+--- a/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c
++++ b/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c
@@ -22,7 +22,7 @@
#include <pthreadP.h>
@@ -22,9 +27,8 @@ diff -urN glibc-2.18.orig/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedun
static _Unwind_Reason_Code (*libgcc_s_personality)
(_Unwind_State, struct _Unwind_Exception *, struct _Unwind_Context *);
static _Unwind_Reason_Code (*libgcc_s_forcedunwind)
-diff -urN glibc-2.18.orig/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c glibc-2.18/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c
---- glibc-2.18.orig/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c 2013-08-11 02:52:55.000000000 +0400
-+++ glibc-2.18/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c 2016-09-15 02:29:37.352917115 +0300
+--- a/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c
++++ b/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c
@@ -20,7 +20,7 @@
#include <stdio.h>
#include <unwind.h>
@@ -34,9 +38,8 @@ diff -urN glibc-2.18.orig/ports/sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c
static _Unwind_Reason_Code (*libgcc_s_personality)
(_Unwind_State, struct _Unwind_Exception *, struct _Unwind_Context *);
-diff -urN glibc-2.18.orig/sysdeps/gnu/unwind-resume.c glibc-2.18/sysdeps/gnu/unwind-resume.c
---- glibc-2.18.orig/sysdeps/gnu/unwind-resume.c 2013-08-11 02:52:55.000000000 +0400
-+++ glibc-2.18/sysdeps/gnu/unwind-resume.c 2016-09-15 02:29:53.376431503 +0300
+--- a/sysdeps/gnu/unwind-resume.c
++++ b/sysdeps/gnu/unwind-resume.c
@@ -21,7 +21,7 @@
#include <unwind.h>
#include <gnu/lib-names.h>
diff --git a/packages/glibc/2.20/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.19/0007-Fix-combreloc-test-BSD-grep.patch
index fdc3a60..c352aa8 100644
--- a/packages/glibc/2.20/140-Fix-combreloc-test-BSD-grep.patch
+++ b/packages/glibc/2.19/0007-Fix-combreloc-test-BSD-grep.patch
@@ -13,16 +13,13 @@ by configure as "not found". As a result, support for "-z combreloc"
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
+ configure | 2 +-
+ configure.ac | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
-diff --git a/configure b/configure
-index eecd0ac..0118bd1 100755
--- a/configure
+++ b/configure
-@@ -5804,7 +5804,7 @@ if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
+@@ -6228,7 +6228,7 @@
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; }
then
@@ -31,11 +28,9 @@ index eecd0ac..0118bd1 100755
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
-diff --git a/configure.ac b/configure.ac
-index 4a77411..19f6d87 100644
--- a/configure.ac
+++ b/configure.ac
-@@ -1391,7 +1391,7 @@ dnl cross-platform since the gcc used can be a cross compiler. Without
+@@ -1537,7 +1537,7 @@
dnl introducing new options this is not easily doable. Instead use a tool
dnl which always is cross-platform: readelf. To detect whether -z combreloc
dnl look for a section named .rel.dyn.
@@ -44,6 +39,3 @@ index 4a77411..19f6d87 100644
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
---
-2.9.3
-
diff --git a/packages/glibc/2.19/0008-typedef-caddr.patch b/packages/glibc/2.19/0008-typedef-caddr.patch
new file mode 100644
index 0000000..e38f83d
--- /dev/null
+++ b/packages/glibc/2.19/0008-typedef-caddr.patch
@@ -0,0 +1,31 @@
+---
+ posix/sys/types.h | 3 +++
+ sunrpc/rpc/types.h | 3 +++
+ 2 files changed, 6 insertions(+)
+
+--- a/posix/sys/types.h
++++ b/posix/sys/types.h
+@@ -113,7 +113,10 @@
+ #ifdef __USE_BSD
+ # ifndef __daddr_t_defined
+ typedef __daddr_t daddr_t;
++# if ! defined(caddr_t) && ! defined(__caddr_t_defined)
+ typedef __caddr_t caddr_t;
++# define __caddr_t_defined
++# endif
+ # define __daddr_t_defined
+ # endif
+ #endif
+--- a/sunrpc/rpc/types.h
++++ b/sunrpc/rpc/types.h
+@@ -86,7 +86,10 @@
+ #endif
+ #ifndef __daddr_t_defined
+ typedef __daddr_t daddr_t;
++# if ! defined(caddr_t) && ! defined(__caddr_t_defined)
+ typedef __caddr_t caddr_t;
++# define __caddr_t_defined
++# endif
+ # define __daddr_t_defined
+ #endif
+
diff --git a/packages/glibc/2.19/0009-fix-rpc_parse-format.patch b/packages/glibc/2.19/0009-fix-rpc_parse-format.patch
new file mode 100644
index 0000000..341d541
--- /dev/null
+++ b/packages/glibc/2.19/0009-fix-rpc_parse-format.patch
@@ -0,0 +1,62 @@
+commit 5874510faaf3cbd0bb112aaacab9f225002beed1
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Tue Nov 8 23:44:51 2016 +0000
+
+ Fix rpcgen buffer overrun (bug 20790).
+
+ Building with GCC 7 produces an error building rpcgen:
+
+ rpc_parse.c: In function 'get_prog_declaration':
+ rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ~~~~^
+ rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+ That buffer overrun is for the case where the .x file declares a
+ program with a million arguments. The strcpy two lines above can
+ generate a buffer overrun much more simply for a long argument name.
+
+ The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
+ provides a bound on the buffer size needed, so this patch just changes
+ the buffer size to MAXLINESIZE to avoid both possible buffer
+ overruns. A testcase is added that rpcgen does not crash with a
+ 500-character argument name, where it previously crashed.
+
+ It would not at all surprise me if there are many other ways of
+ crashing rpcgen with either valid or invalid input; fuzz testing would
+ likely find various such bugs, though I don't think they are that
+ important to fix (rpcgen is not that likely to be used with untrusted
+ .x files as input). (As well as fuzz-findable bugs there are probably
+ also issues when various int variables get overflowed on very large
+ input.) The test infrastructure for rpcgen-not-crashing tests would
+ need extending if tests are to be added for cases where rpcgen should
+ produce an error, as opposed to cases where it should succeed.
+
+ Tested for x86_64 and x86.
+
+ [BZ #20790]
+ * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
+ to MAXLINESIZE.
+ * sunrpc/bug20790.x: New file.
+ * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
+ variable.
+ [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
+ [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
+
+---
+ sunrpc/rpc_parse.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/sunrpc/rpc_parse.c
++++ b/sunrpc/rpc_parse.c
+@@ -521,7 +521,7 @@
+ get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
+ {
+ token tok;
+- char name[10]; /* argument name */
++ char name[MAXLINESIZE]; /* argument name */
+
+ if (dkind == DEF_PROGRAM)
+ {
diff --git a/packages/glibc/2.19/930-explicit-boolean.patch b/packages/glibc/2.19/0010-explicit-boolean.patch
index 780fae6..47b62b0 100644
--- a/packages/glibc/2.19/930-explicit-boolean.patch
+++ b/packages/glibc/2.19/0010-explicit-boolean.patch
@@ -7,11 +7,13 @@ Date: Fri Oct 14 12:53:27 2016 -0700
* sysdeps/ieee754/dbl-64/e_pow.c (checkint) Make conditions explicitly
boolean.
-diff --git a/sysdeps/ieee754/dbl-64/e_pow.c b/sysdeps/ieee754/dbl-64/e_pow.c
-index 663fa392c2..bd758b5979 100644
+---
+ sysdeps/ieee754/dbl-64/e_pow.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
--- a/sysdeps/ieee754/dbl-64/e_pow.c
+++ b/sysdeps/ieee754/dbl-64/e_pow.c
-@@ -466,15 +466,15 @@ checkint (double x)
+@@ -441,15 +441,15 @@
return (n & 1) ? -1 : 1; /* odd or even */
if (k > 20)
{
diff --git a/packages/glibc/2.19/0011-nis-bogus-conditional.patch b/packages/glibc/2.19/0011-nis-bogus-conditional.patch
new file mode 100644
index 0000000..e728368
--- /dev/null
+++ b/packages/glibc/2.19/0011-nis-bogus-conditional.patch
@@ -0,0 +1,64 @@
+commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Wed Dec 21 23:44:01 2016 +0000
+
+ Fix nss_nisplus build with mainline GCC (bug 20978).
+
+ glibc build with current mainline GCC fails because
+ nis/nss_nisplus/nisplus-alias.c contains code
+
+ if (name != NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
+ }
+
+ char buf[strlen (name) + 9 + tablename_len];
+
+ producing an error about strlen being called on a pointer that is
+ always NULL (and a subsequent use of that pointer with a %s format in
+ snprintf).
+
+ As Andreas noted, the bogus conditional comes from a 1997 change:
+
+ - if (name == NULL || strlen(name) > 8)
+ - return NSS_STATUS_NOTFOUND;
+ - else
+ + if (name != NULL || strlen(name) <= 8)
+
+ So the intention is clearly to return an error for NULL name.
+
+ This patch duly inverts the sense of the conditional. It fixes the
+ build with GCC mainline, and passes usual glibc testsuite testing for
+ x86_64. However, I have not tried any actual substantive nisplus
+ testing, do not have an environment for such testing, and do not know
+ whether it is possible that strlen (name) or tablename_len might be
+ large so that the VLA for buf is actually a security issue. However,
+ if it is a security issue, there are plenty of other similar instances
+ in the nisplus code (that haven't been hidden by a bogus comparison
+ with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
+ string passed to nis_list, so a local fix in the caller wouldn't
+ suffice anyway (see bug 20987). (Calls to strdupa and other such
+ macros that use alloca must be considered equally questionable
+ regarding stack overflow issues as direct calls to alloca and VLA
+ declarations.)
+
+ [BZ #20978]
+ * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
+ Compare name == NULL, not name != NULL.
+
+---
+ nis/nss_nisplus/nisplus-alias.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/nis/nss_nisplus/nisplus-alias.c
++++ b/nis/nss_nisplus/nisplus-alias.c
+@@ -291,7 +291,7 @@
+ return status;
+ }
+
+- if (name != NULL)
++ if (name == NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.19/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.19/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
deleted file mode 100644
index 6fd663a..0000000
--- a/packages/glibc/2.19/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
-From: Yvan Roux <yvan.roux@linaro.org>
-Date: Fri, 15 Apr 2016 13:29:26 +0200
-Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
- -Wparentheses
-
----
- ChangeLog | 5 +++++
- nis/nis_call.c | 20 +++++++++++---------
- stdlib/setenv.c | 26 ++++++++++++++------------
- 3 files changed, 30 insertions(+), 21 deletions(-)
-
-diff --git a/nis/nis_call.c b/nis/nis_call.c
-index 3fa37e4..cb7839a 100644
---- a/nis/nis_call.c
-+++ b/nis/nis_call.c
-@@ -680,16 +680,18 @@ nis_server_cache_add (const_nis_name name, int search_parent,
- /* Choose which entry should be evicted from the cache. */
- loc = &nis_server_cache[0];
- if (*loc != NULL)
-- for (i = 1; i < 16; ++i)
-- if (nis_server_cache[i] == NULL)
-- {
-+ {
-+ for (i = 1; i < 16; ++i)
-+ if (nis_server_cache[i] == NULL)
-+ {
-+ loc = &nis_server_cache[i];
-+ break;
-+ }
-+ else if ((*loc)->uses > nis_server_cache[i]->uses
-+ || ((*loc)->uses == nis_server_cache[i]->uses
-+ && (*loc)->expires > nis_server_cache[i]->expires))
- loc = &nis_server_cache[i];
-- break;
-- }
-- else if ((*loc)->uses > nis_server_cache[i]->uses
-- || ((*loc)->uses == nis_server_cache[i]->uses
-- && (*loc)->expires > nis_server_cache[i]->expires))
-- loc = &nis_server_cache[i];
-+ }
- old = *loc;
- *loc = new;
-
-diff --git a/stdlib/setenv.c b/stdlib/setenv.c
-index da61ee0..e66045f 100644
---- a/stdlib/setenv.c
-+++ b/stdlib/setenv.c
-@@ -278,18 +278,20 @@ unsetenv (const char *name)
- ep = __environ;
- if (ep != NULL)
- while (*ep != NULL)
-- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-- {
-- /* Found it. Remove this pointer by moving later ones back. */
-- char **dp = ep;
--
-- do
-- dp[0] = dp[1];
-- while (*dp++);
-- /* Continue the loop in case NAME appears again. */
-- }
-- else
-- ++ep;
-+ {
-+ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-+ {
-+ /* Found it. Remove this pointer by moving later ones back. */
-+ char **dp = ep;
-+
-+ do
-+ dp[0] = dp[1];
-+ while (*dp++);
-+ /* Continue the loop in case NAME appears again. */
-+ }
-+ else
-+ ++ep;
-+ }
-
- UNLOCK;
-
---
-2.7.4
-
diff --git a/packages/glibc/2.19/102-fix-signed-shift-overlow.patch b/packages/glibc/2.19/102-fix-signed-shift-overlow.patch
deleted file mode 100644
index ef49f83..0000000
--- a/packages/glibc/2.19/102-fix-signed-shift-overlow.patch
+++ /dev/null
@@ -1,98 +0,0 @@
-commit 5542236837c5c41435f8282ec92799f480c36f18
-Author: Paul Eggert <eggert@cs.ucla.edu>
-Date: Tue Jul 21 22:50:29 2015 -0700
-
- Port the 0x7efe...feff pattern to GCC 6.
-
- See Steve Ellcey's bug report in:
- https://sourceware.org/ml/libc-alpha/2015-07/msg00673.html
- * string/memrchr.c (MEMRCHR):
- * string/rawmemchr.c (RAWMEMCHR):
- * string/strchr.c (strchr):
- * string/strchrnul.c (STRCHRNUL):
- Rewrite code to avoid issues with signed shift overflow.
-
-diff --git a/string/memrchr.c b/string/memrchr.c
-index 0c8fd84..86cd5b9 100644
---- a/string/memrchr.c
-+++ b/string/memrchr.c
-@@ -96,15 +96,8 @@ MEMRCHR
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
--
-- if (sizeof (longword) != 4 && sizeof (longword) != 8)
-- abort ();
--
--#if LONG_MAX <= LONG_MAX_32_BITS
-- magic_bits = 0x7efefeff;
--#else
-- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
--#endif
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/rawmemchr.c b/string/rawmemchr.c
-index 05b22be..228ca9d 100644
---- a/string/rawmemchr.c
-+++ b/string/rawmemchr.c
-@@ -86,15 +86,8 @@ RAWMEMCHR (s, c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
--
-- if (sizeof (longword) != 4 && sizeof (longword) != 8)
-- abort ();
--
--#if LONG_MAX <= LONG_MAX_32_BITS
-- magic_bits = 0x7efefeff;
--#else
-- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
--#endif
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/strchr.c b/string/strchr.c
-index 5f90075..f13b2b3 100644
---- a/string/strchr.c
-+++ b/string/strchr.c
-@@ -60,13 +60,8 @@ strchr (const char *s, int c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
-- switch (sizeof (longword))
-- {
-- case 4: magic_bits = 0x7efefeffL; break;
-- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
-- default:
-- abort ();
-- }
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/strchrnul.c b/string/strchrnul.c
-index 2678f1d..daf0b3f 100644
---- a/string/strchrnul.c
-+++ b/string/strchrnul.c
-@@ -66,13 +66,8 @@ STRCHRNUL (s, c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
-- switch (sizeof (longword))
-- {
-- case 4: magic_bits = 0x7efefeffL; break;
-- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
-- default:
-- abort ();
-- }
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
diff --git a/packages/glibc/2.19/103-dl-openat64-variadic.patch b/packages/glibc/2.19/103-dl-openat64-variadic.patch
deleted file mode 100644
index fe94b96..0000000
--- a/packages/glibc/2.19/103-dl-openat64-variadic.patch
+++ /dev/null
@@ -1,195 +0,0 @@
-commit 9dd346ff431fc761f1b748bd4da8bb59f7652094
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Tue Oct 20 11:54:09 2015 +0000
-
- Convert 113 more function definitions to prototype style (files with assertions).
-
- This mostly automatically-generated patch converts 113 function
- definitions in glibc from old-style K&R to prototype-style. Following
- my other recent such patches, this one deals with the case of function
- definitions in files that either contain assertions or where grep
- suggested they might contain assertions - and thus where it isn't
- possible to use a simple object code comparison as a sanity check on
- the correctness of the patch, because line numbers are changed.
-
- A few such automatically-generated changes needed to be supplemented
- by manual changes for the result to compile. openat64 had a prototype
- declaration with "..." but an old-style definition in
- sysdeps/unix/sysv/linux/dl-openat64.c, and "..." needed adding to the
- generated prototype in the definition (I've filed
- <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68024> for diagnosing
- such cases in GCC; the old state was undefined behavior not requiring
- a diagnostic, but one seems a good idea). In addition, as Florian has
- noted regparm attribute mismatches between declaration and definition
- are only diagnosed for prototype definitions, and five functions
- needed internal_function added to their definitions (in the case of
- __pthread_mutex_cond_lock, via the macro definition of
- __pthread_mutex_lock) to compile on i386.
-
- After this patch is in, remaining old-style definitions are probably
- most readily fixed manually before we can turn on
- -Wold-style-definition for all builds.
-
- Tested for x86_64 and x86 (testsuite).
-
- * crypt/md5-crypt.c (__md5_crypt_r): Convert to prototype-style
- function definition.
- * crypt/sha256-crypt.c (__sha256_crypt_r): Likewise.
- * crypt/sha512-crypt.c (__sha512_crypt_r): Likewise.
- * debug/backtracesyms.c (__backtrace_symbols): Likewise.
- * elf/dl-minimal.c (_itoa): Likewise.
- * hurd/hurdmalloc.c (malloc): Likewise.
- (free): Likewise.
- (realloc): Likewise.
- * inet/inet6_option.c (inet6_option_space): Likewise.
- (inet6_option_init): Likewise.
- (inet6_option_append): Likewise.
- (inet6_option_alloc): Likewise.
- (inet6_option_next): Likewise.
- (inet6_option_find): Likewise.
- * io/ftw.c (FTW_NAME): Likewise.
- (NFTW_NAME): Likewise.
- (NFTW_NEW_NAME): Likewise.
- (NFTW_OLD_NAME): Likewise.
- * libio/iofwide.c (_IO_fwide): Likewise.
- * libio/strops.c (_IO_str_init_static_internal): Likewise.
- (_IO_str_init_static): Likewise.
- (_IO_str_init_readonly): Likewise.
- (_IO_str_overflow): Likewise.
- (_IO_str_underflow): Likewise.
- (_IO_str_count): Likewise.
- (_IO_str_seekoff): Likewise.
- (_IO_str_pbackfail): Likewise.
- (_IO_str_finish): Likewise.
- * libio/wstrops.c (_IO_wstr_init_static): Likewise.
- (_IO_wstr_overflow): Likewise.
- (_IO_wstr_underflow): Likewise.
- (_IO_wstr_count): Likewise.
- (_IO_wstr_seekoff): Likewise.
- (_IO_wstr_pbackfail): Likewise.
- (_IO_wstr_finish): Likewise.
- * locale/programs/localedef.c (normalize_codeset): Likewise.
- * locale/programs/locarchive.c (add_locale_to_archive): Likewise.
- (add_locales_to_archive): Likewise.
- (delete_locales_from_archive): Likewise.
- * malloc/malloc.c (__libc_mallinfo): Likewise.
- * math/gen-auto-libm-tests.c (init_fp_formats): Likewise.
- * misc/tsearch.c (__tfind): Likewise.
- * nptl/pthread_attr_destroy.c (__pthread_attr_destroy): Likewise.
- * nptl/pthread_attr_getdetachstate.c
- (__pthread_attr_getdetachstate): Likewise.
- * nptl/pthread_attr_getguardsize.c (pthread_attr_getguardsize):
- Likewise.
- * nptl/pthread_attr_getinheritsched.c
- (__pthread_attr_getinheritsched): Likewise.
- * nptl/pthread_attr_getschedparam.c
- (__pthread_attr_getschedparam): Likewise.
- * nptl/pthread_attr_getschedpolicy.c
- (__pthread_attr_getschedpolicy): Likewise.
- * nptl/pthread_attr_getscope.c (__pthread_attr_getscope):
- Likewise.
- * nptl/pthread_attr_getstack.c (__pthread_attr_getstack):
- Likewise.
- * nptl/pthread_attr_getstackaddr.c (__pthread_attr_getstackaddr):
- Likewise.
- * nptl/pthread_attr_getstacksize.c (__pthread_attr_getstacksize):
- Likewise.
- * nptl/pthread_attr_init.c (__pthread_attr_init_2_1): Likewise.
- (__pthread_attr_init_2_0): Likewise.
- * nptl/pthread_attr_setdetachstate.c
- (__pthread_attr_setdetachstate): Likewise.
- * nptl/pthread_attr_setguardsize.c (pthread_attr_setguardsize):
- Likewise.
- * nptl/pthread_attr_setinheritsched.c
- (__pthread_attr_setinheritsched): Likewise.
- * nptl/pthread_attr_setschedparam.c
- (__pthread_attr_setschedparam): Likewise.
- * nptl/pthread_attr_setschedpolicy.c
- (__pthread_attr_setschedpolicy): Likewise.
- * nptl/pthread_attr_setscope.c (__pthread_attr_setscope):
- Likewise.
- * nptl/pthread_attr_setstack.c (__pthread_attr_setstack):
- Likewise.
- * nptl/pthread_attr_setstackaddr.c (__pthread_attr_setstackaddr):
- Likewise.
- * nptl/pthread_attr_setstacksize.c (__pthread_attr_setstacksize):
- Likewise.
- * nptl/pthread_condattr_setclock.c (pthread_condattr_setclock):
- Likewise.
- * nptl/pthread_create.c (__find_in_stack_list): Likewise.
- * nptl/pthread_getattr_np.c (pthread_getattr_np): Likewise.
- * nptl/pthread_mutex_cond_lock.c (__pthread_mutex_lock): Define to
- use internal_function.
- * nptl/pthread_mutex_init.c (__pthread_mutex_init): Convert to
- prototype-style function definition.
- * nptl/pthread_mutex_lock.c (__pthread_mutex_lock): Likewise.
- (__pthread_mutex_cond_lock_adjust): Likewise. Use
- internal_function.
- * nptl/pthread_mutex_timedlock.c (pthread_mutex_timedlock):
- Convert to prototype-style function definition.
- * nptl/pthread_mutex_trylock.c (__pthread_mutex_trylock):
- Likewise.
- * nptl/pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt):
- Likewise.
- (__pthread_mutex_unlock): Likewise.
- * nptl_db/td_ta_clear_event.c (td_ta_clear_event): Likewise.
- * nptl_db/td_ta_set_event.c (td_ta_set_event): Likewise.
- * nptl_db/td_thr_clear_event.c (td_thr_clear_event): Likewise.
- * nptl_db/td_thr_event_enable.c (td_thr_event_enable): Likewise.
- * nptl_db/td_thr_set_event.c (td_thr_set_event): Likewise.
- * nss/makedb.c (process_input): Likewise.
- * posix/fnmatch.c (__strchrnul): Likewise.
- (__wcschrnul): Likewise.
- (fnmatch): Likewise.
- * posix/fnmatch_loop.c (FCT): Likewise.
- * posix/glob.c (globfree): Likewise.
- (__glob_pattern_type): Likewise.
- (__glob_pattern_p): Likewise.
- * posix/regcomp.c (re_compile_pattern): Likewise.
- (re_set_syntax): Likewise.
- (re_compile_fastmap): Likewise.
- (regcomp): Likewise.
- (regerror): Likewise.
- (regfree): Likewise.
- * posix/regexec.c (regexec): Likewise.
- (re_match): Likewise.
- (re_search): Likewise.
- (re_match_2): Likewise.
- (re_search_2): Likewise.
- (re_search_stub): Likewise. Use internal_function
- (re_copy_regs): Likewise.
- (re_set_registers): Convert to prototype-style function
- definition.
- (prune_impossible_nodes): Likewise. Use internal_function.
- * resolv/inet_net_pton.c (inet_net_pton): Convert to
- prototype-style function definition.
- (inet_net_pton_ipv4): Likewise.
- * stdlib/strtod_l.c (____STRTOF_INTERNAL): Likewise.
- * sysdeps/pthread/aio_cancel.c (aio_cancel): Likewise.
- * sysdeps/pthread/aio_suspend.c (aio_suspend): Likewise.
- * sysdeps/pthread/timer_delete.c (timer_delete): Likewise.
- * sysdeps/unix/sysv/linux/dl-openat64.c (openat64): Likewise.
- Make variadic.
- * time/strptime_l.c (localtime_r): Convert to prototype-style
- function definition.
- * wcsmbs/mbsnrtowcs.c (__mbsnrtowcs): Likewise.
- * wcsmbs/mbsrtowcs_l.c (__mbsrtowcs_l): Likewise.
- * wcsmbs/wcsnrtombs.c (__wcsnrtombs): Likewise.
- * wcsmbs/wcsrtombs.c (__wcsrtombs): Likewise.
-
-diff --git a/sysdeps/unix/sysv/linux/dl-openat64.c b/sysdeps/unix/sysv/linux/dl-openat64.c
-index 7d100bb..7eea0ca 100644
---- a/sysdeps/unix/sysv/linux/dl-openat64.c
-+++ b/sysdeps/unix/sysv/linux/dl-openat64.c
-@@ -23,10 +23,7 @@
-
-
- int
--openat64 (dfd, file, oflag)
-- int dfd;
-- const char *file;
-- int oflag;
-+openat64 (int dfd, const char *file, int oflag, ...)
- {
- assert ((oflag & O_CREAT) == 0);
-
diff --git a/packages/glibc/2.19/105-misleading-indentation.patch b/packages/glibc/2.19/105-misleading-indentation.patch
deleted file mode 100644
index 1dd8d85..0000000
--- a/packages/glibc/2.19/105-misleading-indentation.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-commit 976ef870542580cf5fed896c2c652b3e1a95f9da
-Author: Steve Ellcey <sellcey@mips.com>
-Date: Fri Dec 11 09:19:37 2015 -0800
-
- Fix indentation.
-
- * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
- Fix indentation.
-
-diff --git a/sysdeps/ieee754/flt-32/k_rem_pio2f.c b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-index 0c7685c..392afdb 100644
---- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-+++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-@@ -65,7 +65,9 @@ int __kernel_rem_pio2f(float *x, float *y, int e0, int nx, int prec, const int32
-
- /* compute q[0],q[1],...q[jk] */
- for (i=0;i<=jk;i++) {
-- for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw;
-+ for(j=0,fw=0.0;j<=jx;j++)
-+ fw += x[j]*f[jx+i-j];
-+ q[i] = fw;
- }
-
- jz = jk;
diff --git a/packages/glibc/2.19/920-fix-rpc_parse-format.patch b/packages/glibc/2.19/920-fix-rpc_parse-format.patch
deleted file mode 100644
index 37e58da..0000000
--- a/packages/glibc/2.19/920-fix-rpc_parse-format.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-commit 5874510faaf3cbd0bb112aaacab9f225002beed1
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Tue Nov 8 23:44:51 2016 +0000
-
- Fix rpcgen buffer overrun (bug 20790).
-
- Building with GCC 7 produces an error building rpcgen:
-
- rpc_parse.c: In function 'get_prog_declaration':
- rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ~~~~^
- rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
- That buffer overrun is for the case where the .x file declares a
- program with a million arguments. The strcpy two lines above can
- generate a buffer overrun much more simply for a long argument name.
-
- The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
- provides a bound on the buffer size needed, so this patch just changes
- the buffer size to MAXLINESIZE to avoid both possible buffer
- overruns. A testcase is added that rpcgen does not crash with a
- 500-character argument name, where it previously crashed.
-
- It would not at all surprise me if there are many other ways of
- crashing rpcgen with either valid or invalid input; fuzz testing would
- likely find various such bugs, though I don't think they are that
- important to fix (rpcgen is not that likely to be used with untrusted
- .x files as input). (As well as fuzz-findable bugs there are probably
- also issues when various int variables get overflowed on very large
- input.) The test infrastructure for rpcgen-not-crashing tests would
- need extending if tests are to be added for cases where rpcgen should
- produce an error, as opposed to cases where it should succeed.
-
- Tested for x86_64 and x86.
-
- [BZ #20790]
- * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
- to MAXLINESIZE.
- * sunrpc/bug20790.x: New file.
- * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
- variable.
- [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
- [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
-
-diff --git a/sunrpc/rpc_parse.c b/sunrpc/rpc_parse.c
-index 1a1df6d8c2..505a6554cf 100644
---- a/sunrpc/rpc_parse.c
-+++ b/sunrpc/rpc_parse.c
-@@ -521,7 +521,7 @@ static void
- get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
- {
- token tok;
-- char name[10]; /* argument name */
-+ char name[MAXLINESIZE]; /* argument name */
-
- if (dkind == DEF_PROGRAM)
- {
diff --git a/packages/glibc/2.19/940-nis-bogus-conditional.patch b/packages/glibc/2.19/940-nis-bogus-conditional.patch
deleted file mode 100644
index 09b38cf..0000000
--- a/packages/glibc/2.19/940-nis-bogus-conditional.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Wed Dec 21 23:44:01 2016 +0000
-
- Fix nss_nisplus build with mainline GCC (bug 20978).
-
- glibc build with current mainline GCC fails because
- nis/nss_nisplus/nisplus-alias.c contains code
-
- if (name != NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
- }
-
- char buf[strlen (name) + 9 + tablename_len];
-
- producing an error about strlen being called on a pointer that is
- always NULL (and a subsequent use of that pointer with a %s format in
- snprintf).
-
- As Andreas noted, the bogus conditional comes from a 1997 change:
-
- - if (name == NULL || strlen(name) > 8)
- - return NSS_STATUS_NOTFOUND;
- - else
- + if (name != NULL || strlen(name) <= 8)
-
- So the intention is clearly to return an error for NULL name.
-
- This patch duly inverts the sense of the conditional. It fixes the
- build with GCC mainline, and passes usual glibc testsuite testing for
- x86_64. However, I have not tried any actual substantive nisplus
- testing, do not have an environment for such testing, and do not know
- whether it is possible that strlen (name) or tablename_len might be
- large so that the VLA for buf is actually a security issue. However,
- if it is a security issue, there are plenty of other similar instances
- in the nisplus code (that haven't been hidden by a bogus comparison
- with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
- string passed to nis_list, so a local fix in the caller wouldn't
- suffice anyway (see bug 20987). (Calls to strdupa and other such
- macros that use alloca must be considered equally questionable
- regarding stack overflow issues as direct calls to alloca and VLA
- declarations.)
-
- [BZ #20978]
- * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
- Compare name == NULL, not name != NULL.
-
-diff --git a/nis/nss_nisplus/nisplus-alias.c b/nis/nss_nisplus/nisplus-alias.c
-index 7f698b4e6d..cb5acce01d 100644
---- a/nis/nss_nisplus/nisplus-alias.c
-+++ b/nis/nss_nisplus/nisplus-alias.c
-@@ -291,7 +291,7 @@ _nss_nisplus_getaliasbyname_r (const char *name, struct aliasent *alias,
- return status;
- }
-
-- if (name != NULL)
-+ if (name == NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.20/100-sparc-nptl.patch b/packages/glibc/2.20/0000-sparc-nptl.patch
index 21f0337..4c5a10e 100644
--- a/packages/glibc/2.20/100-sparc-nptl.patch
+++ b/packages/glibc/2.20/0000-sparc-nptl.patch
@@ -1,5 +1,7 @@
-diff --git a/sysdeps/sparc/sparc32/sem_trywait.c b/sysdeps/sparc/sparc32/sem_trywait.c
-index 7d0fc55..ad9b4ad 100644
+---
+ sysdeps/sparc/sparc32/sem_trywait.c | 1 +
+ 1 file changed, 1 insertion(+)
+
--- a/sysdeps/sparc/sparc32/sem_trywait.c
+++ b/sysdeps/sparc/sparc32/sem_trywait.c
@@ -22,6 +22,7 @@
@@ -10,5 +12,3 @@ index 7d0fc55..ad9b4ad 100644
#include <shlib-compat.h>
-
-
diff --git a/packages/glibc/2.20/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.20/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
new file mode 100644
index 0000000..d92014e
--- /dev/null
+++ b/packages/glibc/2.20/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
@@ -0,0 +1,75 @@
+From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
+From: Yvan Roux <yvan.roux@linaro.org>
+Date: Fri, 15 Apr 2016 13:29:26 +0200
+Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
+ -Wparentheses
+
+---
+ nis/nis_call.c | 20 +++++++++++---------
+ stdlib/setenv.c | 24 +++++++++++++-----------
+ 2 files changed, 24 insertions(+), 20 deletions(-)
+
+--- a/nis/nis_call.c
++++ b/nis/nis_call.c
+@@ -680,16 +680,18 @@
+ /* Choose which entry should be evicted from the cache. */
+ loc = &nis_server_cache[0];
+ if (*loc != NULL)
+- for (i = 1; i < 16; ++i)
+- if (nis_server_cache[i] == NULL)
+- {
++ {
++ for (i = 1; i < 16; ++i)
++ if (nis_server_cache[i] == NULL)
++ {
++ loc = &nis_server_cache[i];
++ break;
++ }
++ else if ((*loc)->uses > nis_server_cache[i]->uses
++ || ((*loc)->uses == nis_server_cache[i]->uses
++ && (*loc)->expires > nis_server_cache[i]->expires))
+ loc = &nis_server_cache[i];
+- break;
+- }
+- else if ((*loc)->uses > nis_server_cache[i]->uses
+- || ((*loc)->uses == nis_server_cache[i]->uses
+- && (*loc)->expires > nis_server_cache[i]->expires))
+- loc = &nis_server_cache[i];
++ }
+ old = *loc;
+ *loc = new;
+
+--- a/stdlib/setenv.c
++++ b/stdlib/setenv.c
+@@ -262,18 +262,20 @@
+ ep = __environ;
+ if (ep != NULL)
+ while (*ep != NULL)
+- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
+- {
+- /* Found it. Remove this pointer by moving later ones back. */
+- char **dp = ep;
++ {
++ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
++ {
++ /* Found it. Remove this pointer by moving later ones back. */
++ char **dp = ep;
+
+- do
+- dp[0] = dp[1];
+- while (*dp++);
+- /* Continue the loop in case NAME appears again. */
+- }
+- else
+- ++ep;
++ do
++ dp[0] = dp[1];
++ while (*dp++);
++ /* Continue the loop in case NAME appears again. */
++ }
++ else
++ ++ep;
++ }
+
+ UNLOCK;
+
diff --git a/packages/glibc/2.20/0002-fix-signed-shift-overlow.patch b/packages/glibc/2.20/0002-fix-signed-shift-overlow.patch
new file mode 100644
index 0000000..c7cc330
--- /dev/null
+++ b/packages/glibc/2.20/0002-fix-signed-shift-overlow.patch
@@ -0,0 +1,97 @@
+commit 5542236837c5c41435f8282ec92799f480c36f18
+Author: Paul Eggert <eggert@cs.ucla.edu>
+Date: Tue Jul 21 22:50:29 2015 -0700
+
+ Port the 0x7efe...feff pattern to GCC 6.
+
+ See Steve Ellcey's bug report in:
+ https://sourceware.org/ml/libc-alpha/2015-07/msg00673.html
+ * string/memrchr.c (MEMRCHR):
+ * string/rawmemchr.c (RAWMEMCHR):
+ * string/strchr.c (strchr):
+ * string/strchrnul.c (STRCHRNUL):
+ Rewrite code to avoid issues with signed shift overflow.
+
+---
+ string/memrchr.c | 11 ++---------
+ string/rawmemchr.c | 11 ++---------
+ string/strchr.c | 9 ++-------
+ string/strchrnul.c | 9 ++-------
+ 4 files changed, 8 insertions(+), 32 deletions(-)
+
+--- a/string/memrchr.c
++++ b/string/memrchr.c
+@@ -96,15 +96,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+-
+- if (sizeof (longword) != 4 && sizeof (longword) != 8)
+- abort ();
+-
+-#if LONG_MAX <= LONG_MAX_32_BITS
+- magic_bits = 0x7efefeff;
+-#else
+- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
+-#endif
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/rawmemchr.c
++++ b/string/rawmemchr.c
+@@ -86,15 +86,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+-
+- if (sizeof (longword) != 4 && sizeof (longword) != 8)
+- abort ();
+-
+-#if LONG_MAX <= LONG_MAX_32_BITS
+- magic_bits = 0x7efefeff;
+-#else
+- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
+-#endif
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/strchr.c
++++ b/string/strchr.c
+@@ -60,13 +60,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+- switch (sizeof (longword))
+- {
+- case 4: magic_bits = 0x7efefeffL; break;
+- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
+- default:
+- abort ();
+- }
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/strchrnul.c
++++ b/string/strchrnul.c
+@@ -66,13 +66,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+- switch (sizeof (longword))
+- {
+- case 4: magic_bits = 0x7efefeffL; break;
+- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
+- default:
+- abort ();
+- }
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
diff --git a/packages/glibc/2.20/0003-dl-openat64-variadic.patch b/packages/glibc/2.20/0003-dl-openat64-variadic.patch
new file mode 100644
index 0000000..552db12
--- /dev/null
+++ b/packages/glibc/2.20/0003-dl-openat64-variadic.patch
@@ -0,0 +1,197 @@
+commit 9dd346ff431fc761f1b748bd4da8bb59f7652094
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Tue Oct 20 11:54:09 2015 +0000
+
+ Convert 113 more function definitions to prototype style (files with assertions).
+
+ This mostly automatically-generated patch converts 113 function
+ definitions in glibc from old-style K&R to prototype-style. Following
+ my other recent such patches, this one deals with the case of function
+ definitions in files that either contain assertions or where grep
+ suggested they might contain assertions - and thus where it isn't
+ possible to use a simple object code comparison as a sanity check on
+ the correctness of the patch, because line numbers are changed.
+
+ A few such automatically-generated changes needed to be supplemented
+ by manual changes for the result to compile. openat64 had a prototype
+ declaration with "..." but an old-style definition in
+ sysdeps/unix/sysv/linux/dl-openat64.c, and "..." needed adding to the
+ generated prototype in the definition (I've filed
+ <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68024> for diagnosing
+ such cases in GCC; the old state was undefined behavior not requiring
+ a diagnostic, but one seems a good idea). In addition, as Florian has
+ noted regparm attribute mismatches between declaration and definition
+ are only diagnosed for prototype definitions, and five functions
+ needed internal_function added to their definitions (in the case of
+ __pthread_mutex_cond_lock, via the macro definition of
+ __pthread_mutex_lock) to compile on i386.
+
+ After this patch is in, remaining old-style definitions are probably
+ most readily fixed manually before we can turn on
+ -Wold-style-definition for all builds.
+
+ Tested for x86_64 and x86 (testsuite).
+
+ * crypt/md5-crypt.c (__md5_crypt_r): Convert to prototype-style
+ function definition.
+ * crypt/sha256-crypt.c (__sha256_crypt_r): Likewise.
+ * crypt/sha512-crypt.c (__sha512_crypt_r): Likewise.
+ * debug/backtracesyms.c (__backtrace_symbols): Likewise.
+ * elf/dl-minimal.c (_itoa): Likewise.
+ * hurd/hurdmalloc.c (malloc): Likewise.
+ (free): Likewise.
+ (realloc): Likewise.
+ * inet/inet6_option.c (inet6_option_space): Likewise.
+ (inet6_option_init): Likewise.
+ (inet6_option_append): Likewise.
+ (inet6_option_alloc): Likewise.
+ (inet6_option_next): Likewise.
+ (inet6_option_find): Likewise.
+ * io/ftw.c (FTW_NAME): Likewise.
+ (NFTW_NAME): Likewise.
+ (NFTW_NEW_NAME): Likewise.
+ (NFTW_OLD_NAME): Likewise.
+ * libio/iofwide.c (_IO_fwide): Likewise.
+ * libio/strops.c (_IO_str_init_static_internal): Likewise.
+ (_IO_str_init_static): Likewise.
+ (_IO_str_init_readonly): Likewise.
+ (_IO_str_overflow): Likewise.
+ (_IO_str_underflow): Likewise.
+ (_IO_str_count): Likewise.
+ (_IO_str_seekoff): Likewise.
+ (_IO_str_pbackfail): Likewise.
+ (_IO_str_finish): Likewise.
+ * libio/wstrops.c (_IO_wstr_init_static): Likewise.
+ (_IO_wstr_overflow): Likewise.
+ (_IO_wstr_underflow): Likewise.
+ (_IO_wstr_count): Likewise.
+ (_IO_wstr_seekoff): Likewise.
+ (_IO_wstr_pbackfail): Likewise.
+ (_IO_wstr_finish): Likewise.
+ * locale/programs/localedef.c (normalize_codeset): Likewise.
+ * locale/programs/locarchive.c (add_locale_to_archive): Likewise.
+ (add_locales_to_archive): Likewise.
+ (delete_locales_from_archive): Likewise.
+ * malloc/malloc.c (__libc_mallinfo): Likewise.
+ * math/gen-auto-libm-tests.c (init_fp_formats): Likewise.
+ * misc/tsearch.c (__tfind): Likewise.
+ * nptl/pthread_attr_destroy.c (__pthread_attr_destroy): Likewise.
+ * nptl/pthread_attr_getdetachstate.c
+ (__pthread_attr_getdetachstate): Likewise.
+ * nptl/pthread_attr_getguardsize.c (pthread_attr_getguardsize):
+ Likewise.
+ * nptl/pthread_attr_getinheritsched.c
+ (__pthread_attr_getinheritsched): Likewise.
+ * nptl/pthread_attr_getschedparam.c
+ (__pthread_attr_getschedparam): Likewise.
+ * nptl/pthread_attr_getschedpolicy.c
+ (__pthread_attr_getschedpolicy): Likewise.
+ * nptl/pthread_attr_getscope.c (__pthread_attr_getscope):
+ Likewise.
+ * nptl/pthread_attr_getstack.c (__pthread_attr_getstack):
+ Likewise.
+ * nptl/pthread_attr_getstackaddr.c (__pthread_attr_getstackaddr):
+ Likewise.
+ * nptl/pthread_attr_getstacksize.c (__pthread_attr_getstacksize):
+ Likewise.
+ * nptl/pthread_attr_init.c (__pthread_attr_init_2_1): Likewise.
+ (__pthread_attr_init_2_0): Likewise.
+ * nptl/pthread_attr_setdetachstate.c
+ (__pthread_attr_setdetachstate): Likewise.
+ * nptl/pthread_attr_setguardsize.c (pthread_attr_setguardsize):
+ Likewise.
+ * nptl/pthread_attr_setinheritsched.c
+ (__pthread_attr_setinheritsched): Likewise.
+ * nptl/pthread_attr_setschedparam.c
+ (__pthread_attr_setschedparam): Likewise.
+ * nptl/pthread_attr_setschedpolicy.c
+ (__pthread_attr_setschedpolicy): Likewise.
+ * nptl/pthread_attr_setscope.c (__pthread_attr_setscope):
+ Likewise.
+ * nptl/pthread_attr_setstack.c (__pthread_attr_setstack):
+ Likewise.
+ * nptl/pthread_attr_setstackaddr.c (__pthread_attr_setstackaddr):
+ Likewise.
+ * nptl/pthread_attr_setstacksize.c (__pthread_attr_setstacksize):
+ Likewise.
+ * nptl/pthread_condattr_setclock.c (pthread_condattr_setclock):
+ Likewise.
+ * nptl/pthread_create.c (__find_in_stack_list): Likewise.
+ * nptl/pthread_getattr_np.c (pthread_getattr_np): Likewise.
+ * nptl/pthread_mutex_cond_lock.c (__pthread_mutex_lock): Define to
+ use internal_function.
+ * nptl/pthread_mutex_init.c (__pthread_mutex_init): Convert to
+ prototype-style function definition.
+ * nptl/pthread_mutex_lock.c (__pthread_mutex_lock): Likewise.
+ (__pthread_mutex_cond_lock_adjust): Likewise. Use
+ internal_function.
+ * nptl/pthread_mutex_timedlock.c (pthread_mutex_timedlock):
+ Convert to prototype-style function definition.
+ * nptl/pthread_mutex_trylock.c (__pthread_mutex_trylock):
+ Likewise.
+ * nptl/pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt):
+ Likewise.
+ (__pthread_mutex_unlock): Likewise.
+ * nptl_db/td_ta_clear_event.c (td_ta_clear_event): Likewise.
+ * nptl_db/td_ta_set_event.c (td_ta_set_event): Likewise.
+ * nptl_db/td_thr_clear_event.c (td_thr_clear_event): Likewise.
+ * nptl_db/td_thr_event_enable.c (td_thr_event_enable): Likewise.
+ * nptl_db/td_thr_set_event.c (td_thr_set_event): Likewise.
+ * nss/makedb.c (process_input): Likewise.
+ * posix/fnmatch.c (__strchrnul): Likewise.
+ (__wcschrnul): Likewise.
+ (fnmatch): Likewise.
+ * posix/fnmatch_loop.c (FCT): Likewise.
+ * posix/glob.c (globfree): Likewise.
+ (__glob_pattern_type): Likewise.
+ (__glob_pattern_p): Likewise.
+ * posix/regcomp.c (re_compile_pattern): Likewise.
+ (re_set_syntax): Likewise.
+ (re_compile_fastmap): Likewise.
+ (regcomp): Likewise.
+ (regerror): Likewise.
+ (regfree): Likewise.
+ * posix/regexec.c (regexec): Likewise.
+ (re_match): Likewise.
+ (re_search): Likewise.
+ (re_match_2): Likewise.
+ (re_search_2): Likewise.
+ (re_search_stub): Likewise. Use internal_function
+ (re_copy_regs): Likewise.
+ (re_set_registers): Convert to prototype-style function
+ definition.
+ (prune_impossible_nodes): Likewise. Use internal_function.
+ * resolv/inet_net_pton.c (inet_net_pton): Convert to
+ prototype-style function definition.
+ (inet_net_pton_ipv4): Likewise.
+ * stdlib/strtod_l.c (____STRTOF_INTERNAL): Likewise.
+ * sysdeps/pthread/aio_cancel.c (aio_cancel): Likewise.
+ * sysdeps/pthread/aio_suspend.c (aio_suspend): Likewise.
+ * sysdeps/pthread/timer_delete.c (timer_delete): Likewise.
+ * sysdeps/unix/sysv/linux/dl-openat64.c (openat64): Likewise.
+ Make variadic.
+ * time/strptime_l.c (localtime_r): Convert to prototype-style
+ function definition.
+ * wcsmbs/mbsnrtowcs.c (__mbsnrtowcs): Likewise.
+ * wcsmbs/mbsrtowcs_l.c (__mbsrtowcs_l): Likewise.
+ * wcsmbs/wcsnrtombs.c (__wcsnrtombs): Likewise.
+ * wcsmbs/wcsrtombs.c (__wcsrtombs): Likewise.
+
+---
+ sysdeps/unix/sysv/linux/dl-openat64.c | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
+--- a/sysdeps/unix/sysv/linux/dl-openat64.c
++++ b/sysdeps/unix/sysv/linux/dl-openat64.c
+@@ -23,10 +23,7 @@
+
+
+ int
+-openat64 (dfd, file, oflag)
+- int dfd;
+- const char *file;
+- int oflag;
++openat64 (int dfd, const char *file, int oflag, ...)
+ {
+ assert ((oflag & O_CREAT) == 0);
+
diff --git a/packages/glibc/2.19/104-unused-variables.patch b/packages/glibc/2.20/0004-unused-variables.patch
index 889c9bb..694bc61 100644
--- a/packages/glibc/2.19/104-unused-variables.patch
+++ b/packages/glibc/2.20/0004-unused-variables.patch
@@ -19,8 +19,19 @@ Date: Fri Sep 18 20:27:20 2015 +0100
* timezone/private.h (time_t_min): Likewise. (time_t_max):
Likewise.
-diff --git a/resolv/base64.c b/resolv/base64.c
-index ea584ed..519e5d2 100644
+---
+ resolv/base64.c | 4 ----
+ sysdeps/ieee754/dbl-64/atnat2.h | 4 ----
+ sysdeps/ieee754/dbl-64/uexp.h | 2 +-
+ sysdeps/ieee754/dbl-64/upow.h | 2 --
+ sysdeps/ieee754/flt-32/e_log10f.c | 2 --
+ sysdeps/ieee754/flt-32/s_cosf.c | 2 --
+ sysdeps/ieee754/ldbl-128/e_lgammal_r.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_erfl.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_log1pl.c | 1 -
+ timezone/private.h | 10 ----------
+ 10 files changed, 1 insertion(+), 28 deletions(-)
+
--- a/resolv/base64.c
+++ b/resolv/base64.c
@@ -40,10 +40,6 @@
@@ -34,8 +45,6 @@ index ea584ed..519e5d2 100644
#include <sys/types.h>
#include <sys/param.h>
#include <sys/socket.h>
-diff --git a/sysdeps/ieee754/dbl-64/atnat2.h b/sysdeps/ieee754/dbl-64/atnat2.h
-index e0d65af..82943f9 100644
--- a/sysdeps/ieee754/dbl-64/atnat2.h
+++ b/sysdeps/ieee754/dbl-64/atnat2.h
@@ -65,10 +65,8 @@
@@ -60,8 +69,6 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0x7f3321d2, 0xc002d97c} }, /* -3pi/4 */
/**/ u1 = {{0x00000000, 0x3c314c2a} }, /* 9.377e-19 */
/**/ u2 = {{0x00000000, 0x3bf955e4} }, /* 8.584e-20 */
-diff --git a/sysdeps/ieee754/dbl-64/uexp.h b/sysdeps/ieee754/dbl-64/uexp.h
-index 6817eaf..42b21f2 100644
--- a/sysdeps/ieee754/dbl-64/uexp.h
+++ b/sysdeps/ieee754/dbl-64/uexp.h
@@ -29,7 +29,7 @@
@@ -73,8 +80,6 @@ index 6817eaf..42b21f2 100644
err_0 = 1.000014, err_1 = 0.000016;
const static int4 bigint = 0x40862002,
badint = 0x40876000,smallint = 0x3C8fffff;
-diff --git a/sysdeps/ieee754/dbl-64/upow.h b/sysdeps/ieee754/dbl-64/upow.h
-index c8569a9..b4911e5 100644
--- a/sysdeps/ieee754/dbl-64/upow.h
+++ b/sysdeps/ieee754/dbl-64/upow.h
@@ -34,7 +34,6 @@
@@ -93,11 +98,9 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0xfefa3800, 0x3fe62e42}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x93c76730, 0x3d2ef357}}, /* ln(2)-ln2a */
/**/ bigu = {{0xfffffd2c, 0x4297ffff}}, /* 1.5*2**42 -724*2**-10 */
-diff --git a/sysdeps/ieee754/flt-32/e_log10f.c b/sysdeps/ieee754/flt-32/e_log10f.c
-index 96f0e81..1daeef7 100644
--- a/sysdeps/ieee754/flt-32/e_log10f.c
+++ b/sysdeps/ieee754/flt-32/e_log10f.c
-@@ -22,8 +22,6 @@ ivln10 = 4.3429449201e-01, /* 0x3ede5bd9 */
+@@ -22,8 +22,6 @@
log10_2hi = 3.0102920532e-01, /* 0x3e9a2080 */
log10_2lo = 7.9034151668e-07; /* 0x355427db */
@@ -106,11 +109,9 @@ index 96f0e81..1daeef7 100644
float
__ieee754_log10f(float x)
{
-diff --git a/sysdeps/ieee754/flt-32/s_cosf.c b/sysdeps/ieee754/flt-32/s_cosf.c
-index 864ab27..0affd40 100644
--- a/sysdeps/ieee754/flt-32/s_cosf.c
+++ b/sysdeps/ieee754/flt-32/s_cosf.c
-@@ -21,8 +21,6 @@ static char rcsid[] = "$NetBSD: s_cosf.c,v 1.4 1995/05/10 20:47:03 jtc Exp $";
+@@ -21,8 +21,6 @@
#include <math.h>
#include <math_private.h>
@@ -119,11 +120,9 @@ index 864ab27..0affd40 100644
#ifndef COSF
# define COSF_FUNC __cosf
#else
-diff --git a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-index 500aacc..ab5a96e 100644
--- a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
+++ b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-@@ -82,7 +82,6 @@ DIAG_IGNORE_NEEDS_COMMENT (4.6, "-Woverflow");
+@@ -74,7 +74,6 @@
static const long double PIL = 3.1415926535897932384626433832795028841972E0L;
static const long double MAXLGM = 1.0485738685148938358098967157129705071571E4928L;
static const long double one = 1.0L;
@@ -131,11 +130,9 @@ index 500aacc..ab5a96e 100644
static const long double huge = 1.0e4000L;
/* log gamma(x) = ( x - 0.5 ) * log(x) - x + LS2PI + 1/x P(1/x^2)
-diff --git a/sysdeps/ieee754/ldbl-128/s_erfl.c b/sysdeps/ieee754/ldbl-128/s_erfl.c
-index fa4609f..08c80a3 100644
--- a/sysdeps/ieee754/ldbl-128/s_erfl.c
+++ b/sysdeps/ieee754/ldbl-128/s_erfl.c
-@@ -140,7 +140,6 @@ deval (long double x, const long double *p, int n)
+@@ -140,7 +140,6 @@
static const long double
tiny = 1e-4931L,
@@ -143,11 +140,9 @@ index fa4609f..08c80a3 100644
one = 1.0L,
two = 2.0L,
/* 2/sqrt(pi) - 1 */
-diff --git a/sysdeps/ieee754/ldbl-128/s_log1pl.c b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-index ff759bc..9609550 100644
--- a/sysdeps/ieee754/ldbl-128/s_log1pl.c
+++ b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-@@ -117,7 +117,6 @@ static const long double C2 = 1.428606820309417232121458176568075500134E-6L;
+@@ -116,7 +116,6 @@
static const long double sqrth = 0.7071067811865475244008443621048490392848L;
/* ln (2^16384 * (1 - 2^-113)) */
@@ -155,11 +150,9 @@ index ff759bc..9609550 100644
static const long double zero = 0.0L;
long double
-diff --git a/timezone/private.h b/timezone/private.h
-index 4e8f4ae..ed19e06 100644
--- a/timezone/private.h
+++ b/timezone/private.h
-@@ -326,16 +326,6 @@ const char * scheck(const char * string, const char * format);
+@@ -326,16 +326,6 @@
#define TYPE_SIGNED(type) (((type) -1) < 0)
#endif /* !defined TYPE_SIGNED */
diff --git a/packages/glibc/2.20/0005-misleading-indentation.patch b/packages/glibc/2.20/0005-misleading-indentation.patch
new file mode 100644
index 0000000..8e08259
--- /dev/null
+++ b/packages/glibc/2.20/0005-misleading-indentation.patch
@@ -0,0 +1,26 @@
+commit 976ef870542580cf5fed896c2c652b3e1a95f9da
+Author: Steve Ellcey <sellcey@mips.com>
+Date: Fri Dec 11 09:19:37 2015 -0800
+
+ Fix indentation.
+
+ * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
+ Fix indentation.
+
+---
+ sysdeps/ieee754/flt-32/k_rem_pio2f.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+--- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
++++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
+@@ -65,7 +65,9 @@
+
+ /* compute q[0],q[1],...q[jk] */
+ for (i=0;i<=jk;i++) {
+- for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw;
++ for(j=0,fw=0.0;j<=jx;j++)
++ fw += x[j]*f[jx+i-j];
++ q[i] = fw;
+ }
+
+ jz = jk;
diff --git a/packages/glibc/2.18/106-dl-open-array-bounds.patch b/packages/glibc/2.20/0006-dl-open-array-bounds.patch
index 08a9076..83eb0b3 100644
--- a/packages/glibc/2.18/106-dl-open-array-bounds.patch
+++ b/packages/glibc/2.20/0006-dl-open-array-bounds.patch
@@ -4,11 +4,13 @@ Date: Fri Apr 17 12:11:58 2015 -0700
Fuller check for invalid NSID in _dl_open.
-diff --git a/elf/dl-open.c b/elf/dl-open.c
-index 0dbe07f..2d0e082 100644
+---
+ elf/dl-open.c | 12 +++++++++---
+ 1 file changed, 9 insertions(+), 3 deletions(-)
+
--- a/elf/dl-open.c
+++ b/elf/dl-open.c
-@@ -211,7 +211,7 @@ dl_open_worker (void *a)
+@@ -211,7 +211,7 @@
struct link_map *l = _dl_find_dso_for_object ((ElfW(Addr)) caller_dlopen);
if (l)
@@ -17,7 +19,7 @@ index 0dbe07f..2d0e082 100644
if (args->nsid == __LM_ID_CALLER)
args->nsid = call_map->l_ns;
-@@ -619,8 +619,14 @@ no more namespaces available for dlmopen()"));
+@@ -627,8 +627,14 @@
/* Never allow loading a DSO in a namespace which is empty. Such
direct placements is only causing problems. Also don't allow
loading into a namespace used for auditing. */
diff --git a/packages/glibc/2.19/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.20/0007-Fix-combreloc-test-BSD-grep.patch
index fdc3a60..f56a4ca 100644
--- a/packages/glibc/2.19/140-Fix-combreloc-test-BSD-grep.patch
+++ b/packages/glibc/2.20/0007-Fix-combreloc-test-BSD-grep.patch
@@ -13,16 +13,13 @@ by configure as "not found". As a result, support for "-z combreloc"
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
+ configure | 2 +-
+ configure.ac | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
-diff --git a/configure b/configure
-index eecd0ac..0118bd1 100755
--- a/configure
+++ b/configure
-@@ -5804,7 +5804,7 @@ if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
+@@ -6025,7 +6025,7 @@
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; }
then
@@ -31,11 +28,9 @@ index eecd0ac..0118bd1 100755
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
-diff --git a/configure.ac b/configure.ac
-index 4a77411..19f6d87 100644
--- a/configure.ac
+++ b/configure.ac
-@@ -1391,7 +1391,7 @@ dnl cross-platform since the gcc used can be a cross compiler. Without
+@@ -1397,7 +1397,7 @@
dnl introducing new options this is not easily doable. Instead use a tool
dnl which always is cross-platform: readelf. To detect whether -z combreloc
dnl look for a section named .rel.dyn.
@@ -44,6 +39,3 @@ index 4a77411..19f6d87 100644
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
---
-2.9.3
-
diff --git a/packages/glibc/2.20/910-typedef-caddr.patch b/packages/glibc/2.20/0008-typedef-caddr.patch
index fc7979b..980939b 100644
--- a/packages/glibc/2.20/910-typedef-caddr.patch
+++ b/packages/glibc/2.20/0008-typedef-caddr.patch
@@ -1,8 +1,11 @@
-diff -urN glibc-2.23-orig/posix/sys/types.h glibc-2.23/posix/sys/types.h
---- glibc-2.23-orig/posix/sys/types.h 2016-02-18 12:54:00.000000000 -0500
-+++ glibc-2.23/posix/sys/types.h 2017-01-06 11:40:05.842147165 -0500
+---
+ posix/sys/types.h | 3 +++
+ 1 file changed, 3 insertions(+)
+
+--- a/posix/sys/types.h
++++ b/posix/sys/types.h
@@ -113,7 +113,10 @@
- #ifdef __USE_MISC
+ #ifdef __USE_MISC
# ifndef __daddr_t_defined
typedef __daddr_t daddr_t;
+# if ! defined(caddr_t) && ! defined(__caddr_t_defined)
@@ -12,4 +15,3 @@ diff -urN glibc-2.23-orig/posix/sys/types.h glibc-2.23/posix/sys/types.h
# define __daddr_t_defined
# endif
#endif
-
diff --git a/packages/glibc/2.20/0009-fix-rpc_parse-format.patch b/packages/glibc/2.20/0009-fix-rpc_parse-format.patch
new file mode 100644
index 0000000..341d541
--- /dev/null
+++ b/packages/glibc/2.20/0009-fix-rpc_parse-format.patch
@@ -0,0 +1,62 @@
+commit 5874510faaf3cbd0bb112aaacab9f225002beed1
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Tue Nov 8 23:44:51 2016 +0000
+
+ Fix rpcgen buffer overrun (bug 20790).
+
+ Building with GCC 7 produces an error building rpcgen:
+
+ rpc_parse.c: In function 'get_prog_declaration':
+ rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ~~~~^
+ rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+ That buffer overrun is for the case where the .x file declares a
+ program with a million arguments. The strcpy two lines above can
+ generate a buffer overrun much more simply for a long argument name.
+
+ The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
+ provides a bound on the buffer size needed, so this patch just changes
+ the buffer size to MAXLINESIZE to avoid both possible buffer
+ overruns. A testcase is added that rpcgen does not crash with a
+ 500-character argument name, where it previously crashed.
+
+ It would not at all surprise me if there are many other ways of
+ crashing rpcgen with either valid or invalid input; fuzz testing would
+ likely find various such bugs, though I don't think they are that
+ important to fix (rpcgen is not that likely to be used with untrusted
+ .x files as input). (As well as fuzz-findable bugs there are probably
+ also issues when various int variables get overflowed on very large
+ input.) The test infrastructure for rpcgen-not-crashing tests would
+ need extending if tests are to be added for cases where rpcgen should
+ produce an error, as opposed to cases where it should succeed.
+
+ Tested for x86_64 and x86.
+
+ [BZ #20790]
+ * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
+ to MAXLINESIZE.
+ * sunrpc/bug20790.x: New file.
+ * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
+ variable.
+ [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
+ [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
+
+---
+ sunrpc/rpc_parse.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/sunrpc/rpc_parse.c
++++ b/sunrpc/rpc_parse.c
+@@ -521,7 +521,7 @@
+ get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
+ {
+ token tok;
+- char name[10]; /* argument name */
++ char name[MAXLINESIZE]; /* argument name */
+
+ if (dkind == DEF_PROGRAM)
+ {
diff --git a/packages/glibc/2.20/930-explicit-boolean.patch b/packages/glibc/2.20/0010-explicit-boolean.patch
index 780fae6..ff7cd87 100644
--- a/packages/glibc/2.20/930-explicit-boolean.patch
+++ b/packages/glibc/2.20/0010-explicit-boolean.patch
@@ -7,11 +7,13 @@ Date: Fri Oct 14 12:53:27 2016 -0700
* sysdeps/ieee754/dbl-64/e_pow.c (checkint) Make conditions explicitly
boolean.
-diff --git a/sysdeps/ieee754/dbl-64/e_pow.c b/sysdeps/ieee754/dbl-64/e_pow.c
-index 663fa392c2..bd758b5979 100644
+---
+ sysdeps/ieee754/dbl-64/e_pow.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
--- a/sysdeps/ieee754/dbl-64/e_pow.c
+++ b/sysdeps/ieee754/dbl-64/e_pow.c
-@@ -466,15 +466,15 @@ checkint (double x)
+@@ -462,15 +462,15 @@
return (n & 1) ? -1 : 1; /* odd or even */
if (k > 20)
{
diff --git a/packages/glibc/2.20/0011-nis-bogus-conditional.patch b/packages/glibc/2.20/0011-nis-bogus-conditional.patch
new file mode 100644
index 0000000..e728368
--- /dev/null
+++ b/packages/glibc/2.20/0011-nis-bogus-conditional.patch
@@ -0,0 +1,64 @@
+commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Wed Dec 21 23:44:01 2016 +0000
+
+ Fix nss_nisplus build with mainline GCC (bug 20978).
+
+ glibc build with current mainline GCC fails because
+ nis/nss_nisplus/nisplus-alias.c contains code
+
+ if (name != NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
+ }
+
+ char buf[strlen (name) + 9 + tablename_len];
+
+ producing an error about strlen being called on a pointer that is
+ always NULL (and a subsequent use of that pointer with a %s format in
+ snprintf).
+
+ As Andreas noted, the bogus conditional comes from a 1997 change:
+
+ - if (name == NULL || strlen(name) > 8)
+ - return NSS_STATUS_NOTFOUND;
+ - else
+ + if (name != NULL || strlen(name) <= 8)
+
+ So the intention is clearly to return an error for NULL name.
+
+ This patch duly inverts the sense of the conditional. It fixes the
+ build with GCC mainline, and passes usual glibc testsuite testing for
+ x86_64. However, I have not tried any actual substantive nisplus
+ testing, do not have an environment for such testing, and do not know
+ whether it is possible that strlen (name) or tablename_len might be
+ large so that the VLA for buf is actually a security issue. However,
+ if it is a security issue, there are plenty of other similar instances
+ in the nisplus code (that haven't been hidden by a bogus comparison
+ with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
+ string passed to nis_list, so a local fix in the caller wouldn't
+ suffice anyway (see bug 20987). (Calls to strdupa and other such
+ macros that use alloca must be considered equally questionable
+ regarding stack overflow issues as direct calls to alloca and VLA
+ declarations.)
+
+ [BZ #20978]
+ * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
+ Compare name == NULL, not name != NULL.
+
+---
+ nis/nss_nisplus/nisplus-alias.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/nis/nss_nisplus/nisplus-alias.c
++++ b/nis/nss_nisplus/nisplus-alias.c
+@@ -291,7 +291,7 @@
+ return status;
+ }
+
+- if (name != NULL)
++ if (name == NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.20/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.20/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
deleted file mode 100644
index 6fd663a..0000000
--- a/packages/glibc/2.20/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
-From: Yvan Roux <yvan.roux@linaro.org>
-Date: Fri, 15 Apr 2016 13:29:26 +0200
-Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
- -Wparentheses
-
----
- ChangeLog | 5 +++++
- nis/nis_call.c | 20 +++++++++++---------
- stdlib/setenv.c | 26 ++++++++++++++------------
- 3 files changed, 30 insertions(+), 21 deletions(-)
-
-diff --git a/nis/nis_call.c b/nis/nis_call.c
-index 3fa37e4..cb7839a 100644
---- a/nis/nis_call.c
-+++ b/nis/nis_call.c
-@@ -680,16 +680,18 @@ nis_server_cache_add (const_nis_name name, int search_parent,
- /* Choose which entry should be evicted from the cache. */
- loc = &nis_server_cache[0];
- if (*loc != NULL)
-- for (i = 1; i < 16; ++i)
-- if (nis_server_cache[i] == NULL)
-- {
-+ {
-+ for (i = 1; i < 16; ++i)
-+ if (nis_server_cache[i] == NULL)
-+ {
-+ loc = &nis_server_cache[i];
-+ break;
-+ }
-+ else if ((*loc)->uses > nis_server_cache[i]->uses
-+ || ((*loc)->uses == nis_server_cache[i]->uses
-+ && (*loc)->expires > nis_server_cache[i]->expires))
- loc = &nis_server_cache[i];
-- break;
-- }
-- else if ((*loc)->uses > nis_server_cache[i]->uses
-- || ((*loc)->uses == nis_server_cache[i]->uses
-- && (*loc)->expires > nis_server_cache[i]->expires))
-- loc = &nis_server_cache[i];
-+ }
- old = *loc;
- *loc = new;
-
-diff --git a/stdlib/setenv.c b/stdlib/setenv.c
-index da61ee0..e66045f 100644
---- a/stdlib/setenv.c
-+++ b/stdlib/setenv.c
-@@ -278,18 +278,20 @@ unsetenv (const char *name)
- ep = __environ;
- if (ep != NULL)
- while (*ep != NULL)
-- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-- {
-- /* Found it. Remove this pointer by moving later ones back. */
-- char **dp = ep;
--
-- do
-- dp[0] = dp[1];
-- while (*dp++);
-- /* Continue the loop in case NAME appears again. */
-- }
-- else
-- ++ep;
-+ {
-+ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-+ {
-+ /* Found it. Remove this pointer by moving later ones back. */
-+ char **dp = ep;
-+
-+ do
-+ dp[0] = dp[1];
-+ while (*dp++);
-+ /* Continue the loop in case NAME appears again. */
-+ }
-+ else
-+ ++ep;
-+ }
-
- UNLOCK;
-
---
-2.7.4
-
diff --git a/packages/glibc/2.20/102-fix-signed-shift-overlow.patch b/packages/glibc/2.20/102-fix-signed-shift-overlow.patch
deleted file mode 100644
index ef49f83..0000000
--- a/packages/glibc/2.20/102-fix-signed-shift-overlow.patch
+++ /dev/null
@@ -1,98 +0,0 @@
-commit 5542236837c5c41435f8282ec92799f480c36f18
-Author: Paul Eggert <eggert@cs.ucla.edu>
-Date: Tue Jul 21 22:50:29 2015 -0700
-
- Port the 0x7efe...feff pattern to GCC 6.
-
- See Steve Ellcey's bug report in:
- https://sourceware.org/ml/libc-alpha/2015-07/msg00673.html
- * string/memrchr.c (MEMRCHR):
- * string/rawmemchr.c (RAWMEMCHR):
- * string/strchr.c (strchr):
- * string/strchrnul.c (STRCHRNUL):
- Rewrite code to avoid issues with signed shift overflow.
-
-diff --git a/string/memrchr.c b/string/memrchr.c
-index 0c8fd84..86cd5b9 100644
---- a/string/memrchr.c
-+++ b/string/memrchr.c
-@@ -96,15 +96,8 @@ MEMRCHR
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
--
-- if (sizeof (longword) != 4 && sizeof (longword) != 8)
-- abort ();
--
--#if LONG_MAX <= LONG_MAX_32_BITS
-- magic_bits = 0x7efefeff;
--#else
-- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
--#endif
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/rawmemchr.c b/string/rawmemchr.c
-index 05b22be..228ca9d 100644
---- a/string/rawmemchr.c
-+++ b/string/rawmemchr.c
-@@ -86,15 +86,8 @@ RAWMEMCHR (s, c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
--
-- if (sizeof (longword) != 4 && sizeof (longword) != 8)
-- abort ();
--
--#if LONG_MAX <= LONG_MAX_32_BITS
-- magic_bits = 0x7efefeff;
--#else
-- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
--#endif
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/strchr.c b/string/strchr.c
-index 5f90075..f13b2b3 100644
---- a/string/strchr.c
-+++ b/string/strchr.c
-@@ -60,13 +60,8 @@ strchr (const char *s, int c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
-- switch (sizeof (longword))
-- {
-- case 4: magic_bits = 0x7efefeffL; break;
-- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
-- default:
-- abort ();
-- }
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/strchrnul.c b/string/strchrnul.c
-index 2678f1d..daf0b3f 100644
---- a/string/strchrnul.c
-+++ b/string/strchrnul.c
-@@ -66,13 +66,8 @@ STRCHRNUL (s, c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
-- switch (sizeof (longword))
-- {
-- case 4: magic_bits = 0x7efefeffL; break;
-- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
-- default:
-- abort ();
-- }
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
diff --git a/packages/glibc/2.20/103-dl-openat64-variadic.patch b/packages/glibc/2.20/103-dl-openat64-variadic.patch
deleted file mode 100644
index fe94b96..0000000
--- a/packages/glibc/2.20/103-dl-openat64-variadic.patch
+++ /dev/null
@@ -1,195 +0,0 @@
-commit 9dd346ff431fc761f1b748bd4da8bb59f7652094
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Tue Oct 20 11:54:09 2015 +0000
-
- Convert 113 more function definitions to prototype style (files with assertions).
-
- This mostly automatically-generated patch converts 113 function
- definitions in glibc from old-style K&R to prototype-style. Following
- my other recent such patches, this one deals with the case of function
- definitions in files that either contain assertions or where grep
- suggested they might contain assertions - and thus where it isn't
- possible to use a simple object code comparison as a sanity check on
- the correctness of the patch, because line numbers are changed.
-
- A few such automatically-generated changes needed to be supplemented
- by manual changes for the result to compile. openat64 had a prototype
- declaration with "..." but an old-style definition in
- sysdeps/unix/sysv/linux/dl-openat64.c, and "..." needed adding to the
- generated prototype in the definition (I've filed
- <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68024> for diagnosing
- such cases in GCC; the old state was undefined behavior not requiring
- a diagnostic, but one seems a good idea). In addition, as Florian has
- noted regparm attribute mismatches between declaration and definition
- are only diagnosed for prototype definitions, and five functions
- needed internal_function added to their definitions (in the case of
- __pthread_mutex_cond_lock, via the macro definition of
- __pthread_mutex_lock) to compile on i386.
-
- After this patch is in, remaining old-style definitions are probably
- most readily fixed manually before we can turn on
- -Wold-style-definition for all builds.
-
- Tested for x86_64 and x86 (testsuite).
-
- * crypt/md5-crypt.c (__md5_crypt_r): Convert to prototype-style
- function definition.
- * crypt/sha256-crypt.c (__sha256_crypt_r): Likewise.
- * crypt/sha512-crypt.c (__sha512_crypt_r): Likewise.
- * debug/backtracesyms.c (__backtrace_symbols): Likewise.
- * elf/dl-minimal.c (_itoa): Likewise.
- * hurd/hurdmalloc.c (malloc): Likewise.
- (free): Likewise.
- (realloc): Likewise.
- * inet/inet6_option.c (inet6_option_space): Likewise.
- (inet6_option_init): Likewise.
- (inet6_option_append): Likewise.
- (inet6_option_alloc): Likewise.
- (inet6_option_next): Likewise.
- (inet6_option_find): Likewise.
- * io/ftw.c (FTW_NAME): Likewise.
- (NFTW_NAME): Likewise.
- (NFTW_NEW_NAME): Likewise.
- (NFTW_OLD_NAME): Likewise.
- * libio/iofwide.c (_IO_fwide): Likewise.
- * libio/strops.c (_IO_str_init_static_internal): Likewise.
- (_IO_str_init_static): Likewise.
- (_IO_str_init_readonly): Likewise.
- (_IO_str_overflow): Likewise.
- (_IO_str_underflow): Likewise.
- (_IO_str_count): Likewise.
- (_IO_str_seekoff): Likewise.
- (_IO_str_pbackfail): Likewise.
- (_IO_str_finish): Likewise.
- * libio/wstrops.c (_IO_wstr_init_static): Likewise.
- (_IO_wstr_overflow): Likewise.
- (_IO_wstr_underflow): Likewise.
- (_IO_wstr_count): Likewise.
- (_IO_wstr_seekoff): Likewise.
- (_IO_wstr_pbackfail): Likewise.
- (_IO_wstr_finish): Likewise.
- * locale/programs/localedef.c (normalize_codeset): Likewise.
- * locale/programs/locarchive.c (add_locale_to_archive): Likewise.
- (add_locales_to_archive): Likewise.
- (delete_locales_from_archive): Likewise.
- * malloc/malloc.c (__libc_mallinfo): Likewise.
- * math/gen-auto-libm-tests.c (init_fp_formats): Likewise.
- * misc/tsearch.c (__tfind): Likewise.
- * nptl/pthread_attr_destroy.c (__pthread_attr_destroy): Likewise.
- * nptl/pthread_attr_getdetachstate.c
- (__pthread_attr_getdetachstate): Likewise.
- * nptl/pthread_attr_getguardsize.c (pthread_attr_getguardsize):
- Likewise.
- * nptl/pthread_attr_getinheritsched.c
- (__pthread_attr_getinheritsched): Likewise.
- * nptl/pthread_attr_getschedparam.c
- (__pthread_attr_getschedparam): Likewise.
- * nptl/pthread_attr_getschedpolicy.c
- (__pthread_attr_getschedpolicy): Likewise.
- * nptl/pthread_attr_getscope.c (__pthread_attr_getscope):
- Likewise.
- * nptl/pthread_attr_getstack.c (__pthread_attr_getstack):
- Likewise.
- * nptl/pthread_attr_getstackaddr.c (__pthread_attr_getstackaddr):
- Likewise.
- * nptl/pthread_attr_getstacksize.c (__pthread_attr_getstacksize):
- Likewise.
- * nptl/pthread_attr_init.c (__pthread_attr_init_2_1): Likewise.
- (__pthread_attr_init_2_0): Likewise.
- * nptl/pthread_attr_setdetachstate.c
- (__pthread_attr_setdetachstate): Likewise.
- * nptl/pthread_attr_setguardsize.c (pthread_attr_setguardsize):
- Likewise.
- * nptl/pthread_attr_setinheritsched.c
- (__pthread_attr_setinheritsched): Likewise.
- * nptl/pthread_attr_setschedparam.c
- (__pthread_attr_setschedparam): Likewise.
- * nptl/pthread_attr_setschedpolicy.c
- (__pthread_attr_setschedpolicy): Likewise.
- * nptl/pthread_attr_setscope.c (__pthread_attr_setscope):
- Likewise.
- * nptl/pthread_attr_setstack.c (__pthread_attr_setstack):
- Likewise.
- * nptl/pthread_attr_setstackaddr.c (__pthread_attr_setstackaddr):
- Likewise.
- * nptl/pthread_attr_setstacksize.c (__pthread_attr_setstacksize):
- Likewise.
- * nptl/pthread_condattr_setclock.c (pthread_condattr_setclock):
- Likewise.
- * nptl/pthread_create.c (__find_in_stack_list): Likewise.
- * nptl/pthread_getattr_np.c (pthread_getattr_np): Likewise.
- * nptl/pthread_mutex_cond_lock.c (__pthread_mutex_lock): Define to
- use internal_function.
- * nptl/pthread_mutex_init.c (__pthread_mutex_init): Convert to
- prototype-style function definition.
- * nptl/pthread_mutex_lock.c (__pthread_mutex_lock): Likewise.
- (__pthread_mutex_cond_lock_adjust): Likewise. Use
- internal_function.
- * nptl/pthread_mutex_timedlock.c (pthread_mutex_timedlock):
- Convert to prototype-style function definition.
- * nptl/pthread_mutex_trylock.c (__pthread_mutex_trylock):
- Likewise.
- * nptl/pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt):
- Likewise.
- (__pthread_mutex_unlock): Likewise.
- * nptl_db/td_ta_clear_event.c (td_ta_clear_event): Likewise.
- * nptl_db/td_ta_set_event.c (td_ta_set_event): Likewise.
- * nptl_db/td_thr_clear_event.c (td_thr_clear_event): Likewise.
- * nptl_db/td_thr_event_enable.c (td_thr_event_enable): Likewise.
- * nptl_db/td_thr_set_event.c (td_thr_set_event): Likewise.
- * nss/makedb.c (process_input): Likewise.
- * posix/fnmatch.c (__strchrnul): Likewise.
- (__wcschrnul): Likewise.
- (fnmatch): Likewise.
- * posix/fnmatch_loop.c (FCT): Likewise.
- * posix/glob.c (globfree): Likewise.
- (__glob_pattern_type): Likewise.
- (__glob_pattern_p): Likewise.
- * posix/regcomp.c (re_compile_pattern): Likewise.
- (re_set_syntax): Likewise.
- (re_compile_fastmap): Likewise.
- (regcomp): Likewise.
- (regerror): Likewise.
- (regfree): Likewise.
- * posix/regexec.c (regexec): Likewise.
- (re_match): Likewise.
- (re_search): Likewise.
- (re_match_2): Likewise.
- (re_search_2): Likewise.
- (re_search_stub): Likewise. Use internal_function
- (re_copy_regs): Likewise.
- (re_set_registers): Convert to prototype-style function
- definition.
- (prune_impossible_nodes): Likewise. Use internal_function.
- * resolv/inet_net_pton.c (inet_net_pton): Convert to
- prototype-style function definition.
- (inet_net_pton_ipv4): Likewise.
- * stdlib/strtod_l.c (____STRTOF_INTERNAL): Likewise.
- * sysdeps/pthread/aio_cancel.c (aio_cancel): Likewise.
- * sysdeps/pthread/aio_suspend.c (aio_suspend): Likewise.
- * sysdeps/pthread/timer_delete.c (timer_delete): Likewise.
- * sysdeps/unix/sysv/linux/dl-openat64.c (openat64): Likewise.
- Make variadic.
- * time/strptime_l.c (localtime_r): Convert to prototype-style
- function definition.
- * wcsmbs/mbsnrtowcs.c (__mbsnrtowcs): Likewise.
- * wcsmbs/mbsrtowcs_l.c (__mbsrtowcs_l): Likewise.
- * wcsmbs/wcsnrtombs.c (__wcsnrtombs): Likewise.
- * wcsmbs/wcsrtombs.c (__wcsrtombs): Likewise.
-
-diff --git a/sysdeps/unix/sysv/linux/dl-openat64.c b/sysdeps/unix/sysv/linux/dl-openat64.c
-index 7d100bb..7eea0ca 100644
---- a/sysdeps/unix/sysv/linux/dl-openat64.c
-+++ b/sysdeps/unix/sysv/linux/dl-openat64.c
-@@ -23,10 +23,7 @@
-
-
- int
--openat64 (dfd, file, oflag)
-- int dfd;
-- const char *file;
-- int oflag;
-+openat64 (int dfd, const char *file, int oflag, ...)
- {
- assert ((oflag & O_CREAT) == 0);
-
diff --git a/packages/glibc/2.20/105-misleading-indentation.patch b/packages/glibc/2.20/105-misleading-indentation.patch
deleted file mode 100644
index 1dd8d85..0000000
--- a/packages/glibc/2.20/105-misleading-indentation.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-commit 976ef870542580cf5fed896c2c652b3e1a95f9da
-Author: Steve Ellcey <sellcey@mips.com>
-Date: Fri Dec 11 09:19:37 2015 -0800
-
- Fix indentation.
-
- * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
- Fix indentation.
-
-diff --git a/sysdeps/ieee754/flt-32/k_rem_pio2f.c b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-index 0c7685c..392afdb 100644
---- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-+++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-@@ -65,7 +65,9 @@ int __kernel_rem_pio2f(float *x, float *y, int e0, int nx, int prec, const int32
-
- /* compute q[0],q[1],...q[jk] */
- for (i=0;i<=jk;i++) {
-- for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw;
-+ for(j=0,fw=0.0;j<=jx;j++)
-+ fw += x[j]*f[jx+i-j];
-+ q[i] = fw;
- }
-
- jz = jk;
diff --git a/packages/glibc/2.20/920-fix-rpc_parse-format.patch b/packages/glibc/2.20/920-fix-rpc_parse-format.patch
deleted file mode 100644
index 37e58da..0000000
--- a/packages/glibc/2.20/920-fix-rpc_parse-format.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-commit 5874510faaf3cbd0bb112aaacab9f225002beed1
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Tue Nov 8 23:44:51 2016 +0000
-
- Fix rpcgen buffer overrun (bug 20790).
-
- Building with GCC 7 produces an error building rpcgen:
-
- rpc_parse.c: In function 'get_prog_declaration':
- rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ~~~~^
- rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
- That buffer overrun is for the case where the .x file declares a
- program with a million arguments. The strcpy two lines above can
- generate a buffer overrun much more simply for a long argument name.
-
- The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
- provides a bound on the buffer size needed, so this patch just changes
- the buffer size to MAXLINESIZE to avoid both possible buffer
- overruns. A testcase is added that rpcgen does not crash with a
- 500-character argument name, where it previously crashed.
-
- It would not at all surprise me if there are many other ways of
- crashing rpcgen with either valid or invalid input; fuzz testing would
- likely find various such bugs, though I don't think they are that
- important to fix (rpcgen is not that likely to be used with untrusted
- .x files as input). (As well as fuzz-findable bugs there are probably
- also issues when various int variables get overflowed on very large
- input.) The test infrastructure for rpcgen-not-crashing tests would
- need extending if tests are to be added for cases where rpcgen should
- produce an error, as opposed to cases where it should succeed.
-
- Tested for x86_64 and x86.
-
- [BZ #20790]
- * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
- to MAXLINESIZE.
- * sunrpc/bug20790.x: New file.
- * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
- variable.
- [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
- [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
-
-diff --git a/sunrpc/rpc_parse.c b/sunrpc/rpc_parse.c
-index 1a1df6d8c2..505a6554cf 100644
---- a/sunrpc/rpc_parse.c
-+++ b/sunrpc/rpc_parse.c
-@@ -521,7 +521,7 @@ static void
- get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
- {
- token tok;
-- char name[10]; /* argument name */
-+ char name[MAXLINESIZE]; /* argument name */
-
- if (dkind == DEF_PROGRAM)
- {
diff --git a/packages/glibc/2.20/940-nis-bogus-conditional.patch b/packages/glibc/2.20/940-nis-bogus-conditional.patch
deleted file mode 100644
index 09b38cf..0000000
--- a/packages/glibc/2.20/940-nis-bogus-conditional.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Wed Dec 21 23:44:01 2016 +0000
-
- Fix nss_nisplus build with mainline GCC (bug 20978).
-
- glibc build with current mainline GCC fails because
- nis/nss_nisplus/nisplus-alias.c contains code
-
- if (name != NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
- }
-
- char buf[strlen (name) + 9 + tablename_len];
-
- producing an error about strlen being called on a pointer that is
- always NULL (and a subsequent use of that pointer with a %s format in
- snprintf).
-
- As Andreas noted, the bogus conditional comes from a 1997 change:
-
- - if (name == NULL || strlen(name) > 8)
- - return NSS_STATUS_NOTFOUND;
- - else
- + if (name != NULL || strlen(name) <= 8)
-
- So the intention is clearly to return an error for NULL name.
-
- This patch duly inverts the sense of the conditional. It fixes the
- build with GCC mainline, and passes usual glibc testsuite testing for
- x86_64. However, I have not tried any actual substantive nisplus
- testing, do not have an environment for such testing, and do not know
- whether it is possible that strlen (name) or tablename_len might be
- large so that the VLA for buf is actually a security issue. However,
- if it is a security issue, there are plenty of other similar instances
- in the nisplus code (that haven't been hidden by a bogus comparison
- with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
- string passed to nis_list, so a local fix in the caller wouldn't
- suffice anyway (see bug 20987). (Calls to strdupa and other such
- macros that use alloca must be considered equally questionable
- regarding stack overflow issues as direct calls to alloca and VLA
- declarations.)
-
- [BZ #20978]
- * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
- Compare name == NULL, not name != NULL.
-
-diff --git a/nis/nss_nisplus/nisplus-alias.c b/nis/nss_nisplus/nisplus-alias.c
-index 7f698b4e6d..cb5acce01d 100644
---- a/nis/nss_nisplus/nisplus-alias.c
-+++ b/nis/nss_nisplus/nisplus-alias.c
-@@ -291,7 +291,7 @@ _nss_nisplus_getaliasbyname_r (const char *name, struct aliasent *alias,
- return status;
- }
-
-- if (name != NULL)
-+ if (name == NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.21/0000-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.21/0000-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
new file mode 100644
index 0000000..b9509a3
--- /dev/null
+++ b/packages/glibc/2.21/0000-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
@@ -0,0 +1,75 @@
+From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
+From: Yvan Roux <yvan.roux@linaro.org>
+Date: Fri, 15 Apr 2016 13:29:26 +0200
+Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
+ -Wparentheses
+
+---
+ nis/nis_call.c | 20 +++++++++++---------
+ stdlib/setenv.c | 24 +++++++++++++-----------
+ 2 files changed, 24 insertions(+), 20 deletions(-)
+
+--- a/nis/nis_call.c
++++ b/nis/nis_call.c
+@@ -680,16 +680,18 @@
+ /* Choose which entry should be evicted from the cache. */
+ loc = &nis_server_cache[0];
+ if (*loc != NULL)
+- for (i = 1; i < 16; ++i)
+- if (nis_server_cache[i] == NULL)
+- {
++ {
++ for (i = 1; i < 16; ++i)
++ if (nis_server_cache[i] == NULL)
++ {
++ loc = &nis_server_cache[i];
++ break;
++ }
++ else if ((*loc)->uses > nis_server_cache[i]->uses
++ || ((*loc)->uses == nis_server_cache[i]->uses
++ && (*loc)->expires > nis_server_cache[i]->expires))
+ loc = &nis_server_cache[i];
+- break;
+- }
+- else if ((*loc)->uses > nis_server_cache[i]->uses
+- || ((*loc)->uses == nis_server_cache[i]->uses
+- && (*loc)->expires > nis_server_cache[i]->expires))
+- loc = &nis_server_cache[i];
++ }
+ old = *loc;
+ *loc = new;
+
+--- a/stdlib/setenv.c
++++ b/stdlib/setenv.c
+@@ -269,18 +269,20 @@
+ ep = __environ;
+ if (ep != NULL)
+ while (*ep != NULL)
+- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
+- {
+- /* Found it. Remove this pointer by moving later ones back. */
+- char **dp = ep;
++ {
++ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
++ {
++ /* Found it. Remove this pointer by moving later ones back. */
++ char **dp = ep;
+
+- do
+- dp[0] = dp[1];
+- while (*dp++);
+- /* Continue the loop in case NAME appears again. */
+- }
+- else
+- ++ep;
++ do
++ dp[0] = dp[1];
++ while (*dp++);
++ /* Continue the loop in case NAME appears again. */
++ }
++ else
++ ++ep;
++ }
+
+ UNLOCK;
+
diff --git a/packages/glibc/2.21/0001-fix-signed-shift-overlow.patch b/packages/glibc/2.21/0001-fix-signed-shift-overlow.patch
new file mode 100644
index 0000000..c7cc330
--- /dev/null
+++ b/packages/glibc/2.21/0001-fix-signed-shift-overlow.patch
@@ -0,0 +1,97 @@
+commit 5542236837c5c41435f8282ec92799f480c36f18
+Author: Paul Eggert <eggert@cs.ucla.edu>
+Date: Tue Jul 21 22:50:29 2015 -0700
+
+ Port the 0x7efe...feff pattern to GCC 6.
+
+ See Steve Ellcey's bug report in:
+ https://sourceware.org/ml/libc-alpha/2015-07/msg00673.html
+ * string/memrchr.c (MEMRCHR):
+ * string/rawmemchr.c (RAWMEMCHR):
+ * string/strchr.c (strchr):
+ * string/strchrnul.c (STRCHRNUL):
+ Rewrite code to avoid issues with signed shift overflow.
+
+---
+ string/memrchr.c | 11 ++---------
+ string/rawmemchr.c | 11 ++---------
+ string/strchr.c | 9 ++-------
+ string/strchrnul.c | 9 ++-------
+ 4 files changed, 8 insertions(+), 32 deletions(-)
+
+--- a/string/memrchr.c
++++ b/string/memrchr.c
+@@ -96,15 +96,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+-
+- if (sizeof (longword) != 4 && sizeof (longword) != 8)
+- abort ();
+-
+-#if LONG_MAX <= LONG_MAX_32_BITS
+- magic_bits = 0x7efefeff;
+-#else
+- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
+-#endif
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/rawmemchr.c
++++ b/string/rawmemchr.c
+@@ -86,15 +86,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+-
+- if (sizeof (longword) != 4 && sizeof (longword) != 8)
+- abort ();
+-
+-#if LONG_MAX <= LONG_MAX_32_BITS
+- magic_bits = 0x7efefeff;
+-#else
+- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
+-#endif
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/strchr.c
++++ b/string/strchr.c
+@@ -60,13 +60,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+- switch (sizeof (longword))
+- {
+- case 4: magic_bits = 0x7efefeffL; break;
+- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
+- default:
+- abort ();
+- }
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/strchrnul.c
++++ b/string/strchrnul.c
+@@ -66,13 +66,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+- switch (sizeof (longword))
+- {
+- case 4: magic_bits = 0x7efefeffL; break;
+- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
+- default:
+- abort ();
+- }
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
diff --git a/packages/glibc/2.21/0002-dl-openat64-variadic.patch b/packages/glibc/2.21/0002-dl-openat64-variadic.patch
new file mode 100644
index 0000000..552db12
--- /dev/null
+++ b/packages/glibc/2.21/0002-dl-openat64-variadic.patch
@@ -0,0 +1,197 @@
+commit 9dd346ff431fc761f1b748bd4da8bb59f7652094
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Tue Oct 20 11:54:09 2015 +0000
+
+ Convert 113 more function definitions to prototype style (files with assertions).
+
+ This mostly automatically-generated patch converts 113 function
+ definitions in glibc from old-style K&R to prototype-style. Following
+ my other recent such patches, this one deals with the case of function
+ definitions in files that either contain assertions or where grep
+ suggested they might contain assertions - and thus where it isn't
+ possible to use a simple object code comparison as a sanity check on
+ the correctness of the patch, because line numbers are changed.
+
+ A few such automatically-generated changes needed to be supplemented
+ by manual changes for the result to compile. openat64 had a prototype
+ declaration with "..." but an old-style definition in
+ sysdeps/unix/sysv/linux/dl-openat64.c, and "..." needed adding to the
+ generated prototype in the definition (I've filed
+ <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68024> for diagnosing
+ such cases in GCC; the old state was undefined behavior not requiring
+ a diagnostic, but one seems a good idea). In addition, as Florian has
+ noted regparm attribute mismatches between declaration and definition
+ are only diagnosed for prototype definitions, and five functions
+ needed internal_function added to their definitions (in the case of
+ __pthread_mutex_cond_lock, via the macro definition of
+ __pthread_mutex_lock) to compile on i386.
+
+ After this patch is in, remaining old-style definitions are probably
+ most readily fixed manually before we can turn on
+ -Wold-style-definition for all builds.
+
+ Tested for x86_64 and x86 (testsuite).
+
+ * crypt/md5-crypt.c (__md5_crypt_r): Convert to prototype-style
+ function definition.
+ * crypt/sha256-crypt.c (__sha256_crypt_r): Likewise.
+ * crypt/sha512-crypt.c (__sha512_crypt_r): Likewise.
+ * debug/backtracesyms.c (__backtrace_symbols): Likewise.
+ * elf/dl-minimal.c (_itoa): Likewise.
+ * hurd/hurdmalloc.c (malloc): Likewise.
+ (free): Likewise.
+ (realloc): Likewise.
+ * inet/inet6_option.c (inet6_option_space): Likewise.
+ (inet6_option_init): Likewise.
+ (inet6_option_append): Likewise.
+ (inet6_option_alloc): Likewise.
+ (inet6_option_next): Likewise.
+ (inet6_option_find): Likewise.
+ * io/ftw.c (FTW_NAME): Likewise.
+ (NFTW_NAME): Likewise.
+ (NFTW_NEW_NAME): Likewise.
+ (NFTW_OLD_NAME): Likewise.
+ * libio/iofwide.c (_IO_fwide): Likewise.
+ * libio/strops.c (_IO_str_init_static_internal): Likewise.
+ (_IO_str_init_static): Likewise.
+ (_IO_str_init_readonly): Likewise.
+ (_IO_str_overflow): Likewise.
+ (_IO_str_underflow): Likewise.
+ (_IO_str_count): Likewise.
+ (_IO_str_seekoff): Likewise.
+ (_IO_str_pbackfail): Likewise.
+ (_IO_str_finish): Likewise.
+ * libio/wstrops.c (_IO_wstr_init_static): Likewise.
+ (_IO_wstr_overflow): Likewise.
+ (_IO_wstr_underflow): Likewise.
+ (_IO_wstr_count): Likewise.
+ (_IO_wstr_seekoff): Likewise.
+ (_IO_wstr_pbackfail): Likewise.
+ (_IO_wstr_finish): Likewise.
+ * locale/programs/localedef.c (normalize_codeset): Likewise.
+ * locale/programs/locarchive.c (add_locale_to_archive): Likewise.
+ (add_locales_to_archive): Likewise.
+ (delete_locales_from_archive): Likewise.
+ * malloc/malloc.c (__libc_mallinfo): Likewise.
+ * math/gen-auto-libm-tests.c (init_fp_formats): Likewise.
+ * misc/tsearch.c (__tfind): Likewise.
+ * nptl/pthread_attr_destroy.c (__pthread_attr_destroy): Likewise.
+ * nptl/pthread_attr_getdetachstate.c
+ (__pthread_attr_getdetachstate): Likewise.
+ * nptl/pthread_attr_getguardsize.c (pthread_attr_getguardsize):
+ Likewise.
+ * nptl/pthread_attr_getinheritsched.c
+ (__pthread_attr_getinheritsched): Likewise.
+ * nptl/pthread_attr_getschedparam.c
+ (__pthread_attr_getschedparam): Likewise.
+ * nptl/pthread_attr_getschedpolicy.c
+ (__pthread_attr_getschedpolicy): Likewise.
+ * nptl/pthread_attr_getscope.c (__pthread_attr_getscope):
+ Likewise.
+ * nptl/pthread_attr_getstack.c (__pthread_attr_getstack):
+ Likewise.
+ * nptl/pthread_attr_getstackaddr.c (__pthread_attr_getstackaddr):
+ Likewise.
+ * nptl/pthread_attr_getstacksize.c (__pthread_attr_getstacksize):
+ Likewise.
+ * nptl/pthread_attr_init.c (__pthread_attr_init_2_1): Likewise.
+ (__pthread_attr_init_2_0): Likewise.
+ * nptl/pthread_attr_setdetachstate.c
+ (__pthread_attr_setdetachstate): Likewise.
+ * nptl/pthread_attr_setguardsize.c (pthread_attr_setguardsize):
+ Likewise.
+ * nptl/pthread_attr_setinheritsched.c
+ (__pthread_attr_setinheritsched): Likewise.
+ * nptl/pthread_attr_setschedparam.c
+ (__pthread_attr_setschedparam): Likewise.
+ * nptl/pthread_attr_setschedpolicy.c
+ (__pthread_attr_setschedpolicy): Likewise.
+ * nptl/pthread_attr_setscope.c (__pthread_attr_setscope):
+ Likewise.
+ * nptl/pthread_attr_setstack.c (__pthread_attr_setstack):
+ Likewise.
+ * nptl/pthread_attr_setstackaddr.c (__pthread_attr_setstackaddr):
+ Likewise.
+ * nptl/pthread_attr_setstacksize.c (__pthread_attr_setstacksize):
+ Likewise.
+ * nptl/pthread_condattr_setclock.c (pthread_condattr_setclock):
+ Likewise.
+ * nptl/pthread_create.c (__find_in_stack_list): Likewise.
+ * nptl/pthread_getattr_np.c (pthread_getattr_np): Likewise.
+ * nptl/pthread_mutex_cond_lock.c (__pthread_mutex_lock): Define to
+ use internal_function.
+ * nptl/pthread_mutex_init.c (__pthread_mutex_init): Convert to
+ prototype-style function definition.
+ * nptl/pthread_mutex_lock.c (__pthread_mutex_lock): Likewise.
+ (__pthread_mutex_cond_lock_adjust): Likewise. Use
+ internal_function.
+ * nptl/pthread_mutex_timedlock.c (pthread_mutex_timedlock):
+ Convert to prototype-style function definition.
+ * nptl/pthread_mutex_trylock.c (__pthread_mutex_trylock):
+ Likewise.
+ * nptl/pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt):
+ Likewise.
+ (__pthread_mutex_unlock): Likewise.
+ * nptl_db/td_ta_clear_event.c (td_ta_clear_event): Likewise.
+ * nptl_db/td_ta_set_event.c (td_ta_set_event): Likewise.
+ * nptl_db/td_thr_clear_event.c (td_thr_clear_event): Likewise.
+ * nptl_db/td_thr_event_enable.c (td_thr_event_enable): Likewise.
+ * nptl_db/td_thr_set_event.c (td_thr_set_event): Likewise.
+ * nss/makedb.c (process_input): Likewise.
+ * posix/fnmatch.c (__strchrnul): Likewise.
+ (__wcschrnul): Likewise.
+ (fnmatch): Likewise.
+ * posix/fnmatch_loop.c (FCT): Likewise.
+ * posix/glob.c (globfree): Likewise.
+ (__glob_pattern_type): Likewise.
+ (__glob_pattern_p): Likewise.
+ * posix/regcomp.c (re_compile_pattern): Likewise.
+ (re_set_syntax): Likewise.
+ (re_compile_fastmap): Likewise.
+ (regcomp): Likewise.
+ (regerror): Likewise.
+ (regfree): Likewise.
+ * posix/regexec.c (regexec): Likewise.
+ (re_match): Likewise.
+ (re_search): Likewise.
+ (re_match_2): Likewise.
+ (re_search_2): Likewise.
+ (re_search_stub): Likewise. Use internal_function
+ (re_copy_regs): Likewise.
+ (re_set_registers): Convert to prototype-style function
+ definition.
+ (prune_impossible_nodes): Likewise. Use internal_function.
+ * resolv/inet_net_pton.c (inet_net_pton): Convert to
+ prototype-style function definition.
+ (inet_net_pton_ipv4): Likewise.
+ * stdlib/strtod_l.c (____STRTOF_INTERNAL): Likewise.
+ * sysdeps/pthread/aio_cancel.c (aio_cancel): Likewise.
+ * sysdeps/pthread/aio_suspend.c (aio_suspend): Likewise.
+ * sysdeps/pthread/timer_delete.c (timer_delete): Likewise.
+ * sysdeps/unix/sysv/linux/dl-openat64.c (openat64): Likewise.
+ Make variadic.
+ * time/strptime_l.c (localtime_r): Convert to prototype-style
+ function definition.
+ * wcsmbs/mbsnrtowcs.c (__mbsnrtowcs): Likewise.
+ * wcsmbs/mbsrtowcs_l.c (__mbsrtowcs_l): Likewise.
+ * wcsmbs/wcsnrtombs.c (__wcsnrtombs): Likewise.
+ * wcsmbs/wcsrtombs.c (__wcsrtombs): Likewise.
+
+---
+ sysdeps/unix/sysv/linux/dl-openat64.c | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
+--- a/sysdeps/unix/sysv/linux/dl-openat64.c
++++ b/sysdeps/unix/sysv/linux/dl-openat64.c
+@@ -23,10 +23,7 @@
+
+
+ int
+-openat64 (dfd, file, oflag)
+- int dfd;
+- const char *file;
+- int oflag;
++openat64 (int dfd, const char *file, int oflag, ...)
+ {
+ assert ((oflag & O_CREAT) == 0);
+
diff --git a/packages/glibc/2.22/104-unused-variables.patch b/packages/glibc/2.21/0003-unused-variables.patch
index fd4def0..3359834 100644
--- a/packages/glibc/2.22/104-unused-variables.patch
+++ b/packages/glibc/2.21/0003-unused-variables.patch
@@ -19,8 +19,19 @@ Date: Fri Sep 18 20:27:20 2015 +0100
* timezone/private.h (time_t_min): Likewise. (time_t_max):
Likewise.
-diff --git a/resolv/base64.c b/resolv/base64.c
-index ea584ed..519e5d2 100644
+---
+ resolv/base64.c | 4 ----
+ sysdeps/ieee754/dbl-64/atnat2.h | 4 ----
+ sysdeps/ieee754/dbl-64/uexp.h | 2 +-
+ sysdeps/ieee754/dbl-64/upow.h | 2 --
+ sysdeps/ieee754/flt-32/e_log10f.c | 2 --
+ sysdeps/ieee754/flt-32/s_cosf.c | 2 --
+ sysdeps/ieee754/ldbl-128/e_lgammal_r.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_erfl.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_log1pl.c | 1 -
+ timezone/private.h | 10 ----------
+ 10 files changed, 1 insertion(+), 28 deletions(-)
+
--- a/resolv/base64.c
+++ b/resolv/base64.c
@@ -40,10 +40,6 @@
@@ -34,8 +45,6 @@ index ea584ed..519e5d2 100644
#include <sys/types.h>
#include <sys/param.h>
#include <sys/socket.h>
-diff --git a/sysdeps/ieee754/dbl-64/atnat2.h b/sysdeps/ieee754/dbl-64/atnat2.h
-index e0d65af..82943f9 100644
--- a/sysdeps/ieee754/dbl-64/atnat2.h
+++ b/sysdeps/ieee754/dbl-64/atnat2.h
@@ -65,10 +65,8 @@
@@ -60,8 +69,6 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0x7f3321d2, 0xc002d97c} }, /* -3pi/4 */
/**/ u1 = {{0x00000000, 0x3c314c2a} }, /* 9.377e-19 */
/**/ u2 = {{0x00000000, 0x3bf955e4} }, /* 8.584e-20 */
-diff --git a/sysdeps/ieee754/dbl-64/uexp.h b/sysdeps/ieee754/dbl-64/uexp.h
-index 6817eaf..42b21f2 100644
--- a/sysdeps/ieee754/dbl-64/uexp.h
+++ b/sysdeps/ieee754/dbl-64/uexp.h
@@ -29,7 +29,7 @@
@@ -73,8 +80,6 @@ index 6817eaf..42b21f2 100644
err_0 = 1.000014, err_1 = 0.000016;
const static int4 bigint = 0x40862002,
badint = 0x40876000,smallint = 0x3C8fffff;
-diff --git a/sysdeps/ieee754/dbl-64/upow.h b/sysdeps/ieee754/dbl-64/upow.h
-index c8569a9..b4911e5 100644
--- a/sysdeps/ieee754/dbl-64/upow.h
+++ b/sysdeps/ieee754/dbl-64/upow.h
@@ -34,7 +34,6 @@
@@ -93,11 +98,9 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0xfefa3800, 0x3fe62e42}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x93c76730, 0x3d2ef357}}, /* ln(2)-ln2a */
/**/ bigu = {{0xfffffd2c, 0x4297ffff}}, /* 1.5*2**42 -724*2**-10 */
-diff --git a/sysdeps/ieee754/flt-32/e_log10f.c b/sysdeps/ieee754/flt-32/e_log10f.c
-index 96f0e81..1daeef7 100644
--- a/sysdeps/ieee754/flt-32/e_log10f.c
+++ b/sysdeps/ieee754/flt-32/e_log10f.c
-@@ -22,8 +22,6 @@ ivln10 = 4.3429449201e-01, /* 0x3ede5bd9 */
+@@ -22,8 +22,6 @@
log10_2hi = 3.0102920532e-01, /* 0x3e9a2080 */
log10_2lo = 7.9034151668e-07; /* 0x355427db */
@@ -106,11 +109,9 @@ index 96f0e81..1daeef7 100644
float
__ieee754_log10f(float x)
{
-diff --git a/sysdeps/ieee754/flt-32/s_cosf.c b/sysdeps/ieee754/flt-32/s_cosf.c
-index 864ab27..0affd40 100644
--- a/sysdeps/ieee754/flt-32/s_cosf.c
+++ b/sysdeps/ieee754/flt-32/s_cosf.c
-@@ -21,8 +21,6 @@ static char rcsid[] = "$NetBSD: s_cosf.c,v 1.4 1995/05/10 20:47:03 jtc Exp $";
+@@ -21,8 +21,6 @@
#include <math.h>
#include <math_private.h>
@@ -119,11 +120,9 @@ index 864ab27..0affd40 100644
#ifndef COSF
# define COSF_FUNC __cosf
#else
-diff --git a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-index 500aacc..ab5a96e 100644
--- a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
+++ b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-@@ -82,7 +82,6 @@ DIAG_IGNORE_NEEDS_COMMENT (4.6, "-Woverflow");
+@@ -82,7 +82,6 @@
static const long double MAXLGM = 1.0485738685148938358098967157129705071571E4928L;
DIAG_POP_NEEDS_COMMENT;
static const long double one = 1.0L;
@@ -131,11 +130,9 @@ index 500aacc..ab5a96e 100644
static const long double huge = LDBL_MAX;
/* log gamma(x) = ( x - 0.5 ) * log(x) - x + LS2PI + 1/x P(1/x^2)
-diff --git a/sysdeps/ieee754/ldbl-128/s_erfl.c b/sysdeps/ieee754/ldbl-128/s_erfl.c
-index fa4609f..08c80a3 100644
--- a/sysdeps/ieee754/ldbl-128/s_erfl.c
+++ b/sysdeps/ieee754/ldbl-128/s_erfl.c
-@@ -140,7 +140,6 @@ deval (long double x, const long double *p, int n)
+@@ -140,7 +140,6 @@
static const long double
tiny = 1e-4931L,
@@ -143,11 +140,9 @@ index fa4609f..08c80a3 100644
one = 1.0L,
two = 2.0L,
/* 2/sqrt(pi) - 1 */
-diff --git a/sysdeps/ieee754/ldbl-128/s_log1pl.c b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-index ff759bc..9609550 100644
--- a/sysdeps/ieee754/ldbl-128/s_log1pl.c
+++ b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-@@ -117,7 +117,6 @@ static const long double C2 = 1.428606820309417232121458176568075500134E-6L;
+@@ -116,7 +116,6 @@
static const long double sqrth = 0.7071067811865475244008443621048490392848L;
/* ln (2^16384 * (1 - 2^-113)) */
@@ -155,11 +150,9 @@ index ff759bc..9609550 100644
static const long double zero = 0.0L;
long double
-diff --git a/timezone/private.h b/timezone/private.h
-index 4e8f4ae..ed19e06 100644
--- a/timezone/private.h
+++ b/timezone/private.h
-@@ -326,16 +326,6 @@ const char * scheck(const char * string, const char * format);
+@@ -326,16 +326,6 @@
#define TYPE_SIGNED(type) (((type) -1) < 0)
#endif /* !defined TYPE_SIGNED */
diff --git a/packages/glibc/2.21/0004-misleading-indentation.patch b/packages/glibc/2.21/0004-misleading-indentation.patch
new file mode 100644
index 0000000..8e08259
--- /dev/null
+++ b/packages/glibc/2.21/0004-misleading-indentation.patch
@@ -0,0 +1,26 @@
+commit 976ef870542580cf5fed896c2c652b3e1a95f9da
+Author: Steve Ellcey <sellcey@mips.com>
+Date: Fri Dec 11 09:19:37 2015 -0800
+
+ Fix indentation.
+
+ * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
+ Fix indentation.
+
+---
+ sysdeps/ieee754/flt-32/k_rem_pio2f.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+--- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
++++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
+@@ -65,7 +65,9 @@
+
+ /* compute q[0],q[1],...q[jk] */
+ for (i=0;i<=jk;i++) {
+- for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw;
++ for(j=0,fw=0.0;j<=jx;j++)
++ fw += x[j]*f[jx+i-j];
++ q[i] = fw;
+ }
+
+ jz = jk;
diff --git a/packages/glibc/2.19/106-dl-open-array-bounds.patch b/packages/glibc/2.21/0005-dl-open-array-bounds.patch
index 08a9076..ae626f1 100644
--- a/packages/glibc/2.19/106-dl-open-array-bounds.patch
+++ b/packages/glibc/2.21/0005-dl-open-array-bounds.patch
@@ -4,11 +4,13 @@ Date: Fri Apr 17 12:11:58 2015 -0700
Fuller check for invalid NSID in _dl_open.
-diff --git a/elf/dl-open.c b/elf/dl-open.c
-index 0dbe07f..2d0e082 100644
+---
+ elf/dl-open.c | 12 +++++++++---
+ 1 file changed, 9 insertions(+), 3 deletions(-)
+
--- a/elf/dl-open.c
+++ b/elf/dl-open.c
-@@ -211,7 +211,7 @@ dl_open_worker (void *a)
+@@ -211,7 +211,7 @@
struct link_map *l = _dl_find_dso_for_object ((ElfW(Addr)) caller_dlopen);
if (l)
@@ -17,7 +19,7 @@ index 0dbe07f..2d0e082 100644
if (args->nsid == __LM_ID_CALLER)
args->nsid = call_map->l_ns;
-@@ -619,8 +619,14 @@ no more namespaces available for dlmopen()"));
+@@ -629,8 +629,14 @@
/* Never allow loading a DSO in a namespace which is empty. Such
direct placements is only causing problems. Also don't allow
loading into a namespace used for auditing. */
diff --git a/packages/glibc/2.21/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.21/0006-Fix-combreloc-test-BSD-grep.patch
index fdc3a60..f90947b 100644
--- a/packages/glibc/2.21/140-Fix-combreloc-test-BSD-grep.patch
+++ b/packages/glibc/2.21/0006-Fix-combreloc-test-BSD-grep.patch
@@ -13,16 +13,13 @@ by configure as "not found". As a result, support for "-z combreloc"
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
+ configure | 2 +-
+ configure.ac | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
-diff --git a/configure b/configure
-index eecd0ac..0118bd1 100755
--- a/configure
+++ b/configure
-@@ -5804,7 +5804,7 @@ if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
+@@ -6017,7 +6017,7 @@
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; }
then
@@ -31,11 +28,9 @@ index eecd0ac..0118bd1 100755
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
-diff --git a/configure.ac b/configure.ac
-index 4a77411..19f6d87 100644
--- a/configure.ac
+++ b/configure.ac
-@@ -1391,7 +1391,7 @@ dnl cross-platform since the gcc used can be a cross compiler. Without
+@@ -1391,7 +1391,7 @@
dnl introducing new options this is not easily doable. Instead use a tool
dnl which always is cross-platform: readelf. To detect whether -z combreloc
dnl look for a section named .rel.dyn.
@@ -44,6 +39,3 @@ index 4a77411..19f6d87 100644
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
---
-2.9.3
-
diff --git a/packages/glibc/2.21/910-typedef-caddr.patch b/packages/glibc/2.21/0007-typedef-caddr.patch
index fc7979b..980939b 100644
--- a/packages/glibc/2.21/910-typedef-caddr.patch
+++ b/packages/glibc/2.21/0007-typedef-caddr.patch
@@ -1,8 +1,11 @@
-diff -urN glibc-2.23-orig/posix/sys/types.h glibc-2.23/posix/sys/types.h
---- glibc-2.23-orig/posix/sys/types.h 2016-02-18 12:54:00.000000000 -0500
-+++ glibc-2.23/posix/sys/types.h 2017-01-06 11:40:05.842147165 -0500
+---
+ posix/sys/types.h | 3 +++
+ 1 file changed, 3 insertions(+)
+
+--- a/posix/sys/types.h
++++ b/posix/sys/types.h
@@ -113,7 +113,10 @@
- #ifdef __USE_MISC
+ #ifdef __USE_MISC
# ifndef __daddr_t_defined
typedef __daddr_t daddr_t;
+# if ! defined(caddr_t) && ! defined(__caddr_t_defined)
@@ -12,4 +15,3 @@ diff -urN glibc-2.23-orig/posix/sys/types.h glibc-2.23/posix/sys/types.h
# define __daddr_t_defined
# endif
#endif
-
diff --git a/packages/glibc/2.21/0008-fix-rpc_parse-format.patch b/packages/glibc/2.21/0008-fix-rpc_parse-format.patch
new file mode 100644
index 0000000..341d541
--- /dev/null
+++ b/packages/glibc/2.21/0008-fix-rpc_parse-format.patch
@@ -0,0 +1,62 @@
+commit 5874510faaf3cbd0bb112aaacab9f225002beed1
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Tue Nov 8 23:44:51 2016 +0000
+
+ Fix rpcgen buffer overrun (bug 20790).
+
+ Building with GCC 7 produces an error building rpcgen:
+
+ rpc_parse.c: In function 'get_prog_declaration':
+ rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ~~~~^
+ rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+ That buffer overrun is for the case where the .x file declares a
+ program with a million arguments. The strcpy two lines above can
+ generate a buffer overrun much more simply for a long argument name.
+
+ The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
+ provides a bound on the buffer size needed, so this patch just changes
+ the buffer size to MAXLINESIZE to avoid both possible buffer
+ overruns. A testcase is added that rpcgen does not crash with a
+ 500-character argument name, where it previously crashed.
+
+ It would not at all surprise me if there are many other ways of
+ crashing rpcgen with either valid or invalid input; fuzz testing would
+ likely find various such bugs, though I don't think they are that
+ important to fix (rpcgen is not that likely to be used with untrusted
+ .x files as input). (As well as fuzz-findable bugs there are probably
+ also issues when various int variables get overflowed on very large
+ input.) The test infrastructure for rpcgen-not-crashing tests would
+ need extending if tests are to be added for cases where rpcgen should
+ produce an error, as opposed to cases where it should succeed.
+
+ Tested for x86_64 and x86.
+
+ [BZ #20790]
+ * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
+ to MAXLINESIZE.
+ * sunrpc/bug20790.x: New file.
+ * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
+ variable.
+ [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
+ [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
+
+---
+ sunrpc/rpc_parse.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/sunrpc/rpc_parse.c
++++ b/sunrpc/rpc_parse.c
+@@ -521,7 +521,7 @@
+ get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
+ {
+ token tok;
+- char name[10]; /* argument name */
++ char name[MAXLINESIZE]; /* argument name */
+
+ if (dkind == DEF_PROGRAM)
+ {
diff --git a/packages/glibc/2.21/930-explicit-boolean.patch b/packages/glibc/2.21/0009-explicit-boolean.patch
index 780fae6..ff7cd87 100644
--- a/packages/glibc/2.21/930-explicit-boolean.patch
+++ b/packages/glibc/2.21/0009-explicit-boolean.patch
@@ -7,11 +7,13 @@ Date: Fri Oct 14 12:53:27 2016 -0700
* sysdeps/ieee754/dbl-64/e_pow.c (checkint) Make conditions explicitly
boolean.
-diff --git a/sysdeps/ieee754/dbl-64/e_pow.c b/sysdeps/ieee754/dbl-64/e_pow.c
-index 663fa392c2..bd758b5979 100644
+---
+ sysdeps/ieee754/dbl-64/e_pow.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
--- a/sysdeps/ieee754/dbl-64/e_pow.c
+++ b/sysdeps/ieee754/dbl-64/e_pow.c
-@@ -466,15 +466,15 @@ checkint (double x)
+@@ -462,15 +462,15 @@
return (n & 1) ? -1 : 1; /* odd or even */
if (k > 20)
{
diff --git a/packages/glibc/2.21/0010-nis-bogus-conditional.patch b/packages/glibc/2.21/0010-nis-bogus-conditional.patch
new file mode 100644
index 0000000..e728368
--- /dev/null
+++ b/packages/glibc/2.21/0010-nis-bogus-conditional.patch
@@ -0,0 +1,64 @@
+commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Wed Dec 21 23:44:01 2016 +0000
+
+ Fix nss_nisplus build with mainline GCC (bug 20978).
+
+ glibc build with current mainline GCC fails because
+ nis/nss_nisplus/nisplus-alias.c contains code
+
+ if (name != NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
+ }
+
+ char buf[strlen (name) + 9 + tablename_len];
+
+ producing an error about strlen being called on a pointer that is
+ always NULL (and a subsequent use of that pointer with a %s format in
+ snprintf).
+
+ As Andreas noted, the bogus conditional comes from a 1997 change:
+
+ - if (name == NULL || strlen(name) > 8)
+ - return NSS_STATUS_NOTFOUND;
+ - else
+ + if (name != NULL || strlen(name) <= 8)
+
+ So the intention is clearly to return an error for NULL name.
+
+ This patch duly inverts the sense of the conditional. It fixes the
+ build with GCC mainline, and passes usual glibc testsuite testing for
+ x86_64. However, I have not tried any actual substantive nisplus
+ testing, do not have an environment for such testing, and do not know
+ whether it is possible that strlen (name) or tablename_len might be
+ large so that the VLA for buf is actually a security issue. However,
+ if it is a security issue, there are plenty of other similar instances
+ in the nisplus code (that haven't been hidden by a bogus comparison
+ with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
+ string passed to nis_list, so a local fix in the caller wouldn't
+ suffice anyway (see bug 20987). (Calls to strdupa and other such
+ macros that use alloca must be considered equally questionable
+ regarding stack overflow issues as direct calls to alloca and VLA
+ declarations.)
+
+ [BZ #20978]
+ * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
+ Compare name == NULL, not name != NULL.
+
+---
+ nis/nss_nisplus/nisplus-alias.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/nis/nss_nisplus/nisplus-alias.c
++++ b/nis/nss_nisplus/nisplus-alias.c
+@@ -291,7 +291,7 @@
+ return status;
+ }
+
+- if (name != NULL)
++ if (name == NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.21/950-dlclose-assert.patch b/packages/glibc/2.21/0011-dlclose-assert.patch
index 6e2fcff..4a9de10 100644
--- a/packages/glibc/2.21/950-dlclose-assert.patch
+++ b/packages/glibc/2.21/0011-dlclose-assert.patch
@@ -4,11 +4,13 @@ Date: Fri Apr 17 14:29:40 2015 -0700
Avoid confusing compiler with dynamically impossible statically invalid dereference in _dl_close_worker.
-diff --git a/elf/dl-close.c b/elf/dl-close.c
-index cf8f9e0465..412f71d70b 100644
+---
+ elf/dl-close.c | 16 +++++++++++++---
+ 1 file changed, 13 insertions(+), 3 deletions(-)
+
--- a/elf/dl-close.c
+++ b/elf/dl-close.c
-@@ -641,9 +641,16 @@ _dl_close_worker (struct link_map *map)
+@@ -641,9 +641,16 @@
DL_UNMAP (imap);
/* Finally, unlink the data structure and free it. */
@@ -28,7 +30,7 @@ index cf8f9e0465..412f71d70b 100644
{
assert (nsid != LM_ID_BASE);
ns->_ns_loaded = imap->l_next;
-@@ -652,6 +659,9 @@ _dl_close_worker (struct link_map *map)
+@@ -652,6 +659,9 @@
we leave for debuggers to examine. */
r->r_map = (void *) ns->_ns_loaded;
}
diff --git a/packages/glibc/2.21/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.21/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
deleted file mode 100644
index 6fd663a..0000000
--- a/packages/glibc/2.21/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
-From: Yvan Roux <yvan.roux@linaro.org>
-Date: Fri, 15 Apr 2016 13:29:26 +0200
-Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
- -Wparentheses
-
----
- ChangeLog | 5 +++++
- nis/nis_call.c | 20 +++++++++++---------
- stdlib/setenv.c | 26 ++++++++++++++------------
- 3 files changed, 30 insertions(+), 21 deletions(-)
-
-diff --git a/nis/nis_call.c b/nis/nis_call.c
-index 3fa37e4..cb7839a 100644
---- a/nis/nis_call.c
-+++ b/nis/nis_call.c
-@@ -680,16 +680,18 @@ nis_server_cache_add (const_nis_name name, int search_parent,
- /* Choose which entry should be evicted from the cache. */
- loc = &nis_server_cache[0];
- if (*loc != NULL)
-- for (i = 1; i < 16; ++i)
-- if (nis_server_cache[i] == NULL)
-- {
-+ {
-+ for (i = 1; i < 16; ++i)
-+ if (nis_server_cache[i] == NULL)
-+ {
-+ loc = &nis_server_cache[i];
-+ break;
-+ }
-+ else if ((*loc)->uses > nis_server_cache[i]->uses
-+ || ((*loc)->uses == nis_server_cache[i]->uses
-+ && (*loc)->expires > nis_server_cache[i]->expires))
- loc = &nis_server_cache[i];
-- break;
-- }
-- else if ((*loc)->uses > nis_server_cache[i]->uses
-- || ((*loc)->uses == nis_server_cache[i]->uses
-- && (*loc)->expires > nis_server_cache[i]->expires))
-- loc = &nis_server_cache[i];
-+ }
- old = *loc;
- *loc = new;
-
-diff --git a/stdlib/setenv.c b/stdlib/setenv.c
-index da61ee0..e66045f 100644
---- a/stdlib/setenv.c
-+++ b/stdlib/setenv.c
-@@ -278,18 +278,20 @@ unsetenv (const char *name)
- ep = __environ;
- if (ep != NULL)
- while (*ep != NULL)
-- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-- {
-- /* Found it. Remove this pointer by moving later ones back. */
-- char **dp = ep;
--
-- do
-- dp[0] = dp[1];
-- while (*dp++);
-- /* Continue the loop in case NAME appears again. */
-- }
-- else
-- ++ep;
-+ {
-+ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-+ {
-+ /* Found it. Remove this pointer by moving later ones back. */
-+ char **dp = ep;
-+
-+ do
-+ dp[0] = dp[1];
-+ while (*dp++);
-+ /* Continue the loop in case NAME appears again. */
-+ }
-+ else
-+ ++ep;
-+ }
-
- UNLOCK;
-
---
-2.7.4
-
diff --git a/packages/glibc/2.21/102-fix-signed-shift-overlow.patch b/packages/glibc/2.21/102-fix-signed-shift-overlow.patch
deleted file mode 100644
index ef49f83..0000000
--- a/packages/glibc/2.21/102-fix-signed-shift-overlow.patch
+++ /dev/null
@@ -1,98 +0,0 @@
-commit 5542236837c5c41435f8282ec92799f480c36f18
-Author: Paul Eggert <eggert@cs.ucla.edu>
-Date: Tue Jul 21 22:50:29 2015 -0700
-
- Port the 0x7efe...feff pattern to GCC 6.
-
- See Steve Ellcey's bug report in:
- https://sourceware.org/ml/libc-alpha/2015-07/msg00673.html
- * string/memrchr.c (MEMRCHR):
- * string/rawmemchr.c (RAWMEMCHR):
- * string/strchr.c (strchr):
- * string/strchrnul.c (STRCHRNUL):
- Rewrite code to avoid issues with signed shift overflow.
-
-diff --git a/string/memrchr.c b/string/memrchr.c
-index 0c8fd84..86cd5b9 100644
---- a/string/memrchr.c
-+++ b/string/memrchr.c
-@@ -96,15 +96,8 @@ MEMRCHR
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
--
-- if (sizeof (longword) != 4 && sizeof (longword) != 8)
-- abort ();
--
--#if LONG_MAX <= LONG_MAX_32_BITS
-- magic_bits = 0x7efefeff;
--#else
-- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
--#endif
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/rawmemchr.c b/string/rawmemchr.c
-index 05b22be..228ca9d 100644
---- a/string/rawmemchr.c
-+++ b/string/rawmemchr.c
-@@ -86,15 +86,8 @@ RAWMEMCHR (s, c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
--
-- if (sizeof (longword) != 4 && sizeof (longword) != 8)
-- abort ();
--
--#if LONG_MAX <= LONG_MAX_32_BITS
-- magic_bits = 0x7efefeff;
--#else
-- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
--#endif
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/strchr.c b/string/strchr.c
-index 5f90075..f13b2b3 100644
---- a/string/strchr.c
-+++ b/string/strchr.c
-@@ -60,13 +60,8 @@ strchr (const char *s, int c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
-- switch (sizeof (longword))
-- {
-- case 4: magic_bits = 0x7efefeffL; break;
-- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
-- default:
-- abort ();
-- }
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/strchrnul.c b/string/strchrnul.c
-index 2678f1d..daf0b3f 100644
---- a/string/strchrnul.c
-+++ b/string/strchrnul.c
-@@ -66,13 +66,8 @@ STRCHRNUL (s, c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
-- switch (sizeof (longword))
-- {
-- case 4: magic_bits = 0x7efefeffL; break;
-- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
-- default:
-- abort ();
-- }
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
diff --git a/packages/glibc/2.21/103-dl-openat64-variadic.patch b/packages/glibc/2.21/103-dl-openat64-variadic.patch
deleted file mode 100644
index fe94b96..0000000
--- a/packages/glibc/2.21/103-dl-openat64-variadic.patch
+++ /dev/null
@@ -1,195 +0,0 @@
-commit 9dd346ff431fc761f1b748bd4da8bb59f7652094
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Tue Oct 20 11:54:09 2015 +0000
-
- Convert 113 more function definitions to prototype style (files with assertions).
-
- This mostly automatically-generated patch converts 113 function
- definitions in glibc from old-style K&R to prototype-style. Following
- my other recent such patches, this one deals with the case of function
- definitions in files that either contain assertions or where grep
- suggested they might contain assertions - and thus where it isn't
- possible to use a simple object code comparison as a sanity check on
- the correctness of the patch, because line numbers are changed.
-
- A few such automatically-generated changes needed to be supplemented
- by manual changes for the result to compile. openat64 had a prototype
- declaration with "..." but an old-style definition in
- sysdeps/unix/sysv/linux/dl-openat64.c, and "..." needed adding to the
- generated prototype in the definition (I've filed
- <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68024> for diagnosing
- such cases in GCC; the old state was undefined behavior not requiring
- a diagnostic, but one seems a good idea). In addition, as Florian has
- noted regparm attribute mismatches between declaration and definition
- are only diagnosed for prototype definitions, and five functions
- needed internal_function added to their definitions (in the case of
- __pthread_mutex_cond_lock, via the macro definition of
- __pthread_mutex_lock) to compile on i386.
-
- After this patch is in, remaining old-style definitions are probably
- most readily fixed manually before we can turn on
- -Wold-style-definition for all builds.
-
- Tested for x86_64 and x86 (testsuite).
-
- * crypt/md5-crypt.c (__md5_crypt_r): Convert to prototype-style
- function definition.
- * crypt/sha256-crypt.c (__sha256_crypt_r): Likewise.
- * crypt/sha512-crypt.c (__sha512_crypt_r): Likewise.
- * debug/backtracesyms.c (__backtrace_symbols): Likewise.
- * elf/dl-minimal.c (_itoa): Likewise.
- * hurd/hurdmalloc.c (malloc): Likewise.
- (free): Likewise.
- (realloc): Likewise.
- * inet/inet6_option.c (inet6_option_space): Likewise.
- (inet6_option_init): Likewise.
- (inet6_option_append): Likewise.
- (inet6_option_alloc): Likewise.
- (inet6_option_next): Likewise.
- (inet6_option_find): Likewise.
- * io/ftw.c (FTW_NAME): Likewise.
- (NFTW_NAME): Likewise.
- (NFTW_NEW_NAME): Likewise.
- (NFTW_OLD_NAME): Likewise.
- * libio/iofwide.c (_IO_fwide): Likewise.
- * libio/strops.c (_IO_str_init_static_internal): Likewise.
- (_IO_str_init_static): Likewise.
- (_IO_str_init_readonly): Likewise.
- (_IO_str_overflow): Likewise.
- (_IO_str_underflow): Likewise.
- (_IO_str_count): Likewise.
- (_IO_str_seekoff): Likewise.
- (_IO_str_pbackfail): Likewise.
- (_IO_str_finish): Likewise.
- * libio/wstrops.c (_IO_wstr_init_static): Likewise.
- (_IO_wstr_overflow): Likewise.
- (_IO_wstr_underflow): Likewise.
- (_IO_wstr_count): Likewise.
- (_IO_wstr_seekoff): Likewise.
- (_IO_wstr_pbackfail): Likewise.
- (_IO_wstr_finish): Likewise.
- * locale/programs/localedef.c (normalize_codeset): Likewise.
- * locale/programs/locarchive.c (add_locale_to_archive): Likewise.
- (add_locales_to_archive): Likewise.
- (delete_locales_from_archive): Likewise.
- * malloc/malloc.c (__libc_mallinfo): Likewise.
- * math/gen-auto-libm-tests.c (init_fp_formats): Likewise.
- * misc/tsearch.c (__tfind): Likewise.
- * nptl/pthread_attr_destroy.c (__pthread_attr_destroy): Likewise.
- * nptl/pthread_attr_getdetachstate.c
- (__pthread_attr_getdetachstate): Likewise.
- * nptl/pthread_attr_getguardsize.c (pthread_attr_getguardsize):
- Likewise.
- * nptl/pthread_attr_getinheritsched.c
- (__pthread_attr_getinheritsched): Likewise.
- * nptl/pthread_attr_getschedparam.c
- (__pthread_attr_getschedparam): Likewise.
- * nptl/pthread_attr_getschedpolicy.c
- (__pthread_attr_getschedpolicy): Likewise.
- * nptl/pthread_attr_getscope.c (__pthread_attr_getscope):
- Likewise.
- * nptl/pthread_attr_getstack.c (__pthread_attr_getstack):
- Likewise.
- * nptl/pthread_attr_getstackaddr.c (__pthread_attr_getstackaddr):
- Likewise.
- * nptl/pthread_attr_getstacksize.c (__pthread_attr_getstacksize):
- Likewise.
- * nptl/pthread_attr_init.c (__pthread_attr_init_2_1): Likewise.
- (__pthread_attr_init_2_0): Likewise.
- * nptl/pthread_attr_setdetachstate.c
- (__pthread_attr_setdetachstate): Likewise.
- * nptl/pthread_attr_setguardsize.c (pthread_attr_setguardsize):
- Likewise.
- * nptl/pthread_attr_setinheritsched.c
- (__pthread_attr_setinheritsched): Likewise.
- * nptl/pthread_attr_setschedparam.c
- (__pthread_attr_setschedparam): Likewise.
- * nptl/pthread_attr_setschedpolicy.c
- (__pthread_attr_setschedpolicy): Likewise.
- * nptl/pthread_attr_setscope.c (__pthread_attr_setscope):
- Likewise.
- * nptl/pthread_attr_setstack.c (__pthread_attr_setstack):
- Likewise.
- * nptl/pthread_attr_setstackaddr.c (__pthread_attr_setstackaddr):
- Likewise.
- * nptl/pthread_attr_setstacksize.c (__pthread_attr_setstacksize):
- Likewise.
- * nptl/pthread_condattr_setclock.c (pthread_condattr_setclock):
- Likewise.
- * nptl/pthread_create.c (__find_in_stack_list): Likewise.
- * nptl/pthread_getattr_np.c (pthread_getattr_np): Likewise.
- * nptl/pthread_mutex_cond_lock.c (__pthread_mutex_lock): Define to
- use internal_function.
- * nptl/pthread_mutex_init.c (__pthread_mutex_init): Convert to
- prototype-style function definition.
- * nptl/pthread_mutex_lock.c (__pthread_mutex_lock): Likewise.
- (__pthread_mutex_cond_lock_adjust): Likewise. Use
- internal_function.
- * nptl/pthread_mutex_timedlock.c (pthread_mutex_timedlock):
- Convert to prototype-style function definition.
- * nptl/pthread_mutex_trylock.c (__pthread_mutex_trylock):
- Likewise.
- * nptl/pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt):
- Likewise.
- (__pthread_mutex_unlock): Likewise.
- * nptl_db/td_ta_clear_event.c (td_ta_clear_event): Likewise.
- * nptl_db/td_ta_set_event.c (td_ta_set_event): Likewise.
- * nptl_db/td_thr_clear_event.c (td_thr_clear_event): Likewise.
- * nptl_db/td_thr_event_enable.c (td_thr_event_enable): Likewise.
- * nptl_db/td_thr_set_event.c (td_thr_set_event): Likewise.
- * nss/makedb.c (process_input): Likewise.
- * posix/fnmatch.c (__strchrnul): Likewise.
- (__wcschrnul): Likewise.
- (fnmatch): Likewise.
- * posix/fnmatch_loop.c (FCT): Likewise.
- * posix/glob.c (globfree): Likewise.
- (__glob_pattern_type): Likewise.
- (__glob_pattern_p): Likewise.
- * posix/regcomp.c (re_compile_pattern): Likewise.
- (re_set_syntax): Likewise.
- (re_compile_fastmap): Likewise.
- (regcomp): Likewise.
- (regerror): Likewise.
- (regfree): Likewise.
- * posix/regexec.c (regexec): Likewise.
- (re_match): Likewise.
- (re_search): Likewise.
- (re_match_2): Likewise.
- (re_search_2): Likewise.
- (re_search_stub): Likewise. Use internal_function
- (re_copy_regs): Likewise.
- (re_set_registers): Convert to prototype-style function
- definition.
- (prune_impossible_nodes): Likewise. Use internal_function.
- * resolv/inet_net_pton.c (inet_net_pton): Convert to
- prototype-style function definition.
- (inet_net_pton_ipv4): Likewise.
- * stdlib/strtod_l.c (____STRTOF_INTERNAL): Likewise.
- * sysdeps/pthread/aio_cancel.c (aio_cancel): Likewise.
- * sysdeps/pthread/aio_suspend.c (aio_suspend): Likewise.
- * sysdeps/pthread/timer_delete.c (timer_delete): Likewise.
- * sysdeps/unix/sysv/linux/dl-openat64.c (openat64): Likewise.
- Make variadic.
- * time/strptime_l.c (localtime_r): Convert to prototype-style
- function definition.
- * wcsmbs/mbsnrtowcs.c (__mbsnrtowcs): Likewise.
- * wcsmbs/mbsrtowcs_l.c (__mbsrtowcs_l): Likewise.
- * wcsmbs/wcsnrtombs.c (__wcsnrtombs): Likewise.
- * wcsmbs/wcsrtombs.c (__wcsrtombs): Likewise.
-
-diff --git a/sysdeps/unix/sysv/linux/dl-openat64.c b/sysdeps/unix/sysv/linux/dl-openat64.c
-index 7d100bb..7eea0ca 100644
---- a/sysdeps/unix/sysv/linux/dl-openat64.c
-+++ b/sysdeps/unix/sysv/linux/dl-openat64.c
-@@ -23,10 +23,7 @@
-
-
- int
--openat64 (dfd, file, oflag)
-- int dfd;
-- const char *file;
-- int oflag;
-+openat64 (int dfd, const char *file, int oflag, ...)
- {
- assert ((oflag & O_CREAT) == 0);
-
diff --git a/packages/glibc/2.21/105-misleading-indentation.patch b/packages/glibc/2.21/105-misleading-indentation.patch
deleted file mode 100644
index 1dd8d85..0000000
--- a/packages/glibc/2.21/105-misleading-indentation.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-commit 976ef870542580cf5fed896c2c652b3e1a95f9da
-Author: Steve Ellcey <sellcey@mips.com>
-Date: Fri Dec 11 09:19:37 2015 -0800
-
- Fix indentation.
-
- * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
- Fix indentation.
-
-diff --git a/sysdeps/ieee754/flt-32/k_rem_pio2f.c b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-index 0c7685c..392afdb 100644
---- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-+++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-@@ -65,7 +65,9 @@ int __kernel_rem_pio2f(float *x, float *y, int e0, int nx, int prec, const int32
-
- /* compute q[0],q[1],...q[jk] */
- for (i=0;i<=jk;i++) {
-- for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw;
-+ for(j=0,fw=0.0;j<=jx;j++)
-+ fw += x[j]*f[jx+i-j];
-+ q[i] = fw;
- }
-
- jz = jk;
diff --git a/packages/glibc/2.21/920-fix-rpc_parse-format.patch b/packages/glibc/2.21/920-fix-rpc_parse-format.patch
deleted file mode 100644
index 37e58da..0000000
--- a/packages/glibc/2.21/920-fix-rpc_parse-format.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-commit 5874510faaf3cbd0bb112aaacab9f225002beed1
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Tue Nov 8 23:44:51 2016 +0000
-
- Fix rpcgen buffer overrun (bug 20790).
-
- Building with GCC 7 produces an error building rpcgen:
-
- rpc_parse.c: In function 'get_prog_declaration':
- rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ~~~~^
- rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
- That buffer overrun is for the case where the .x file declares a
- program with a million arguments. The strcpy two lines above can
- generate a buffer overrun much more simply for a long argument name.
-
- The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
- provides a bound on the buffer size needed, so this patch just changes
- the buffer size to MAXLINESIZE to avoid both possible buffer
- overruns. A testcase is added that rpcgen does not crash with a
- 500-character argument name, where it previously crashed.
-
- It would not at all surprise me if there are many other ways of
- crashing rpcgen with either valid or invalid input; fuzz testing would
- likely find various such bugs, though I don't think they are that
- important to fix (rpcgen is not that likely to be used with untrusted
- .x files as input). (As well as fuzz-findable bugs there are probably
- also issues when various int variables get overflowed on very large
- input.) The test infrastructure for rpcgen-not-crashing tests would
- need extending if tests are to be added for cases where rpcgen should
- produce an error, as opposed to cases where it should succeed.
-
- Tested for x86_64 and x86.
-
- [BZ #20790]
- * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
- to MAXLINESIZE.
- * sunrpc/bug20790.x: New file.
- * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
- variable.
- [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
- [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
-
-diff --git a/sunrpc/rpc_parse.c b/sunrpc/rpc_parse.c
-index 1a1df6d8c2..505a6554cf 100644
---- a/sunrpc/rpc_parse.c
-+++ b/sunrpc/rpc_parse.c
-@@ -521,7 +521,7 @@ static void
- get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
- {
- token tok;
-- char name[10]; /* argument name */
-+ char name[MAXLINESIZE]; /* argument name */
-
- if (dkind == DEF_PROGRAM)
- {
diff --git a/packages/glibc/2.21/940-nis-bogus-conditional.patch b/packages/glibc/2.21/940-nis-bogus-conditional.patch
deleted file mode 100644
index 09b38cf..0000000
--- a/packages/glibc/2.21/940-nis-bogus-conditional.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Wed Dec 21 23:44:01 2016 +0000
-
- Fix nss_nisplus build with mainline GCC (bug 20978).
-
- glibc build with current mainline GCC fails because
- nis/nss_nisplus/nisplus-alias.c contains code
-
- if (name != NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
- }
-
- char buf[strlen (name) + 9 + tablename_len];
-
- producing an error about strlen being called on a pointer that is
- always NULL (and a subsequent use of that pointer with a %s format in
- snprintf).
-
- As Andreas noted, the bogus conditional comes from a 1997 change:
-
- - if (name == NULL || strlen(name) > 8)
- - return NSS_STATUS_NOTFOUND;
- - else
- + if (name != NULL || strlen(name) <= 8)
-
- So the intention is clearly to return an error for NULL name.
-
- This patch duly inverts the sense of the conditional. It fixes the
- build with GCC mainline, and passes usual glibc testsuite testing for
- x86_64. However, I have not tried any actual substantive nisplus
- testing, do not have an environment for such testing, and do not know
- whether it is possible that strlen (name) or tablename_len might be
- large so that the VLA for buf is actually a security issue. However,
- if it is a security issue, there are plenty of other similar instances
- in the nisplus code (that haven't been hidden by a bogus comparison
- with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
- string passed to nis_list, so a local fix in the caller wouldn't
- suffice anyway (see bug 20987). (Calls to strdupa and other such
- macros that use alloca must be considered equally questionable
- regarding stack overflow issues as direct calls to alloca and VLA
- declarations.)
-
- [BZ #20978]
- * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
- Compare name == NULL, not name != NULL.
-
-diff --git a/nis/nss_nisplus/nisplus-alias.c b/nis/nss_nisplus/nisplus-alias.c
-index 7f698b4e6d..cb5acce01d 100644
---- a/nis/nss_nisplus/nisplus-alias.c
-+++ b/nis/nss_nisplus/nisplus-alias.c
-@@ -291,7 +291,7 @@ _nss_nisplus_getaliasbyname_r (const char *name, struct aliasent *alias,
- return status;
- }
-
-- if (name != NULL)
-+ if (name == NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.22/100-sparc32-sem_open-missing-include.patch b/packages/glibc/2.22/0000-sparc32-sem_open-missing-include.patch
index b481046..1153d7b 100644
--- a/packages/glibc/2.22/100-sparc32-sem_open-missing-include.patch
+++ b/packages/glibc/2.22/0000-sparc32-sem_open-missing-include.patch
@@ -7,8 +7,10 @@ Date: Mon Aug 31 15:27:21 2015 -0700
[BZ #18870]
* sysdeps/sparc/sparc32/sem_open.c: Add missing #include
-diff --git a/sysdeps/sparc/sparc32/sem_open.c b/sysdeps/sparc/sparc32/sem_open.c
-index 16cb9ad..59df2d7 100644
+---
+ sysdeps/sparc/sparc32/sem_open.c | 1 +
+ 1 file changed, 1 insertion(+)
+
--- a/sysdeps/sparc/sparc32/sem_open.c
+++ b/sysdeps/sparc/sparc32/sem_open.c
@@ -29,6 +29,7 @@
diff --git a/packages/glibc/2.22/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.22/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
new file mode 100644
index 0000000..9232b1b
--- /dev/null
+++ b/packages/glibc/2.22/0001-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
@@ -0,0 +1,75 @@
+From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
+From: Yvan Roux <yvan.roux@linaro.org>
+Date: Fri, 15 Apr 2016 13:29:26 +0200
+Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
+ -Wparentheses
+
+---
+ nis/nis_call.c | 20 +++++++++++---------
+ stdlib/setenv.c | 24 +++++++++++++-----------
+ 2 files changed, 24 insertions(+), 20 deletions(-)
+
+--- a/nis/nis_call.c
++++ b/nis/nis_call.c
+@@ -680,16 +680,18 @@
+ /* Choose which entry should be evicted from the cache. */
+ loc = &nis_server_cache[0];
+ if (*loc != NULL)
+- for (i = 1; i < 16; ++i)
+- if (nis_server_cache[i] == NULL)
+- {
++ {
++ for (i = 1; i < 16; ++i)
++ if (nis_server_cache[i] == NULL)
++ {
++ loc = &nis_server_cache[i];
++ break;
++ }
++ else if ((*loc)->uses > nis_server_cache[i]->uses
++ || ((*loc)->uses == nis_server_cache[i]->uses
++ && (*loc)->expires > nis_server_cache[i]->expires))
+ loc = &nis_server_cache[i];
+- break;
+- }
+- else if ((*loc)->uses > nis_server_cache[i]->uses
+- || ((*loc)->uses == nis_server_cache[i]->uses
+- && (*loc)->expires > nis_server_cache[i]->expires))
+- loc = &nis_server_cache[i];
++ }
+ old = *loc;
+ *loc = new;
+
+--- a/stdlib/setenv.c
++++ b/stdlib/setenv.c
+@@ -289,18 +289,20 @@
+ ep = __environ;
+ if (ep != NULL)
+ while (*ep != NULL)
+- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
+- {
+- /* Found it. Remove this pointer by moving later ones back. */
+- char **dp = ep;
++ {
++ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
++ {
++ /* Found it. Remove this pointer by moving later ones back. */
++ char **dp = ep;
+
+- do
+- dp[0] = dp[1];
+- while (*dp++);
+- /* Continue the loop in case NAME appears again. */
+- }
+- else
+- ++ep;
++ do
++ dp[0] = dp[1];
++ while (*dp++);
++ /* Continue the loop in case NAME appears again. */
++ }
++ else
++ ++ep;
++ }
+
+ UNLOCK;
+
diff --git a/packages/glibc/2.22/0002-fix-signed-shift-overlow.patch b/packages/glibc/2.22/0002-fix-signed-shift-overlow.patch
new file mode 100644
index 0000000..c7cc330
--- /dev/null
+++ b/packages/glibc/2.22/0002-fix-signed-shift-overlow.patch
@@ -0,0 +1,97 @@
+commit 5542236837c5c41435f8282ec92799f480c36f18
+Author: Paul Eggert <eggert@cs.ucla.edu>
+Date: Tue Jul 21 22:50:29 2015 -0700
+
+ Port the 0x7efe...feff pattern to GCC 6.
+
+ See Steve Ellcey's bug report in:
+ https://sourceware.org/ml/libc-alpha/2015-07/msg00673.html
+ * string/memrchr.c (MEMRCHR):
+ * string/rawmemchr.c (RAWMEMCHR):
+ * string/strchr.c (strchr):
+ * string/strchrnul.c (STRCHRNUL):
+ Rewrite code to avoid issues with signed shift overflow.
+
+---
+ string/memrchr.c | 11 ++---------
+ string/rawmemchr.c | 11 ++---------
+ string/strchr.c | 9 ++-------
+ string/strchrnul.c | 9 ++-------
+ 4 files changed, 8 insertions(+), 32 deletions(-)
+
+--- a/string/memrchr.c
++++ b/string/memrchr.c
+@@ -96,15 +96,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+-
+- if (sizeof (longword) != 4 && sizeof (longword) != 8)
+- abort ();
+-
+-#if LONG_MAX <= LONG_MAX_32_BITS
+- magic_bits = 0x7efefeff;
+-#else
+- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
+-#endif
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/rawmemchr.c
++++ b/string/rawmemchr.c
+@@ -86,15 +86,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+-
+- if (sizeof (longword) != 4 && sizeof (longword) != 8)
+- abort ();
+-
+-#if LONG_MAX <= LONG_MAX_32_BITS
+- magic_bits = 0x7efefeff;
+-#else
+- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
+-#endif
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/strchr.c
++++ b/string/strchr.c
+@@ -60,13 +60,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+- switch (sizeof (longword))
+- {
+- case 4: magic_bits = 0x7efefeffL; break;
+- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
+- default:
+- abort ();
+- }
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
+--- a/string/strchrnul.c
++++ b/string/strchrnul.c
+@@ -66,13 +66,8 @@
+
+ The 1-bits make sure that carries propagate to the next 0-bit.
+ The 0-bits provide holes for carries to fall into. */
+- switch (sizeof (longword))
+- {
+- case 4: magic_bits = 0x7efefeffL; break;
+- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
+- default:
+- abort ();
+- }
++ magic_bits = -1;
++ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
+
+ /* Set up a longword, each of whose bytes is C. */
+ charmask = c | (c << 8);
diff --git a/packages/glibc/2.22/103-dl-openat64-variadic.patch b/packages/glibc/2.22/0003-dl-openat64-variadic.patch
index 302088e..f57764f 100644
--- a/packages/glibc/2.22/103-dl-openat64-variadic.patch
+++ b/packages/glibc/2.22/0003-dl-openat64-variadic.patch
@@ -177,8 +177,10 @@ Date: Tue Oct 20 11:54:09 2015 +0000
* wcsmbs/wcsnrtombs.c (__wcsnrtombs): Likewise.
* wcsmbs/wcsrtombs.c (__wcsrtombs): Likewise.
-diff --git a/sysdeps/unix/sysv/linux/dl-openat64.c b/sysdeps/unix/sysv/linux/dl-openat64.c
-index 7d100bb..7eea0ca 100644
+---
+ sysdeps/unix/sysv/linux/dl-openat64.c | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
--- a/sysdeps/unix/sysv/linux/dl-openat64.c
+++ b/sysdeps/unix/sysv/linux/dl-openat64.c
@@ -23,10 +23,7 @@
diff --git a/packages/glibc/2.21/104-unused-variables.patch b/packages/glibc/2.22/0004-unused-variables.patch
index fd4def0..c9211d6 100644
--- a/packages/glibc/2.21/104-unused-variables.patch
+++ b/packages/glibc/2.22/0004-unused-variables.patch
@@ -19,8 +19,19 @@ Date: Fri Sep 18 20:27:20 2015 +0100
* timezone/private.h (time_t_min): Likewise. (time_t_max):
Likewise.
-diff --git a/resolv/base64.c b/resolv/base64.c
-index ea584ed..519e5d2 100644
+---
+ resolv/base64.c | 4 ----
+ sysdeps/ieee754/dbl-64/atnat2.h | 4 ----
+ sysdeps/ieee754/dbl-64/uexp.h | 2 +-
+ sysdeps/ieee754/dbl-64/upow.h | 2 --
+ sysdeps/ieee754/flt-32/e_log10f.c | 2 --
+ sysdeps/ieee754/flt-32/s_cosf.c | 2 --
+ sysdeps/ieee754/ldbl-128/e_lgammal_r.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_erfl.c | 1 -
+ sysdeps/ieee754/ldbl-128/s_log1pl.c | 1 -
+ timezone/private.h | 10 ----------
+ 10 files changed, 1 insertion(+), 28 deletions(-)
+
--- a/resolv/base64.c
+++ b/resolv/base64.c
@@ -40,10 +40,6 @@
@@ -34,8 +45,6 @@ index ea584ed..519e5d2 100644
#include <sys/types.h>
#include <sys/param.h>
#include <sys/socket.h>
-diff --git a/sysdeps/ieee754/dbl-64/atnat2.h b/sysdeps/ieee754/dbl-64/atnat2.h
-index e0d65af..82943f9 100644
--- a/sysdeps/ieee754/dbl-64/atnat2.h
+++ b/sysdeps/ieee754/dbl-64/atnat2.h
@@ -65,10 +65,8 @@
@@ -60,8 +69,6 @@ index e0d65af..82943f9 100644
/**/ mtqpi = {{0x7f3321d2, 0xc002d97c} }, /* -3pi/4 */
/**/ u1 = {{0x00000000, 0x3c314c2a} }, /* 9.377e-19 */
/**/ u2 = {{0x00000000, 0x3bf955e4} }, /* 8.584e-20 */
-diff --git a/sysdeps/ieee754/dbl-64/uexp.h b/sysdeps/ieee754/dbl-64/uexp.h
-index 6817eaf..42b21f2 100644
--- a/sysdeps/ieee754/dbl-64/uexp.h
+++ b/sysdeps/ieee754/dbl-64/uexp.h
@@ -29,7 +29,7 @@
@@ -73,8 +80,6 @@ index 6817eaf..42b21f2 100644
err_0 = 1.000014, err_1 = 0.000016;
const static int4 bigint = 0x40862002,
badint = 0x40876000,smallint = 0x3C8fffff;
-diff --git a/sysdeps/ieee754/dbl-64/upow.h b/sysdeps/ieee754/dbl-64/upow.h
-index c8569a9..b4911e5 100644
--- a/sysdeps/ieee754/dbl-64/upow.h
+++ b/sysdeps/ieee754/dbl-64/upow.h
@@ -34,7 +34,6 @@
@@ -93,11 +98,9 @@ index c8569a9..b4911e5 100644
/**/ ln2a = {{0xfefa3800, 0x3fe62e42}}, /* ln(2) 43 bits */
/**/ ln2b = {{0x93c76730, 0x3d2ef357}}, /* ln(2)-ln2a */
/**/ bigu = {{0xfffffd2c, 0x4297ffff}}, /* 1.5*2**42 -724*2**-10 */
-diff --git a/sysdeps/ieee754/flt-32/e_log10f.c b/sysdeps/ieee754/flt-32/e_log10f.c
-index 96f0e81..1daeef7 100644
--- a/sysdeps/ieee754/flt-32/e_log10f.c
+++ b/sysdeps/ieee754/flt-32/e_log10f.c
-@@ -22,8 +22,6 @@ ivln10 = 4.3429449201e-01, /* 0x3ede5bd9 */
+@@ -22,8 +22,6 @@
log10_2hi = 3.0102920532e-01, /* 0x3e9a2080 */
log10_2lo = 7.9034151668e-07; /* 0x355427db */
@@ -106,11 +109,9 @@ index 96f0e81..1daeef7 100644
float
__ieee754_log10f(float x)
{
-diff --git a/sysdeps/ieee754/flt-32/s_cosf.c b/sysdeps/ieee754/flt-32/s_cosf.c
-index 864ab27..0affd40 100644
--- a/sysdeps/ieee754/flt-32/s_cosf.c
+++ b/sysdeps/ieee754/flt-32/s_cosf.c
-@@ -21,8 +21,6 @@ static char rcsid[] = "$NetBSD: s_cosf.c,v 1.4 1995/05/10 20:47:03 jtc Exp $";
+@@ -21,8 +21,6 @@
#include <math.h>
#include <math_private.h>
@@ -119,11 +120,9 @@ index 864ab27..0affd40 100644
#ifndef COSF
# define COSF_FUNC __cosf
#else
-diff --git a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-index 500aacc..ab5a96e 100644
--- a/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
+++ b/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
-@@ -82,7 +82,6 @@ DIAG_IGNORE_NEEDS_COMMENT (4.6, "-Woverflow");
+@@ -82,7 +82,6 @@
static const long double MAXLGM = 1.0485738685148938358098967157129705071571E4928L;
DIAG_POP_NEEDS_COMMENT;
static const long double one = 1.0L;
@@ -131,11 +130,9 @@ index 500aacc..ab5a96e 100644
static const long double huge = LDBL_MAX;
/* log gamma(x) = ( x - 0.5 ) * log(x) - x + LS2PI + 1/x P(1/x^2)
-diff --git a/sysdeps/ieee754/ldbl-128/s_erfl.c b/sysdeps/ieee754/ldbl-128/s_erfl.c
-index fa4609f..08c80a3 100644
--- a/sysdeps/ieee754/ldbl-128/s_erfl.c
+++ b/sysdeps/ieee754/ldbl-128/s_erfl.c
-@@ -140,7 +140,6 @@ deval (long double x, const long double *p, int n)
+@@ -140,7 +140,6 @@
static const long double
tiny = 1e-4931L,
@@ -143,11 +140,9 @@ index fa4609f..08c80a3 100644
one = 1.0L,
two = 2.0L,
/* 2/sqrt(pi) - 1 */
-diff --git a/sysdeps/ieee754/ldbl-128/s_log1pl.c b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-index ff759bc..9609550 100644
--- a/sysdeps/ieee754/ldbl-128/s_log1pl.c
+++ b/sysdeps/ieee754/ldbl-128/s_log1pl.c
-@@ -117,7 +117,6 @@ static const long double C2 = 1.428606820309417232121458176568075500134E-6L;
+@@ -117,7 +117,6 @@
static const long double sqrth = 0.7071067811865475244008443621048490392848L;
/* ln (2^16384 * (1 - 2^-113)) */
@@ -155,11 +150,9 @@ index ff759bc..9609550 100644
static const long double zero = 0.0L;
long double
-diff --git a/timezone/private.h b/timezone/private.h
-index 4e8f4ae..ed19e06 100644
--- a/timezone/private.h
+++ b/timezone/private.h
-@@ -326,16 +326,6 @@ const char * scheck(const char * string, const char * format);
+@@ -326,16 +326,6 @@
#define TYPE_SIGNED(type) (((type) -1) < 0)
#endif /* !defined TYPE_SIGNED */
diff --git a/packages/glibc/2.22/0005-misleading-indentation.patch b/packages/glibc/2.22/0005-misleading-indentation.patch
new file mode 100644
index 0000000..8e08259
--- /dev/null
+++ b/packages/glibc/2.22/0005-misleading-indentation.patch
@@ -0,0 +1,26 @@
+commit 976ef870542580cf5fed896c2c652b3e1a95f9da
+Author: Steve Ellcey <sellcey@mips.com>
+Date: Fri Dec 11 09:19:37 2015 -0800
+
+ Fix indentation.
+
+ * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
+ Fix indentation.
+
+---
+ sysdeps/ieee754/flt-32/k_rem_pio2f.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+--- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
++++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
+@@ -65,7 +65,9 @@
+
+ /* compute q[0],q[1],...q[jk] */
+ for (i=0;i<=jk;i++) {
+- for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw;
++ for(j=0,fw=0.0;j<=jx;j++)
++ fw += x[j]*f[jx+i-j];
++ q[i] = fw;
+ }
+
+ jz = jk;
diff --git a/packages/glibc/2.22/120-cve-2105-7547-getaddrinfo-stack.patch b/packages/glibc/2.22/0006-cve-2105-7547-getaddrinfo-stack.patch
index 257c5f2..504edad 100644
--- a/packages/glibc/2.22/120-cve-2105-7547-getaddrinfo-stack.patch
+++ b/packages/glibc/2.22/0006-cve-2105-7547-getaddrinfo-stack.patch
@@ -1,6 +1,11 @@
-diff -ruN glibc-2.22.orig/resolv/nss_dns/dns-host.c glibc-2.22/resolv/nss_dns/dns-host.c
---- glibc-2.22.orig/resolv/nss_dns/dns-host.c 2015-08-04 23:42:21.000000000 -0700
-+++ glibc-2.22/resolv/nss_dns/dns-host.c 2016-02-16 13:38:38.000000000 -0800
+---
+ resolv/nss_dns/dns-host.c | 111 ++++++++++++++++++-
+ resolv/res_query.c | 3
+ resolv/res_send.c | 264 ++++++++++++++++++++++++++++++++++------------
+ 3 files changed, 309 insertions(+), 69 deletions(-)
+
+--- a/resolv/nss_dns/dns-host.c
++++ b/resolv/nss_dns/dns-host.c
@@ -1031,7 +1031,10 @@
int h_namelen = 0;
@@ -147,9 +152,8 @@ diff -ruN glibc-2.22.orig/resolv/nss_dns/dns-host.c glibc-2.22/resolv/nss_dns/dn
}
return status;
-diff -ruN glibc-2.22.orig/resolv/res_query.c glibc-2.22/resolv/res_query.c
---- glibc-2.22.orig/resolv/res_query.c 2015-08-04 23:42:21.000000000 -0700
-+++ glibc-2.22/resolv/res_query.c 2016-02-16 13:38:38.000000000 -0800
+--- a/resolv/res_query.c
++++ b/resolv/res_query.c
@@ -396,6 +396,7 @@
{
free (*answerp2);
@@ -174,9 +178,8 @@ diff -ruN glibc-2.22.orig/resolv/res_query.c glibc-2.22/resolv/res_query.c
*answerp2_malloced = 0;
}
if (saved_herrno != -1)
-diff -ruN glibc-2.22.orig/resolv/res_send.c glibc-2.22/resolv/res_send.c
---- glibc-2.22.orig/resolv/res_send.c 2015-08-04 23:42:21.000000000 -0700
-+++ glibc-2.22/resolv/res_send.c 2016-02-16 13:43:59.000000000 -0800
+--- a/resolv/res_send.c
++++ b/resolv/res_send.c
@@ -1,3 +1,20 @@
+/* Copyright (C) 2016 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
diff --git a/packages/glibc/2.22/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.22/0007-Fix-combreloc-test-BSD-grep.patch
index fdc3a60..c0be460 100644
--- a/packages/glibc/2.22/140-Fix-combreloc-test-BSD-grep.patch
+++ b/packages/glibc/2.22/0007-Fix-combreloc-test-BSD-grep.patch
@@ -13,16 +13,13 @@ by configure as "not found". As a result, support for "-z combreloc"
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
+ configure | 2 +-
+ configure.ac | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
-diff --git a/configure b/configure
-index eecd0ac..0118bd1 100755
--- a/configure
+++ b/configure
-@@ -5804,7 +5804,7 @@ if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
+@@ -6172,7 +6172,7 @@
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; }
then
@@ -31,11 +28,9 @@ index eecd0ac..0118bd1 100755
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
-diff --git a/configure.ac b/configure.ac
-index 4a77411..19f6d87 100644
--- a/configure.ac
+++ b/configure.ac
-@@ -1391,7 +1391,7 @@ dnl cross-platform since the gcc used can be a cross compiler. Without
+@@ -1442,7 +1442,7 @@
dnl introducing new options this is not easily doable. Instead use a tool
dnl which always is cross-platform: readelf. To detect whether -z combreloc
dnl look for a section named .rel.dyn.
@@ -44,6 +39,3 @@ index 4a77411..19f6d87 100644
libc_cv_z_combreloc=yes
else
libc_cv_z_combreloc=no
---
-2.9.3
-
diff --git a/packages/glibc/2.22/910-typedef-caddr.patch b/packages/glibc/2.22/0008-typedef-caddr.patch
index fc7979b..980939b 100644
--- a/packages/glibc/2.22/910-typedef-caddr.patch
+++ b/packages/glibc/2.22/0008-typedef-caddr.patch
@@ -1,8 +1,11 @@
-diff -urN glibc-2.23-orig/posix/sys/types.h glibc-2.23/posix/sys/types.h
---- glibc-2.23-orig/posix/sys/types.h 2016-02-18 12:54:00.000000000 -0500
-+++ glibc-2.23/posix/sys/types.h 2017-01-06 11:40:05.842147165 -0500
+---
+ posix/sys/types.h | 3 +++
+ 1 file changed, 3 insertions(+)
+
+--- a/posix/sys/types.h
++++ b/posix/sys/types.h
@@ -113,7 +113,10 @@
- #ifdef __USE_MISC
+ #ifdef __USE_MISC
# ifndef __daddr_t_defined
typedef __daddr_t daddr_t;
+# if ! defined(caddr_t) && ! defined(__caddr_t_defined)
@@ -12,4 +15,3 @@ diff -urN glibc-2.23-orig/posix/sys/types.h glibc-2.23/posix/sys/types.h
# define __daddr_t_defined
# endif
#endif
-
diff --git a/packages/glibc/2.22/0009-fix-rpc_parse-format.patch b/packages/glibc/2.22/0009-fix-rpc_parse-format.patch
new file mode 100644
index 0000000..341d541
--- /dev/null
+++ b/packages/glibc/2.22/0009-fix-rpc_parse-format.patch
@@ -0,0 +1,62 @@
+commit 5874510faaf3cbd0bb112aaacab9f225002beed1
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Tue Nov 8 23:44:51 2016 +0000
+
+ Fix rpcgen buffer overrun (bug 20790).
+
+ Building with GCC 7 produces an error building rpcgen:
+
+ rpc_parse.c: In function 'get_prog_declaration':
+ rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ~~~~^
+ rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+ That buffer overrun is for the case where the .x file declares a
+ program with a million arguments. The strcpy two lines above can
+ generate a buffer overrun much more simply for a long argument name.
+
+ The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
+ provides a bound on the buffer size needed, so this patch just changes
+ the buffer size to MAXLINESIZE to avoid both possible buffer
+ overruns. A testcase is added that rpcgen does not crash with a
+ 500-character argument name, where it previously crashed.
+
+ It would not at all surprise me if there are many other ways of
+ crashing rpcgen with either valid or invalid input; fuzz testing would
+ likely find various such bugs, though I don't think they are that
+ important to fix (rpcgen is not that likely to be used with untrusted
+ .x files as input). (As well as fuzz-findable bugs there are probably
+ also issues when various int variables get overflowed on very large
+ input.) The test infrastructure for rpcgen-not-crashing tests would
+ need extending if tests are to be added for cases where rpcgen should
+ produce an error, as opposed to cases where it should succeed.
+
+ Tested for x86_64 and x86.
+
+ [BZ #20790]
+ * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
+ to MAXLINESIZE.
+ * sunrpc/bug20790.x: New file.
+ * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
+ variable.
+ [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
+ [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
+
+---
+ sunrpc/rpc_parse.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/sunrpc/rpc_parse.c
++++ b/sunrpc/rpc_parse.c
+@@ -521,7 +521,7 @@
+ get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
+ {
+ token tok;
+- char name[10]; /* argument name */
++ char name[MAXLINESIZE]; /* argument name */
+
+ if (dkind == DEF_PROGRAM)
+ {
diff --git a/packages/glibc/2.22/930-explicit-boolean.patch b/packages/glibc/2.22/0010-explicit-boolean.patch
index 780fae6..ff7cd87 100644
--- a/packages/glibc/2.22/930-explicit-boolean.patch
+++ b/packages/glibc/2.22/0010-explicit-boolean.patch
@@ -7,11 +7,13 @@ Date: Fri Oct 14 12:53:27 2016 -0700
* sysdeps/ieee754/dbl-64/e_pow.c (checkint) Make conditions explicitly
boolean.
-diff --git a/sysdeps/ieee754/dbl-64/e_pow.c b/sysdeps/ieee754/dbl-64/e_pow.c
-index 663fa392c2..bd758b5979 100644
+---
+ sysdeps/ieee754/dbl-64/e_pow.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
--- a/sysdeps/ieee754/dbl-64/e_pow.c
+++ b/sysdeps/ieee754/dbl-64/e_pow.c
-@@ -466,15 +466,15 @@ checkint (double x)
+@@ -462,15 +462,15 @@
return (n & 1) ? -1 : 1; /* odd or even */
if (k > 20)
{
diff --git a/packages/glibc/2.22/0011-nis-bogus-conditional.patch b/packages/glibc/2.22/0011-nis-bogus-conditional.patch
new file mode 100644
index 0000000..e728368
--- /dev/null
+++ b/packages/glibc/2.22/0011-nis-bogus-conditional.patch
@@ -0,0 +1,64 @@
+commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Wed Dec 21 23:44:01 2016 +0000
+
+ Fix nss_nisplus build with mainline GCC (bug 20978).
+
+ glibc build with current mainline GCC fails because
+ nis/nss_nisplus/nisplus-alias.c contains code
+
+ if (name != NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
+ }
+
+ char buf[strlen (name) + 9 + tablename_len];
+
+ producing an error about strlen being called on a pointer that is
+ always NULL (and a subsequent use of that pointer with a %s format in
+ snprintf).
+
+ As Andreas noted, the bogus conditional comes from a 1997 change:
+
+ - if (name == NULL || strlen(name) > 8)
+ - return NSS_STATUS_NOTFOUND;
+ - else
+ + if (name != NULL || strlen(name) <= 8)
+
+ So the intention is clearly to return an error for NULL name.
+
+ This patch duly inverts the sense of the conditional. It fixes the
+ build with GCC mainline, and passes usual glibc testsuite testing for
+ x86_64. However, I have not tried any actual substantive nisplus
+ testing, do not have an environment for such testing, and do not know
+ whether it is possible that strlen (name) or tablename_len might be
+ large so that the VLA for buf is actually a security issue. However,
+ if it is a security issue, there are plenty of other similar instances
+ in the nisplus code (that haven't been hidden by a bogus comparison
+ with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
+ string passed to nis_list, so a local fix in the caller wouldn't
+ suffice anyway (see bug 20987). (Calls to strdupa and other such
+ macros that use alloca must be considered equally questionable
+ regarding stack overflow issues as direct calls to alloca and VLA
+ declarations.)
+
+ [BZ #20978]
+ * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
+ Compare name == NULL, not name != NULL.
+
+---
+ nis/nss_nisplus/nisplus-alias.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/nis/nss_nisplus/nisplus-alias.c
++++ b/nis/nss_nisplus/nisplus-alias.c
+@@ -291,7 +291,7 @@
+ return status;
+ }
+
+- if (name != NULL)
++ if (name == NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.22/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.22/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
deleted file mode 100644
index 6fd663a..0000000
--- a/packages/glibc/2.22/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
-From: Yvan Roux <yvan.roux@linaro.org>
-Date: Fri, 15 Apr 2016 13:29:26 +0200
-Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
- -Wparentheses
-
----
- ChangeLog | 5 +++++
- nis/nis_call.c | 20 +++++++++++---------
- stdlib/setenv.c | 26 ++++++++++++++------------
- 3 files changed, 30 insertions(+), 21 deletions(-)
-
-diff --git a/nis/nis_call.c b/nis/nis_call.c
-index 3fa37e4..cb7839a 100644
---- a/nis/nis_call.c
-+++ b/nis/nis_call.c
-@@ -680,16 +680,18 @@ nis_server_cache_add (const_nis_name name, int search_parent,
- /* Choose which entry should be evicted from the cache. */
- loc = &nis_server_cache[0];
- if (*loc != NULL)
-- for (i = 1; i < 16; ++i)
-- if (nis_server_cache[i] == NULL)
-- {
-+ {
-+ for (i = 1; i < 16; ++i)
-+ if (nis_server_cache[i] == NULL)
-+ {
-+ loc = &nis_server_cache[i];
-+ break;
-+ }
-+ else if ((*loc)->uses > nis_server_cache[i]->uses
-+ || ((*loc)->uses == nis_server_cache[i]->uses
-+ && (*loc)->expires > nis_server_cache[i]->expires))
- loc = &nis_server_cache[i];
-- break;
-- }
-- else if ((*loc)->uses > nis_server_cache[i]->uses
-- || ((*loc)->uses == nis_server_cache[i]->uses
-- && (*loc)->expires > nis_server_cache[i]->expires))
-- loc = &nis_server_cache[i];
-+ }
- old = *loc;
- *loc = new;
-
-diff --git a/stdlib/setenv.c b/stdlib/setenv.c
-index da61ee0..e66045f 100644
---- a/stdlib/setenv.c
-+++ b/stdlib/setenv.c
-@@ -278,18 +278,20 @@ unsetenv (const char *name)
- ep = __environ;
- if (ep != NULL)
- while (*ep != NULL)
-- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-- {
-- /* Found it. Remove this pointer by moving later ones back. */
-- char **dp = ep;
--
-- do
-- dp[0] = dp[1];
-- while (*dp++);
-- /* Continue the loop in case NAME appears again. */
-- }
-- else
-- ++ep;
-+ {
-+ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-+ {
-+ /* Found it. Remove this pointer by moving later ones back. */
-+ char **dp = ep;
-+
-+ do
-+ dp[0] = dp[1];
-+ while (*dp++);
-+ /* Continue the loop in case NAME appears again. */
-+ }
-+ else
-+ ++ep;
-+ }
-
- UNLOCK;
-
---
-2.7.4
-
diff --git a/packages/glibc/2.22/102-fix-signed-shift-overlow.patch b/packages/glibc/2.22/102-fix-signed-shift-overlow.patch
deleted file mode 100644
index ef49f83..0000000
--- a/packages/glibc/2.22/102-fix-signed-shift-overlow.patch
+++ /dev/null
@@ -1,98 +0,0 @@
-commit 5542236837c5c41435f8282ec92799f480c36f18
-Author: Paul Eggert <eggert@cs.ucla.edu>
-Date: Tue Jul 21 22:50:29 2015 -0700
-
- Port the 0x7efe...feff pattern to GCC 6.
-
- See Steve Ellcey's bug report in:
- https://sourceware.org/ml/libc-alpha/2015-07/msg00673.html
- * string/memrchr.c (MEMRCHR):
- * string/rawmemchr.c (RAWMEMCHR):
- * string/strchr.c (strchr):
- * string/strchrnul.c (STRCHRNUL):
- Rewrite code to avoid issues with signed shift overflow.
-
-diff --git a/string/memrchr.c b/string/memrchr.c
-index 0c8fd84..86cd5b9 100644
---- a/string/memrchr.c
-+++ b/string/memrchr.c
-@@ -96,15 +96,8 @@ MEMRCHR
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
--
-- if (sizeof (longword) != 4 && sizeof (longword) != 8)
-- abort ();
--
--#if LONG_MAX <= LONG_MAX_32_BITS
-- magic_bits = 0x7efefeff;
--#else
-- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
--#endif
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/rawmemchr.c b/string/rawmemchr.c
-index 05b22be..228ca9d 100644
---- a/string/rawmemchr.c
-+++ b/string/rawmemchr.c
-@@ -86,15 +86,8 @@ RAWMEMCHR (s, c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
--
-- if (sizeof (longword) != 4 && sizeof (longword) != 8)
-- abort ();
--
--#if LONG_MAX <= LONG_MAX_32_BITS
-- magic_bits = 0x7efefeff;
--#else
-- magic_bits = ((unsigned long int) 0x7efefefe << 32) | 0xfefefeff;
--#endif
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/strchr.c b/string/strchr.c
-index 5f90075..f13b2b3 100644
---- a/string/strchr.c
-+++ b/string/strchr.c
-@@ -60,13 +60,8 @@ strchr (const char *s, int c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
-- switch (sizeof (longword))
-- {
-- case 4: magic_bits = 0x7efefeffL; break;
-- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
-- default:
-- abort ();
-- }
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
-diff --git a/string/strchrnul.c b/string/strchrnul.c
-index 2678f1d..daf0b3f 100644
---- a/string/strchrnul.c
-+++ b/string/strchrnul.c
-@@ -66,13 +66,8 @@ STRCHRNUL (s, c_in)
-
- The 1-bits make sure that carries propagate to the next 0-bit.
- The 0-bits provide holes for carries to fall into. */
-- switch (sizeof (longword))
-- {
-- case 4: magic_bits = 0x7efefeffL; break;
-- case 8: magic_bits = ((0x7efefefeL << 16) << 16) | 0xfefefeffL; break;
-- default:
-- abort ();
-- }
-+ magic_bits = -1;
-+ magic_bits = magic_bits / 0xff * 0xfe << 1 >> 1 | 1;
-
- /* Set up a longword, each of whose bytes is C. */
- charmask = c | (c << 8);
diff --git a/packages/glibc/2.22/105-misleading-indentation.patch b/packages/glibc/2.22/105-misleading-indentation.patch
deleted file mode 100644
index 1dd8d85..0000000
--- a/packages/glibc/2.22/105-misleading-indentation.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-commit 976ef870542580cf5fed896c2c652b3e1a95f9da
-Author: Steve Ellcey <sellcey@mips.com>
-Date: Fri Dec 11 09:19:37 2015 -0800
-
- Fix indentation.
-
- * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f):
- Fix indentation.
-
-diff --git a/sysdeps/ieee754/flt-32/k_rem_pio2f.c b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-index 0c7685c..392afdb 100644
---- a/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-+++ b/sysdeps/ieee754/flt-32/k_rem_pio2f.c
-@@ -65,7 +65,9 @@ int __kernel_rem_pio2f(float *x, float *y, int e0, int nx, int prec, const int32
-
- /* compute q[0],q[1],...q[jk] */
- for (i=0;i<=jk;i++) {
-- for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw;
-+ for(j=0,fw=0.0;j<=jx;j++)
-+ fw += x[j]*f[jx+i-j];
-+ q[i] = fw;
- }
-
- jz = jk;
diff --git a/packages/glibc/2.22/920-fix-rpc_parse-format.patch b/packages/glibc/2.22/920-fix-rpc_parse-format.patch
deleted file mode 100644
index 37e58da..0000000
--- a/packages/glibc/2.22/920-fix-rpc_parse-format.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-commit 5874510faaf3cbd0bb112aaacab9f225002beed1
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Tue Nov 8 23:44:51 2016 +0000
-
- Fix rpcgen buffer overrun (bug 20790).
-
- Building with GCC 7 produces an error building rpcgen:
-
- rpc_parse.c: In function 'get_prog_declaration':
- rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ~~~~^
- rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
- That buffer overrun is for the case where the .x file declares a
- program with a million arguments. The strcpy two lines above can
- generate a buffer overrun much more simply for a long argument name.
-
- The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
- provides a bound on the buffer size needed, so this patch just changes
- the buffer size to MAXLINESIZE to avoid both possible buffer
- overruns. A testcase is added that rpcgen does not crash with a
- 500-character argument name, where it previously crashed.
-
- It would not at all surprise me if there are many other ways of
- crashing rpcgen with either valid or invalid input; fuzz testing would
- likely find various such bugs, though I don't think they are that
- important to fix (rpcgen is not that likely to be used with untrusted
- .x files as input). (As well as fuzz-findable bugs there are probably
- also issues when various int variables get overflowed on very large
- input.) The test infrastructure for rpcgen-not-crashing tests would
- need extending if tests are to be added for cases where rpcgen should
- produce an error, as opposed to cases where it should succeed.
-
- Tested for x86_64 and x86.
-
- [BZ #20790]
- * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
- to MAXLINESIZE.
- * sunrpc/bug20790.x: New file.
- * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
- variable.
- [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
- [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
-
-diff --git a/sunrpc/rpc_parse.c b/sunrpc/rpc_parse.c
-index 1a1df6d8c2..505a6554cf 100644
---- a/sunrpc/rpc_parse.c
-+++ b/sunrpc/rpc_parse.c
-@@ -521,7 +521,7 @@ static void
- get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
- {
- token tok;
-- char name[10]; /* argument name */
-+ char name[MAXLINESIZE]; /* argument name */
-
- if (dkind == DEF_PROGRAM)
- {
diff --git a/packages/glibc/2.22/940-nis-bogus-conditional.patch b/packages/glibc/2.22/940-nis-bogus-conditional.patch
deleted file mode 100644
index 09b38cf..0000000
--- a/packages/glibc/2.22/940-nis-bogus-conditional.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Wed Dec 21 23:44:01 2016 +0000
-
- Fix nss_nisplus build with mainline GCC (bug 20978).
-
- glibc build with current mainline GCC fails because
- nis/nss_nisplus/nisplus-alias.c contains code
-
- if (name != NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
- }
-
- char buf[strlen (name) + 9 + tablename_len];
-
- producing an error about strlen being called on a pointer that is
- always NULL (and a subsequent use of that pointer with a %s format in
- snprintf).
-
- As Andreas noted, the bogus conditional comes from a 1997 change:
-
- - if (name == NULL || strlen(name) > 8)
- - return NSS_STATUS_NOTFOUND;
- - else
- + if (name != NULL || strlen(name) <= 8)
-
- So the intention is clearly to return an error for NULL name.
-
- This patch duly inverts the sense of the conditional. It fixes the
- build with GCC mainline, and passes usual glibc testsuite testing for
- x86_64. However, I have not tried any actual substantive nisplus
- testing, do not have an environment for such testing, and do not know
- whether it is possible that strlen (name) or tablename_len might be
- large so that the VLA for buf is actually a security issue. However,
- if it is a security issue, there are plenty of other similar instances
- in the nisplus code (that haven't been hidden by a bogus comparison
- with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
- string passed to nis_list, so a local fix in the caller wouldn't
- suffice anyway (see bug 20987). (Calls to strdupa and other such
- macros that use alloca must be considered equally questionable
- regarding stack overflow issues as direct calls to alloca and VLA
- declarations.)
-
- [BZ #20978]
- * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
- Compare name == NULL, not name != NULL.
-
-diff --git a/nis/nss_nisplus/nisplus-alias.c b/nis/nss_nisplus/nisplus-alias.c
-index 7f698b4e6d..cb5acce01d 100644
---- a/nis/nss_nisplus/nisplus-alias.c
-+++ b/nis/nss_nisplus/nisplus-alias.c
-@@ -291,7 +291,7 @@ _nss_nisplus_getaliasbyname_r (const char *name, struct aliasent *alias,
- return status;
- }
-
-- if (name != NULL)
-+ if (name == NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.23/0000-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.23/0000-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
new file mode 100644
index 0000000..49d0204
--- /dev/null
+++ b/packages/glibc/2.23/0000-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
@@ -0,0 +1,75 @@
+From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
+From: Yvan Roux <yvan.roux@linaro.org>
+Date: Fri, 15 Apr 2016 13:29:26 +0200
+Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
+ -Wparentheses
+
+---
+ nis/nis_call.c | 20 +++++++++++---------
+ stdlib/setenv.c | 24 +++++++++++++-----------
+ 2 files changed, 24 insertions(+), 20 deletions(-)
+
+--- a/nis/nis_call.c
++++ b/nis/nis_call.c
+@@ -680,16 +680,18 @@
+ /* Choose which entry should be evicted from the cache. */
+ loc = &nis_server_cache[0];
+ if (*loc != NULL)
+- for (i = 1; i < 16; ++i)
+- if (nis_server_cache[i] == NULL)
+- {
++ {
++ for (i = 1; i < 16; ++i)
++ if (nis_server_cache[i] == NULL)
++ {
++ loc = &nis_server_cache[i];
++ break;
++ }
++ else if ((*loc)->uses > nis_server_cache[i]->uses
++ || ((*loc)->uses == nis_server_cache[i]->uses
++ && (*loc)->expires > nis_server_cache[i]->expires))
+ loc = &nis_server_cache[i];
+- break;
+- }
+- else if ((*loc)->uses > nis_server_cache[i]->uses
+- || ((*loc)->uses == nis_server_cache[i]->uses
+- && (*loc)->expires > nis_server_cache[i]->expires))
+- loc = &nis_server_cache[i];
++ }
+ old = *loc;
+ *loc = new;
+
+--- a/stdlib/setenv.c
++++ b/stdlib/setenv.c
+@@ -278,18 +278,20 @@
+ ep = __environ;
+ if (ep != NULL)
+ while (*ep != NULL)
+- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
+- {
+- /* Found it. Remove this pointer by moving later ones back. */
+- char **dp = ep;
++ {
++ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
++ {
++ /* Found it. Remove this pointer by moving later ones back. */
++ char **dp = ep;
+
+- do
+- dp[0] = dp[1];
+- while (*dp++);
+- /* Continue the loop in case NAME appears again. */
+- }
+- else
+- ++ep;
++ do
++ dp[0] = dp[1];
++ while (*dp++);
++ /* Continue the loop in case NAME appears again. */
++ }
++ else
++ ++ep;
++ }
+
+ UNLOCK;
+
diff --git a/packages/glibc/2.23/120-Fix-build-with-enable-static-nss.patch b/packages/glibc/2.23/0001-Fix-build-with-enable-static-nss.patch
index 59ab087..32c1ca2 100644
--- a/packages/glibc/2.23/120-Fix-build-with-enable-static-nss.patch
+++ b/packages/glibc/2.23/0001-Fix-build-with-enable-static-nss.patch
@@ -8,15 +8,12 @@ Subject: [PATCH] Fix build with --enable-static-nss
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- nss/nsswitch.c | 2 +-
- 2 files changed, 6 insertions(+), 1 deletion(-)
+ nss/nsswitch.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
-diff --git a/nss/nsswitch.c b/nss/nsswitch.c
-index 0a65f6a..8f31658 100644
--- a/nss/nsswitch.c
+++ b/nss/nsswitch.c
-@@ -94,7 +94,7 @@ static name_database *service_table;
+@@ -94,7 +94,7 @@
static name_database_entry *defconfig_entries;
@@ -25,6 +22,3 @@ index 0a65f6a..8f31658 100644
/* Nonzero if this is the nscd process. */
static bool is_nscd;
/* The callback passed to the init functions when nscd is used. */
---
-2.9.3
-
diff --git a/packages/glibc/2.23/0002-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.23/0002-Fix-combreloc-test-BSD-grep.patch
new file mode 100644
index 0000000..6c05092
--- /dev/null
+++ b/packages/glibc/2.23/0002-Fix-combreloc-test-BSD-grep.patch
@@ -0,0 +1,41 @@
+From 61d5f9c09b3157db76bd1a393e248c262a8d9dd4 Mon Sep 17 00:00:00 2001
+From: Alexey Neyman <stilor@att.net>
+Date: Wed, 8 Mar 2017 14:31:10 -0800
+Subject: [PATCH] Fix combreloc test with BSD grep
+
+The test for "-z combreloc" fails when cross-compiling on a machine
+that uses BSD grep (e.g. on macos). grep complains about empty
+subexpression and exits with non-zero status, which is interpreted
+by configure as "not found". As a result, support for "-z combreloc"
+(HAVE_Z_COMBRELOC) is not detected, leading to link failure on SPARC.
+
+ * configure.ac: Avoid empty subexpression in grep.
+
+Signed-off-by: Alexey Neyman <stilor@att.net>
+---
+ configure | 2 +-
+ configure.ac | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+--- a/configure
++++ b/configure
+@@ -5527,7 +5527,7 @@
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; }
+ then
+- if $READELF -S conftest.so | grep '\.rel\(a\|\)\.dyn' > /dev/null; then
++ if $READELF -S conftest.so | grep '\.\(rel\|rela\)\.dyn' > /dev/null; then
+ libc_cv_z_combreloc=yes
+ else
+ libc_cv_z_combreloc=no
+--- a/configure.ac
++++ b/configure.ac
+@@ -1243,7 +1243,7 @@
+ dnl introducing new options this is not easily doable. Instead use a tool
+ dnl which always is cross-platform: readelf. To detect whether -z combreloc
+ dnl look for a section named .rel.dyn.
+- if $READELF -S conftest.so | grep '\.rel\(a\|\)\.dyn' > /dev/null; then
++ if $READELF -S conftest.so | grep '\.\(rel\|rela\)\.dyn' > /dev/null; then
+ libc_cv_z_combreloc=yes
+ else
+ libc_cv_z_combreloc=no
diff --git a/packages/glibc/2.23/910-typedef-caddr.patch b/packages/glibc/2.23/0003-typedef-caddr.patch
index fc7979b..980939b 100644
--- a/packages/glibc/2.23/910-typedef-caddr.patch
+++ b/packages/glibc/2.23/0003-typedef-caddr.patch
@@ -1,8 +1,11 @@
-diff -urN glibc-2.23-orig/posix/sys/types.h glibc-2.23/posix/sys/types.h
---- glibc-2.23-orig/posix/sys/types.h 2016-02-18 12:54:00.000000000 -0500
-+++ glibc-2.23/posix/sys/types.h 2017-01-06 11:40:05.842147165 -0500
+---
+ posix/sys/types.h | 3 +++
+ 1 file changed, 3 insertions(+)
+
+--- a/posix/sys/types.h
++++ b/posix/sys/types.h
@@ -113,7 +113,10 @@
- #ifdef __USE_MISC
+ #ifdef __USE_MISC
# ifndef __daddr_t_defined
typedef __daddr_t daddr_t;
+# if ! defined(caddr_t) && ! defined(__caddr_t_defined)
@@ -12,4 +15,3 @@ diff -urN glibc-2.23-orig/posix/sys/types.h glibc-2.23/posix/sys/types.h
# define __daddr_t_defined
# endif
#endif
-
diff --git a/packages/glibc/2.23/0004-fix-rpc_parse-format.patch b/packages/glibc/2.23/0004-fix-rpc_parse-format.patch
new file mode 100644
index 0000000..341d541
--- /dev/null
+++ b/packages/glibc/2.23/0004-fix-rpc_parse-format.patch
@@ -0,0 +1,62 @@
+commit 5874510faaf3cbd0bb112aaacab9f225002beed1
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Tue Nov 8 23:44:51 2016 +0000
+
+ Fix rpcgen buffer overrun (bug 20790).
+
+ Building with GCC 7 produces an error building rpcgen:
+
+ rpc_parse.c: In function 'get_prog_declaration':
+ rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ~~~~^
+ rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+ That buffer overrun is for the case where the .x file declares a
+ program with a million arguments. The strcpy two lines above can
+ generate a buffer overrun much more simply for a long argument name.
+
+ The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
+ provides a bound on the buffer size needed, so this patch just changes
+ the buffer size to MAXLINESIZE to avoid both possible buffer
+ overruns. A testcase is added that rpcgen does not crash with a
+ 500-character argument name, where it previously crashed.
+
+ It would not at all surprise me if there are many other ways of
+ crashing rpcgen with either valid or invalid input; fuzz testing would
+ likely find various such bugs, though I don't think they are that
+ important to fix (rpcgen is not that likely to be used with untrusted
+ .x files as input). (As well as fuzz-findable bugs there are probably
+ also issues when various int variables get overflowed on very large
+ input.) The test infrastructure for rpcgen-not-crashing tests would
+ need extending if tests are to be added for cases where rpcgen should
+ produce an error, as opposed to cases where it should succeed.
+
+ Tested for x86_64 and x86.
+
+ [BZ #20790]
+ * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
+ to MAXLINESIZE.
+ * sunrpc/bug20790.x: New file.
+ * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
+ variable.
+ [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
+ [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
+
+---
+ sunrpc/rpc_parse.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/sunrpc/rpc_parse.c
++++ b/sunrpc/rpc_parse.c
+@@ -521,7 +521,7 @@
+ get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
+ {
+ token tok;
+- char name[10]; /* argument name */
++ char name[MAXLINESIZE]; /* argument name */
+
+ if (dkind == DEF_PROGRAM)
+ {
diff --git a/packages/glibc/2.23/0005-explicit-boolean.patch b/packages/glibc/2.23/0005-explicit-boolean.patch
new file mode 100644
index 0000000..98dc50d
--- /dev/null
+++ b/packages/glibc/2.23/0005-explicit-boolean.patch
@@ -0,0 +1,35 @@
+commit e223d1fe72e820d96f43831412ab267a1ace04d0
+Author: steve ellcey-CA Eng-Software <sellcey@sellcey-thinkpad.caveonetworks.com>
+Date: Fri Oct 14 12:53:27 2016 -0700
+
+ Fix warnings from latest GCC.
+
+ * sysdeps/ieee754/dbl-64/e_pow.c (checkint) Make conditions explicitly
+ boolean.
+
+---
+ sysdeps/ieee754/dbl-64/e_pow.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+--- a/sysdeps/ieee754/dbl-64/e_pow.c
++++ b/sysdeps/ieee754/dbl-64/e_pow.c
+@@ -466,15 +466,15 @@
+ return (n & 1) ? -1 : 1; /* odd or even */
+ if (k > 20)
+ {
+- if (n << (k - 20))
++ if (n << (k - 20) != 0)
+ return 0; /* if not integer */
+- return (n << (k - 21)) ? -1 : 1;
++ return (n << (k - 21) != 0) ? -1 : 1;
+ }
+ if (n)
+ return 0; /*if not integer */
+ if (k == 20)
+ return (m & 1) ? -1 : 1;
+- if (m << (k + 12))
++ if (m << (k + 12) != 0)
+ return 0;
+- return (m << (k + 11)) ? -1 : 1;
++ return (m << (k + 11) != 0) ? -1 : 1;
+ }
diff --git a/packages/glibc/2.23/0006-nis-bogus-conditional.patch b/packages/glibc/2.23/0006-nis-bogus-conditional.patch
new file mode 100644
index 0000000..e728368
--- /dev/null
+++ b/packages/glibc/2.23/0006-nis-bogus-conditional.patch
@@ -0,0 +1,64 @@
+commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Wed Dec 21 23:44:01 2016 +0000
+
+ Fix nss_nisplus build with mainline GCC (bug 20978).
+
+ glibc build with current mainline GCC fails because
+ nis/nss_nisplus/nisplus-alias.c contains code
+
+ if (name != NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
+ }
+
+ char buf[strlen (name) + 9 + tablename_len];
+
+ producing an error about strlen being called on a pointer that is
+ always NULL (and a subsequent use of that pointer with a %s format in
+ snprintf).
+
+ As Andreas noted, the bogus conditional comes from a 1997 change:
+
+ - if (name == NULL || strlen(name) > 8)
+ - return NSS_STATUS_NOTFOUND;
+ - else
+ + if (name != NULL || strlen(name) <= 8)
+
+ So the intention is clearly to return an error for NULL name.
+
+ This patch duly inverts the sense of the conditional. It fixes the
+ build with GCC mainline, and passes usual glibc testsuite testing for
+ x86_64. However, I have not tried any actual substantive nisplus
+ testing, do not have an environment for such testing, and do not know
+ whether it is possible that strlen (name) or tablename_len might be
+ large so that the VLA for buf is actually a security issue. However,
+ if it is a security issue, there are plenty of other similar instances
+ in the nisplus code (that haven't been hidden by a bogus comparison
+ with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
+ string passed to nis_list, so a local fix in the caller wouldn't
+ suffice anyway (see bug 20987). (Calls to strdupa and other such
+ macros that use alloca must be considered equally questionable
+ regarding stack overflow issues as direct calls to alloca and VLA
+ declarations.)
+
+ [BZ #20978]
+ * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
+ Compare name == NULL, not name != NULL.
+
+---
+ nis/nss_nisplus/nisplus-alias.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/nis/nss_nisplus/nisplus-alias.c
++++ b/nis/nss_nisplus/nisplus-alias.c
+@@ -291,7 +291,7 @@
+ return status;
+ }
+
+- if (name != NULL)
++ if (name == NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.23/997-regexp-common.patch b/packages/glibc/2.23/0007-regexp-common.patch
index 7764c99..89e8371 100644
--- a/packages/glibc/2.23/997-regexp-common.patch
+++ b/packages/glibc/2.23/0007-regexp-common.patch
@@ -32,8 +32,10 @@ Date: Fri Jun 23 14:38:46 2017 -0700
(loc2): Likewise.
(locs): Likewise.
-diff --git a/misc/regexp.c b/misc/regexp.c
-index 19d76c0c37..eaea7c3b89 100644
+---
+ misc/regexp.c | 9 +++++----
+ 1 file changed, 5 insertions(+), 4 deletions(-)
+
--- a/misc/regexp.c
+++ b/misc/regexp.c
@@ -29,14 +29,15 @@
diff --git a/packages/glibc/2.23/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch b/packages/glibc/2.23/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
deleted file mode 100644
index 6fd663a..0000000
--- a/packages/glibc/2.23/101-Suppress-GCC-6-warning-about-ambiguous-else-with-Wpa.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-From df1cf48777fe4cd81ad7fb09ecbe5b31432b7c1c Mon Sep 17 00:00:00 2001
-From: Yvan Roux <yvan.roux@linaro.org>
-Date: Fri, 15 Apr 2016 13:29:26 +0200
-Subject: [PATCH] Suppress GCC 6 warning about ambiguous 'else' with
- -Wparentheses
-
----
- ChangeLog | 5 +++++
- nis/nis_call.c | 20 +++++++++++---------
- stdlib/setenv.c | 26 ++++++++++++++------------
- 3 files changed, 30 insertions(+), 21 deletions(-)
-
-diff --git a/nis/nis_call.c b/nis/nis_call.c
-index 3fa37e4..cb7839a 100644
---- a/nis/nis_call.c
-+++ b/nis/nis_call.c
-@@ -680,16 +680,18 @@ nis_server_cache_add (const_nis_name name, int search_parent,
- /* Choose which entry should be evicted from the cache. */
- loc = &nis_server_cache[0];
- if (*loc != NULL)
-- for (i = 1; i < 16; ++i)
-- if (nis_server_cache[i] == NULL)
-- {
-+ {
-+ for (i = 1; i < 16; ++i)
-+ if (nis_server_cache[i] == NULL)
-+ {
-+ loc = &nis_server_cache[i];
-+ break;
-+ }
-+ else if ((*loc)->uses > nis_server_cache[i]->uses
-+ || ((*loc)->uses == nis_server_cache[i]->uses
-+ && (*loc)->expires > nis_server_cache[i]->expires))
- loc = &nis_server_cache[i];
-- break;
-- }
-- else if ((*loc)->uses > nis_server_cache[i]->uses
-- || ((*loc)->uses == nis_server_cache[i]->uses
-- && (*loc)->expires > nis_server_cache[i]->expires))
-- loc = &nis_server_cache[i];
-+ }
- old = *loc;
- *loc = new;
-
-diff --git a/stdlib/setenv.c b/stdlib/setenv.c
-index da61ee0..e66045f 100644
---- a/stdlib/setenv.c
-+++ b/stdlib/setenv.c
-@@ -278,18 +278,20 @@ unsetenv (const char *name)
- ep = __environ;
- if (ep != NULL)
- while (*ep != NULL)
-- if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-- {
-- /* Found it. Remove this pointer by moving later ones back. */
-- char **dp = ep;
--
-- do
-- dp[0] = dp[1];
-- while (*dp++);
-- /* Continue the loop in case NAME appears again. */
-- }
-- else
-- ++ep;
-+ {
-+ if (!strncmp (*ep, name, len) && (*ep)[len] == '=')
-+ {
-+ /* Found it. Remove this pointer by moving later ones back. */
-+ char **dp = ep;
-+
-+ do
-+ dp[0] = dp[1];
-+ while (*dp++);
-+ /* Continue the loop in case NAME appears again. */
-+ }
-+ else
-+ ++ep;
-+ }
-
- UNLOCK;
-
---
-2.7.4
-
diff --git a/packages/glibc/2.23/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.23/140-Fix-combreloc-test-BSD-grep.patch
deleted file mode 100644
index fdc3a60..0000000
--- a/packages/glibc/2.23/140-Fix-combreloc-test-BSD-grep.patch
+++ /dev/null
@@ -1,49 +0,0 @@
-From 61d5f9c09b3157db76bd1a393e248c262a8d9dd4 Mon Sep 17 00:00:00 2001
-From: Alexey Neyman <stilor@att.net>
-Date: Wed, 8 Mar 2017 14:31:10 -0800
-Subject: [PATCH] Fix combreloc test with BSD grep
-
-The test for "-z combreloc" fails when cross-compiling on a machine
-that uses BSD grep (e.g. on macos). grep complains about empty
-subexpression and exits with non-zero status, which is interpreted
-by configure as "not found". As a result, support for "-z combreloc"
-(HAVE_Z_COMBRELOC) is not detected, leading to link failure on SPARC.
-
- * configure.ac: Avoid empty subexpression in grep.
-
-Signed-off-by: Alexey Neyman <stilor@att.net>
----
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
-
-diff --git a/configure b/configure
-index eecd0ac..0118bd1 100755
---- a/configure
-+++ b/configure
-@@ -5804,7 +5804,7 @@ if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }
- then
-- if $READELF -S conftest.so | grep '\.rel\(a\|\)\.dyn' > /dev/null; then
-+ if $READELF -S conftest.so | grep '\.\(rel\|rela\)\.dyn' > /dev/null; then
- libc_cv_z_combreloc=yes
- else
- libc_cv_z_combreloc=no
-diff --git a/configure.ac b/configure.ac
-index 4a77411..19f6d87 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -1391,7 +1391,7 @@ dnl cross-platform since the gcc used can be a cross compiler. Without
- dnl introducing new options this is not easily doable. Instead use a tool
- dnl which always is cross-platform: readelf. To detect whether -z combreloc
- dnl look for a section named .rel.dyn.
-- if $READELF -S conftest.so | grep '\.rel\(a\|\)\.dyn' > /dev/null; then
-+ if $READELF -S conftest.so | grep '\.\(rel\|rela\)\.dyn' > /dev/null; then
- libc_cv_z_combreloc=yes
- else
- libc_cv_z_combreloc=no
---
-2.9.3
-
diff --git a/packages/glibc/2.23/920-fix-rpc_parse-format.patch b/packages/glibc/2.23/920-fix-rpc_parse-format.patch
deleted file mode 100644
index 37e58da..0000000
--- a/packages/glibc/2.23/920-fix-rpc_parse-format.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-commit 5874510faaf3cbd0bb112aaacab9f225002beed1
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Tue Nov 8 23:44:51 2016 +0000
-
- Fix rpcgen buffer overrun (bug 20790).
-
- Building with GCC 7 produces an error building rpcgen:
-
- rpc_parse.c: In function 'get_prog_declaration':
- rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ~~~~^
- rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
- That buffer overrun is for the case where the .x file declares a
- program with a million arguments. The strcpy two lines above can
- generate a buffer overrun much more simply for a long argument name.
-
- The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
- provides a bound on the buffer size needed, so this patch just changes
- the buffer size to MAXLINESIZE to avoid both possible buffer
- overruns. A testcase is added that rpcgen does not crash with a
- 500-character argument name, where it previously crashed.
-
- It would not at all surprise me if there are many other ways of
- crashing rpcgen with either valid or invalid input; fuzz testing would
- likely find various such bugs, though I don't think they are that
- important to fix (rpcgen is not that likely to be used with untrusted
- .x files as input). (As well as fuzz-findable bugs there are probably
- also issues when various int variables get overflowed on very large
- input.) The test infrastructure for rpcgen-not-crashing tests would
- need extending if tests are to be added for cases where rpcgen should
- produce an error, as opposed to cases where it should succeed.
-
- Tested for x86_64 and x86.
-
- [BZ #20790]
- * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
- to MAXLINESIZE.
- * sunrpc/bug20790.x: New file.
- * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
- variable.
- [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
- [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
-
-diff --git a/sunrpc/rpc_parse.c b/sunrpc/rpc_parse.c
-index 1a1df6d8c2..505a6554cf 100644
---- a/sunrpc/rpc_parse.c
-+++ b/sunrpc/rpc_parse.c
-@@ -521,7 +521,7 @@ static void
- get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
- {
- token tok;
-- char name[10]; /* argument name */
-+ char name[MAXLINESIZE]; /* argument name */
-
- if (dkind == DEF_PROGRAM)
- {
diff --git a/packages/glibc/2.23/930-explicit-boolean.patch b/packages/glibc/2.23/930-explicit-boolean.patch
deleted file mode 100644
index 780fae6..0000000
--- a/packages/glibc/2.23/930-explicit-boolean.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-commit e223d1fe72e820d96f43831412ab267a1ace04d0
-Author: steve ellcey-CA Eng-Software <sellcey@sellcey-thinkpad.caveonetworks.com>
-Date: Fri Oct 14 12:53:27 2016 -0700
-
- Fix warnings from latest GCC.
-
- * sysdeps/ieee754/dbl-64/e_pow.c (checkint) Make conditions explicitly
- boolean.
-
-diff --git a/sysdeps/ieee754/dbl-64/e_pow.c b/sysdeps/ieee754/dbl-64/e_pow.c
-index 663fa392c2..bd758b5979 100644
---- a/sysdeps/ieee754/dbl-64/e_pow.c
-+++ b/sysdeps/ieee754/dbl-64/e_pow.c
-@@ -466,15 +466,15 @@ checkint (double x)
- return (n & 1) ? -1 : 1; /* odd or even */
- if (k > 20)
- {
-- if (n << (k - 20))
-+ if (n << (k - 20) != 0)
- return 0; /* if not integer */
-- return (n << (k - 21)) ? -1 : 1;
-+ return (n << (k - 21) != 0) ? -1 : 1;
- }
- if (n)
- return 0; /*if not integer */
- if (k == 20)
- return (m & 1) ? -1 : 1;
-- if (m << (k + 12))
-+ if (m << (k + 12) != 0)
- return 0;
-- return (m << (k + 11)) ? -1 : 1;
-+ return (m << (k + 11) != 0) ? -1 : 1;
- }
diff --git a/packages/glibc/2.23/940-nis-bogus-conditional.patch b/packages/glibc/2.23/940-nis-bogus-conditional.patch
deleted file mode 100644
index 09b38cf..0000000
--- a/packages/glibc/2.23/940-nis-bogus-conditional.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Wed Dec 21 23:44:01 2016 +0000
-
- Fix nss_nisplus build with mainline GCC (bug 20978).
-
- glibc build with current mainline GCC fails because
- nis/nss_nisplus/nisplus-alias.c contains code
-
- if (name != NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
- }
-
- char buf[strlen (name) + 9 + tablename_len];
-
- producing an error about strlen being called on a pointer that is
- always NULL (and a subsequent use of that pointer with a %s format in
- snprintf).
-
- As Andreas noted, the bogus conditional comes from a 1997 change:
-
- - if (name == NULL || strlen(name) > 8)
- - return NSS_STATUS_NOTFOUND;
- - else
- + if (name != NULL || strlen(name) <= 8)
-
- So the intention is clearly to return an error for NULL name.
-
- This patch duly inverts the sense of the conditional. It fixes the
- build with GCC mainline, and passes usual glibc testsuite testing for
- x86_64. However, I have not tried any actual substantive nisplus
- testing, do not have an environment for such testing, and do not know
- whether it is possible that strlen (name) or tablename_len might be
- large so that the VLA for buf is actually a security issue. However,
- if it is a security issue, there are plenty of other similar instances
- in the nisplus code (that haven't been hidden by a bogus comparison
- with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
- string passed to nis_list, so a local fix in the caller wouldn't
- suffice anyway (see bug 20987). (Calls to strdupa and other such
- macros that use alloca must be considered equally questionable
- regarding stack overflow issues as direct calls to alloca and VLA
- declarations.)
-
- [BZ #20978]
- * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
- Compare name == NULL, not name != NULL.
-
-diff --git a/nis/nss_nisplus/nisplus-alias.c b/nis/nss_nisplus/nisplus-alias.c
-index 7f698b4e6d..cb5acce01d 100644
---- a/nis/nss_nisplus/nisplus-alias.c
-+++ b/nis/nss_nisplus/nisplus-alias.c
-@@ -291,7 +291,7 @@ _nss_nisplus_getaliasbyname_r (const char *name, struct aliasent *alias,
- return status;
- }
-
-- if (name != NULL)
-+ if (name == NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.24/110-sh-fix-gcc6.patch b/packages/glibc/2.24/0000-sh-fix-gcc6.patch
index cacf390..ef9e31c 100644
--- a/packages/glibc/2.24/110-sh-fix-gcc6.patch
+++ b/packages/glibc/2.24/0000-sh-fix-gcc6.patch
@@ -7,14 +7,12 @@ Subject: [PATCH] sh: conditional is false in dl-conflict.c
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- sysdeps/sh/dl-machine.h | 2 +-
+ sysdeps/sh/dl-machine.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
-diff --git a/sysdeps/sh/dl-machine.h b/sysdeps/sh/dl-machine.h
-index 449deea..2b468af 100644
--- a/sysdeps/sh/dl-machine.h
+++ b/sysdeps/sh/dl-machine.h
-@@ -389,7 +389,7 @@ elf_machine_rela (struct link_map *map, const Elf32_Rela *reloc,
+@@ -389,7 +389,7 @@
break;
case R_SH_DIR32:
{
@@ -23,6 +21,3 @@ index 449deea..2b468af 100644
/* This is defined in rtld.c, but nowhere in the static
libc.a; make the reference weak so static programs can
still link. This declaration cannot be done when
---
-2.9.3
-
diff --git a/packages/glibc/2.25/120-Fix-build-with-enable-static-nss.patch b/packages/glibc/2.24/0001-Fix-build-with-enable-static-nss.patch
index 59ab087..32c1ca2 100644
--- a/packages/glibc/2.25/120-Fix-build-with-enable-static-nss.patch
+++ b/packages/glibc/2.24/0001-Fix-build-with-enable-static-nss.patch
@@ -8,15 +8,12 @@ Subject: [PATCH] Fix build with --enable-static-nss
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- nss/nsswitch.c | 2 +-
- 2 files changed, 6 insertions(+), 1 deletion(-)
+ nss/nsswitch.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
-diff --git a/nss/nsswitch.c b/nss/nsswitch.c
-index 0a65f6a..8f31658 100644
--- a/nss/nsswitch.c
+++ b/nss/nsswitch.c
-@@ -94,7 +94,7 @@ static name_database *service_table;
+@@ -94,7 +94,7 @@
static name_database_entry *defconfig_entries;
@@ -25,6 +22,3 @@ index 0a65f6a..8f31658 100644
/* Nonzero if this is the nscd process. */
static bool is_nscd;
/* The callback passed to the init functions when nscd is used. */
---
-2.9.3
-
diff --git a/packages/glibc/2.24/0002-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.24/0002-Fix-combreloc-test-BSD-grep.patch
new file mode 100644
index 0000000..1108df6
--- /dev/null
+++ b/packages/glibc/2.24/0002-Fix-combreloc-test-BSD-grep.patch
@@ -0,0 +1,41 @@
+From 61d5f9c09b3157db76bd1a393e248c262a8d9dd4 Mon Sep 17 00:00:00 2001
+From: Alexey Neyman <stilor@att.net>
+Date: Wed, 8 Mar 2017 14:31:10 -0800
+Subject: [PATCH] Fix combreloc test with BSD grep
+
+The test for "-z combreloc" fails when cross-compiling on a machine
+that uses BSD grep (e.g. on macos). grep complains about empty
+subexpression and exits with non-zero status, which is interpreted
+by configure as "not found". As a result, support for "-z combreloc"
+(HAVE_Z_COMBRELOC) is not detected, leading to link failure on SPARC.
+
+ * configure.ac: Avoid empty subexpression in grep.
+
+Signed-off-by: Alexey Neyman <stilor@att.net>
+---
+ configure | 2 +-
+ configure.ac | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+--- a/configure
++++ b/configure
+@@ -5532,7 +5532,7 @@
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; }
+ then
+- if $READELF -S conftest.so | grep '\.rel\(a\|\)\.dyn' > /dev/null; then
++ if $READELF -S conftest.so | grep '\.\(rel\|rela\)\.dyn' > /dev/null; then
+ libc_cv_z_combreloc=yes
+ else
+ libc_cv_z_combreloc=no
+--- a/configure.ac
++++ b/configure.ac
+@@ -1246,7 +1246,7 @@
+ dnl introducing new options this is not easily doable. Instead use a tool
+ dnl which always is cross-platform: readelf. To detect whether -z combreloc
+ dnl look for a section named .rel.dyn.
+- if $READELF -S conftest.so | grep '\.rel\(a\|\)\.dyn' > /dev/null; then
++ if $READELF -S conftest.so | grep '\.\(rel\|rela\)\.dyn' > /dev/null; then
+ libc_cv_z_combreloc=yes
+ else
+ libc_cv_z_combreloc=no
diff --git a/packages/glibc/2.24/0003-typedef-caddr.patch b/packages/glibc/2.24/0003-typedef-caddr.patch
new file mode 100644
index 0000000..980939b
--- /dev/null
+++ b/packages/glibc/2.24/0003-typedef-caddr.patch
@@ -0,0 +1,17 @@
+---
+ posix/sys/types.h | 3 +++
+ 1 file changed, 3 insertions(+)
+
+--- a/posix/sys/types.h
++++ b/posix/sys/types.h
+@@ -113,7 +113,10 @@
+ #ifdef __USE_MISC
+ # ifndef __daddr_t_defined
+ typedef __daddr_t daddr_t;
++# if ! defined(caddr_t) && ! defined(__caddr_t_defined)
+ typedef __caddr_t caddr_t;
++# define __caddr_t_defined
++# endif
+ # define __daddr_t_defined
+ # endif
+ #endif
diff --git a/packages/glibc/2.24/0004-fix-rpc_parse-format.patch b/packages/glibc/2.24/0004-fix-rpc_parse-format.patch
new file mode 100644
index 0000000..341d541
--- /dev/null
+++ b/packages/glibc/2.24/0004-fix-rpc_parse-format.patch
@@ -0,0 +1,62 @@
+commit 5874510faaf3cbd0bb112aaacab9f225002beed1
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Tue Nov 8 23:44:51 2016 +0000
+
+ Fix rpcgen buffer overrun (bug 20790).
+
+ Building with GCC 7 produces an error building rpcgen:
+
+ rpc_parse.c: In function 'get_prog_declaration':
+ rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ~~~~^
+ rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
+ sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
+ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+ That buffer overrun is for the case where the .x file declares a
+ program with a million arguments. The strcpy two lines above can
+ generate a buffer overrun much more simply for a long argument name.
+
+ The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
+ provides a bound on the buffer size needed, so this patch just changes
+ the buffer size to MAXLINESIZE to avoid both possible buffer
+ overruns. A testcase is added that rpcgen does not crash with a
+ 500-character argument name, where it previously crashed.
+
+ It would not at all surprise me if there are many other ways of
+ crashing rpcgen with either valid or invalid input; fuzz testing would
+ likely find various such bugs, though I don't think they are that
+ important to fix (rpcgen is not that likely to be used with untrusted
+ .x files as input). (As well as fuzz-findable bugs there are probably
+ also issues when various int variables get overflowed on very large
+ input.) The test infrastructure for rpcgen-not-crashing tests would
+ need extending if tests are to be added for cases where rpcgen should
+ produce an error, as opposed to cases where it should succeed.
+
+ Tested for x86_64 and x86.
+
+ [BZ #20790]
+ * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
+ to MAXLINESIZE.
+ * sunrpc/bug20790.x: New file.
+ * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
+ variable.
+ [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
+ [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
+
+---
+ sunrpc/rpc_parse.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/sunrpc/rpc_parse.c
++++ b/sunrpc/rpc_parse.c
+@@ -521,7 +521,7 @@
+ get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
+ {
+ token tok;
+- char name[10]; /* argument name */
++ char name[MAXLINESIZE]; /* argument name */
+
+ if (dkind == DEF_PROGRAM)
+ {
diff --git a/packages/glibc/2.24/0005-explicit-boolean.patch b/packages/glibc/2.24/0005-explicit-boolean.patch
new file mode 100644
index 0000000..98dc50d
--- /dev/null
+++ b/packages/glibc/2.24/0005-explicit-boolean.patch
@@ -0,0 +1,35 @@
+commit e223d1fe72e820d96f43831412ab267a1ace04d0
+Author: steve ellcey-CA Eng-Software <sellcey@sellcey-thinkpad.caveonetworks.com>
+Date: Fri Oct 14 12:53:27 2016 -0700
+
+ Fix warnings from latest GCC.
+
+ * sysdeps/ieee754/dbl-64/e_pow.c (checkint) Make conditions explicitly
+ boolean.
+
+---
+ sysdeps/ieee754/dbl-64/e_pow.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+--- a/sysdeps/ieee754/dbl-64/e_pow.c
++++ b/sysdeps/ieee754/dbl-64/e_pow.c
+@@ -466,15 +466,15 @@
+ return (n & 1) ? -1 : 1; /* odd or even */
+ if (k > 20)
+ {
+- if (n << (k - 20))
++ if (n << (k - 20) != 0)
+ return 0; /* if not integer */
+- return (n << (k - 21)) ? -1 : 1;
++ return (n << (k - 21) != 0) ? -1 : 1;
+ }
+ if (n)
+ return 0; /*if not integer */
+ if (k == 20)
+ return (m & 1) ? -1 : 1;
+- if (m << (k + 12))
++ if (m << (k + 12) != 0)
+ return 0;
+- return (m << (k + 11)) ? -1 : 1;
++ return (m << (k + 11) != 0) ? -1 : 1;
+ }
diff --git a/packages/glibc/2.24/0006-nis-bogus-conditional.patch b/packages/glibc/2.24/0006-nis-bogus-conditional.patch
new file mode 100644
index 0000000..e728368
--- /dev/null
+++ b/packages/glibc/2.24/0006-nis-bogus-conditional.patch
@@ -0,0 +1,64 @@
+commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
+Author: Joseph Myers <joseph@codesourcery.com>
+Date: Wed Dec 21 23:44:01 2016 +0000
+
+ Fix nss_nisplus build with mainline GCC (bug 20978).
+
+ glibc build with current mainline GCC fails because
+ nis/nss_nisplus/nisplus-alias.c contains code
+
+ if (name != NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
+ }
+
+ char buf[strlen (name) + 9 + tablename_len];
+
+ producing an error about strlen being called on a pointer that is
+ always NULL (and a subsequent use of that pointer with a %s format in
+ snprintf).
+
+ As Andreas noted, the bogus conditional comes from a 1997 change:
+
+ - if (name == NULL || strlen(name) > 8)
+ - return NSS_STATUS_NOTFOUND;
+ - else
+ + if (name != NULL || strlen(name) <= 8)
+
+ So the intention is clearly to return an error for NULL name.
+
+ This patch duly inverts the sense of the conditional. It fixes the
+ build with GCC mainline, and passes usual glibc testsuite testing for
+ x86_64. However, I have not tried any actual substantive nisplus
+ testing, do not have an environment for such testing, and do not know
+ whether it is possible that strlen (name) or tablename_len might be
+ large so that the VLA for buf is actually a security issue. However,
+ if it is a security issue, there are plenty of other similar instances
+ in the nisplus code (that haven't been hidden by a bogus comparison
+ with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
+ string passed to nis_list, so a local fix in the caller wouldn't
+ suffice anyway (see bug 20987). (Calls to strdupa and other such
+ macros that use alloca must be considered equally questionable
+ regarding stack overflow issues as direct calls to alloca and VLA
+ declarations.)
+
+ [BZ #20978]
+ * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
+ Compare name == NULL, not name != NULL.
+
+---
+ nis/nss_nisplus/nisplus-alias.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/nis/nss_nisplus/nisplus-alias.c
++++ b/nis/nss_nisplus/nisplus-alias.c
+@@ -291,7 +291,7 @@
+ return status;
+ }
+
+- if (name != NULL)
++ if (name == NULL)
+ {
+ *errnop = EINVAL;
+ return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.24/997-regexp-common.patch b/packages/glibc/2.24/0007-regexp-common.patch
index 7764c99..89e8371 100644
--- a/packages/glibc/2.24/997-regexp-common.patch
+++ b/packages/glibc/2.24/0007-regexp-common.patch
@@ -32,8 +32,10 @@ Date: Fri Jun 23 14:38:46 2017 -0700
(loc2): Likewise.
(locs): Likewise.
-diff --git a/misc/regexp.c b/misc/regexp.c
-index 19d76c0c37..eaea7c3b89 100644
+---
+ misc/regexp.c | 9 +++++----
+ 1 file changed, 5 insertions(+), 4 deletions(-)
+
--- a/misc/regexp.c
+++ b/misc/regexp.c
@@ -29,14 +29,15 @@
diff --git a/packages/glibc/2.24/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.24/140-Fix-combreloc-test-BSD-grep.patch
deleted file mode 100644
index fdc3a60..0000000
--- a/packages/glibc/2.24/140-Fix-combreloc-test-BSD-grep.patch
+++ /dev/null
@@ -1,49 +0,0 @@
-From 61d5f9c09b3157db76bd1a393e248c262a8d9dd4 Mon Sep 17 00:00:00 2001
-From: Alexey Neyman <stilor@att.net>
-Date: Wed, 8 Mar 2017 14:31:10 -0800
-Subject: [PATCH] Fix combreloc test with BSD grep
-
-The test for "-z combreloc" fails when cross-compiling on a machine
-that uses BSD grep (e.g. on macos). grep complains about empty
-subexpression and exits with non-zero status, which is interpreted
-by configure as "not found". As a result, support for "-z combreloc"
-(HAVE_Z_COMBRELOC) is not detected, leading to link failure on SPARC.
-
- * configure.ac: Avoid empty subexpression in grep.
-
-Signed-off-by: Alexey Neyman <stilor@att.net>
----
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
-
-diff --git a/configure b/configure
-index eecd0ac..0118bd1 100755
---- a/configure
-+++ b/configure
-@@ -5804,7 +5804,7 @@ if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }
- then
-- if $READELF -S conftest.so | grep '\.rel\(a\|\)\.dyn' > /dev/null; then
-+ if $READELF -S conftest.so | grep '\.\(rel\|rela\)\.dyn' > /dev/null; then
- libc_cv_z_combreloc=yes
- else
- libc_cv_z_combreloc=no
-diff --git a/configure.ac b/configure.ac
-index 4a77411..19f6d87 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -1391,7 +1391,7 @@ dnl cross-platform since the gcc used can be a cross compiler. Without
- dnl introducing new options this is not easily doable. Instead use a tool
- dnl which always is cross-platform: readelf. To detect whether -z combreloc
- dnl look for a section named .rel.dyn.
-- if $READELF -S conftest.so | grep '\.rel\(a\|\)\.dyn' > /dev/null; then
-+ if $READELF -S conftest.so | grep '\.\(rel\|rela\)\.dyn' > /dev/null; then
- libc_cv_z_combreloc=yes
- else
- libc_cv_z_combreloc=no
---
-2.9.3
-
diff --git a/packages/glibc/2.24/910-typedef-caddr.patch b/packages/glibc/2.24/910-typedef-caddr.patch
deleted file mode 100644
index fc7979b..0000000
--- a/packages/glibc/2.24/910-typedef-caddr.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-diff -urN glibc-2.23-orig/posix/sys/types.h glibc-2.23/posix/sys/types.h
---- glibc-2.23-orig/posix/sys/types.h 2016-02-18 12:54:00.000000000 -0500
-+++ glibc-2.23/posix/sys/types.h 2017-01-06 11:40:05.842147165 -0500
-@@ -113,7 +113,10 @@
- #ifdef __USE_MISC
- # ifndef __daddr_t_defined
- typedef __daddr_t daddr_t;
-+# if ! defined(caddr_t) && ! defined(__caddr_t_defined)
- typedef __caddr_t caddr_t;
-+# define __caddr_t_defined
-+# endif
- # define __daddr_t_defined
- # endif
- #endif
-
diff --git a/packages/glibc/2.24/920-fix-rpc_parse-format.patch b/packages/glibc/2.24/920-fix-rpc_parse-format.patch
deleted file mode 100644
index 37e58da..0000000
--- a/packages/glibc/2.24/920-fix-rpc_parse-format.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-commit 5874510faaf3cbd0bb112aaacab9f225002beed1
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Tue Nov 8 23:44:51 2016 +0000
-
- Fix rpcgen buffer overrun (bug 20790).
-
- Building with GCC 7 produces an error building rpcgen:
-
- rpc_parse.c: In function 'get_prog_declaration':
- rpc_parse.c:543:25: error: may write a terminating nul past the end of the destination [-Werror=format-length=]
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ~~~~^
- rpc_parse.c:543:5: note: format output between 5 and 14 bytes into a destination of size 10
- sprintf (name, "%s%d", ARGNAME, num); /* default name of argument */
- ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
- That buffer overrun is for the case where the .x file declares a
- program with a million arguments. The strcpy two lines above can
- generate a buffer overrun much more simply for a long argument name.
-
- The limit on length of line read by rpcgen (MAXLINESIZE == 1024)
- provides a bound on the buffer size needed, so this patch just changes
- the buffer size to MAXLINESIZE to avoid both possible buffer
- overruns. A testcase is added that rpcgen does not crash with a
- 500-character argument name, where it previously crashed.
-
- It would not at all surprise me if there are many other ways of
- crashing rpcgen with either valid or invalid input; fuzz testing would
- likely find various such bugs, though I don't think they are that
- important to fix (rpcgen is not that likely to be used with untrusted
- .x files as input). (As well as fuzz-findable bugs there are probably
- also issues when various int variables get overflowed on very large
- input.) The test infrastructure for rpcgen-not-crashing tests would
- need extending if tests are to be added for cases where rpcgen should
- produce an error, as opposed to cases where it should succeed.
-
- Tested for x86_64 and x86.
-
- [BZ #20790]
- * sunrpc/rpc_parse.c (get_prog_declaration): Increase buffer size
- to MAXLINESIZE.
- * sunrpc/bug20790.x: New file.
- * sunrpc/Makefile [$(run-built-tests) = yes] (rpcgen-tests): New
- variable.
- [$(run-built-tests) = yes] (tests-special): Add $(rpcgen-tests).
- [$(run-built-tests) = yes] ($(rpcgen-tests)): New rule.
-
-diff --git a/sunrpc/rpc_parse.c b/sunrpc/rpc_parse.c
-index 1a1df6d8c2..505a6554cf 100644
---- a/sunrpc/rpc_parse.c
-+++ b/sunrpc/rpc_parse.c
-@@ -521,7 +521,7 @@ static void
- get_prog_declaration (declaration * dec, defkind dkind, int num /* arg number */ )
- {
- token tok;
-- char name[10]; /* argument name */
-+ char name[MAXLINESIZE]; /* argument name */
-
- if (dkind == DEF_PROGRAM)
- {
diff --git a/packages/glibc/2.24/930-explicit-boolean.patch b/packages/glibc/2.24/930-explicit-boolean.patch
deleted file mode 100644
index 780fae6..0000000
--- a/packages/glibc/2.24/930-explicit-boolean.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-commit e223d1fe72e820d96f43831412ab267a1ace04d0
-Author: steve ellcey-CA Eng-Software <sellcey@sellcey-thinkpad.caveonetworks.com>
-Date: Fri Oct 14 12:53:27 2016 -0700
-
- Fix warnings from latest GCC.
-
- * sysdeps/ieee754/dbl-64/e_pow.c (checkint) Make conditions explicitly
- boolean.
-
-diff --git a/sysdeps/ieee754/dbl-64/e_pow.c b/sysdeps/ieee754/dbl-64/e_pow.c
-index 663fa392c2..bd758b5979 100644
---- a/sysdeps/ieee754/dbl-64/e_pow.c
-+++ b/sysdeps/ieee754/dbl-64/e_pow.c
-@@ -466,15 +466,15 @@ checkint (double x)
- return (n & 1) ? -1 : 1; /* odd or even */
- if (k > 20)
- {
-- if (n << (k - 20))
-+ if (n << (k - 20) != 0)
- return 0; /* if not integer */
-- return (n << (k - 21)) ? -1 : 1;
-+ return (n << (k - 21) != 0) ? -1 : 1;
- }
- if (n)
- return 0; /*if not integer */
- if (k == 20)
- return (m & 1) ? -1 : 1;
-- if (m << (k + 12))
-+ if (m << (k + 12) != 0)
- return 0;
-- return (m << (k + 11)) ? -1 : 1;
-+ return (m << (k + 11) != 0) ? -1 : 1;
- }
diff --git a/packages/glibc/2.24/940-nis-bogus-conditional.patch b/packages/glibc/2.24/940-nis-bogus-conditional.patch
deleted file mode 100644
index 09b38cf..0000000
--- a/packages/glibc/2.24/940-nis-bogus-conditional.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-commit f88759ea9bd3c8d8fef28f123ba9767cb0e421a3
-Author: Joseph Myers <joseph@codesourcery.com>
-Date: Wed Dec 21 23:44:01 2016 +0000
-
- Fix nss_nisplus build with mainline GCC (bug 20978).
-
- glibc build with current mainline GCC fails because
- nis/nss_nisplus/nisplus-alias.c contains code
-
- if (name != NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
- }
-
- char buf[strlen (name) + 9 + tablename_len];
-
- producing an error about strlen being called on a pointer that is
- always NULL (and a subsequent use of that pointer with a %s format in
- snprintf).
-
- As Andreas noted, the bogus conditional comes from a 1997 change:
-
- - if (name == NULL || strlen(name) > 8)
- - return NSS_STATUS_NOTFOUND;
- - else
- + if (name != NULL || strlen(name) <= 8)
-
- So the intention is clearly to return an error for NULL name.
-
- This patch duly inverts the sense of the conditional. It fixes the
- build with GCC mainline, and passes usual glibc testsuite testing for
- x86_64. However, I have not tried any actual substantive nisplus
- testing, do not have an environment for such testing, and do not know
- whether it is possible that strlen (name) or tablename_len might be
- large so that the VLA for buf is actually a security issue. However,
- if it is a security issue, there are plenty of other similar instances
- in the nisplus code (that haven't been hidden by a bogus comparison
- with NULL) - and nis_table.c:__create_ib_request uses strdupa on the
- string passed to nis_list, so a local fix in the caller wouldn't
- suffice anyway (see bug 20987). (Calls to strdupa and other such
- macros that use alloca must be considered equally questionable
- regarding stack overflow issues as direct calls to alloca and VLA
- declarations.)
-
- [BZ #20978]
- * nis/nss_nisplus/nisplus-alias.c (_nss_nisplus_getaliasbyname_r):
- Compare name == NULL, not name != NULL.
-
-diff --git a/nis/nss_nisplus/nisplus-alias.c b/nis/nss_nisplus/nisplus-alias.c
-index 7f698b4e6d..cb5acce01d 100644
---- a/nis/nss_nisplus/nisplus-alias.c
-+++ b/nis/nss_nisplus/nisplus-alias.c
-@@ -291,7 +291,7 @@ _nss_nisplus_getaliasbyname_r (const char *name, struct aliasent *alias,
- return status;
- }
-
-- if (name != NULL)
-+ if (name == NULL)
- {
- *errnop = EINVAL;
- return NSS_STATUS_UNAVAIL;
diff --git a/packages/glibc/2.25/110-sh-fix-gcc6.patch b/packages/glibc/2.25/0000-sh-fix-gcc6.patch
index cacf390..ef9e31c 100644
--- a/packages/glibc/2.25/110-sh-fix-gcc6.patch
+++ b/packages/glibc/2.25/0000-sh-fix-gcc6.patch
@@ -7,14 +7,12 @@ Subject: [PATCH] sh: conditional is false in dl-conflict.c
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- sysdeps/sh/dl-machine.h | 2 +-
+ sysdeps/sh/dl-machine.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
-diff --git a/sysdeps/sh/dl-machine.h b/sysdeps/sh/dl-machine.h
-index 449deea..2b468af 100644
--- a/sysdeps/sh/dl-machine.h
+++ b/sysdeps/sh/dl-machine.h
-@@ -389,7 +389,7 @@ elf_machine_rela (struct link_map *map, const Elf32_Rela *reloc,
+@@ -389,7 +389,7 @@
break;
case R_SH_DIR32:
{
@@ -23,6 +21,3 @@ index 449deea..2b468af 100644
/* This is defined in rtld.c, but nowhere in the static
libc.a; make the reference weak so static programs can
still link. This declaration cannot be done when
---
-2.9.3
-
diff --git a/packages/glibc/2.24/120-Fix-build-with-enable-static-nss.patch b/packages/glibc/2.25/0001-Fix-build-with-enable-static-nss.patch
index 59ab087..32c1ca2 100644
--- a/packages/glibc/2.24/120-Fix-build-with-enable-static-nss.patch
+++ b/packages/glibc/2.25/0001-Fix-build-with-enable-static-nss.patch
@@ -8,15 +8,12 @@ Subject: [PATCH] Fix build with --enable-static-nss
Signed-off-by: Alexey Neyman <stilor@att.net>
---
- ChangeLog | 5 +++++
- nss/nsswitch.c | 2 +-
- 2 files changed, 6 insertions(+), 1 deletion(-)
+ nss/nsswitch.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
-diff --git a/nss/nsswitch.c b/nss/nsswitch.c
-index 0a65f6a..8f31658 100644
--- a/nss/nsswitch.c
+++ b/nss/nsswitch.c
-@@ -94,7 +94,7 @@ static name_database *service_table;
+@@ -94,7 +94,7 @@
static name_database_entry *defconfig_entries;
@@ -25,6 +22,3 @@ index 0a65f6a..8f31658 100644
/* Nonzero if this is the nscd process. */
static bool is_nscd;
/* The callback passed to the init functions when nscd is used. */
---
-2.9.3
-
diff --git a/packages/glibc/2.25/0002-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.25/0002-Fix-combreloc-test-BSD-grep.patch
new file mode 100644
index 0000000..43a2b67
--- /dev/null
+++ b/packages/glibc/2.25/0002-Fix-combreloc-test-BSD-grep.patch
@@ -0,0 +1,41 @@
+From 61d5f9c09b3157db76bd1a393e248c262a8d9dd4 Mon Sep 17 00:00:00 2001
+From: Alexey Neyman <stilor@att.net>
+Date: Wed, 8 Mar 2017 14:31:10 -0800
+Subject: [PATCH] Fix combreloc test with BSD grep
+
+The test for "-z combreloc" fails when cross-compiling on a machine
+that uses BSD grep (e.g. on macos). grep complains about empty
+subexpression and exits with non-zero status, which is interpreted
+by configure as "not found". As a result, support for "-z combreloc"
+(HAVE_Z_COMBRELOC) is not detected, leading to link failure on SPARC.
+
+ * configure.ac: Avoid empty subexpression in grep.
+
+Signed-off-by: Alexey Neyman <stilor@att.net>
+---
+ configure | 2 +-
+ configure.ac | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+--- a/configure
++++ b/configure
+@@ -5804,7 +5804,7 @@
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; }
+ then
+- if $READELF -S conftest.so | grep '\.rel\(a\|\)\.dyn' > /dev/null; then
++ if $READELF -S conftest.so | grep '\.\(rel\|rela\)\.dyn' > /dev/null; then
+ libc_cv_z_combreloc=yes
+ else
+ libc_cv_z_combreloc=no
+--- a/configure.ac
++++ b/configure.ac
+@@ -1391,7 +1391,7 @@
+ dnl introducing new options this is not easily doable. Instead use a tool
+ dnl which always is cross-platform: readelf. To detect whether -z combreloc
+ dnl look for a section named .rel.dyn.
+- if $READELF -S conftest.so | grep '\.rel\(a\|\)\.dyn' > /dev/null; then
++ if $READELF -S conftest.so | grep '\.\(rel\|rela\)\.dyn' > /dev/null; then
+ libc_cv_z_combreloc=yes
+ else
+ libc_cv_z_combreloc=no
diff --git a/packages/glibc/2.25/0003-typedef-caddr.patch b/packages/glibc/2.25/0003-typedef-caddr.patch
new file mode 100644
index 0000000..980939b
--- /dev/null
+++ b/packages/glibc/2.25/0003-typedef-caddr.patch
@@ -0,0 +1,17 @@
+---
+ posix/sys/types.h | 3 +++
+ 1 file changed, 3 insertions(+)
+
+--- a/posix/sys/types.h
++++ b/posix/sys/types.h
+@@ -113,7 +113,10 @@
+ #ifdef __USE_MISC
+ # ifndef __daddr_t_defined
+ typedef __daddr_t daddr_t;
++# if ! defined(caddr_t) && ! defined(__caddr_t_defined)
+ typedef __caddr_t caddr_t;
++# define __caddr_t_defined
++# endif
+ # define __daddr_t_defined
+ # endif
+ #endif
diff --git a/packages/glibc/2.25/960-sh4-trap-divdi3.patch b/packages/glibc/2.25/0004-sh4-trap-divdi3.patch
index 99fad46..33b6b15 100644
--- a/packages/glibc/2.25/960-sh4-trap-divdi3.patch
+++ b/packages/glibc/2.25/0004-sh4-trap-divdi3.patch
@@ -80,9 +80,20 @@ Date: Wed Mar 15 15:44:59 2017 -0300
* sysdeps/wordsize-32/symbol-hacks.h: Definitions move to ...
* sysdeps/wordsize-32/divdi3-symbol-hacks.h: ... here.
-diff --git a/sysdeps/i386/symbol-hacks.h b/sysdeps/i386/symbol-hacks.h
-new file mode 100644
-index 0000000000..36a13c83f7
+---
+ sysdeps/i386/symbol-hacks.h | 21 ++++++++++++++
+ sysdeps/m68k/symbol-hacks.h | 21 ++++++++++++++
+ sysdeps/powerpc/powerpc32/symbol-hacks.h | 21 ++++++++++++++
+ sysdeps/s390/s390-32/symbol-hacks.h | 21 ++++++++++++++
+ sysdeps/unix/sysv/linux/i386/Makefile | 5 +++
+ sysdeps/unix/sysv/linux/m68k/Makefile | 5 +++
+ sysdeps/unix/sysv/linux/powerpc/powerpc32/Makefile | 8 +++++
+ sysdeps/unix/sysv/linux/s390/s390-32/Makefile | 8 +++++
+ sysdeps/wordsize-32/Makefile | 7 ----
+ sysdeps/wordsize-32/divdi3-symbol-hacks.h | 31 +++++++++++++++++++++
+ sysdeps/wordsize-32/symbol-hacks.h | 31 ---------------------
+ 11 files changed, 141 insertions(+), 38 deletions(-)
+
--- /dev/null
+++ b/sysdeps/i386/symbol-hacks.h
@@ -0,0 +1,21 @@
@@ -107,9 +118,6 @@ index 0000000000..36a13c83f7
+#include <sysdeps/wordsize-32/divdi3-symbol-hacks.h>
+
+#include_next "symbol-hacks.h"
-diff --git a/sysdeps/m68k/symbol-hacks.h b/sysdeps/m68k/symbol-hacks.h
-new file mode 100644
-index 0000000000..e449d29810
--- /dev/null
+++ b/sysdeps/m68k/symbol-hacks.h
@@ -0,0 +1,21 @@
@@ -134,9 +142,6 @@ index 0000000000..e449d29810
+#include <sysdeps/wordsize-32/divdi3-symbol-hacks.h>
+
+#include_next "symbol-hacks.h"
-diff --git a/sysdeps/powerpc/powerpc32/symbol-hacks.h b/sysdeps/powerpc/powerpc32/symbol-hacks.h
-new file mode 100644
-index 0000000000..dbb3141621
--- /dev/null
+++ b/sysdeps/powerpc/powerpc32/symbol-hacks.h
@@ -0,0 +1,21 @@
@@ -161,9 +166,6 @@ index 0000000000..dbb3141621
+#include <sysdeps/wordsize-32/divdi3-symbol-hacks.h>
+
+#include_next "symbol-hacks.h"
-diff --git a/sysdeps/s390/s390-32/symbol-hacks.h b/sysdeps/s390/s390-32/symbol-hacks.h
-new file mode 100644
-index 0000000000..585c42365a
--- /dev/null
+++ b/sysdeps/s390/s390-32/symbol-hacks.h
@@ -0,0 +1,21 @@
@@ -188,11 +190,9 @@ index 0000000000..585c42365a
+#include <sysdeps/wordsize-32/divdi3-symbol-hacks.h>
+
+#include_next "symbol-hacks.h"
-diff --git a/sysdeps/unix/sysv/linux/i386/Makefile b/sysdeps/unix/sysv/linux/i386/Makefile
-index 6aac0dfe15..4080b8c966 100644
--- a/sysdeps/unix/sysv/linux/i386/Makefile
+++ b/sysdeps/unix/sysv/linux/i386/Makefile
-@@ -26,6 +26,11 @@ endif
+@@ -55,6 +55,11 @@
ifeq ($(subdir),csu)
sysdep-dl-routines += sysdep
@@ -204,11 +204,9 @@ index 6aac0dfe15..4080b8c966 100644
endif
ifeq ($(subdir),nptl)
-diff --git a/sysdeps/unix/sysv/linux/m68k/Makefile b/sysdeps/unix/sysv/linux/m68k/Makefile
-index 5c50ce6927..ce1f696a6f 100644
--- a/sysdeps/unix/sysv/linux/m68k/Makefile
+++ b/sysdeps/unix/sysv/linux/m68k/Makefile
-@@ -4,6 +4,11 @@ m68k-syntax-flag = -DMOTOROLA_SYNTAX
+@@ -4,6 +4,11 @@
ifeq ($(subdir),csu)
sysdep_routines += m68k-helpers
@@ -220,8 +218,6 @@ index 5c50ce6927..ce1f696a6f 100644
endif
ifeq ($(subdir),misc)
-diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/Makefile b/sysdeps/unix/sysv/linux/powerpc/powerpc32/Makefile
-index 3d6c150582..1f45659ed1 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/Makefile
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/Makefile
@@ -1,2 +1,10 @@
@@ -235,11 +231,9 @@ index 3d6c150582..1f45659ed1 100644
+CPPFLAGS-divdi3.c = -Din_divdi3_c
+endif
+endif
-diff --git a/sysdeps/unix/sysv/linux/s390/s390-32/Makefile b/sysdeps/unix/sysv/linux/s390/s390-32/Makefile
-index da3b3c76b4..fd8cf92633 100644
--- a/sysdeps/unix/sysv/linux/s390/s390-32/Makefile
+++ b/sysdeps/unix/sysv/linux/s390/s390-32/Makefile
-@@ -21,3 +21,11 @@ endif
+@@ -21,3 +21,11 @@
ifeq ($(subdir),stdlib)
sysdep_routines += __makecontext_ret
endif
@@ -251,9 +245,6 @@ index da3b3c76b4..fd8cf92633 100644
+CPPFLAGS-divdi3.c = -Din_divdi3_c
+endif
+endif
-diff --git a/sysdeps/wordsize-32/Makefile b/sysdeps/wordsize-32/Makefile
-deleted file mode 100644
-index 82beac44ed..0000000000
--- a/sysdeps/wordsize-32/Makefile
+++ /dev/null
@@ -1,7 +0,0 @@
@@ -264,9 +255,6 @@ index 82beac44ed..0000000000
-CPPFLAGS-divdi3.c = -Din_divdi3_c
-endif
-endif
-diff --git a/sysdeps/wordsize-32/divdi3-symbol-hacks.h b/sysdeps/wordsize-32/divdi3-symbol-hacks.h
-new file mode 100644
-index 0000000000..6c90cb796d
--- /dev/null
+++ b/sysdeps/wordsize-32/divdi3-symbol-hacks.h
@@ -0,0 +1,31 @@
@@ -301,9 +289,6 @@ index 0000000000..6c90cb796d
+asm ("__moddi3 = __moddi3_internal");
+asm ("__umoddi3 = __umoddi3_internal");
+#endif
-diff --git a/sysdeps/wordsize-32/symbol-hacks.h b/sysdeps/wordsize-32/symbol-hacks.h
-deleted file mode 100644
-index 0aec1e0b97..0000000000
--- a/sysdeps/wordsize-32/symbol-hacks.h
+++ /dev/null
@@ -1,31 +0,0 @@
diff --git a/packages/glibc/2.25/961-sparc-extra-plt-call.patch b/packages/glibc/2.25/0005-sparc-extra-plt-call.patch
index 3781cf0..7b01b83 100644
--- a/packages/glibc/2.25/961-sparc-extra-plt-call.patch
+++ b/packages/glibc/2.25/0005-sparc-extra-plt-call.patch
@@ -22,11 +22,16 @@ Date: Thu Mar 16 09:15:57 2017 -0300
* sysdeps/sparc/sparc32/sparcv9/udiv.S (.udiv): Likewise.
* sysdeps/sparc/sparc32/udiv.S (.udiv): Likewise.
-diff --git a/sysdeps/sparc/sparc32/Makefile b/sysdeps/sparc/sparc32/Makefile
-index da205898cf..14d6e03c6f 100644
+---
+ sysdeps/sparc/sparc32/Makefile | 6 ++++++
+ sysdeps/sparc/sparc32/sparcv8/udiv.S | 1 +
+ sysdeps/sparc/sparc32/sparcv9/udiv.S | 1 +
+ sysdeps/sparc/sparc32/udiv.S | 1 +
+ 4 files changed, 9 insertions(+)
+
--- a/sysdeps/sparc/sparc32/Makefile
+++ b/sysdeps/sparc/sparc32/Makefile
-@@ -47,3 +47,9 @@ $(divrem:%=$(sysdep_dir)/sparc/sparc32/%.S): $(sysdep_dir)/sparc/sparc32/divrem.
+@@ -47,3 +47,9 @@
mv -f $@-tmp $@
sysdep-realclean := $(sysdep-realclean) $(divrem:%=sysdeps/sparc/sparc32/%.S)
@@ -36,29 +41,23 @@ index da205898cf..14d6e03c6f 100644
+# the exported libc one to __wrap_.udiv and use linker option --wrap to make any
+# call to .udiv to call the wrapper symbol.
+libc.so-gnulib += -Wl,--wrap=.udiv
-diff --git a/sysdeps/sparc/sparc32/sparcv8/udiv.S b/sysdeps/sparc/sparc32/sparcv8/udiv.S
-index d71954351e..e9cab4e4ef 100644
--- a/sysdeps/sparc/sparc32/sparcv8/udiv.S
+++ b/sysdeps/sparc/sparc32/sparcv8/udiv.S
-@@ -13,3 +13,4 @@ ENTRY(.udiv)
+@@ -13,3 +13,4 @@
udiv %o0, %o1, %o0
END(.udiv)
+strong_alias (.udiv, __wrap_.udiv)
-diff --git a/sysdeps/sparc/sparc32/sparcv9/udiv.S b/sysdeps/sparc/sparc32/sparcv9/udiv.S
-index de79899756..368f85ede2 100644
--- a/sysdeps/sparc/sparc32/sparcv9/udiv.S
+++ b/sysdeps/sparc/sparc32/sparcv9/udiv.S
-@@ -15,3 +15,4 @@ ENTRY(.udiv)
+@@ -15,3 +15,4 @@
udiv %o0, %o1, %o0
END(.udiv)
+strong_alias (.udiv, __wrap_.udiv)
-diff --git a/sysdeps/sparc/sparc32/udiv.S b/sysdeps/sparc/sparc32/udiv.S
-index 8dfff66158..ade0afdf40 100644
--- a/sysdeps/sparc/sparc32/udiv.S
+++ b/sysdeps/sparc/sparc32/udiv.S
-@@ -344,3 +344,4 @@ LOC(got_result):
+@@ -344,3 +344,4 @@
mov %o2, %o0
END(.udiv)
diff --git a/packages/glibc/2.25/997-regexp-common.patch b/packages/glibc/2.25/0006-regexp-common.patch
index 7764c99..89e8371 100644
--- a/packages/glibc/2.25/997-regexp-common.patch
+++ b/packages/glibc/2.25/0006-regexp-common.patch
@@ -32,8 +32,10 @@ Date: Fri Jun 23 14:38:46 2017 -0700
(loc2): Likewise.
(locs): Likewise.
-diff --git a/misc/regexp.c b/misc/regexp.c
-index 19d76c0c37..eaea7c3b89 100644
+---
+ misc/regexp.c | 9 +++++----
+ 1 file changed, 5 insertions(+), 4 deletions(-)
+
--- a/misc/regexp.c
+++ b/misc/regexp.c
@@ -29,14 +29,15 @@
diff --git a/packages/glibc/2.25/140-Fix-combreloc-test-BSD-grep.patch b/packages/glibc/2.25/140-Fix-combreloc-test-BSD-grep.patch
deleted file mode 100644
index fdc3a60..0000000
--- a/packages/glibc/2.25/140-Fix-combreloc-test-BSD-grep.patch
+++ /dev/null
@@ -1,49 +0,0 @@
-From 61d5f9c09b3157db76bd1a393e248c262a8d9dd4 Mon Sep 17 00:00:00 2001
-From: Alexey Neyman <stilor@att.net>
-Date: Wed, 8 Mar 2017 14:31:10 -0800
-Subject: [PATCH] Fix combreloc test with BSD grep
-
-The test for "-z combreloc" fails when cross-compiling on a machine
-that uses BSD grep (e.g. on macos). grep complains about empty
-subexpression and exits with non-zero status, which is interpreted
-by configure as "not found". As a result, support for "-z combreloc"
-(HAVE_Z_COMBRELOC) is not detected, leading to link failure on SPARC.
-
- * configure.ac: Avoid empty subexpression in grep.
-
-Signed-off-by: Alexey Neyman <stilor@att.net>
----
- ChangeLog | 5 +++++
- configure | 2 +-
- configure.ac | 2 +-
- 3 files changed, 7 insertions(+), 2 deletions(-)
-
-diff --git a/configure b/configure
-index eecd0ac..0118bd1 100755
---- a/configure
-+++ b/configure
-@@ -5804,7 +5804,7 @@ if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }
- then
-- if $READELF -S conftest.so | grep '\.rel\(a\|\)\.dyn' > /dev/null; then
-+ if $READELF -S conftest.so | grep '\.\(rel\|rela\)\.dyn' > /dev/null; then
- libc_cv_z_combreloc=yes
- else
- libc_cv_z_combreloc=no
-diff --git a/configure.ac b/configure.ac
-index 4a77411..19f6d87 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -1391,7 +1391,7 @@ dnl cross-platform since the gcc used can be a cross compiler. Without
- dnl introducing new options this is not easily doable. Instead use a tool
- dnl which always is cross-platform: readelf. To detect whether -z combreloc
- dnl look for a section named .rel.dyn.
-- if $READELF -S conftest.so | grep '\.rel\(a\|\)\.dyn' > /dev/null; then
-+ if $READELF -S conftest.so | grep '\.\(rel\|rela\)\.dyn' > /dev/null; then
- libc_cv_z_combreloc=yes
- else
- libc_cv_z_combreloc=no
---
-2.9.3
-
diff --git a/packages/glibc/2.25/910-typedef-caddr.patch b/packages/glibc/2.25/910-typedef-caddr.patch
deleted file mode 100644
index fc7979b..0000000
--- a/packages/glibc/2.25/910-typedef-caddr.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-diff -urN glibc-2.23-orig/posix/sys/types.h glibc-2.23/posix/sys/types.h
---- glibc-2.23-orig/posix/sys/types.h 2016-02-18 12:54:00.000000000 -0500
-+++ glibc-2.23/posix/sys/types.h 2017-01-06 11:40:05.842147165 -0500
-@@ -113,7 +113,10 @@
- #ifdef __USE_MISC
- # ifndef __daddr_t_defined
- typedef __daddr_t daddr_t;
-+# if ! defined(caddr_t) && ! defined(__caddr_t_defined)
- typedef __caddr_t caddr_t;
-+# define __caddr_t_defined
-+# endif
- # define __daddr_t_defined
- # endif
- #endif
-
diff --git a/packages/glibc/2.26/0000-typedef-caddr.patch b/packages/glibc/2.26/0000-typedef-caddr.patch
new file mode 100644
index 0000000..980939b
--- /dev/null
+++ b/packages/glibc/2.26/0000-typedef-caddr.patch
@@ -0,0 +1,17 @@
+---
+ posix/sys/types.h | 3 +++
+ 1 file changed, 3 insertions(+)
+
+--- a/posix/sys/types.h
++++ b/posix/sys/types.h
+@@ -113,7 +113,10 @@
+ #ifdef __USE_MISC
+ # ifndef __daddr_t_defined
+ typedef __daddr_t daddr_t;
++# if ! defined(caddr_t) && ! defined(__caddr_t_defined)
+ typedef __caddr_t caddr_t;
++# define __caddr_t_defined
++# endif
+ # define __daddr_t_defined
+ # endif
+ #endif
diff --git a/packages/glibc/2.26/910-typedef-caddr.patch b/packages/glibc/2.26/910-typedef-caddr.patch
deleted file mode 100644
index fc7979b..0000000
--- a/packages/glibc/2.26/910-typedef-caddr.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-diff -urN glibc-2.23-orig/posix/sys/types.h glibc-2.23/posix/sys/types.h
---- glibc-2.23-orig/posix/sys/types.h 2016-02-18 12:54:00.000000000 -0500
-+++ glibc-2.23/posix/sys/types.h 2017-01-06 11:40:05.842147165 -0500
-@@ -113,7 +113,10 @@
- #ifdef __USE_MISC
- # ifndef __daddr_t_defined
- typedef __daddr_t daddr_t;
-+# if ! defined(caddr_t) && ! defined(__caddr_t_defined)
- typedef __caddr_t caddr_t;
-+# define __caddr_t_defined
-+# endif
- # define __daddr_t_defined
- # endif
- #endif
-