/[packages]/updates/3/glibc/current/SPECS/glibc.spec
ViewVC logotype

Contents of /updates/3/glibc/current/SPECS/glibc.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 156856 - (show annotations) (download)
Thu Oct 20 10:13:17 2011 UTC (12 years, 6 months ago) by tmb
Original Path: cauldron/glibc/current/SPECS/glibc.spec
File size: 49555 byte(s)
drop P46 (already merged in glibc-ports-2.14.1)
1 # RH 2.2.4-20, SuSE 2.3.1-32
2 %define name %{cross_prefix}glibc
3
4 # <epoch>:<version>-<release> tags for glibc main package
5 %define glibcversion 2.14.1
6 %define __glibcrelease 0.2
7 %define glibcepoch 6
8
9 # CVS snapshots of glibc
10 %define RELEASE 1
11 %if %{RELEASE}
12 %define source_package glibc-%{glibcversion}
13 %define source_dir glibc-%{glibcversion}
14 %define _glibcrelease %{__glibcrelease}
15 %define portsversion %{glibcversion}
16 %else
17 %define snapshot 20081113
18 %define source_package glibc-%{glibcversion}-%{snapshot}
19 %define source_dir glibc-%{glibcversion}
20 %define _glibcrelease 0.%{snapshot}.%{__glibcrelease}
21 %define portsversion 2.9
22 %endif
23
24 %define glibcrelease %mkrel %{_glibcrelease}
25
26 # crypt blowfish support
27 %define crypt_bf_ver 1.2
28
29 # Define "cross" to an architecture to which glibc is to be
30 # cross-compiled
31 %define build_cross 0
32 %{expand: %{?cross: %%global build_cross 1}}
33
34 %if %{build_cross}
35 %define target_cpu %{cross}
36 %define cross_prefix cross-%{target_cpu}-
37 %define _prefix /usr/%{target_cpu}-%{_real_vendor}-linux%{gnuext}
38 %define cross_program_prefix %{target_cpu}-%{_real_vendor}-linux%{gnuext}-
39 %define _exec_prefix %{_prefix}
40 # brain damage alert: should not be needed imho
41 # overriding _prefix and _exec_prefix should be enough
42 %define _bindir %{_exec_prefix}/bin
43 %define _sbindir %{_exec_prefix}/sbin
44 %define _libexecdir %{_exec_prefix}/libexec
45 %define _datadir %{_prefix}/share
46 %define _sharedstatedir %{_prefix}/com
47 %define _localstatedir %{_prefix}/var
48 %define _lib lib
49 %define _libdir %{_exec_prefix}/%{_lib}
50 %define _slibdir %{_exec_prefix}/%{_lib}
51 %define _slibdir32 %{_exec_prefix}/lib
52 %define _includedir %{_prefix}/include
53 %else
54 %define gnuext %{_gnu}
55 %define target_cpu %{_target_cpu}
56 %define cross_prefix %{nil}
57 %define cross_program_prefix %{nil}
58 %define _slibdir /%{_lib}
59 %define _slibdir32 /lib
60 %endif
61
62 # Define target (base) architecture
63 %define arch %(echo %{target_cpu}|sed -e "s/\\(i.86\\|athlon\\)/i386/" -e "s/amd64/x86_64/")
64 %define isarch() %(case " %* " in (*" %{arch} "*) echo 1;; (*) echo 0;; esac)
65
66 %if %{build_cross}
67 %if %isarch %arm
68 %define gnuext -gnueabi
69 %else
70 %define gnuext -gnu
71 %endif
72 %endif
73
74 # Define Xen arches to build with -mno-tls-direct-direct-seg-refs
75 %define xenarches %{ix86} x86_64
76
77 # arches which requires glibc-port
78 %define ports_arch %arm %mips
79
80 # Define to build nscd with selinux support
81 %define build_selinux 0
82
83 # Flag for build_pdf_doc:
84 # 1 build glibc with PDF documentation
85 # 0 don't build PDF glibc documentation (e.g. for bootstrap build)
86 %define build_pdf_doc 1
87
88 # Enable checking by default for arches where we know tests all pass
89 %define build_check 1
90
91 # Allow make check to fail only when running kernels where we know
92 # tests must pass (no missing features or bugs in the kernel)
93 %define check_min_kver 2.6.33
94
95 # Define to build a biarch package
96 %define build_biarch 0
97 %if %isarch x86_64 mips64 mips64el
98 %define build_biarch 1
99 %endif
100
101 # Define to build glibc-debug package
102 %define build_debug 1
103 %define _enable_debug_packages 1
104 %if "%{_enable_debug_packages}" == "1"
105 %define build_debug 0
106 %endif
107
108 # Define to bootstrap new glibc
109 %define build_bootstrap 0
110 %{expand: %{!?build_cross_bootstrap: %global build_cross_bootstrap 0}}
111
112 %define build_profile 1
113 %define build_nscd 1
114 %define build_doc 1
115 %define build_utils 1
116 %define build_i18ndata 1
117 %define build_timezone 0
118
119 # Disable a few defaults when cross-compiling a glibc
120 %if %{build_cross}
121 %define build_doc 0
122 %define build_pdf_doc 0
123 %define build_biarch 0
124 %define build_check 0
125 %define build_debug 0
126 %define build_nscd 0
127 %define build_profile 0
128 %define build_utils 0
129 %define build_i18ndata 0
130 %define build_timezone 0
131 %endif
132
133 # Allow --with[out] <feature> at rpm command line build
134 %{expand: %{?_without_PDF: %%global build_pdf_doc 0}}
135 %{expand: %{?_without_CHECK: %%global build_check 0}}
136 %{expand: %{?_without_UTILS: %%global build_utils 0}}
137 %{expand: %{?_without_BOOTSTRAP:%%global build_bootstrap 0}}
138 %{expand: %{?_with_PDF: %%global build_pdf_doc 1}}
139 %{expand: %{?_with_CHECK: %%global build_check 1}}
140 %{expand: %{?_with_UTILS: %%global build_utils 1}}
141 %{expand: %{?_with_BOOTSTRAP: %%global build_bootstrap 1}}
142
143 Summary: The GNU libc libraries
144 Name: %{name}
145 Version: %{glibcversion}
146 Release: %{glibcrelease}
147 Epoch: %{glibcepoch}
148 License: LGPL
149 Group: System/Libraries
150 Url: http://www.gnu.org/software/libc/
151
152 # FSF source
153 Source0: http://ftp.gnu.org/gnu/glibc/%{source_package}.tar.xz
154 %if %{RELEASE}
155 Source1: http://ftp.gnu.org/gnu/glibc/%{source_package}.tar.xz.sig
156 %endif
157
158 # Red Hat tarball
159 Source2: glibc-redhat.tar.bz2
160 Source3: glibc-manpages.tar.bz2
161 Source4: glibc-find-requires.sh
162 Source5: glibc-check.sh
163
164 # wrapper to avoid rpm circular dependencies
165 Source14: glibc-post-wrapper.c
166
167 # Blowfish support
168 Source16: http://www.openwall.com/crypt/crypt_blowfish-%{crypt_bf_ver}.tar.gz
169 Source17: http://www.openwall.com/crypt/crypt_blowfish-%{crypt_bf_ver}.tar.gz.sign
170 Source18: http://cvsweb.openwall.com/cgi/cvsweb.cgi/~checkout~/Owl/packages/glibc/crypt_freesec.c
171 Source19: http://cvsweb.openwall.com/cgi/cvsweb.cgi/~checkout~/Owl/packages/glibc/crypt_freesec.h
172
173 # tarball are at http://ftp.gnu.org/gnu/glibc/
174 # for snapshots :
175 # git clone git://sources.redhat.com/git/glibc-ports.git
176 # git archive --format=tar --prefix=glibc-ports-2.9/ HEAD | bzip2 -c > ../glibc-ports-2.9-$(date +%%Y%%m%%d).tar.bz2
177 Source20: http://ftp.gnu.org/gnu/glibc/glibc-ports-%{portsversion}.tar.xz
178 %if %{RELEASE}
179 Source21: http://ftp.gnu.org/gnu/glibc/glibc-ports-%{portsversion}.tar.xz.sig
180 %endif
181
182 Buildroot: %{_tmppath}/glibc-%{PACKAGE_VERSION}-root
183 %if %{build_cross}
184 Autoreq: false
185 Autoprov: false
186 %else
187 Provides: glibc-crypt_blowfish = %{crypt_bf_ver}
188 Provides: should-restart = system
189 %if %isarch %{xenarches}
190 Obsoletes: %{name}-xen
191 Provides: %{name}-xen
192 %endif
193 # The dynamic linker supports DT_GNU_HASH
194 Provides: rtld(GNU_HASH)
195 Autoreq: false
196 %endif
197 BuildRequires: patch, gettext, perl
198 BuildRequires: linux-userspace-headers
199 %if %{build_selinux}
200 BuildRequires: libselinux-devel >= 1.17.10
201 %endif
202 # need linker for -Wl,--hash-style=both (>= 2.16.91.0.7-6})
203 # need gnu indirect function for multiarch (>= 2.19.51.0.14-1)
204 %define binutils_version 2.19.51.0.14-1
205 BuildRequires: %{cross_prefix}binutils >= %{binutils_version}
206 # we need the static dash
207 %define ash_bin /bin/dash.static
208 Requires(pre): dash-static
209 Requires(post): dash-static
210 # we need an ldconfig with TLS support
211 %if %{build_cross}
212 BuildRequires: %{cross_prefix}gcc >= 3.2.2-4
213 %endif
214 %ifarch x86_64
215 BuildRequires: %{cross_prefix}gcc >= 3.1.1-0.5
216 %endif
217 BuildRequires: %{cross_prefix}gcc >= 4.0.1-2
218 %if !%{build_cross}
219 %ifarch mips mipsel
220 Provides: ld.so.1
221 %endif
222 %endif
223
224 # Old prelink versions brakes the system with glibc 2.11
225 Conflicts: prelink < 1:0.4.2-1.20091104.1
226
227 BuildRequires: texinfo
228 %if %{build_pdf_doc}
229 BuildRequires: texlive
230 %endif
231 %if %{build_utils}
232 BuildRequires: gd-devel
233 %endif
234 BuildRequires: autoconf2.5
235 BuildRequires: libcap-devel
236 BuildRequires: rpm-mageia-setup-build >= 1.104
237 BuildRequires: spec-helper >= 0.31.2
238
239 # make "localedef --add-to-archive" to follow symlink
240 # safe to send ustream, need to be kept for locales
241 Patch00: glibc-2.11.1-localedef-archive-follow-symlinks.patch
242
243 # various path fix, for _PATH_VI and _PATH_VARDB
244 Patch01: glibc-2.12.1-fhs.patch
245 Patch02: glibc-2.9-ldd-non-exec.patch
246 # try to fallback on loading /lib/libnss_*.so.X.Y when the loading
247 # of /lib/libnss_*.so.X failed. Should be dropped, IMHO.
248 Patch04: glibc-2.2-nss-upgrade.patch
249
250 # patch from https://qa.mandriva.com/show_bug.cgi?id=58834
251 # deferred upstream until rfc is changed, no need to push upstream
252 Patch05: glibc-2.12.1-assign-global-scope-to-RFC-1918-addresses.patch
253 Patch06: glibc-2.9-share-locale.patch
254
255 # default nsswitch.conf
256 # should be moved out patch and be a regular Source
257 Patch07: glibc-2.3.6-nsswitch.conf.patch
258
259 # use xvt instead of xterm in xtrace.sh
260 # cannot be pushed upstream as xvt is Ma* specific
261 Patch09: glibc-2.2.4-xterm-xvt.patch
262
263 # add transliteration for "COLON SIGN"
264 # ( used for the money of money of san salvador )
265 Patch11: glibc-2.4.90-compat-EUR-currencies.patch
266 Patch12: glibc-2.3.6-ppc-build-lddlibc4.patch
267
268 # fix the chkconfig header, should be sent upstream
269 Patch13: glibc-2.3.3-nscd-enable.patch
270
271 # disable cache for hosts on nscd, as this is seen as insecure
272 # if the system relie on reverse dns for security
273 Patch14: glibc-2.9-nscd-no-host-cache.patch
274
275 Patch17: glibc-2.4.90-i386-hwcapinfo.patch
276 Patch18: glibc-2.7-provide_CFI_for_the_outermost_function.patch
277
278 # another fix for nscd init script, make it start after network, ldap, mysql and ypbind
279 # should be sent upstream
280 Patch19: glibc-2.8-nscd-init-should-start.patch
281
282 # according to the patch : "The Linux kernel has a bug which silently ignore the invalid
283 # c_cflag on pty.". Patch is likely fixed in kernel, but this should be checked
284 Patch22: glibc-2.3.2-tcsetattr-kernel-bug-workaround.patch
285
286 # add some new timezone for various cities
287 # Halifax, Montreal, Johannesburg
288 # should be sent upstream ( I guess )
289 Patch23: glibc-2.3.4-timezone.patch
290 Patch24: glibc-2.10.1-biarch-cpp-defines.patch
291 Patch26: glibc-2.6-nice_fix.patch
292
293 # fix a typo, safe to send upstream
294 Patch27: glibc-2.8-ENOTTY-fr-translation.patch
295 Patch28: glibc-2.4.90-gcc4-fortify.patch
296 Patch29: glibc-2.3.5-biarch-utils.patch
297
298 # remove multiarch header, Ma* specific patch
299 # check if still needed or if the work was finished
300 Patch30: glibc-2.10.1-multiarch.patch
301 Patch31: glibc-2.4.90-i586-hptiming.patch
302
303 # do not use i686 optimised library if the processor do not support
304 # cmov ( some i686 cpu don't, from VIA iirc )
305 # shuld be sent upstream, IMHO
306 Patch32: glibc-2.3.4-i586-if-no-cmov.patch
307
308 # translation fixes, need to be checked with some i18n team member
309 # should be safe to send upstream once checked
310 Patch33: glibc-2.3.6-pt_BR-i18nfixes.patch
311 Patch34: glibc-2.4.90-testsuite-ldbl-bits.patch
312
313 # disable parallel testsuite of rt on powerpc with SMT
314 Patch38: glibc-2.4.90-testsuite-rt-notparallel.patch
315 Patch39: glibc-2.10.1-mdv-owl-crypt_freesec.patch
316 Patch40: glibc-2.14.1-avx-relocate_fcrypt.patch
317 Patch41: glibc-2.14.1-avx-increase_BF_FRAME.patch
318 Patch42: glibc-2.10.1-mdv-avx-owl-crypt.patch
319
320 # add support for sha256 and sha512 in crypt
321 # likely coming from owl
322 Patch43: glibc-2.7-mdv-wrapper_handle_sha.patch
323
324 # check for libcap, even if selinux is disabled
325 # should be sent upstream
326 Patch44: glibc-2.14.1-dont-tie-libcap-with-selinux.patch
327 # change page size to 16k. mandatory for loongson
328 # but not necessary a good idea for other socs
329 Patch46: glibc_mips_16k_page_size.patch
330
331 # Determine minium kernel versions
332 %define enablekernel 2.6.33
333 Conflicts: kernel < %{enablekernel}
334
335 # People changed location of rpm scripts...
336 %define rpmscripts /usr/lib/rpm/%{_real_vendor}
337
338 # Don't try to explicitly provide GLIBC_PRIVATE versioned libraries
339 %define __find_provides %{_builddir}/%{source_dir}/find_provides.sh
340 %define __find_requires %{_builddir}/%{source_dir}/find_requires.sh
341
342 %if !%{build_cross}
343 Obsoletes: ld.so
344 Provides: ld.so
345 %endif
346
347 Obsoletes: ldconfig
348 Provides: ldconfig = %{glibcepoch}:%{glibcversion}-%{glibcrelease} /sbin/ldconfig
349
350 %description
351 The glibc package contains standard libraries which are used by
352 multiple programs on the system. In order to save disk space and
353 memory, as well as to make upgrading easier, common system code is
354 kept in one place and shared between programs. This particular package
355 contains the most important sets of shared libraries: the standard C
356 library and the standard math library. Without these two libraries, a
357 Linux system will not function. The glibc package also contains
358 national language (locale) support.
359
360 This package now also provides ldconfig which was package seperately in
361 the past. Ldconfig is a basic system program which determines run-time
362 link bindings between ld.so and shared libraries. Ldconfig scans a running
363 system and sets up the symbolic links that are used to load shared
364 libraries properly. It also creates a cache (/etc/ld.so.cache) which
365 speeds the loading of programs which use shared libraries.
366
367 %package devel
368 Summary: Header and object files for development using standard C libraries
369 Group: Development/C
370 Requires(post): info-install
371 Requires(preun): info-install
372 Requires(post): coreutils
373 Requires(postun): coreutils, awk
374 Obsoletes: libc-debug, libc-headers, libc-devel, linuxthreads-devel, nptl-devel
375 %if !%{build_debug}
376 Obsoletes: %{name}-debug < 6:2.3.2-15
377 %endif
378 Requires: %{name} = %{glibcepoch}:%{glibcversion}-%{glibcrelease}
379 %if !%{build_cross}
380 Requires: linux-userspace-headers
381 %endif
382 %if !%isarch ppc
383 Conflicts: %{cross_prefix}gcc < 2.96-0.50
384 %endif
385 # needs a gcc4 fortify capable compiler
386 Conflicts: gcc4.0 < 4.0.1-2
387 %if %{build_cross}
388 Autoreq: false
389 Autoprov: false
390 %else
391 Autoreq: true
392 %endif
393 Provides: glibc-crypt_blowfish-devel = %{crypt_bf_ver}
394
395 %description devel
396 The glibc-devel package contains the header and object files necessary
397 for developing programs which use the standard C libraries (which are
398 used by nearly all programs). If you are developing programs which
399 will use the standard C libraries, your system needs to have these
400 standard header and object files available in order to create the
401 executables.
402
403 This package also includes the C header files for the Linux kernel.
404 The header files define structures and constants that are needed for
405 building most standard programs. The header files are also needed for
406 rebuilding the kernel.
407
408 Install glibc-devel if you are going to develop programs which will
409 use the standard C libraries.
410
411 %package static-devel
412 Summary: Static libraries for GNU C library
413 Group: Development/C
414 Requires: %{name}-devel = %{glibcepoch}:%{glibcversion}-%{glibcrelease}
415
416 %description static-devel
417 The glibc-static-devel package contains the static libraries necessary
418 for developing programs which use the standard C libraries. Install
419 glibc-static-devel if you need to statically link your program or
420 library.
421
422 %package profile
423 Summary: The GNU libc libraries, including support for gprof profiling
424 Group: Development/C
425 Obsoletes: libc-profile
426 Provides: libc-profile = %{glibcversion}-%{glibcrelease}
427 Autoreq: true
428
429 %description profile
430 The glibc-profile package includes the GNU libc libraries and support
431 for profiling using the gprof program. Profiling is analyzing a
432 program's functions to see how much CPU time they use and determining
433 which functions are calling other functions during execution. To use
434 gprof to profile a program, your program needs to use the GNU libc
435 libraries included in glibc-profile (instead of the standard GNU libc
436 libraries included in the glibc package).
437
438 If you are going to use the gprof program to profile a program, you'll
439 need to install the glibc-profile program.
440
441 %package -n nscd
442 Summary: A Name Service Caching Daemon (nscd)
443 Group: System/Servers
444 Requires(pre): rpm-helper
445 Requires(preun): rpm-helper
446 Requires(post): rpm-helper
447 Requires(postun): rpm-helper
448 Autoreq: true
449
450 %description -n nscd
451 Nscd caches name service lookups and can dramatically improve
452 performance with NIS+, and may help with DNS as well. Note that you
453 can't use nscd with 2.0 kernels because of bugs in the kernel-side
454 thread support. Unfortunately, nscd happens to hit these bugs
455 particularly hard.
456
457 Install nscd if you need a name service lookup caching daemon, and
458 you're not using a version 2.0 kernel.
459
460 %if %{build_debug}
461 %package debug
462 Summary: Shared standard C libraries with debugging information
463 Group: System/Libraries
464 Requires: %{name} = %{glibcepoch}:%{glibcversion}-%{glibcrelease}
465 Autoreq: false
466
467 %description debug
468 The glibc-debug package contains shared standard C libraries with
469 debugging information. You need this only if you want to step into C
470 library routines during debugging.
471
472 To use these libraries, you need to add %{_libdir}/debug to your
473 LD_LIBRARY_PATH variable prior to starting the debugger.
474 %endif
475
476 %package utils
477 Summary: Development utilities from GNU C library
478 Group: Development/Other
479 Requires: %{name} = %{glibcepoch}:%{glibcversion}-%{glibcrelease}
480
481 %description utils
482 The glibc-utils package contains memusage, a memory usage profiler,
483 mtrace, a memory leak tracer and xtrace, a function call tracer which
484 can be helpful during program debugging.
485
486 If unsure if you need this, don't install this package.
487
488 %if %{build_i18ndata}
489 %package i18ndata
490 Summary: Database sources for 'locale'
491 Group: System/Libraries
492
493 %description i18ndata
494 This package contains the data needed to build the locale data files
495 to use the internationalization features of the GNU libc.
496 %endif
497
498 %if %{build_timezone}
499 %package -n timezone
500 Summary: Time zone descriptions
501 Group: System/Base
502
503 %description -n timezone
504 These are configuration files that describe possible
505 time zones.
506 %endif
507
508 %package doc
509 Summary: GNU C library documentation
510 Group: Development/Other
511 BuildArch: noarch
512
513 %description doc
514 The glibc-doc package contains documentation for the GNU C library in
515 info format.
516
517 %if %{build_pdf_doc}
518 %package doc-pdf
519 Summary: GNU C library documentation
520 Group: Development/Other
521 BuildArch: noarch
522
523 %description doc-pdf
524 The glibc-doc-pdf package contains the printable documentation for the
525 GNU C library in PDF format.
526 %endif
527
528 %prep
529 %setup -q -n %{source_dir} -a 3 -a 2 -a 16
530
531 %patch00 -p1 -b .localedef-archive-follow-symlinks
532 %patch01 -p1 -b .fhs
533 %patch02 -p1 -b .ldd-non-exec
534 %patch04 -p1 -b .nss-upgrade
535 %patch05 -p1 -b .assign-global-scope-to-RFC-1918-addresses
536 %patch06 -p1 -b .share-locale
537 %patch07 -p1 -b .nsswitch.conf
538 %patch09 -p1 -b .xterm-xvt
539 %patch11 -p1 -b .compat-EUR-currencies
540 %patch12 -p1 -b .ppc-lddlibc4
541 %patch13 -p1 -b .nscd-enable
542 %patch14 -p1 -b .nscd-no-host-cache
543 %patch17 -p1 -b .i386-hwcapinfo
544 %patch18 -p0 -R -b .provide_CFI_for_the_outermost_function
545 %patch19 -p1 -b .nscd-init-should-start
546 # (tmb) 2011-10-18: disable to verify kernels are fixed.
547 #patch22 -p1 -b .tcsetattr-kernel-bug-workaround
548 %patch23 -p1 -b .timezone
549 %patch24 -p1 -b .biarch-cpp-defines
550 %patch26 -p1 -b .nice-fix
551 %patch27 -p1 -b .ENOTTY-fr-translation
552 %patch28 -p1 -b .gcc4-fortify
553 %patch29 -p1 -b .biarch-utils
554 %patch30 -p1 -b .multiarch-check
555 %patch31 -p1 -b .i586-hptiming
556 %patch32 -p1 -b .i586-if-no-cmov
557 %patch33 -p1 -b .pt_BR-i18nfixes
558 %patch34 -p1 -b .testsuite-ldbl-bits
559 %patch38 -p1 -b .testsuite-rt-notparallel
560 %patch44 -p1 -b .dont-tie-libcap-with-selinux
561
562 %if %isarch %ports_arch
563 tar xjf %{SOURCE20}
564 mv glibc-ports-%{glibcversion} ports
565 %patch47 -p1 -b .mcount
566 %endif
567
568 # copy freesec source
569 cp %{_sourcedir}/crypt_freesec.[ch] crypt/
570 echo "Applying crypt_blowfish patch:"
571 %patch42 -p1 -b .mdv-avx-owl-crypt
572 mv crypt/crypt.h crypt/gnu-crypt.h
573 cp -a crypt_blowfish-%{crypt_bf_ver}/*.[chS] crypt/
574
575 ## FreeSec support for extended/new-style/BSDI hashes in crypt(3)
576 %patch39 -p1 -b .mdv-owl-crypt_freesec
577 %patch40 -p1 -b .avx-relocate_fcrypt
578 %patch41 -p1 -b .avx-increase_BF_FRAME
579 # add sha256-crypt and sha512-crypt support to the Openwall wrapper
580 #patch43 -p0 -b .mdv-wrapper_handle_sha
581
582 %if %{build_selinux}
583 # XXX kludge to build nscd with selinux support as it added -nostdinc
584 # so /usr/include/selinux is not found
585 ln -s %{_includedir}/selinux selinux
586 %endif
587
588 find . -type f -size 0 -o -name "*.orig" -exec rm -f {} \;
589
590 # (Anssi 03/2008) FIXME: use _provides_exceptions
591 cat > find_provides.sh << EOF
592 #!/bin/sh
593 %{rpmscripts}/find-provides | grep -v GLIBC_PRIVATE
594 exit 0
595 EOF
596 chmod +x find_provides.sh
597
598 cat > find_requires.bootstrap.sh << EOF
599 /bin/sh %{SOURCE4} %{buildroot} %{_target_cpu} | grep -v "\(GLIBC_PRIVATE\|linux-gate\|linux-vdso\)"
600 exit 0
601 EOF
602 chmod +x find_requires.bootstrap.sh
603
604 # XXX: use better way later to avoid LD_LIBRARY_PATH issue
605 cat %{rpmscripts}/find-requires | sed '/.*LD_LIBRARY_PATH.*/d;' > find_requires
606 chmod +x find_requires
607 # (Anssi 03/2008) FIXME: use _requires_exceptions
608 cat > find_requires.noprivate.sh << EOF
609 %{_builddir}/%{source_dir}/find_requires %{buildroot} %{_target_cpu} | \
610 grep -v GLIBC_PRIVATE
611 exit 0
612 EOF
613 chmod +x find_requires.noprivate.sh
614
615 # FIXME: fix system rpm find-requires to use the prefix cross version
616 %if %{build_bootstrap} || "%{_target_cpu}" != "%{target_cpu}"
617 ln -s find_requires.bootstrap.sh find_requires.sh
618 %else
619 ln -s find_requires.noprivate.sh find_requires.sh
620 %endif
621
622 # Remove patch backups from files we ship in glibc packages
623 rm -f ChangeLog.[^0-9]*
624 rm -f localedata/locales/{???_??,??_??}.*
625 rm -f localedata/locales/[a-z_]*.*
626
627 %build
628 # Prepare test matrix in the next function
629 CheckList=$PWD/Check.list
630 rm -f $CheckList
631 touch $CheckList
632
633 #
634 # CompareKver <kernel version>
635 # function to compare the desired kernel version with running kernel
636 # version (package releases not taken into account in comparison). The
637 # function returns:
638 # -1 = <kernel version> is lesser than current running kernel
639 # 0 = <kernel version> is equal to the current running kernel
640 # 1 = <kernel version> is greater than current running kernel
641 #
642 function CompareKver() {
643 v1=`echo $1 | sed 's/\.\?$/./'`
644 v2=`uname -r | sed 's/[^.0-9].*//' | sed 's/\.\?$/./'`
645 n=1
646 s=0
647 while true; do
648 c1=`echo "$v1" | cut -d "." -f $n`
649 c2=`echo "$v2" | cut -d "." -f $n`
650 if [ -z "$c1" -a -z "$c2" ]; then
651 break
652 elif [ -z "$c1" ]; then
653 s=-1
654 break
655 elif [ -z "$c2" ]; then
656 s=1
657 break
658 elif [ "$c1" -gt "$c2" ]; then
659 s=1
660 break
661 elif [ "$c2" -gt "$c1" ]; then
662 s=-1
663 break
664 fi
665 n=$((n + 1))
666 done
667 echo $s
668 }
669
670 #
671 # BuildGlibc <arch> [<extra_configure_options>+]
672 #
673 function BuildGlibc() {
674 arch="$1"
675 shift 1
676
677 # PowerPC CPU add-on
678 case $arch in
679 cpu-addon,*)
680 cpu=` echo "$arch" | sed -n "/.*,\([^,]*\),.*$/s//\1/p"`
681 arch=`echo "$arch" | sed -n "/.*,.*,\([^,]*\)$/s//\1/p"`
682 ;;
683 *)
684 cpu=$arch
685 ;;
686 esac
687
688 # Select optimization flags and compiler to use
689 BuildAltArch="no"
690 BuildCompFlags=""
691 BuildFlags=""
692 case $arch in
693 i[3456]86 | athlon)
694 BuildFlags="-march=$arch -mtune=generic"
695 if [[ "`uname -m`" = "x86_64" ]]; then
696 BuildAltArch="yes"
697 BuildCompFlags="-m32"
698 fi
699 ;;
700 x86_64)
701 BuildFlags="-mtune=generic"
702 ;;
703 mips|mipsel)
704 BuildFlags="-march=mips3"
705 BuildCompFlags="-march=mips3"
706 ;;
707 mips32|mips32el)
708 BuildFlags="-march=mips3 -mabi=n32"
709 BuildCompFlags="-march=mips3 -mabi=n32"
710 ;;
711 mips64|mips64el)
712 BuildFlags="-march=mips3 -mabi=64"
713 BuildCompFlags="-march=mips3 -mabi=64"
714 ;;
715 armv4t*)
716 BuildFlags="-march=armv4t"
717 BuildCompFlags="-march=armv4t"
718 ;;
719 armv5t*)
720 BuildFlags="-march=armv5t"
721 BuildCompFlags="-march=armv5t"
722 ;;
723 # to check
724 armv7*)
725 BuildFlags="-march=armv7-a"
726 BuildCompFlags="-march=armv7-a"
727 ;;
728 esac
729
730 # Choose multiarch support
731 MultiArchFlags=
732 case $arch in
733 i686 | x86_64)
734 MultiArchFlags="--enable-multi-arch"
735 ;;
736 esac
737
738 # Determine C & C++ compilers
739 BuildCC="%{__cc} $BuildCompFlags"
740 BuildCXX="%{__cxx} $BuildCompFlags"
741
742 # Are we supposed to cross-compile?
743 if [[ "%{target_cpu}" != "%{_target_cpu}" ]]; then
744 # Can't use BuildCC anymore with previous changes.
745 BuildCC="%{cross_program_prefix}gcc $BuildCompFlags"
746 BuildCXX="%{cross_program_prefix}g++ $BuildCompFlags"
747 BuildCross="--build=%{_target_platform}"
748 export libc_cv_forced_unwind=yes libc_cv_c_cleanup=yes
749 fi
750
751 BuildFlags="$BuildFlags -DNDEBUG=1 -O2 -finline-functions -g"
752 if $BuildCC -v 2>&1 | grep -q 'gcc version 3.0'; then
753 # gcc3.0 had really poor inlining heuristics causing problems in
754 # resulting ld.so
755 BuildFlags="$BuildFlags -finline-limit=2000"
756 fi
757
758 # Do not use direct references against %gs when accessing tls data
759 # XXX make it the default in GCC? (for other non glibc specific usage)
760 case $arch in
761 i[3456]86 | x86_64)
762 BuildFlags="$BuildFlags -mno-tls-direct-seg-refs"
763 ;;
764 esac
765
766 # Arch specific compilation flags
767 if [[ "$arch" = "ppc64" ]]; then
768 BuildFlags="$BuildFlags -fno-inline-functions -mno-minimal-toc"
769 fi
770
771 # Extra configure flags
772 ExtraFlags=
773 if [[ "%{build_profile}" != "0" ]]; then
774 ExtraFlags="$ExtraFlags --enable-profile"
775 fi
776
777 # NPTL+TLS are now the default
778 # check for other arches
779 %if %isarch %ports_arch
780 Pthreads="ports nptl"
781 %else
782 Pthreads="nptl"
783 %endif
784 TlsFlags="--with-tls --with-__thread"
785
786 # Add-ons
787 AddOns="$Pthreads,libidn"
788 if [[ "$cpu" != "$arch" ]]; then
789 AddOns="$AddOns,powerpc-cpu"
790 BuildFlags="$BuildFlags -mcpu=$cpu"
791 ExtraFlags="$ExtraFlags --with-cpu=$cpu"
792 fi
793
794 # Build with selinux support?
795 %if %{build_selinux}
796 SElinuxFlags="--with-selinux"
797 %else
798 SElinuxFlags="--without-selinux"
799 %endif
800
801 # Kernel headers directory
802 KernelHeaders=%{_includedir}
803
804 # Determine library name
805 glibc_cv_cc_64bit_output=no
806 if echo ".text" | $BuildCC -c -o test.o -xassembler -; then
807 case `/usr/bin/file test.o` in
808 *"ELF 64"*)
809 glibc_cv_cc_64bit_output=yes
810 ;;
811 esac
812 fi
813 rm -f test.o
814
815 # Force a separate and clean object dir
816 rm -rf build-$cpu-linux
817 mkdir build-$cpu-linux
818 pushd build-$cpu-linux
819 [[ "$BuildAltArch" = "yes" ]] && touch ".alt" || touch ".main"
820 CC="$BuildCC" CXX="$BuildCXX" CFLAGS="$BuildFlags" ../configure \
821 $arch-%{_real_vendor}-linux%{gnuext} $BuildCross \
822 --prefix=%{_prefix} \
823 --libexecdir=%{_prefix}/libexec \
824 --infodir=%{_infodir} \
825 --enable-add-ons="$AddOns" --without-cvs \
826 $TlsFlags $ExtraFlags $MultiArchFlags $SElinuxFlags \
827 --enable-experimental-malloc \
828 --enable-kernel=%{enablekernel} \
829 --with-headers=$KernelHeaders ${1+"$@"}
830 %make -r
831 popd
832
833 # All tests are expected to pass on certain platforms, depending also
834 # on the version of the kernel running
835 case $arch in
836 athlon | ia64 | ppc | ppc64)
837 if [ "`CompareKver %{check_min_kver}`" -lt 0 ]; then
838 check_flags=""
839 else
840 check_flags="-k"
841 fi
842 ;;
843 *)
844 check_flags="-k"
845 ;;
846 esac
847
848 # Generate test matrix
849 [[ -d "build-$arch-linux" ]] || {
850 echo "ERROR: PrepareGlibcTest: build-$arch-linux does not exist!"
851 return 1
852 }
853 local BuildJobs="-j`getconf _NPROCESSORS_ONLN`"
854 echo "$BuildJobs -d build-$arch-linux $check_flags" >> $CheckList
855
856 case $cpu in
857 i686|athlon) base_arch=i586;;
858 power*) base_arch=$arch;;
859 *) base_arch=none;;
860 esac
861
862 [[ -d "build-$base_arch-linux" ]] && {
863 check_flags="$check_flags -l build-$base_arch-linux/elf/ld.so"
864 echo "$BuildJobs -d build-$arch-linux $check_flags" >> $CheckList
865 }
866 return 0
867 }
868
869 # Build main glibc
870 BuildGlibc %{target_cpu}
871
872 %if %{build_biarch}
873 %if %isarch x86_64
874 BuildGlibc i686
875 %endif
876 %endif
877 %if %isarch mips
878 BuildGlibc mips64
879 BuildGlibc mips32
880 %endif
881 %if %isarch mipsel
882 BuildGlibc mips64el
883 BuildGlibc mips32el
884 %endif
885 %if %isarch mips64
886 BuildGlibc mips
887 BuildGlibc mips32
888 %endif
889 %if %isarch mips64el
890 BuildGlibc mipsel
891 BuildGlibc mips32el
892 %endif
893
894 # Build i686 libraries if not already building for i686/athlon
895 case %{target_cpu} in
896 i686 | athlon)
897 ;;
898 i[3-6]86)
899 BuildGlibc i686 --disable-profile
900 ;;
901 esac
902
903 make -C crypt_blowfish-%{crypt_bf_ver} man
904
905 %if %{build_check}
906 export TMPDIR=/tmp
907 export TIMEOUTFACTOR=16
908 Check="$PWD/glibc-check.sh"
909 cat %{SOURCE5} > $Check
910 chmod +x $Check
911 while read arglist; do
912 $Check $arglist || exit 1
913 done < $CheckList
914 %endif
915
916 %install
917 rm -rf $RPM_BUILD_ROOT
918
919 # force use of _NPROCESSORS_ONLN jobs since RPM_BUILD_NCPUS could be
920 # greater for icecream
921 BuildJobs="-j`getconf _NPROCESSORS_ONLN`"
922
923 make install_root=$RPM_BUILD_ROOT install -C build-%{target_cpu}-linux
924 %if %{build_i18ndata}
925 (cd build-%{target_cpu}-linux;
926 make $BuildJobs -C ../localedata objdir=`pwd` \
927 install_root=$RPM_BUILD_ROOT \
928 install-locales
929 )
930 install -m 0644 localedata/SUPPORTED $RPM_BUILD_ROOT/%{_datadir}/i18n/
931 %endif
932 sh manpages/Script.sh
933
934 # Empty filelist for non i686/athlon targets
935 > extralibs.filelist
936
937 # Install biarch libraries
938 %if %{build_biarch} || %isarch mips mipsel
939 %if %isarch x86_64
940 ALT_ARCHES=i686-linux
941 %endif
942 %if %isarch mips
943 ALT_ARCHES="mips64-linux mips32-linux"
944 %endif
945 %if %isarch mipsel
946 ALT_ARCHES="mips64el-linux mips32el-linux"
947 %endif
948 %if %isarch mips64
949 ALT_ARCHES="mips-linux mips32-linux"
950 %endif
951 %if %isarch mips64el
952 ALT_ARCHES="mipsel-linux mips32el-linux"
953 %endif
954
955 for ALT_ARCH in $ALT_ARCHES; do
956 mkdir -p $RPM_BUILD_ROOT/$ALT_ARCH
957 make install_root=$RPM_BUILD_ROOT/$ALT_ARCH install -C build-$ALT_ARCH
958
959 # Dispatch */lib only
960 case "$ALT_ARCH" in
961 mips32*)
962 LIB="%{_slibdir}32"
963 ;;
964 mips64*)
965 LIB="%{_slibdir}64"
966 ;;
967 *)
968 LIB=/lib
969 ;;
970 esac
971 %if !%{build_cross}
972 mv $RPM_BUILD_ROOT/$ALT_ARCH/$LIB $RPM_BUILD_ROOT/$LIB
973 rm -f $RPM_BUILD_ROOT/$ALT_ARCH/%_prefix/lib/pt_chown
974 mv $RPM_BUILD_ROOT/$ALT_ARCH%{_prefix}/libexec/getconf/* \
975 $RPM_BUILD_ROOT%{_prefix}/libexec/getconf/
976 [ ! -d $RPM_BUILD_ROOT/%{_prefix}/$LIB/ ] && mkdir -p $RPM_BUILD_ROOT/%{_prefix}/$LIB/
977 mv $RPM_BUILD_ROOT/$ALT_ARCH/%{_prefix}/$LIB/* $RPM_BUILD_ROOT/%{_prefix}/$LIB/
978 %else
979 mv $RPM_BUILD_ROOT/$ALT_ARCH/%{_prefix}/lib $RPM_BUILD_ROOT/$LIB
980 rm -f $RPM_BUILD_ROOT/%{_prefix}/libexec/pt_chown
981 rm -f $RPM_BUILD_ROOT/$LIB/pt_chown
982 sed -i $RPM_BUILD_ROOT/$LIB/libc.so -e "s!%{_slibdir}!$LIB!g"
983 %endif
984
985 rm -rf $RPM_BUILD_ROOT/$ALT_ARCH
986 # XXX Dispatch 32-bit stubs
987 (sed '/^@/d' include/stubs-prologue.h; LC_ALL=C sort $(find build-$ALT_ARCH -name stubs)) \
988 > $RPM_BUILD_ROOT%{_includedir}/gnu/stubs-32.h
989 done
990 %endif
991 %if %{build_cross}
992 rm -f $RPM_BUILD_ROOT/%{_prefix}/libexec/pt_chown
993 %endif
994
995 # Install extra glibc libraries
996 function InstallGlibc() {
997 local BuildDir="$1"
998 local SubDir="$2"
999 local LibDir="$3"
1000
1001 case $BuildDir in
1002 *) Pthreads=nptl ;;
1003 esac
1004
1005 [[ -z "$LibDir" ]] && LibDir="%{_slibdir}"
1006
1007 pushd $BuildDir
1008 mkdir -p $RPM_BUILD_ROOT$LibDir/$SubDir/
1009 install -m755 libc.so $RPM_BUILD_ROOT$LibDir/$SubDir/`basename $RPM_BUILD_ROOT$LibDir/libc-*.so`
1010 ln -sf `basename $RPM_BUILD_ROOT$LibDir/libc-*.so` $RPM_BUILD_ROOT$LibDir/$SubDir/`basename $RPM_BUILD_ROOT$LibDir/libc.so.*`
1011 install -m755 math/libm.so $RPM_BUILD_ROOT$LibDir/$SubDir/`basename $RPM_BUILD_ROOT$LibDir/libm-*.so`
1012 ln -sf `basename $RPM_BUILD_ROOT$LibDir/libm-*.so` $RPM_BUILD_ROOT$LibDir/$SubDir/`basename $RPM_BUILD_ROOT$LibDir/libm.so.*`
1013 install -m755 $Pthreads/libpthread.so $RPM_BUILD_ROOT$LibDir/$SubDir/`basename $RPM_BUILD_ROOT$LibDir/libpthread-*.so`
1014 ln -sf `basename $RPM_BUILD_ROOT$LibDir/libpthread-*.so` $RPM_BUILD_ROOT$LibDir/$SubDir/`basename $RPM_BUILD_ROOT$LibDir/libpthread.so.*`
1015 install -m755 ${Pthreads}_db/libthread_db.so $RPM_BUILD_ROOT$LibDir/$SubDir/`basename $RPM_BUILD_ROOT$LibDir/libthread_db-*.so`
1016 ln -sf `basename $RPM_BUILD_ROOT$LibDir/libthread_db-*.so` $RPM_BUILD_ROOT$LibDir/$SubDir/`basename $RPM_BUILD_ROOT$LibDir/libthread_db.so.*`
1017 install -m755 rt/librt.so $RPM_BUILD_ROOT$LibDir/$SubDir/`basename $RPM_BUILD_ROOT$LibDir/librt-*.so`
1018 ln -sf `basename $RPM_BUILD_ROOT$LibDir/librt-*.so` $RPM_BUILD_ROOT$LibDir/$SubDir/`basename $RPM_BUILD_ROOT$LibDir/librt.so.*`
1019 echo "%dir $LibDir/$SubDir" >> ../extralibs.filelist
1020 find $RPM_BUILD_ROOT$LibDir/$SubDir -maxdepth 1 -type f -o -type l | sed -e "s|$RPM_BUILD_ROOT||" >> ../extralibs.filelist
1021 popd
1022 }
1023
1024 # Install arch-specific optimized libraries
1025 %if %isarch %{ix86}
1026 case %{target_cpu} in
1027 i[3-5]86)
1028 InstallGlibc build-i686-linux i686
1029 ;;
1030 esac
1031 %endif
1032
1033 # NPTL <bits/stdio-lock.h> is not usable outside of glibc, so include
1034 # the generic one (RH#162634)
1035 install -m644 bits/stdio-lock.h $RPM_BUILD_ROOT%{_includedir}/bits/stdio-lock.h
1036
1037 # Compatibility hack: this locale has vanished from glibc, but some other
1038 # programs are still using it. Normally we would handle it in the %pre
1039 # section but with glibc that is simply not an option
1040 mkdir -p $RPM_BUILD_ROOT%{_datadir}/locale/ru_RU/LC_MESSAGES
1041
1042 # Remove the files we don't want to distribute
1043 rm -f $RPM_BUILD_ROOT%{_libdir}/libNoVersion*
1044 rm -f $RPM_BUILD_ROOT%{_slibdir}/libNoVersion*
1045
1046 ln -sf libbsd-compat.a $RPM_BUILD_ROOT%{_libdir}/libbsd.a
1047 %if %{build_biarch}
1048 ln -sf libbsd-compat.a $RPM_BUILD_ROOT%{_prefix}/lib/libbsd.a
1049 %endif
1050 %if %isarch mips mipsel
1051 ln -sf libbsd-compat.a $RPM_BUILD_ROOT%{_libdir}32/libbsd.a
1052 ln -sf libbsd-compat.a $RPM_BUILD_ROOT%{_libdir}64/libbsd.a
1053 %endif
1054
1055 %if "%{name}" == "glibc"
1056 install -m 644 mageia/nsswitch.conf $RPM_BUILD_ROOT%{_sysconfdir}/nsswitch.conf
1057 %endif
1058
1059 # This is for ncsd - in glibc 2.2
1060 %if %{build_nscd}
1061 install -m 644 nscd/nscd.conf $RPM_BUILD_ROOT%{_sysconfdir}
1062 mkdir -p $RPM_BUILD_ROOT%{_initrddir}
1063 install -m 755 nscd/nscd.init $RPM_BUILD_ROOT%{_initrddir}/nscd
1064 %endif
1065
1066 # These man pages require special attention
1067 mkdir -p %{buildroot}%{_mandir}/man3
1068 install -p -m 0644 crypt_blowfish-%{crypt_bf_ver}/*.3 %{buildroot}%{_mandir}/man3/
1069
1070 # Useless and takes place
1071 rm -rf %buildroot/%{_datadir}/zoneinfo/{posix,right}
1072
1073 # Include ld.so.conf
1074 %if "%{name}" == "glibc"
1075 %if %isarch mips mipsel
1076 # needed to get a ldd which understands o32, n32, 64
1077 install -m 755 $RPM_BUILD_DIR/%{source_dir}/build-mips64el-linux/elf/ldd $RPM_BUILD_ROOT/%{_bindir}/ldd
1078 %endif
1079 echo "include /etc/ld.so.conf.d/*.conf" > $RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf
1080 chmod 644 $RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf
1081 mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf.d
1082
1083 # ldconfig cache
1084 mkdir -p $RPM_BUILD_ROOT%{_var}/cache/ldconfig
1085 touch $RPM_BUILD_ROOT%{_var}/cache/ldconfig/aux-cache
1086
1087 # automatic ldconfig cache update on rpm installs/removals
1088 # (see http://wiki.mandriva.com/en/Rpm_filetriggers)
1089 install -d %buildroot%{_var}/lib/rpm/filetriggers
1090 cat > %buildroot%{_var}/lib/rpm/filetriggers/ldconfig.filter << EOF
1091 ^.((/lib|/usr/lib)(32|64)?/[^/]*\.so\.|/etc/ld.so.conf.d/[^/]*\.conf)
1092 EOF
1093 cat > %buildroot%{_var}/lib/rpm/filetriggers/ldconfig.script << EOF
1094 #!/bin/sh
1095 ldconfig -X
1096 EOF
1097 chmod 755 %buildroot%{_var}/lib/rpm/filetriggers/ldconfig.script
1098 %endif
1099
1100 # Include %{_libdir}/gconv/gconv-modules.cache
1101 > $RPM_BUILD_ROOT%{_libdir}/gconv/gconv-modules.cache
1102 chmod 644 $RPM_BUILD_ROOT%{_libdir}/gconv/gconv-modules.cache
1103
1104 %if "%{name}" == "glibc"
1105 touch $RPM_BUILD_ROOT%{_sysconfdir}/ld.so.cache
1106 %endif
1107
1108 # Add libraries to debug sub-package
1109 %if %{build_debug}
1110 mkdir $RPM_BUILD_ROOT%{_libdir}/debug
1111 #cp -a $RPM_BUILD_ROOT%{_libdir}/*.a $RPM_BUILD_ROOT%{_libdir}/debug/
1112 #rm -f $RPM_BUILD_ROOT%{_libdir}/debug/*_p.a
1113 cp -a $RPM_BUILD_ROOT%{_slibdir}/lib*.so* $RPM_BUILD_ROOT%{_libdir}/debug/
1114
1115 pushd $RPM_BUILD_ROOT%{_libdir}/debug
1116 for lib in *.so*; do
1117 [[ -f "$lib" ]] && DEBUG_LIBS="$DEBUG_LIBS %{_libdir}/debug/$lib"
1118 done
1119 popd
1120 %endif
1121
1122 # Are we cross-compiling?
1123 Strip="strip"
1124 if [[ "%{_target_cpu}" != "%{target_cpu}" ]]; then
1125 Strip="%{cross_program_prefix}$Strip"
1126 fi
1127
1128 # Strip libpthread but keep some symbols
1129 find $RPM_BUILD_ROOT%{_slibdir} -type f -name "libpthread-*.so" \
1130 -o -type f -name "libc-*.so" | \
1131 xargs $Strip -g -R .comment
1132
1133 %if %{build_biarch}
1134 find $RPM_BUILD_ROOT/lib -type f -name "libpthread-*.so" \
1135 -o -type f -name "libc-*.so" | \
1136 xargs $Strip -g -R .comment
1137 %endif
1138
1139 # Strip debugging info from all static libraries
1140 pushd $RPM_BUILD_ROOT%{_slibdir}
1141 for i in *.a; do
1142 if [ -f "$i" ]; then
1143 case "$i" in
1144 *_p.a) ;;
1145 *) $Strip -g -R .comment $i ;;
1146 esac
1147 fi
1148 done
1149 popd
1150
1151 # post install wrapper
1152 %__cc -Os -DSLIBDIR="\"%{_slibdir}\"" -DASH_BIN="\"%{ash_bin}\"" %{SOURCE14} -static \
1153 -L $RPM_BUILD_ROOT%{_libdir}/ \
1154 -o $RPM_BUILD_ROOT%{_sbindir}/glibc-post-wrapper
1155 chmod 700 $RPM_BUILD_ROOT%{_sbindir}/glibc-post-wrapper
1156
1157 # rquota.x and rquota.h are now provided by quota
1158 rm -f $RPM_BUILD_ROOT%{_includedir}/rpcsvc/rquota.[hx]
1159
1160 # Hardlink identical locale files together
1161 %if %{build_i18ndata}
1162 gcc -O2 -o build-%{target_cpu}-linux/hardlink redhat/hardlink.c
1163 build-%{target_cpu}-linux/hardlink -vc $RPM_BUILD_ROOT%{_datadir}/locale
1164 %endif
1165
1166 rm -rf $RPM_BUILD_ROOT%{_includedir}/netatalk/
1167
1168 # Build file list for devel package
1169 find $RPM_BUILD_ROOT%{_includedir} -type f -or -type l > devel.filelist
1170 find $RPM_BUILD_ROOT%{_includedir} -type d | sed "s/^/%dir /" | \
1171 grep -v "%{_libdir}/libnss1.*.so$" | \
1172 grep -v "%{_includedir}$" | >> devel.filelist
1173 find $RPM_BUILD_ROOT%{_libdir} -maxdepth 1 -name "*.so" -o -name "*.o" | egrep -v "(libmemusage.so|libpcprofile.so)" >> devel.filelist
1174 # biarch libs
1175 %if %{build_biarch}
1176 find $RPM_BUILD_ROOT%{_prefix}/lib -maxdepth 1 -name "*.so" -o -name "*.o" | egrep -v "(libmemusage.so|libpcprofile.so)" >> devel.filelist
1177 %endif
1178 %if %isarch mips mipsel
1179 find $RPM_BUILD_ROOT%{_libdir}32 -maxdepth 1 -name "*.so" -o -name "*.o" | egrep -v "(libmemusage.so|libpcprofile.so)" >> devel.filelist
1180 find $RPM_BUILD_ROOT%{_libdir}64 -maxdepth 1 -name "*.so" -o -name "*.o" | egrep -v "(libmemusage.so|libpcprofile.so)" >> devel.filelist
1181 %endif
1182 perl -pi -e "s|$RPM_BUILD_ROOT||" devel.filelist
1183
1184 # /etc/localtime - we're proud of our timezone #Well we may put Paris
1185 %if %{build_timezone}
1186 rm -f $RPM_BUILD_ROOT%{_sysconfdir}/localtime
1187 cp -f $RPM_BUILD_ROOT%{_datadir}/zoneinfo/US/Eastern $RPM_BUILD_ROOT%{_sysconfdir}/localtime
1188 #ln -sf ..%{_datadir}/zoneinfo/US/Eastern $RPM_BUILD_ROOT%{_sysconfdir}/localtime
1189 %endif
1190
1191 # [gg] build PDF documentation
1192 %if %{build_pdf_doc}
1193 (cd manual; texi2dvi -p -t @afourpaper -t @finalout libc.texinfo)
1194 %endif
1195
1196 # the last bit: more documentation
1197 rm -rf documentation
1198 mkdir documentation
1199 cp timezone/README documentation/README.timezone
1200 cp ChangeLog* documentation
1201 gzip -9 documentation/ChangeLog*
1202 mkdir documentation/crypt_blowfish-%{crypt_bf_ver}
1203 install -m 644 crypt_blowfish-%{crypt_bf_ver}/{README,LINKS,PERFORMANCE} \
1204 documentation/crypt_blowfish-%{crypt_bf_ver}
1205
1206 # Generate final rpm filelist, with localized libc.mo files
1207 rm -f rpm.filelist
1208 %if "%{name}" == "glibc"
1209 %find_lang libc
1210 perl -ne '/^\s*$/ or print' libc.lang > rpm.filelist
1211 %endif
1212 cat extralibs.filelist >> rpm.filelist
1213
1214 # Remove unpackaged files
1215 rm -f $RPM_BUILD_ROOT%{_infodir}/dir.old*
1216 rm -rf $RPM_BUILD_ROOT%{_includedir}/asm-*/mach-*/
1217 rm -f $RPM_BUILD_ROOT%{_datadir}/locale/locale-archive*
1218
1219 %if !%{build_utils}
1220 %if %{build_biarch}
1221 rm -f $RPM_BUILD_ROOT%{_slibdir32}/libmemusage.so
1222 rm -f $RPM_BUILD_ROOT%{_slibdir32}/libpcprofile.so
1223 %endif
1224 %if %isarch mips mipsel
1225 rm -f $RPM_BUILD_ROOT%{_slibdir}32/libmemusage.so
1226 rm -f $RPM_BUILD_ROOT%{_slibdir}32/libpcprofile.so
1227 rm -f $RPM_BUILD_ROOT%{_slibdir}64/libmemusage.so
1228 rm -f $RPM_BUILD_ROOT%{_slibdir}64/libpcprofile.so
1229 %endif
1230 rm -f $RPM_BUILD_ROOT%{_slibdir}/libmemusage.so
1231 rm -f $RPM_BUILD_ROOT%{_slibdir}/libpcprofile.so
1232 rm -f $RPM_BUILD_ROOT%{_bindir}/memusage
1233 rm -f $RPM_BUILD_ROOT%{_bindir}/memusagestat
1234 rm -f $RPM_BUILD_ROOT%{_bindir}/mtrace
1235 rm -f $RPM_BUILD_ROOT%{_bindir}/pcprofiledump
1236 rm -f $RPM_BUILD_ROOT%{_bindir}/xtrace
1237 %endif
1238
1239 %if !%{build_timezone}
1240 rm -f $RPM_BUILD_ROOT%{_sysconfdir}/localtime
1241 rm -f $RPM_BUILD_ROOT%{_sbindir}/zdump
1242 rm -f $RPM_BUILD_ROOT%{_sbindir}/zic
1243 rm -f $RPM_BUILD_ROOT%{_mandir}/man1/zdump.1*
1244 rm -rf $RPM_BUILD_ROOT%{_datadir}/zoneinfo
1245 %endif
1246
1247 %if !%{build_i18ndata}
1248 rm -rf $RPM_BUILD_ROOT%{_datadir}/i18n
1249 %endif
1250
1251 %if "%{name}" != "glibc"
1252 rm -rf $RPM_BUILD_ROOT/boot
1253 rm -rf $RPM_BUILD_ROOT/sbin
1254 rm -rf $RPM_BUILD_ROOT/usr/share
1255 rm -rf $RPM_BUILD_ROOT%{_bindir}
1256 rm -rf $RPM_BUILD_ROOT%{_sbindir}
1257 rm -rf $RPM_BUILD_ROOT%{_datadir}
1258 rm -rf $RPM_BUILD_ROOT%{_mandir}
1259 rm -rf $RPM_BUILD_ROOT%{_infodir}
1260 rm -rf $RPM_BUILD_ROOT%{_prefix}/etc
1261 rm -rf $RPM_BUILD_ROOT%{_libdir}/gconv
1262 %endif
1263
1264 # In case we are cross-compiling, don't bother to remake symlinks and
1265 # fool spec-helper when stripping files
1266 %if "%{name}" != "glibc"
1267 export DONT_SYMLINK_LIBS=1
1268 export PATH=%{_bindir}:$PATH
1269 %endif
1270
1271 EXCLUDE_FROM_STRIP="ld-%{glibcversion}.so libpthread libc-%{glibcversion}.so $DEBUG_LIBS"
1272 export EXCLUDE_FROM_STRIP
1273
1274 %if "%{name}" == "glibc"
1275 %define upgradestamp %{_slibdir}/glibc.upgraded
1276 %define broken_link %{_slibdir}/libnss_nis.so.1 %{_slibdir}/libnss_files.so.1 %{_slibdir}/libnss_dns.so.1 %{_slibdir}/libnss_compat.so.1
1277
1278 %pre -p %{ash_bin}
1279 # test(1) and echo(1) are built-ins
1280 if [ -d %{_slibdir} ] && [ ! -f %{_slibdir}/libnss_files-%{glibcversion}.so ]; then
1281 echo > %{upgradestamp}
1282 fi
1283
1284 %post -p %{_sbindir}/glibc-post-wrapper
1285 export LC_ALL=C
1286
1287 if [ "$1" -gt 1 ]; then
1288 # migrate /etc/ld.so.conf to include the new /etc/ld.so.conf.d/
1289 # without external commands but for removing the temporary file
1290 ldso_conf=/etc/ld.so.conf
1291 while read i; do
1292 [ "$i" = "include /etc/ld.so.conf.d/*.conf" ] && keep=1
1293 # Remove previously used include line without absolute path
1294 [ "$i" = "include ld.so.conf.d/*.conf" ] || echo $i
1295 done < $ldso_conf > $ldso_conf-
1296 if [ -z "$keep" ]; then
1297 echo "include /etc/ld.so.conf.d/*.conf" > $ldso_conf
1298 while read i; do
1299 echo $i
1300 done < $ldso_conf- >> $ldso_conf
1301 fi
1302 [ -x /bin/rm ] && /bin/rm -f $ldso_conf-
1303 fi
1304 /sbin/ldconfig
1305
1306 if [ "$1" -gt 1 ]; then
1307 # On upgrade the services doesn't work because libnss couldn't be
1308 # loaded anymore.
1309 if [ -f %{upgradestamp} ]; then
1310 if /usr/bin/readlink /proc/1/exe >/dev/null && \
1311 /usr/bin/readlink /proc/1/root >/dev/null; then
1312 if [ -x /sbin/telinit -a -p /dev/initctl ]; then
1313 /sbin/telinit u
1314 fi
1315 if [ -x /etc/init.d/sshd -a \
1316 -x /usr/sbin/sshd -a \
1317 -x /bin/bash ]; then
1318 /etc/init.d/sshd condrestart
1319 fi
1320 fi
1321 fi
1322 if [ -f /bin/rm ]; then
1323 for i in %broken_link; do
1324 if [ -e $i ] && [ ! -L $i ]; then
1325 /bin/rm -f $i
1326 fi
1327 done
1328 fi
1329 fi
1330 [ -x /bin/rm ] && /bin/rm -f %{upgradestamp}
1331
1332 # always generate the gconv-modules.cache
1333 %{_sbindir}/iconvconfig -o %{_libdir}/gconv/gconv-modules.cache --nostdlib %{_libdir}/gconv
1334
1335 %endif
1336
1337 %pre devel
1338 if [ -L %{_includedir}/scsi ]; then
1339 rm -f %{_includedir}/scsi
1340 fi
1341 if [ -L %{_includedir}/sound ]; then
1342 rm -f %{_includedir}/sound
1343 fi
1344 if [ -L %{_includedir}/linux ]; then
1345 rm -f %{_includedir}/linux
1346 fi
1347 if [ -L %{_includedir}/asm ]; then
1348 rm -f %{_includedir}/asm
1349 fi
1350 if [ -L %{_includedir}/asm-generic ]; then
1351 rm -f %{_includedir}/asm-generic
1352 fi
1353 %if %isarch x86_64
1354 if [ -L %{_includedir}/asm-x86_64 ]; then
1355 rm -f %{_includedir}/asm-x86_64
1356 fi
1357 if [ -L %{_includedir}/asm-i386 ]; then
1358 rm -f %{_includedir}/asm-i386
1359 fi
1360 %endif
1361 %if %isarch %mips
1362 if [ -L %{_includedir}/asm-mips ]; then
1363 rm -f %{_includedir}/asm-mips
1364 fi
1365 %endif
1366 %if %isarch %arm
1367 if [ -L %{_includedir}/asm-arm ]; then
1368 rm -f %{_includedir}/asm-arm
1369 fi
1370 %endif
1371 exit 0
1372
1373 %if %{build_doc}
1374 %post doc
1375 %_install_info libc.info
1376
1377 %preun doc
1378 %_remove_install_info libc.info
1379 %endif
1380
1381 %if %{build_nscd}
1382 %pre -n nscd
1383 %_pre_useradd nscd / /bin/false
1384
1385 %post -n nscd
1386 %_post_service nscd
1387
1388 %preun -n nscd
1389 %_preun_service nscd
1390
1391 %postun -n nscd
1392 %_postun_userdel nscd
1393
1394 if [ "$1" -ge "1" ]; then
1395 /sbin/service nscd condrestart > /dev/null 2>&1 || :
1396 fi
1397 %endif
1398
1399 %clean
1400 #rm -rf "$RPM_BUILD_ROOT"
1401 #rm -f *.filelist*
1402
1403 #
1404 # glibc
1405 #
1406 %files -f rpm.filelist
1407 %defattr(-,root,root)
1408 %if "%{name}" == "glibc"
1409 %if %{build_timezone}
1410 %verify(not md5 size mtime) %config(noreplace) %{_sysconfdir}/localtime
1411 %endif
1412 %verify(not md5 size mtime) %config(noreplace) %{_sysconfdir}/nsswitch.conf
1413 %verify(not md5 size mtime) %config(noreplace) %{_sysconfdir}/ld.so.conf
1414 %dir %{_sysconfdir}/ld.so.conf.d
1415 %config(noreplace) %{_sysconfdir}/rpc
1416 %doc nis/nss
1417 %doc posix/gai.conf
1418 %{_mandir}/man1/*
1419 %{_mandir}/man8/rpcinfo.8*
1420 %{_mandir}/man8/ld.so*
1421 %{_datadir}/locale/locale.alias
1422 /sbin/sln
1423 %dir %{_prefix}/libexec/getconf
1424 %{_prefix}/libexec/getconf/*
1425 %endif
1426 %{_slibdir}/ld-%{glibcversion}.so
1427 %if %isarch i386
1428 %{_slibdir}/ld-linux.so.2
1429 %endif
1430 %if %isarch %arm
1431 %{_slibdir}/ld-linux.so.3
1432 %endif
1433 %if %isarch x86_64
1434 %{_slibdir}/ld-linux-x86-64.so.2
1435 %endif
1436 %if %isarch %mips
1437 %{_slibdir}/ld.so.1
1438 %endif
1439 %{_slibdir}/lib*-[.0-9]*.so
1440 %{_slibdir}/lib*.so.[0-9]*
1441 %{_slibdir}/libSegFault.so
1442 %if "%{name}" == "glibc"
1443 %dir %{_libdir}/audit
1444 %{_libdir}/audit/sotruss-lib.so
1445 %dir %{_libdir}/gconv
1446 %{_libdir}/gconv/*.so
1447 %{_libdir}/gconv/gconv-modules
1448 %ghost %{_libdir}/gconv/gconv-modules.cache
1449 %attr(4755,root,root) %{_prefix}/libexec/pt_chown
1450 %{_bindir}/catchsegv
1451 %{_bindir}/gencat
1452 %{_bindir}/getconf
1453 %{_bindir}/getent
1454 %{_bindir}/iconv
1455 %{_bindir}/ldd
1456 %if %isarch i386
1457 %{_bindir}/lddlibc4
1458 %endif
1459 %{_bindir}/locale
1460 %{_bindir}/localedef
1461 %{_bindir}/rpcgen
1462 %{_bindir}/sotruss
1463 %{_bindir}/sprof
1464 %{_bindir}/tzselect
1465 %{_sbindir}/iconvconfig
1466 %{_sbindir}/glibc-post-wrapper
1467 %endif
1468
1469 %if %{build_biarch}
1470 %{_slibdir32}/ld-%{glibcversion}.so
1471 %{_slibdir32}/ld-linux*.so.2
1472 %{_slibdir32}/lib*-[.0-9]*.so
1473 %{_slibdir32}/lib*.so.[0-9]*
1474 %{_slibdir32}/libSegFault.so
1475 %dir %{_prefix}/lib/audit
1476 %{_prefix}/lib/audit/sotruss-lib.so
1477 %dir %{_prefix}/lib/gconv
1478 %{_prefix}/lib/gconv/*
1479 %endif
1480 %if %isarch mips mipsel
1481 %{_slibdir}32/ld-%{glibcversion}.so
1482 %{_slibdir}32/ld.so.1
1483 %{_slibdir}32/lib*-[.0-9]*.so
1484 %{_slibdir}32/lib*.so.[0-9]*
1485 %{_slibdir}32/libSegFault.so
1486 %dir %{_libdir}32/gconv
1487 %{_libdir}32/gconv/*
1488 %{_slibdir}64/ld-%{glibcversion}.so
1489 %{_slibdir}64/ld.so.1
1490 %{_slibdir}64/lib*-[.0-9]*.so
1491 %{_slibdir}64/lib*.so.[0-9]*
1492 %{_slibdir}64/libSegFault.so
1493 %dir %{_libdir}64/gconv
1494 %{_libdir}64/gconv/*
1495 %endif
1496
1497 #
1498 # ldconfig
1499 #
1500 %if "%{name}" == "glibc"
1501 %defattr(-,root,root)
1502 /sbin/ldconfig
1503 %{_mandir}/man8/ldconfig*
1504 %ghost %{_sysconfdir}/ld.so.cache
1505 %dir %{_var}/cache/ldconfig
1506 %ghost %{_var}/cache/ldconfig/aux-cache
1507 %{_var}/lib/rpm/filetriggers/ldconfig.*
1508 %endif
1509
1510 #
1511 # glibc-devel
1512 #
1513 %files devel -f devel.filelist
1514 %defattr(-,root,root)
1515 %doc README NEWS INSTALL FAQ BUGS NOTES PROJECTS CONFORMANCE
1516 %doc COPYING COPYING.LIB
1517 %doc documentation/* README.libm
1518 %doc hesiod/README.hesiod
1519 %doc crypt/README.ufc-crypt
1520 %if "%{name}" == "glibc"
1521 %{_mandir}/man3/*
1522 %endif
1523 %{_libdir}/libbsd-compat.a
1524 %{_libdir}/libbsd.a
1525 %{_libdir}/libc_nonshared.a
1526 %{_libdir}/libg.a
1527 %{_libdir}/libieee.a
1528 %{_libdir}/libmcheck.a
1529 %{_libdir}/libpthread_nonshared.a
1530 %if "%{name}" == "glibc"
1531 %{_libdir}/librpcsvc.a
1532 %endif
1533
1534 %if %{build_biarch}
1535 %{_prefix}/lib/libbsd-compat.a
1536 %{_prefix}/lib/libbsd.a
1537 %{_prefix}/lib/libc_nonshared.a
1538 %{_prefix}/lib/libg.a
1539 %{_prefix}/lib/libieee.a
1540 %{_prefix}/lib/libmcheck.a
1541 %{_prefix}/lib/libpthread_nonshared.a
1542 %{_prefix}/lib/librpcsvc.a
1543 %endif
1544
1545 %if %isarch mips mipsel
1546 %{_libdir}32/libbsd-compat.a
1547 %{_libdir}32/libbsd.a
1548 %{_libdir}32/libc_nonshared.a
1549 %{_libdir}32/libg.a
1550 %{_libdir}32/libieee.a
1551 %{_libdir}32/libmcheck.a
1552 %{_libdir}32/libpthread_nonshared.a
1553 %if "%{name}" == "glibc"
1554 %{_libdir}32/librpcsvc.a
1555 %endif
1556 %{_libdir}64/libbsd-compat.a
1557 %{_libdir}64/libbsd.a
1558 %{_libdir}64/libc_nonshared.a
1559 %{_libdir}64/libg.a
1560 %{_libdir}64/libieee.a
1561 %{_libdir}64/libmcheck.a
1562 %{_libdir}64/libpthread_nonshared.a
1563 %if "%{name}" == "glibc"
1564 %{_libdir}64/librpcsvc.a
1565 %endif
1566 %endif
1567
1568 #
1569 # glibc-static-devel
1570 #
1571 %files static-devel
1572 %defattr(-,root,root)
1573 %doc COPYING COPYING.LIB
1574 %{_libdir}/libBrokenLocale.a
1575 %{_libdir}/libanl.a
1576 %{_libdir}/libc.a
1577 %{_libdir}/libcrypt.a
1578 %{_libdir}/libdl.a
1579 %{_libdir}/libm.a
1580 %{_libdir}/libnsl.a
1581 %{_libdir}/libpthread.a
1582 %{_libdir}/libresolv.a
1583 %{_libdir}/librt.a
1584 %{_libdir}/libutil.a
1585
1586 %if %{build_biarch}
1587 %{_prefix}/lib/libBrokenLocale.a
1588 %{_prefix}/lib/libanl.a
1589 %{_prefix}/lib/libc.a
1590 %{_prefix}/lib/libcrypt.a
1591 %{_prefix}/lib/libdl.a
1592 %{_prefix}/lib/libm.a
1593 %{_prefix}/lib/libnsl.a
1594 %{_prefix}/lib/libpthread.a
1595 %{_prefix}/lib/libresolv.a
1596 %{_prefix}/lib/librt.a
1597 %{_prefix}/lib/libutil.a
1598 %endif
1599
1600 %if %isarch mips mipsel
1601 %{_libdir}32/libBrokenLocale.a
1602 %{_libdir}32/libanl.a
1603 %{_libdir}32/libc.a
1604 %{_libdir}32/libcrypt.a
1605 %{_libdir}32/libdl.a
1606 %{_libdir}32/libm.a
1607 %{_libdir}32/libnsl.a
1608 %{_libdir}32/libpthread.a
1609 %{_libdir}32/libresolv.a
1610 %{_libdir}32/librt.a
1611 %{_libdir}32/libutil.a
1612
1613 %{_libdir}64/libBrokenLocale.a
1614 %{_libdir}64/libanl.a
1615 %{_libdir}64/libc.a
1616 %{_libdir}64/libcrypt.a
1617 %{_libdir}64/libdl.a
1618 %{_libdir}64/libm.a
1619 %{_libdir}64/libnsl.a
1620 %{_libdir}64/libpthread.a
1621 %{_libdir}64/libresolv.a
1622 %{_libdir}64/librt.a
1623 %{_libdir}64/libutil.a
1624 %endif
1625
1626 #
1627 # glibc-doc
1628 #
1629 %if %{build_doc}
1630 %files doc
1631 %defattr(-,root,root)
1632 %{_infodir}/libc.info*
1633 %endif
1634
1635 #
1636 # glibc-doc-pdf
1637 #
1638 %if %{build_pdf_doc}
1639 %files doc-pdf
1640 %defattr(-,root,root)
1641 %doc manual/libc.pdf
1642 %endif
1643
1644 #
1645 # glibc-debug
1646 #
1647 %if %{build_debug}
1648 %files debug
1649 %defattr(-,root,root)
1650 %dir %{_libdir}/debug
1651 %{_libdir}/debug/*.so
1652 %{_libdir}/debug/*.so.*
1653 %if %isarch mips mipsel
1654 %dir %{_libdir}/debug/lib32
1655 %{_libdir}/debug/lib32/*.so
1656 %{_libdir}/debug/lib32/*.so.*
1657 %dir %{_libdir}/debug/lib64
1658 %{_libdir}/debug/lib64/*.so
1659 %{_libdir}/debug/lib64/*.so.*
1660 %endif
1661 %endif
1662
1663 #
1664 # glibc-profile
1665 #
1666 %if %{build_profile}
1667 %files profile
1668 %defattr(-,root,root)
1669 %{_libdir}/lib*_p.a
1670 %if %{build_biarch}
1671 %{_prefix}/lib/lib*_p.a
1672 %endif
1673 %if %isarch mips mipsel
1674 %{_libdir}32/lib*_p.a
1675 %{_libdir}64/lib*_p.a
1676 %endif
1677 %endif
1678
1679 #
1680 # glibc-utils
1681 #
1682 %if %{build_utils}
1683 %files utils
1684 %defattr(-,root,root)
1685 %if %{build_biarch}
1686 %{_slibdir32}/libmemusage.so
1687 %{_slibdir32}/libpcprofile.so
1688 %endif
1689 %{_slibdir}/libmemusage.so
1690 %{_slibdir}/libpcprofile.so
1691 %{_bindir}/memusage
1692 %{_bindir}/memusagestat
1693 %{_bindir}/mtrace
1694 %{_bindir}/pcprofiledump
1695 %{_bindir}/xtrace
1696 %if %isarch mips mipsel
1697 %{_slibdir}32/libmemusage.so
1698 %{_slibdir}32/libpcprofile.so
1699 %{_slibdir}64/libmemusage.so
1700 %{_slibdir}64/libpcprofile.so
1701 %endif
1702 %endif
1703
1704 #
1705 # nscd
1706 #
1707 %if %{build_nscd}
1708 %files -n nscd
1709 %defattr(-,root,root)
1710 %config(noreplace) %{_sysconfdir}/nscd.conf
1711 %config(noreplace) %{_initrddir}/nscd
1712 %{_sbindir}/nscd
1713 %endif
1714
1715 #
1716 # timezone
1717 #
1718 %if %{build_timezone}
1719 %files -n timezone
1720 %defattr(-,root,root)
1721 %{_sbindir}/zdump
1722 %{_sbindir}/zic
1723 %{_mandir}/man1/zdump.1*
1724 %dir %{_datadir}/zoneinfo
1725 %{_datadir}/zoneinfo/*
1726 %endif
1727
1728 #
1729 # glibc-i18ndata
1730 #
1731 %if %{build_i18ndata}
1732 %files i18ndata
1733 %defattr(-,root,root)
1734 %dir %{_datadir}/i18n
1735 %dir %{_datadir}/i18n/charmaps
1736 %{_datadir}/i18n/charmaps/*
1737 %dir %{_datadir}/i18n/locales
1738 %{_datadir}/i18n/locales/*
1739 %{_datadir}/i18n/SUPPORTED
1740 %endif

  ViewVC Help
Powered by ViewVC 1.1.30