]> git.pld-linux.org Git - packages/glibc.git/blobdiff - glibc.spec
- obsolete
[packages/glibc.git] / glibc.spec
index 17e9edde4e3e8d9696663de020b8e7f616230943..383f60d590b5f5f71e6d3920ab9184711b3cc26c 100644 (file)
@@ -48,7 +48,7 @@ Summary(tr):  GNU libc
 Summary(uk):   GNU libc ×ÅÒÓ¦§ 2.3
 Name:          glibc
 Version:       2.5
-Release:       0.3
+Release:       0.5
 Epoch:         6
 License:       LGPL
 Group:         Libraries
@@ -64,17 +64,17 @@ Source5:    http://qboosh.cs.net.pl/man/%{name}-man-pages.tar.bz2
 # Source5-md5: f464eadf3cf06761f65639e44a179e6b
 Source6:       %{name}-localedb-gen
 Source7:       %{name}-LD-path.c
-Patch0:                %{name}-info.patch
+Patch0:                %{name}-cvs20070210.patch
 Patch1:                %{name}-pl.po-update.patch
 Patch2:                %{name}-pld.patch
 Patch3:                %{name}-crypt-blowfish.patch
 Patch4:                %{name}-alpha-ev6-opcodes.patch
 Patch5:                %{name}-sparc-softfp-gcc.patch
 Patch6:                %{name}-paths.patch
-Patch7:                %{name}-sparc64-fixes.patch
+
 Patch8:                %{name}-missing-nls.patch
 Patch9:                %{name}-java-libc-wait.patch
-
+Patch10:       %{name}-info.patch
 Patch11:       %{name}-no_opt_override.patch
 Patch12:       %{name}-includes.patch
 Patch13:       %{name}-ppc-inline-fsqrt.patch
@@ -833,16 +833,17 @@ Zabawka.
 %setup -q -a1
 ln -s glibc-libidn-%{version} libidn
 %patch0 -p1
-%patch1 -p1
+# needs update/drop
+#%patch1 -p1
 %patch2 -p1
 %patch3 -p1
 %patch4 -p1
 %patch5 -p1
 %patch6 -p1
-%patch7 -p1
+
 %patch8 -p1
 %patch9 -p1
-
+%patch10 -p1
 %patch11 -p1
 %patch12 -p1
 %patch13 -p1
@@ -866,7 +867,545 @@ chmod +x scripts/cpp
 cd nptl/sysdeps/i386 && ln -s i686 i786 && cd -
 cd nptl/sysdeps/unix/sysv/linux/i386 && ln -s i686 i786 && cd -
 
+# Hack till glibc-kernheaders get updated, argh
+%define min_kernel_ver %(echo %{min_kernel} | cut -f 1 -d .)
+%define min_kernel_patc %(echo %{min_kernel} | cut -f 2 -d .)
+%define min_kernel_subl        %(echo %{min_kernel} | cut -f 3 -d .)
+%define min_kernel_code        %(expr %{min_kernel_ver} \\* 65536 + %{min_kernel_patc} \\* 256 + %{min_kernel_subl})
+mkdir -p override_headers/linux
+cat > override_headers/linux/version.h <<EOF
+#define UTS_RELEASE "%{min_kernel}"
+#define LINUX_VERSION_CODE %{min_kernel_code}
+#define KERNEL_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c))
+EOF
+mkdir -p override_headers/asm
+cat > override_headers/asm/unistd.h <<EOF
+#ifndef _HACK_ASM_UNISTD_H
+#include_next <asm/unistd.h>
+%ifarch alpha
+#ifndef __NR_stat64
+#define __NR_stat64                    425
+#define __NR_lstat64                   426
+#define __NR_fstat64                   427
+#endif
+#ifndef __NR_mq_open
+#define __NR_mq_open                   432
+#define __NR_mq_unlink                 433
+#define __NR_mq_timedsend              434
+#define __NR_mq_timedreceive           435
+#define __NR_mq_notify                 436
+#define __NR_mq_getsetattr             437
+#endif
+#ifndef __NR_waitid
+#define __NR_waitid                    438
+#endif
+#ifndef __NR_inotify_init
+#define __NR_inotify_init              444
+#define __NR_inotify_add_watch         445
+#define __NR_inotify_rm_watch          446
+#endif
+%endif
+%ifarch %{ix86}
+#ifndef __NR_mq_open
+#define __NR_mq_open           277
+#define __NR_mq_unlink         (__NR_mq_open+1)
+#define __NR_mq_timedsend      (__NR_mq_open+2)
+#define __NR_mq_timedreceive   (__NR_mq_open+3)
+#define __NR_mq_notify         (__NR_mq_open+4)
+#define __NR_mq_getsetattr     (__NR_mq_open+5)
+#endif
+#ifndef __NR_waitid
+#define __NR_waitid            284
+#endif
+#ifndef __NR_inotify_init
+#define __NR_inotify_init      291
+#define __NR_inotify_add_watch 292
+#define __NR_inotify_rm_watch  293
+#endif
+#ifndef __NR_openat
+#define __NR_openat            295
+#define __NR_mkdirat           296
+#define __NR_mknodat           297
+#define __NR_fchownat          298
+#define __NR_futimesat         299
+#define __NR_unlinkat          301
+#define __NR_renameat          302
+#define __NR_linkat            303
+#define __NR_symlinkat         304
+#define __NR_readlinkat                305
+#define __NR_fchmodat          306
+#define __NR_faccessat         307
+#endif
+#ifndef __NR_fstatat64
+#define __NR_fstatat64         300
+#endif
+#ifndef __NR_pselect6
+#define __NR_pselect6          308
+#define __NR_ppoll             309
+#endif
+#ifndef __NR_unshare
+#define __NR_unshare           310
+#endif
+#ifndef __NR_set_robust_list
+#define __NR_set_robust_list   311
+#define __NR_get_robust_list   312
+#endif
+#ifndef __NR_splice
+#define __NR_splice            313
+#endif
+#ifndef __NR_sync_file_range
+#define __NR_sync_file_range   314
+#endif
+#ifndef __NR_tee
+#define __NR_tee               315
+#endif
+#ifndef __NR_vmsplice
+#define __NR_vmsplice          316
+#endif
+%endif
+%ifarch ia64
+#ifndef __NR_timer_create
+#define __NR_timer_create      1248
+#define __NR_timer_settime     1249
+#define __NR_timer_gettime     1250
+#define __NR_timer_getoverrun  1251
+#define __NR_timer_delete      1252
+#define __NR_clock_settime     1253
+#define __NR_clock_gettime     1254
+#define __NR_clock_getres      1255
+#define __NR_clock_nanosleep   1256
+#endif
+#ifndef __NR_mq_open
+#define __NR_mq_open           1262
+#define __NR_mq_unlink         1263
+#define __NR_mq_timedsend      1264
+#define __NR_mq_timedreceive   1265
+#define __NR_mq_notify         1266
+#define __NR_mq_getsetattr     1267
+#endif
+#ifndef __NR_waitid
+#define __NR_waitid            1270
+#endif
+#ifndef __NR_inotify_init
+#define __NR_inotify_init      1277
+#define __NR_inotify_add_watch 1278
+#define __NR_inotify_rm_watch  1279
+#endif
+#ifndef __NR_openat
+#define __NR_openat            1281
+#define __NR_mkdirat           1282
+#define __NR_mknodat           1283
+#define __NR_fchownat          1284
+#define __NR_futimesat         1285
+#define __NR_newfstatat                1286
+#define __NR_unlinkat          1287
+#define __NR_renameat          1288
+#define __NR_linkat            1289
+#define __NR_symlinkat         1290
+#define __NR_readlinkat                1291
+#define __NR_fchmodat          1292
+#define __NR_faccessat         1293
+#endif
+#if 0
+#ifndef __NR_pselect6
+#define __NR_pselect6          1294
+#define __NR_ppoll             1295
+#endif
+#endif
+#ifndef __NR_unshare
+#define __NR_unshare           1296
+#endif
+#ifndef __NR_splice
+#define __NR_splice            1297
+#endif
+#ifndef __NR_set_robust_list
+#define __NR_set_robust_list   1298
+#define __NR_get_robust_list   1299
+#endif
+#ifndef __NR_sync_file_range
+#define __NR_sync_file_range   1300
+#endif
+#ifndef __NR_tee
+#define __NR_tee               1301
+#endif
+#ifndef __NR_vmsplice
+#define __NR_vmsplice          1302
+#endif
+%endif
+%ifarch ppc
+#ifndef __NR_utimes
+#define __NR_utimes            251
+#endif
+#ifndef __NR_statfs64
+#define __NR_statfs64          252
+#define __NR_fstatfs64         253
+#endif
+#ifndef __NR_fadvise64_64
+#define __NR_fadvise64_64      254
+#endif
+#ifndef __NR_mq_open
+#define __NR_mq_open           262
+#define __NR_mq_unlink         263
+#define __NR_mq_timedsend      264
+#define __NR_mq_timedreceive   265
+#define __NR_mq_notify         266
+#define __NR_mq_getsetattr     267
+#endif
+#ifndef __NR_waitid
+#define __NR_waitid            272
+#endif
+#ifndef __NR_inotify_init
+#define __NR_inotify_init      275
+#define __NR_inotify_add_watch 276
+#define __NR_inotify_rm_watch  277
+#endif
+#ifndef __NR_pselect6
+#define __NR_pselect6          280
+#define __NR_ppoll             281
+#endif
+#ifndef __NR_unshare
+#define __NR_unshare           282
+#endif
+#ifndef __NR_splice
+#define __NR_splice            283
+#endif
+#ifndef __NR_tee
+#define __NR_tee               284
+#endif
+#ifndef __NR_vmsplice
+#define __NR_vmsplice          285
+#endif
+#ifndef __NR_openat
+#define __NR_openat            286
+#define __NR_mkdirat           287
+#define __NR_mknodat           288
+#define __NR_fchownat          289
+#define __NR_futimesat         290
+#define __NR_fstatat64         291
+#define __NR_unlinkat          292
+#define __NR_renameat          293
+#define __NR_linkat            294
+#define __NR_symlinkat         295
+#define __NR_readlinkat                296
+#define __NR_fchmodat          297
+#define __NR_faccessat         298
+#endif
+%endif
+%ifarch ppc64
+#ifndef __NR_utimes
+#define __NR_utimes            251
+#endif
+#ifndef __NR_mq_open
+#define __NR_mq_open           262
+#define __NR_mq_unlink         263
+#define __NR_mq_timedsend      264
+#define __NR_mq_timedreceive   265
+#define __NR_mq_notify         266
+#define __NR_mq_getsetattr     267
+#endif
+#ifndef __NR_waitid
+#define __NR_waitid            272
+#endif
+#ifndef __NR_inotify_init
+#define __NR_inotify_init      275
+#define __NR_inotify_add_watch 276
+#define __NR_inotify_rm_watch  277
+#endif
+#ifndef __NR_pselect6
+#define __NR_pselect6          280
+#define __NR_ppoll             281
+#endif
+#ifndef __NR_unshare
+#define __NR_unshare           282
+#endif
+#ifndef __NR_splice
+#define __NR_splice            283
+#endif
+#ifndef __NR_tee
+#define __NR_tee               284
+#endif
+#ifndef __NR_vmsplice
+#define __NR_vmsplice          285
+#endif
+#ifndef __NR_openat
+#define __NR_openat            286
+#define __NR_mkdirat           287
+#define __NR_mknodat           288
+#define __NR_fchownat          289
+#define __NR_futimesat         290
+#define __NR_newfstatat                291
+#define __NR_unlinkat          292
+#define __NR_renameat          293
+#define __NR_linkat            294
+#define __NR_symlinkat         295
+#define __NR_readlinkat                296
+#define __NR_fchmodat          297
+#define __NR_faccessat         298
+#endif
+%endif
+%ifarch s390
+#ifndef __NR_timer_create
+#define __NR_timer_create      254
+#define __NR_timer_settime     (__NR_timer_create+1)
+#define __NR_timer_gettime     (__NR_timer_create+2)
+#define __NR_timer_getoverrun  (__NR_timer_create+3)
+#define __NR_timer_delete      (__NR_timer_create+4)
+#define __NR_clock_settime     (__NR_timer_create+5)
+#define __NR_clock_gettime     (__NR_timer_create+6)
+#define __NR_clock_getres      (__NR_timer_create+7)
+#define __NR_clock_nanosleep   (__NR_timer_create+8)
+#endif
+#ifndef __NR_fadvise64_64
+#define __NR_fadvise64_64      264
+#endif
+#ifndef __NR_statfs64
+#define __NR_statfs64          265
+#define __NR_fstatfs64         266
+#endif
+#ifndef __NR_mq_open
+#define __NR_mq_open           271
+#define __NR_mq_unlink         272
+#define __NR_mq_timedsend      273
+#define __NR_mq_timedreceive   274
+#define __NR_mq_notify         275
+#define __NR_mq_getsetattr     276
+#endif
+#ifndef __NR_waitid
+#define __NR_waitid            281
+#endif
+#ifndef __NR_inotify_init
+#define __NR_inotify_init      284
+#define __NR_inotify_add_watch 285
+#define __NR_inotify_rm_watch  286
+#endif
+#ifndef __NR_openat
+#define __NR_openat            288
+#define __NR_mkdirat           289
+#define __NR_mknodat           290
+#define __NR_fchownat          291
+#define __NR_futimesat         292
+#define __NR_fstatat64         293
+#define __NR_unlinkat          294
+#define __NR_renameat          295
+#define __NR_linkat            296
+#define __NR_symlinkat         297
+#define __NR_readlinkat                298
+#define __NR_fchmodat          299
+#define __NR_faccessat         300
+#endif
+#ifndef __NR_pselect6
+#define __NR_pselect6          301
+#define __NR_ppoll             302
+#endif
+#ifndef __NR_unshare
+#define __NR_unshare           303
+#endif
+%endif
+%ifarch s390x
+#ifndef __NR_timer_create
+#define __NR_timer_create      254
+#define __NR_timer_settime     (__NR_timer_create+1)
+#define __NR_timer_gettime     (__NR_timer_create+2)
+#define __NR_timer_getoverrun  (__NR_timer_create+3)
+#define __NR_timer_delete      (__NR_timer_create+4)
+#define __NR_clock_settime     (__NR_timer_create+5)
+#define __NR_clock_gettime     (__NR_timer_create+6)
+#define __NR_clock_getres      (__NR_timer_create+7)
+#define __NR_clock_nanosleep   (__NR_timer_create+8)
+#endif
+#ifndef __NR_mq_open
+#define __NR_mq_open           271
+#define __NR_mq_unlink         272
+#define __NR_mq_timedsend      273
+#define __NR_mq_timedreceive   274
+#define __NR_mq_notify         275
+#define __NR_mq_getsetattr     276
+#endif
+#ifndef __NR_waitid
+#define __NR_waitid            281
+#endif
+#ifndef __NR_inotify_init
+#define __NR_inotify_init      284
+#define __NR_inotify_add_watch 285
+#define __NR_inotify_rm_watch  286
+#endif
+#ifndef __NR_openat
+#define __NR_openat            288
+#define __NR_mkdirat           289
+#define __NR_mknodat           290
+#define __NR_fchownat          291
+#define __NR_futimesat         292
+#define __NR_newfstatat                293
+#define __NR_unlinkat          294
+#define __NR_renameat          295
+#define __NR_linkat            296
+#define __NR_symlinkat         297
+#define __NR_readlinkat                298
+#define __NR_fchmodat          299
+#define __NR_faccessat         300
+#endif
+#ifndef __NR_pselect6
+#define __NR_pselect6          301
+#define __NR_ppoll             302
+#endif
+#ifndef __NR_unshare
+#define __NR_unshare           303
+#endif
+%endif
+%ifarch sparc sparcv9 sparc64
+#ifndef __NR_mq_open
+#define __NR_mq_open           273
+#define __NR_mq_unlink         274
+#define __NR_mq_timedsend      275
+#define __NR_mq_timedreceive   276
+#define __NR_mq_notify         277
+#define __NR_mq_getsetattr     278
+#endif
+#ifndef __NR_waitid
+#define __NR_waitid            279
+#endif
+#ifndef __NR_stat64
+#define __NR_fstat64           63
+#define __NR_lstat64           132
+#define __NR_stat64            139
+#endif
+#ifndef __NR_inotify_init
+#define __NR_inotify_init      151
+#define __NR_inotify_add_watch 152
+#define __NR_inotify_rm_watch  156
+#endif
+#ifndef __NR_openat
+#define __NR_openat            284
+#define __NR_mkdirat           285
+#define __NR_mknodat           286
+#define __NR_fchownat          287
+#define __NR_futimesat         288
+#define __NR_newfstatat                289
+#define __NR_unlinkat          290
+#define __NR_renameat          291
+#define __NR_linkat            292
+#define __NR_symlinkat         293
+#define __NR_readlinkat                294
+#define __NR_fchmodat          295
+#define __NR_faccessat         296
+#endif
+#ifndef __NR_pselect6
+#define __NR_pselect6          297
+#define __NR_ppoll             298
+#endif
+#ifndef __NR_unshare
+#define __NR_unshare           299
+#endif
+%endif
+%ifarch x86_64
+#ifndef __NR_mq_open
+#define __NR_mq_open           240
+#define __NR_mq_unlink         241
+#define __NR_mq_timedsend      242
+#define __NR_mq_timedreceive   243
+#define __NR_mq_notify         244
+#define __NR_mq_getsetattr     245
+#endif
+#ifndef __NR_waitid
+#define __NR_waitid            247
+#endif
+#ifndef __NR_inotify_init
+#define __NR_inotify_init      253
+#define __NR_inotify_add_watch 254
+#define __NR_inotify_rm_watch  255
+#endif
+#ifndef __NR_openat
+#define __NR_openat            257
+#define __NR_mkdirat           258
+#define __NR_mknodat           259
+#define __NR_fchownat          260
+#define __NR_futimesat         261
+#define __NR_newfstatat                262
+#define __NR_unlinkat          263
+#define __NR_renameat          264
+#define __NR_linkat            265
+#define __NR_symlinkat         266
+#define __NR_readlinkat                267
+#define __NR_fchmodat          268
+#define __NR_faccessat         269
+#endif
+#ifndef __NR_pselect6
+#define __NR_pselect6          270
+#define __NR_ppoll             271
+#endif
+#ifndef __NR_unshare
+#define __NR_unshare           272
+#endif
+#ifndef __NR_set_robust_list
+#define __NR_set_robust_list   273
+#define __NR_get_robust_list   274
+#endif
+#ifndef __NR_splice
+#define __NR_splice            275
+#endif
+#ifndef __NR_tee
+#define __NR_tee               276
+#endif
+#ifndef __NR_sync_file_range
+#define __NR_sync_file_range   277
+#endif
+#ifndef __NR_vmsplice
+#define __NR_vmsplice          278
+#endif
+%endif
+#endif
+EOF
+cat > override_headers/asm/errno.h <<EOF
+#ifndef _HACK_ASM_ERRNO_H
+#include_next <asm/errno.h>
+%ifarch alpha
+#ifndef ENOKEY
+#define ENOKEY         132
+#define EKEYEXPIRED    133
+#define EKEYREVOKED    134
+#define EKEYREJECTED   135
+#endif
+#ifndef EOWNERDEAD
+#define EOWNERDEAD     136
+#define ENOTRECOVERABLE        137
+#endif
+%endif
+%ifarch %{ix86} ia64 ppc ppc64 s390 s390x x86_64
+#ifndef ENOKEY
+#define ENOKEY         126
+#define EKEYEXPIRED    127
+#define EKEYREVOKED    128
+#define EKEYREJECTED   129
+#endif
+#ifndef EOWNERDEAD
+#define EOWNERDEAD     130
+#define ENOTRECOVERABLE        131
+#endif
+%endif
+%ifarch sparc sparcv9 sparc64
+#ifndef ENOKEY
+#define ENOKEY         128
+#define EKEYEXPIRED    129
+#define EKEYREVOKED    130
+#define EKEYREJECTED   131
+#endif
+#ifndef EOWNERDEAD
+#define EOWNERDEAD     132
+#define ENOTRECOVERABLE        133
+#endif
+%endif
+#endif
+EOF
+
+# A lot of programs still misuse memcpy when they have to use
+# memmove. The memcpy implementation below is not tolerant at
+# all.
+rm -f sysdeps/alpha/alphaev6/memcpy.S
+
 %build
+# glibc has its own way to remove PLT relocations. / H. J. Lu.
+unset LD_SYMBOLIC_FUNCTIONS || :
+
 cp -f /usr/share/automake/config.sub scripts
 %{__aclocal}
 %{__autoconf}
@@ -881,7 +1420,7 @@ AWK="gawk" \
 ../%configure \
        --enable-kernel="%{min_kernel}" \
        --enable-omitfp \
-       --with-headers=%{_includedir} \
+       --with-headers=`cd ..; pwd`/override_headers:%{_includedir} \
        --with%{!?with_selinux:out}-selinux \
        --with-tls \
        --enable-add-ons=nptl,libidn \
@@ -1066,7 +1605,7 @@ rm -rf $RPM_BUILD_ROOT
 
 %if !%{with cross}
 %post  -p /sbin/postshell
-/sbin/glibc-postinst /%{_lib}/%{_host_cpu}
+/sbin/glibc-postinst /%{_lib}/%{_host_cpu} /%{_lib}/tls
 /sbin/ldconfig
 -/sbin/telinit u
 
This page took 0.219297 seconds and 4 git commands to generate.