Sophie

Sophie

distrib > Mandriva > 10.2 > x86_64 > by-pkgid > b61eac44124317f0c83f92720f0243c8 > files > 54

glibc-2.3.4-8mdk.src.rpm

# RH 2.2.4-20, SuSE 2.3.1-32
%define name		%{cross_prefix}glibc

# Define Mandrake Linux version we are building for
%define mdkversion	%(perl -pe '/(\\d+)\\.(\\d)\\.?(\\d)?/; $_="$1$2".($3||0)' /etc/mandrake-release)

# <version>-<release> tags for glibc main package
%define glibcversion	2.3.4
%define glibcrelease	8mdk
%define glibcepoch	6
# <version>-<release> tags from kernel package where headers were
# actually extracted from
%define kheaders_ver	2.6.11
%define kheaders_rel	2mdk
# Don't care about locales/* and pt_chown
%define _unpackaged_files_terminate_build 0
# Add errno compat hack for errata
%define build_errata	0

# CVS snapshots of glibc
%define RELEASE		0
%if %{RELEASE}
%define source_package	glibc-%{glibcversion}
%define source_dir	glibc-%{glibcversion}
%else
%define snapshot	20050301
%define source_package	glibc-%{glibcversion}-%{snapshot}
%define source_dir	glibc-%{glibcversion}
%endif

# Define "cross" to an architecture to which glibc is to be
# cross-compiled
%if %{?cross:1}%{!?cross:0}
%define target_cpu	%{cross}
%define cross_prefix	cross-%{target_cpu}-
%define _prefix		/usr/%{target_cpu}-linux
# FIXME: handle lib64 target platforms
#define lib64arches	ppc64|powerpc64|s390x|sparc64|x86_64|amd64
#define _lib		%(case %{target_arch} in (%{lib64arches}) echo lib64;; (*) echo lib;; esac)
%define _lib		lib
%define _slibdir	%{_prefix}/%{_lib}
%define _ssbindir	%{_sbindir}
%else
%define target_cpu	%{_target_cpu}
%define cross_prefix	%{nil}
%define _slibdir	/%{_lib}
%define _ssbindir	/sbin
%endif

# Define target architecture
%define arch		%(echo %{target_cpu}|sed -e "s/i.86/i386/" -e "s/athlon/i386/" -e "s/amd64/x86_64/")

# Define TLS architectures
%define tlsarches	%{ix86} x86_64 amd64 sparc ppc ppc64 ia64

# Define architectures accepting glibc-compat
%define glibc_compat_arches %{ix86} alpha alphaev6 sparc sparcv9

# Define NPTL architectures
#define nptlkernel	2.5.70
#define nptlmask	[01].*|2.[0-4]*|2.5.[0-9]|2.5.[0-6][0-9]
%define nptlkernel	2.4.25
%define nptlmask	[01].*|2.[0-3]*|2.4.[0-9]*|2.4.1[0-9]*|2.4.2[0-4]*
%define nptlarches	i686|x86_64|amd64|ppc|ppc64|ia64
%define build_nptl	%(case `echo %{arch} | sed -e "s/i386/i686/"` in (%{nptlarches}) echo 1;; (*) echo 0;; esac)

# Define to build nscd with selinux support
%define build_selinux	0

# Flag for build_pdf_doc:
# 1	build glibc with PDF documentation
# 0	don't build PDF glibc documentation (e.g. for bootstrap build)
%define build_pdf_doc	1

# Enable checking by default for arches where we know tests all pass
%define build_check	1

# Define to build a biarch package
%define build_biarch	0
%ifarch sparc64 x86_64 ppc64
%define build_biarch	1
%endif

# Define to build glibc-debug package
%define build_debug	1
%if %{mdkversion} >= 920
%define _enable_debug_packages 1
%endif
%if "%{_enable_debug_packages}" == "1"
%define build_debug	0
%endif

# Define to build with distcc
%define build_distcc	0

# Define to bootstrap new glibc
%define build_bootstrap	0
%{expand: %{!?build_cross_bootstrap: %global build_cross_bootstrap 0}}

%define build_profile	1
%define build_nscd	1
%define build_doc	1
%define build_utils	1
%define build_i18ndata	1
%define build_timezone	1

# Disable a few defaults when cross-compiling a glibc
%if "%{name}" != "glibc"
%define build_doc	0
%define build_pdf_doc	0
%define build_biarch	0
%define build_check	0
%define build_debug	0
%define build_nscd	0
%define build_profile	0
%define build_utils	0
%define build_i18ndata	0
%define build_timezone	0
%endif

# Allow --with[out] <feature> at rpm command line build
%{expand: %{?_without_PDF:	%%global build_pdf_doc 0}}
%{expand: %{?_without_CHECK:	%%global build_check 0}}
%{expand: %{?_without_UTILS:	%%global build_utils 0}}
%{expand: %{?_without_BOOTSTRAP:%%global build_bootstrap 0}}
%{expand: %{?_with_PDF:		%%global build_pdf_doc 1}}
%{expand: %{?_with_CHECK:	%%global build_check 1}}
%{expand: %{?_with_UTILS:	%%global build_utils 1}}
%{expand: %{?_with_BOOTSTRAP:	%%global build_bootstrap 1}}
%{expand: %{?_with_DISTCC:	%%global build_distcc 1}}

Summary:	The GNU libc libraries
Name:		%{name}
Version:	%{glibcversion}
Release:	%{glibcrelease}
Epoch:		%{glibcepoch}
License:	LGPL
Group:		System/Libraries
Url:		http://www.gnu.org/software/libc/

# Red Hat tarball
Source0:	%{source_package}.tar.bz2
Source1:	glibc-redhat.tar.bz2
Source2:	glibc-manpages.tar.bz2
Source3:	glibc-find-requires.sh
Source4:	glibc-compat.tar.bz2
Source5:	glibc-check.sh

# Generated from Kernel-RPM
Source10:	kernel-headers-%{kheaders_ver}.%{kheaders_rel}.tar.bz2
Source11:	make_versionh.sh
Source12:	create_asm_headers.sh

# service --full-restart-all from initscripts 6.91-18mdk
Source13:	glibc-post-upgrade

Buildroot:	%{_tmppath}/glibc-%{PACKAGE_VERSION}-root
Obsoletes:	zoneinfo, libc-static, libc-devel, libc-profile, libc-headers,
Obsoletes: 	linuxthreads, gencat, locale, glibc-localedata
Provides:	glibc-localedata
Autoreq:	false
BuildRequires:	patch, gettext, perl
%if %{build_selinux}
BuildRequires:	libselinux-devel >= 1.17.10
%endif
BuildRequires:	%{cross_prefix}binutils >= 2.13.90.0.18-2mdk
PreReq:         sash >= 3.6 /bin/sh
# we need an rpm with correct db4 lib
Requires:	rpm >= 4.2.2
# we need an ldconfig with TLS support
PreReq:		ldconfig >= %{glibcepoch}:2.3.3-3mdk
%if "%{name}" != "glibc"
ExclusiveArch:	%{ix86}
%endif
%if "%{name}" != "glibc"
BuildPreReq:	%{cross_prefix}gcc >= 3.2.2-4mdk
%endif
%ifarch %{ix86} alpha
BuildPreReq:	gcc >= 2.96-0.50mdk
%endif
%ifarch ia64
BuildPreReq:	gcc >= 3.2.3-1mdk
%endif
%ifarch x86_64
BuildPreReq:	gcc >= 3.1.1-0.5mdk
%endif
%ifarch alpha
Provides:	ld.so.2
%endif
%ifarch ppc
Provides:	ld.so.1
%endif
%ifarch sparc
Obsoletes:	libc
%endif

Conflicts:	rpm <= 4.0-0.65
Conflicts:	%{name}-devel < 2.2.3
# We need initscripts recent enough to not restart service dm
Conflicts:	initscripts < 6.91-18mdk

%if %{build_pdf_doc}
BuildRequires:	texinfo, tetex, tetex-latex
%endif
%if %{build_utils}
BuildRequires:	gd-devel
%endif
BuildRequires:	autoconf2.5

Patch0:		glibc-2.3.3-kernel-2.4.patch.bz2
Patch1:		glibc-2.2.2-fhs.patch.bz2
Patch2:		glibc-2.3.4-ldd-non-exec.patch.bz2
Patch3:		glibc-2.1.92-pthread_create-manpage.patch.bz2
Patch4:		glibc-2.1.95-string2-pointer-arith.patch.bz2
Patch5:		glibc-2.2-nss-upgrade.patch.bz2
Patch6:		glibc-2.2.5-ldconfig-exit-during-install.patch.bz2
Patch7:		glibc-2.2.5-share-locale.patch.bz2
Patch8:		glibc-2.2.3-samba-wins-hosts.patch.bz2
Patch9:		glibc-2.3.3-new-charsets.patch.bz2
Patch10:	glibc-2.2.4-xterm-xvt.patch.bz2
Patch11:	glibc-2.2.4-hack-includes.patch.bz2
Patch12:	glibc-2.3.3-compat-EUR-currencies.patch.bz2
Patch13:	glibc-2.3.3-ppc-build-lddlibc4-ld-linux.patch.bz2
# ThizLinux version for correct gb18030 support
Patch14:	glibc-2.2.5-gb18030-updates.patch.bz2
Patch15:	glibc-2.3.4-glibc22-compat.patch.bz2
Patch16:	glibc-2.2.5-hwcap-check-platform.patch.bz2
Patch17:	glibc-2.3.3-nscd-enable.patch.bz2
Patch18:	glibc-2.3.4-i586-hptiming.patch.bz2
Patch19:	glibc-2.3.3-i386-fix-hwcaps.patch.bz2
Patch20:	glibc-2.3.2-config-amd64-alias.patch.bz2
Patch21:	glibc-2.2.5-nscd-no-host-cache.patch.bz2
Patch22:	glibc-2.3.1-quota.patch.bz2
Patch23:	glibc-2.3.4-i586-if-no-cmov.patch.bz2
Patch24:	glibc-2.3.3-x86_64-new-libm.patch.bz2
Patch25:	glibc-2.3.4-nscd-fixes.patch.bz2
Patch26:	glibc-2.3.4-nscd-HUP.patch.bz2
Patch27:	glibc-2.3.2-errno-compat.patch.bz2
Patch28:	glibc-2.3.2-tcsetattr-kernel-bug-workaround.patch.bz2
Patch29:	glibc-2.3.4-timezone.patch.bz2
Patch30:	glibc-2.3.2-libm-ulps.patch.bz2
Patch31:	glibc-2.3.4-tls-compat.patch.bz2
Patch32:	glibc-2.3.3-lt-nptl-compat.patch.bz2
Patch33:	glibc-2.3.3-gcc34-mtune.patch.bz2
Patch34:	glibc-2.3.3-biarch-cpp-defines.patch.bz2
Patch35:	glibc-2.3.4-run-test-program-prefix.patch.bz2
Patch36:	glibc-2.3.4-i586-no-tls-libs.patch.bz2
Patch37:	glibc-2.3.4-tls-kernel.patch.bz2
Patch38:	glibc-2.3.3-tst-clock1-no-hptiming.patch.bz2
Patch39:	glibc-2.3.4-noversion.patch.bz2
Patch40:	glibc-2.3.3-x86_64-pow10-aliases.patch.bz2
Patch41:	glibc-2.3.3-nice-fix.patch.bz2
Patch42:	glibc-2.3.3-cross-bootstrap.patch.bz2
Patch43:	glibc-2.3.3-compat-mode.patch.bz2
Patch44:	glibc-2.3.4-fix-initstate_r.patch.bz2

# Generated from Kernel RPM
Patch100:	kernel-headers-include-%{kheaders_ver}.%{kheaders_rel}.patch.bz2
Patch101:	kernel-headers-gnu-extensions.patch.bz2
Patch102:	kernel-headers-syscall-mem-clobbers.patch.bz2

# Determine minium kernel versions
%ifarch ia64 x86_64
Conflicts:		kernel < 2.4.0
%define enablemask	[01].*|2.[0-3]*
%else
%ifarch %{ix86}
%define enablemask	[01].*|2.[0-3]*|2.4.0*
%else
%define enablemask	[01].*|2.[0-1]*|2.2.[0-4]|2.2.[0-4][^0-9]*
%endif
%endif

# Don't try to explicitly provide GLIBC_PRIVATE versioned libraries
%define __find_provides	%{_builddir}/%{source_dir}/find_provides.sh
%define __find_requires %{_builddir}/%{source_dir}/find_requires.sh

Obsoletes:	ld.so
Provides:	ld.so

%description
The glibc package contains standard libraries which are used by
multiple programs on the system. In order to save disk space and
memory, as well as to make upgrading easier, common system code is
kept in one place and shared between programs. This particular package
contains the most important sets of shared libraries: the standard C
library and the standard math library. Without these two libraries, a
Linux system will not function.  The glibc package also contains
national language (locale) support.

%package -n ldconfig
Summary:	Creates a shared library cache and maintains symlinks for ld.so
Group:		System/Base

%description -n ldconfig
Ldconfig is a basic system program which determines run-time link
bindings between ld.so and shared libraries. Ldconfig scans a running
system and sets up the symbolic links that are used to load shared
libraries properly. It also creates a cache (/etc/ld.so.cache) which
speeds the loading of programs which use shared libraries.

%package devel
Summary:	Header and object files for development using standard C libraries
Group:		Development/C
Conflicts:	texinfo < 3.11
Prereq:		/sbin/install-info
Obsoletes:	libc-debug, libc-headers, libc-devel, linuxthreads-devel
%if !%{build_debug}
Obsoletes:	glibc-debug < 6:2.3.2-15mdk
%endif
Requires:	%{name} = %{glibcepoch}:%{glibcversion}-%{glibcrelease}
Obsoletes:	kernel-headers
Provides:	kernel-headers = 1:%{kheaders_ver}
%ifnarch ppc
Conflicts:	gcc < 2.96-0.50mdk
%endif
Autoreq:	true

%description devel
The glibc-devel package contains the header and object files necessary
for developing programs which use the standard C libraries (which are
used by nearly all programs).  If you are developing programs which
will use the standard C libraries, your system needs to have these
standard header and object files available in order to create the
executables.

This package also includes the C header files for the Linux kernel.
The header files define structures and constants that are needed for
building most standard programs. The header files are also needed for
rebuilding the kernel.

Install glibc-devel if you are going to develop programs which will
use the standard C libraries.

%package static-devel
Summary:	Static libraries for GNU C library
Group:		Development/C
Requires:	%{name}-devel = %{glibcepoch}:%{glibcversion}-%{glibcrelease}

%description static-devel
The glibc-static-devel package contains the static libraries necessary
for developing programs which use the standard C libraries. Install
glibc-static-devel if you need to statically link your program or
library.

%package -n nptl-devel
Summary:	Header files and static libraries for development using NPTL library.
Group:		Development/Libraries
Requires:	%{name}-devel = %{glibcepoch}:%{glibcversion}-%{glibcrelease}
Autoreq:	true

%description -n nptl-devel
The nptl-devel package contains the header and object files necessary
for developing programs which use the NPTL library (and either need
NPTL specific header files or want to link against NPTL statically).

%package profile
Summary:	The GNU libc libraries, including support for gprof profiling
Group:		Development/C
Obsoletes:	libc-profile
Provides:	libc-profile = %{glibcversion}-%{glibcrelease}
Autoreq:	true

%description profile
The glibc-profile package includes the GNU libc libraries and support
for profiling using the gprof program.  Profiling is analyzing a
program's functions to see how much CPU time they use and determining
which functions are calling other functions during execution.  To use
gprof to profile a program, your program needs to use the GNU libc
libraries included in glibc-profile (instead of the standard GNU libc
libraries included in the glibc package).

If you are going to use the gprof program to profile a program, you'll
need to install the glibc-profile program.

%package -n nscd
Summary:	A Name Service Caching Daemon (nscd)
Group:		System/Servers
Conflicts:	kernel < 2.2.0
PreReq:		/sbin/chkconfig
PreReq:		rpm-helper
Autoreq:	true

%description -n nscd
Nscd caches name service lookups and can dramatically improve
performance with NIS+, and may help with DNS as well. Note that you
can't use nscd with 2.0 kernels because of bugs in the kernel-side
thread support. Unfortunately, nscd happens to hit these bugs
particularly hard.

Install nscd if you need a name service lookup caching daemon, and
you're not using a version 2.0 kernel.

%if %{build_debug}
%package	debug
Summary:	Shared standard C libraries with debugging information
Group:		System/Libraries
Requires:	%{name} = %{glibcepoch}:%{glibcversion}-%{glibcrelease}
Autoreq:	false

%description debug
The glibc-debug package contains shared standard C libraries with
debugging information. You need this only if you want to step into C
library routines during debugging.

To use these libraries, you need to add %{_libdir}/debug to your
LD_LIBRARY_PATH variable prior to starting the debugger.
%endif

%package utils
Summary:	Development utilities from GNU C library
Group:		Development/Other
Requires:	%{name} = %{glibcepoch}:%{glibcversion}-%{glibcrelease}

%description utils
The glibc-utils package contains memusage, a memory usage profiler,
mtrace, a memory leak tracer and xtrace, a function call tracer which
can be helpful during program debugging.

If unsure if you need this, don't install this package.

%package i18ndata
Summary:	Database sources for 'locale'
Group:		System/Libraries

%description i18ndata
This package contains the data needed to build the locale data files
to use the internationalization features of the GNU libc.

%package -n timezone
Summary:	Time zone descriptions
Group:		System/Base
Conflicts:	glibc < 2.2.5-6mdk

%description -n timezone
These are configuration files that describe possible
time zones.

%package doc
Summary:	GNU C library documentation
Group:		Development/Other

%description doc
The glibc-doc package contains documentation for the GNU C library in
info format.

%if %{build_pdf_doc}
%package doc-pdf
Summary:	GNU C library documentation
Group:		Development/Other

%description doc-pdf
The glibc-doc-pdf package contains the printable documentation for the
GNU C library in PDF format.
%endif

%prep
%setup -q -n %{source_dir} -a 10 -a 2 -a 1 -a 4
%patch1 -p1 -b .fhs
%patch2 -p1 -b .ldd-non-exec
%patch3 -p1 -b .pthread_create-manpage
%patch4 -p1 -b .string2-pointer-arith
%patch5 -p1 -b .nss-upgrade
%patch6 -p1 -b .ldconfig-exit-during-install
%patch7 -p1 -b .share-locale
%patch8 -p1 -b .samba-wins-hosts
%patch9 -p1 -b .new-charsets
%patch10 -p1 -b .xterm-xvt
%patch11 -p1 -b .hack-includes
%patch12 -p1 -b .compat-EUR-currencies
%patch13 -p1 -b .ppc-build
#%patch14 -p1 -b .gb18030-updates
%patch15 -p1 -b .glibc22-compat
%patch16 -p1 -b .hwcap-check-platform
%patch17 -p1 -b .nscd-enable
%patch18 -p1 -b .i586-hptiming
%patch19 -p1 -b .i386-fix-hwcaps
%patch20 -p1 -b .config-amd64-alias
%patch21 -p1 -b .nscd-no-host-cache
%patch22 -p1 -b .quota
%patch23 -p1 -b .i586-if-no-cmov
%patch24 -p1 -b .x86_64-new-libm -E
%patch25 -p1 -b .nscd-fixes
%patch26 -p1 -b .nscd-HUP
%if %{build_errata}
%patch27 -p1 -b .errno-compat
%endif
%patch28 -p1 -b .tcsetattr-kernel-bug-workaround
%patch29 -p1 -b .timezone
%patch30 -p1 -b .libm-ulps
%patch31 -p1 -b .tls-compat
%patch32 -p1 -b .lt-nptl-compat
%patch34 -p1 -b .biarch-cpp-defines
%patch35 -p1 -b .run-test-program-prefix
%patch36 -p1 -b .i586-no-tls-libs
%patch37 -p1 -b .tls-kernel
%patch38 -p1 -b .tst-clock1-no-hptiming
%patch39 -p1 -b .noversion
%patch40 -p1 -b .x86_64-pow10-aliases
%patch41 -p1 -b .nice-fix
%if %{build_cross_bootstrap}
%patch42 -p1 -b .cross-bootstrap
%endif
# XXX have a proper look
#patch43 -p1 -b .compat
%patch44 -p1 -b .fix-initstate_r

%ifnarch %{glibc_compat_arches}
rm -rf glibc-compat
%endif

# s/-mcpu/-mtune/ on x86 with gcc3.4
{ echo "int main() {}" | gcc -mcpu=pentiumpro -xc - 2>&1 | grep -q deprecated; } && \
%patch33 -p1 -b .gcc34-mtune

# If we are building enablekernel 2.x.y glibc on older kernel,
# we have to make sure no binaries compiled against that glibc
# are ever run
older_kernel=
case `uname -r` in
%enablemask)
  older_kernel=yes
  ;;
esac
%if %{build_nptl}
case `uname -r` in
%nptlmask)
  older_kernel=yes
  ;;
esac
%endif
if [[ -n "$older_kernel" ]]; then
%patch0 -p1 -b .older-kernel-build
fi

%ifarch armv4l
rm -rf glibc-compat
%endif

pushd kernel-headers/
TARGET=%{target_cpu}
%patch100 -p1
%patch101 -p1
%patch102 -p1
%{expand:%(%__cat %{SOURCE11})}
%{expand:%(%__cat %{SOURCE12})}
popd

%if %{build_selinux}
# XXX kludge to build nscd with selinux support as it added -nostdinc
# so /usr/include/selinux is not found
ln -s %{_includedir}/selinux selinux
%endif

find . -type f -size 0 -o -name "*.orig" -exec rm -f {} \;

cat > find_provides.sh << EOF
#!/bin/sh
/usr/lib/rpm/find-provides | grep -v GLIBC_PRIVATE
exit 0
EOF
chmod +x find_provides.sh

cat > find_requires.bootstrap.sh << EOF
/bin/sh %{SOURCE3} %{buildroot} %{_target_cpu} | grep -v "\(GLIBC_PRIVATE\|linux-gate\)"
exit 0
EOF
chmod +x find_requires.bootstrap.sh

cat > find_requires.noprivate.sh << EOF
/usr/lib/rpm/find-requires %{buildroot} %{_target_cpu} | grep -v GLIBC_PRIVATE
exit 0
EOF
chmod +x find_requires.noprivate.sh

# FIXME: fix system rpm find-requires to use the prefix cross version
%if %{build_bootstrap} || "%{_target_cpu}" != "%{target_cpu}"
ln -s find_requires.bootstrap.sh find_requires.sh
%else
ln -s find_requires.noprivate.sh find_requires.sh
%endif

%build
#
# BuildGlibc <arch> [<extra_configure_options>+]
#
function BuildGlibc() {
  arch="$1"
  shift 1
  nptl=

  # Select minimal kernel version
  case $arch in
    ppc64)
      EnableKernel=2.4.21
      ;;
    ia64 | x86_64 | amd64)
      EnableKernel=2.4.0
      ;;
    i686 | athlon)
      EnableKernel=2.4.1
      ;;
    nptl,*)
      nptl=nptl
      arch=${arch/nptl,/}
      case $arch in
      %{nptlarches})
        EnableKernel=%{nptlkernel}
        ;;
      *)
        echo "ERROR: requesting unsupported NPTL build"
        exit 1
        ;;
      esac
      ;;
    *)
      EnableKernel=2.2.5
      ;;
  esac

  # Select optimization flags and compiler to use
  BuildCompFlags=""
  BuildFlags=""
  case $arch in
    i[3456]86 | athlon)
      BuildFlags="-march=$arch"
      if [[ "`uname -m`" = "x86_64" ]]; then
        BuildCompFlags="-m32"
      fi
      ;;
    ppc)
      if [[ "`uname -m`" = "ppc64" ]]; then
        BuildCompFlags="-m32"
      fi
      ;;
    alphaev6)
      BuildFlags="-mcpu=ev6"
      ;;
    sparc)
      BuildFlags="-fcall-used-g6"
      BuildCompFlags="-m32"
      ;;
    sparcv9)
      BuildFlags="-mcpu=ultrasparc -fcall-used-g6"
      BuildCompFlags="-m32"
      ;;
    sparc64)
      BuildFlags="-mcpu=ultrasparc -mvis -fcall-used-g6"
      BuildCompFlags="-m64"
      ;;
  esac

  # Determine C & C++ compilers
  BuildCC="%{__cc} $BuildCompFlags"
  BuildCXX="%{__cxx} $BuildCompFlags"
%if %{build_distcc}
  DistCC="distcc"
%endif

  # Are we supposed to cross-compile?
  if [[ "%{target_cpu}" != "%{_target_cpu}" ]]; then
    BuildCC="%{target_cpu}-linux-$BuildCC"
    BuildCXX="%{target_cpu}-linux-$BuildCXX"
    BuildCross="--build=%{_target_platform}"
  fi

  BuildFlags="$BuildFlags -DNDEBUG=1 -O2 -finline-functions -g"
  if $BuildCC -v 2>&1 | grep -q 'gcc version 3.0'; then
    # gcc3.0 had really poor inlining heuristics causing problems in
    # resulting ld.so
    BuildFlags="$BuildFlags -finline-limit=2000"
  fi

  # Help systems with a reasonnable amount of registers
  if $BuildCC -frename-registers -S -o /dev/null -xc /dev/null 2>&1; then
    BuildFlags="$BuildFlags -frename-registers"
  fi

  # FIXME: ppc64 specific flags
  if [[ "$arch" = "ppc64" ]]; then
    BuildFlags="$BuildFlags -fno-inline-functions -mno-minimal-toc"
  fi

  # FIXME: don't use unit at time compilation
  if $BuildCC -funit-at-a-time -S -o /dev/null -xc /dev/null 2>&1; then
    BuildFlags="$BuildFlags -fno-unit-at-a-time"
  fi

  if [[ "%{build_profile}" = "0" ]]; then
    ExtraFlags="$ExtraFlags --disable-profile"
  fi

  # Build with TLS
%ifarch %{tlsarches}
  TlsFlags="--with-tls"
%else
  TlsFlags="--without-tls"
%endif
  if [[ -n "$nptl" ]]; then
    Pthreads="nptl"
    TlsFlags="$TlsFlags --with-__thread"
  else
    Pthreads="linuxthreads"
    TlsFlags="$TlsFlags --without-__thread"
  fi

  # Build with selinux support?
%if %{build_selinux}
  SElinuxFlags="--with-selinux"
%else
  SElinuxFlags="--without-selinux"
%endif

  # Kernel headers directory
  KernelHeaders=$PWD/kernel-headers

  # Determine library name
  glibc_cv_cc_64bit_output=no
  if echo ".text" | $BuildCC -c -o test.o -xassembler -; then
    case `/usr/bin/file test.o` in
    *"ELF 64"*)
      glibc_cv_cc_64bit_output=yes
      ;;
    esac
  fi
  rm -f test.o

  # Extra packages to build
%ifarch %{glibc_compat_arches}
  AddOns=",glibc-compat"
%endif

  # Force a separate and clean object dir
  rm -rf build-$arch-linux$nptl
  mkdir  build-$arch-linux$nptl
  pushd  build-$arch-linux$nptl
  CC="$DistCC $BuildCC" CXX="$DistCC $BuildCXX" CFLAGS="$BuildFlags" ../configure \
    $arch-mandrake-linux-gnu $BuildCross \
    --prefix=%{_prefix} \
    --libexecdir=%{_prefix}/lib \
    --infodir=%{_infodir} \
    --enable-add-ons=$Pthreads$AddOns --without-cvs \
    $TlsFlags $ExtraFlags $SElinuxFlags \
    --enable-kernel=$EnableKernel --with-headers=$KernelHeaders ${1+"$@"}
  %make -r CFLAGS="$BuildFlags" PARALLELMFLAGS=-s
  popd
}

# Build main glibc
BuildGlibc %{target_cpu}

%if %{build_biarch}
# Build i586 libraries, and preserve maximum compatibility
%ifarch sparc64
BuildGlibc sparc
%endif
%ifarch x86_64
BuildGlibc i586
%endif
%ifarch ppc64
BuildGlibc ppc
%endif
%endif

# Build i686 libraries if not already building for i686/athlon
case %{target_cpu} in
  i686 | athlon)
    ;;
  i[3-6]86)
    BuildGlibc i686 --disable-profile
    ;;
esac

# Build NPTL libraries
case %{target_cpu} in
  %{nptlarches})
    BuildGlibc nptl,%{target_cpu} --disable-profile
    ;;
  i[3-6]86 | athlon)
    BuildGlibc nptl,i686 --disable-profile
    ;;
esac

# Determine running kernel version
function KernelId() {
  echo $1 | perl -pe '/(\d+)\.(\d\d?)\.(\d\d?)?/; $_=($1*10000)+($2*100)+($3||0)'
}
NPTLKernelVersion=`KernelId %{nptlkernel}`
HostKernelVersion=`KernelId $(uname -r)`

# Regression testsuite
%ifnarch %{ix86} x86_64 ia64 ppc
K=-k
%endif
CheckList=$PWD/Check.list
echo "%_smp_mflags -d build-%{_target_cpu}-linux $K"		> $CheckList
case `uname -m` in
  i686 | athlon) ALT_ARCH=i686;;
  x86_64)        ALT_ARCH=i586; ln -s . build-$ALT_ARCH-linux/csu/32;;
  ppc64)         ALT_ARCH=ppc;  ln -s . build-$ALT_ARCH-linux/csu/32;;
esac
[[ -n "$ALT_ARCH" && -d "build-$ALT_ARCH-linux" ]] &&
echo "%_smp_mflags -d build-$ALT_ARCH-linux $K"			>> $CheckList
if [[ $HostKernelVersion -ge $NPTLKernelVersion ]]; then
[[ -n "$ALT_ARCH" && -d "build-$ALT_ARCH-linuxnptl" ]] &&
echo "%_smp_mflags -d build-$ALT_ARCH-linuxnptl $K"		>> $CheckList
[[ -n "$ALT_ARCH" && -d "build-%{_target_cpu}-linuxnptl" ]] &&
echo "%_smp_mflags -d build-%{_target_cpu}-linuxnptl $K"	>> $CheckList
fi
case `uname -m` in
i686 | athlon)
  echo "%_smp_mflags -d build-$ALT_ARCH-linux     $K -l build-%{_target_cpu}-linux/elf/ld.so"		>> $CheckList
  if [[ $HostKernelVersion -ge $NPTLKernelVersion ]]; then
  echo "%_smp_mflags -d build-$ALT_ARCH-linuxnptl $K -l build-%{_target_cpu}-linux/elf/ld.so"		>> $CheckList
  fi
  ;;
esac
%if %{build_check}
export TMPDIR=/tmp
export TIMEOUTFACTOR=16
Check="$PWD/glibc-check.sh"
cat %{SOURCE5} > $Check
chmod +x $Check
cat $CheckList | while read arglist; do
  $Check $arglist || exit 1;
done
%endif

%install
rm -rf $RPM_BUILD_ROOT

make install_root=$RPM_BUILD_ROOT install -C build-%{target_cpu}-linux
%if %{build_i18ndata}
(cd build-%{target_cpu}-linux; %make install_root=$RPM_BUILD_ROOT install-locales -C ../localedata objdir=`pwd`)
%endif
sh manpages/Script.sh

# Empty filelist for non i686/athlon targets
> extralibs.filelist

# Install biarch libraries
%if %{build_biarch}
%ifarch sparc64
ALT_ARCH=sparc-linux
%endif
%ifarch x86_64
ALT_ARCH=i586-linux
%endif
%ifarch ppc64
ALT_ARCH=ppc-linux
%endif
mkdir -p $RPM_BUILD_ROOT/$ALT_ARCH
make install_root=$RPM_BUILD_ROOT/$ALT_ARCH install -C build-$ALT_ARCH
(cd build-$ALT_ARCH;
  %make -C ../localedata objdir=`pwd` \
	install_root=$RPM_BUILD_ROOT/$ALT_ARCH \
	install-locales
)
# Dispatch */lib only
mv $RPM_BUILD_ROOT/$ALT_ARCH/lib $RPM_BUILD_ROOT/
%ifarch x86_64
rm -f  $RPM_BUILD_ROOT/$ALT_ARCH%{_prefix}/lib/pt_chown
mv     $RPM_BUILD_ROOT/$ALT_ARCH%{_prefix}/lib/getconf/* $RPM_BUILD_ROOT%{_prefix}/lib/getconf/
rmdir  $RPM_BUILD_ROOT/$ALT_ARCH%{_prefix}/lib/getconf
%endif
mv     $RPM_BUILD_ROOT/$ALT_ARCH%{_prefix}/lib/* $RPM_BUILD_ROOT%{_prefix}/lib/
rm -rf $RPM_BUILD_ROOT/$ALT_ARCH
%endif

# Install extra glibc libraries
function InstallGlibc() {
  BuildDir="$1"
  SubDir="$2"
  shift 2

  case $BuildDir in
  *nptl)
    Pthreads=nptl
    ;;
  *)
    Pthreads=linuxthreads
    ;;
  esac

  pushd $BuildDir
  mkdir -p $RPM_BUILD_ROOT%{_slibdir}/$SubDir/
  cp -a libc.so $RPM_BUILD_ROOT%{_slibdir}/$SubDir/`basename $RPM_BUILD_ROOT%{_slibdir}/libc-*.so`
  ln -sf `basename $RPM_BUILD_ROOT%{_slibdir}/libc-*.so` $RPM_BUILD_ROOT%{_slibdir}/$SubDir/`basename $RPM_BUILD_ROOT%{_slibdir}/libc.so.*`
  cp -a math/libm.so $RPM_BUILD_ROOT%{_slibdir}/$SubDir/`basename $RPM_BUILD_ROOT%{_slibdir}/libm-*.so`
  ln -sf `basename $RPM_BUILD_ROOT%{_slibdir}/libm-*.so` $RPM_BUILD_ROOT%{_slibdir}/$SubDir/`basename $RPM_BUILD_ROOT%{_slibdir}/libm.so.*`
  cp -a $Pthreads/libpthread.so $RPM_BUILD_ROOT%{_slibdir}/$SubDir/`basename $RPM_BUILD_ROOT%{_slibdir}/libpthread-*.so`
  ln -sf `basename $RPM_BUILD_ROOT%{_slibdir}/libpthread-*.so` $RPM_BUILD_ROOT%{_slibdir}/$SubDir/`basename $RPM_BUILD_ROOT%{_slibdir}/libpthread.so.*`
  cp -a ${Pthreads}_db/libthread_db.so $RPM_BUILD_ROOT%{_slibdir}/$SubDir/`basename $RPM_BUILD_ROOT%{_slibdir}/libthread_db-*.so`
  ln -sf `basename $RPM_BUILD_ROOT%{_slibdir}/libthread_db-*.so` $RPM_BUILD_ROOT%{_slibdir}/$SubDir/`basename $RPM_BUILD_ROOT%{_slibdir}/libthread_db.so.*`
  cp -a rt/librt.so $RPM_BUILD_ROOT%{_slibdir}/$SubDir/`basename $RPM_BUILD_ROOT%{_slibdir}/librt-*.so`
  ln -sf `basename $RPM_BUILD_ROOT%{_slibdir}/librt-*.so` $RPM_BUILD_ROOT%{_slibdir}/$SubDir/`basename $RPM_BUILD_ROOT%{_slibdir}/librt.so.*`
  echo "%dir %{_slibdir}/$SubDir" >> ../extralibs.filelist
  find $RPM_BUILD_ROOT%{_slibdir}/$SubDir -type f -o -type l | sed -e "s|$RPM_BUILD_ROOT||" >> ../extralibs.filelist
  popd
}

# Install arch-specific optimized libraries
%ifarch %{ix86}
case %{target_cpu} in
i[3-5]86)
  InstallGlibc build-i686-linux i686
  ;;
esac
%endif

# Install NPTL libraries & development files
nptlbuilddir=`echo build-*-linuxnptl`
if [[ -d "$nptlbuilddir" ]]; then
  InstallGlibc $nptlbuilddir tls

  pushd $nptlbuilddir
  mkdir -p $RPM_BUILD_ROOT%{_libdir}/nptl
  cp -a libc.a nptl/libpthread.a nptl/libpthread_nonshared.a rt/librt.a \
    $RPM_BUILD_ROOT%{_libdir}/nptl/
  sed "s| /%{_lib}/| /%{_lib}/tls/|" $RPM_BUILD_ROOT%{_libdir}/libc.so \
    > $RPM_BUILD_ROOT%{_libdir}/nptl/libc.so
  sed "s|^GROUP (.*)|GROUP ( /%{_lib}/tls/"`basename $RPM_BUILD_ROOT/%{_lib}/libpthread.so.*`' %{_libdir}/nptl/libpthread_nonshared.a )|' \
    $RPM_BUILD_ROOT%{_libdir}/libc.so \
    > $RPM_BUILD_ROOT%{_libdir}/nptl/libpthread.so
  ln -sf /%{_lib}/tls/`basename $RPM_BUILD_ROOT/%{_lib}/librt-*.so` \
    $RPM_BUILD_ROOT%{_libdir}/nptl/librt.so

  mkdir -p $RPM_BUILD_ROOT/nptl
  make install_root=$RPM_BUILD_ROOT/nptl install-headers PARALLELMFLAGS=-s
  mkdir -p $RPM_BUILD_ROOT%{_includedir}/nptl
  pushd $RPM_BUILD_ROOT/nptl/%{_includedir}
  for i in `find . -type f`; do
    if ! [[ -f $RPM_BUILD_ROOT%{_includedir}/$i ]] || ! cmp -s $i $RPM_BUILD_ROOT%{_includedir}/$i; then
      mkdir -p $RPM_BUILD_ROOT%{_includedir}/nptl/`dirname $i`
      cp -a $i $RPM_BUILD_ROOT%{_includedir}/nptl/$i
    fi
  done
  popd
  rm -rf $RPM_BUILD_ROOT/nptl
  popd
fi

# Compatibility hack: this locale has vanished from glibc, but some other
# programs are still using it. Normally we would handle it in the %pre
# section but with glibc that is simply not an option
mkdir -p $RPM_BUILD_ROOT%{_datadir}/locale/ru_RU/LC_MESSAGES

# Remove the files we don't want to distribute
rm -f $RPM_BUILD_ROOT%{_libdir}/libNoVersion*
%ifnarch %{glibc_compat_arches}
rm -f $RPM_BUILD_ROOT%{_slibdir}/libNoVersion*
%endif

# The man pages for the linuxthreads require special attention
make -C linuxthreads/man
mkdir -p $RPM_BUILD_ROOT%{_mandir}/man3
install -m 0644 linuxthreads/man/*.3thr $RPM_BUILD_ROOT%{_mandir}/man3

ln -sf libbsd-compat.a $RPM_BUILD_ROOT%{_libdir}/libbsd.a
%if %{build_biarch}
ln -sf libbsd-compat.a $RPM_BUILD_ROOT%{_prefix}/lib/libbsd.a
%endif

%if "%{name}" == "glibc"
install -m 644 redhat/nsswitch.conf $RPM_BUILD_ROOT%{_sysconfdir}/nsswitch.conf
%endif

# Take care of setuids
# -- new security review sez that this shouldn't be needed anymore
#chmod 755 $RPM_BUILD_ROOT%{_libdir}/pt_chown

# This is for ncsd - in glibc 2.2
%if %{build_nscd}
install -m 644 nscd/nscd.conf $RPM_BUILD_ROOT%{_sysconfdir}
mkdir -p $RPM_BUILD_ROOT%{_initrddir}
install -m 755 nscd/nscd.init $RPM_BUILD_ROOT%{_initrddir}/nscd
%endif

# Useless and takes place
rm -rf %buildroot/%{_datadir}/zoneinfo/{posix,right}

# Don't include ld.so.cache
rm -f $RPM_BUILD_ROOT%{_sysconfdir}/ld.so.cache

# Include ld.so.conf
%if "%{name}" == "glibc"
echo "include ld.so.conf.d/*.conf" > $RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf
chmod 644 $RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf
mkdir -p  $RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf.d
%endif

# Include %{_libdir}/gconv/gconv-modules.cache
> $RPM_BUILD_ROOT%{_libdir}/gconv/gconv-modules.cache
chmod 644 $RPM_BUILD_ROOT%{_libdir}/gconv/gconv-modules.cache

# Add libraries to debug sub-package
%if %{build_debug}
mkdir $RPM_BUILD_ROOT%{_libdir}/debug
#cp -a $RPM_BUILD_ROOT%{_libdir}/*.a $RPM_BUILD_ROOT%{_libdir}/debug/
#rm -f $RPM_BUILD_ROOT%{_libdir}/debug/*_p.a
cp -a $RPM_BUILD_ROOT%{_slibdir}/lib*.so* $RPM_BUILD_ROOT%{_libdir}/debug/

pushd $RPM_BUILD_ROOT%{_libdir}/debug
for lib in *.so*; do
  [[ -f "$lib" ]] && DEBUG_LIBS="$DEBUG_LIBS %{_libdir}/debug/$lib"
done
popd
%endif

# Are we cross-compiling?
Strip="strip"
if [[ "%{_target_cpu}" != "%{target_cpu}" ]]; then
  Strip="%{target_cpu}-linux-$Strip"
fi

# Strip libpthread but keep some symbols
find $RPM_BUILD_ROOT%{_slibdir} -type f -name "libpthread-*.so" | \
     xargs $Strip -g -R .comment

%if %{build_biarch}
find $RPM_BUILD_ROOT/lib -type f -name "libpthread-*.so" | \
     xargs $Strip -g -R .comment
%endif

# Strip debugging info from all static libraries
pushd $RPM_BUILD_ROOT%{_libdir}
for i in *.a; do
  if [ -f "$i" ]; then
    case "$i" in
    *_p.a) ;;
    *) $Strip -g -R .comment $i ;;
    esac
  fi
done
popd

# post upgrade script
install -m 700 %{SOURCE13} $RPM_BUILD_ROOT%{_sbindir}/glibc-post-upgrade

# rquota.x and rquota.h are now provided by quota
rm -f $RPM_BUILD_ROOT%{_includedir}/rpcsvc/rquota.[hx]

# Hardlink identical locale files together
%if %{build_i18ndata}
gcc -O2 -o build-%{_target_cpu}-linux/hardlink redhat/hardlink.c
build-%{_target_cpu}-linux/hardlink -vc $RPM_BUILD_ROOT%{_datadir}/locale
%endif

rm -rf $RPM_BUILD_ROOT%{_includedir}/netatalk/

# (sb) PPC - built with ld-linux.so.2, but you get
# a nasty unusable system without retaining ld.so.1
%if "%{arch}" == "ppc"
pushd $RPM_BUILD_ROOT%{_slibdir}
ln -s ld-%{glibcversion}.so ld.so.1
popd
%endif
# likewise, only on native ppc64 biarch builds
%ifarch ppc64
[[ -f $RPM_BUILD_ROOT/lib/ld-linux.so.2 ]] &&
ln -s ld-linux.so.2 $RPM_BUILD_ROOT/lib/ld.so.1
%endif

# Build file list for devel package
find $RPM_BUILD_ROOT%{_includedir} -type f -or -type l > devel.filelist
find $RPM_BUILD_ROOT%{_includedir} -type d  | sed "s/^/%dir /" | \
  grep -v "%{_libdir}/libnss1.*.so$" | \
  grep -v "%{_includedir}$" | \
  grep -v "%{_includedir}/nptl" >> devel.filelist
find $RPM_BUILD_ROOT%{_libdir} -name "*.so" -o -name "*.o" -maxdepth 1 | egrep -v "(libmemusage.so|libpcprofile.so)" >> devel.filelist
# biarch libs
%if %{build_biarch}
find $RPM_BUILD_ROOT%{_prefix}/lib -name "*.so" -o -name "*.o" -maxdepth 1 | egrep -v "(libmemusage.so|libpcprofile.so)" >> devel.filelist
%endif
perl -pi -e "s|$RPM_BUILD_ROOT||" devel.filelist

%if %{build_utils}
if [[ "%{_slibdir}" != "%{_libdir}" ]]; then
mkdir -p $RPM_BUILD_ROOT%{_libdir}
mv -f $RPM_BUILD_ROOT%{_slibdir}/lib{pcprofile,memusage}.so $RPM_BUILD_ROOT%{_libdir}
for i in $RPM_BUILD_ROOT%{_prefix}/bin/{xtrace,memusage}; do
  cp -a $i $i.tmp
  sed -e 's~=%{_slibdir}/libpcprofile.so~=%{_libdir}/libpcprofile.so~' \
      -e 's~=%{_slibdir}/libmemusage.so~=%{_libdir}/libmemusage.so~' \
    $i.tmp > $i
  chmod 755 $i; rm -f $i.tmp
done
fi
%endif

# /etc/localtime - we're proud of our timezone #Well we(mdk) may put Paris
%if %{build_timezone}
rm -f $RPM_BUILD_ROOT%{_sysconfdir}/localtime
cp -f $RPM_BUILD_ROOT%{_datadir}/zoneinfo/US/Eastern $RPM_BUILD_ROOT%{_sysconfdir}/localtime
#ln -sf ..%{_datadir}/zoneinfo/US/Eastern $RPM_BUILD_ROOT%{_sysconfdir}/localtime
%endif

# [gg] build PDF documentation
%if %{build_pdf_doc}
(cd manual; texi2dvi -p -t @afourpaper -t @finalout libc.texinfo)
%endif

# Copy Kernel-Headers
mkdir -p $RPM_BUILD_ROOT%{_includedir}
mkdir -p $RPM_BUILD_ROOT/boot/
cp -avrf kernel-headers/* $RPM_BUILD_ROOT%{_includedir}
echo "#if 0" > $RPM_BUILD_ROOT/boot/kernel.h-%{kheaders_ver}

# the last bit: more documentation
rm -rf documentation
mkdir documentation
cp linuxthreads/ChangeLog  documentation/ChangeLog.threads
cp linuxthreads/Changes documentation/Changes.threads
cp linuxthreads/README documentation/README.threads
cp linuxthreads/FAQ.html documentation/FAQ-threads.html
cp -r linuxthreads/Examples documentation/examples.threads
cp crypt/README.ufc-crypt documentation/README.ufc-crypt
cp timezone/README documentation/README.timezone
cp ChangeLog* documentation
gzip -9 documentation/ChangeLog*

%find_lang libc

# Remove unpackaged files
rm -f $RPM_BUILD_ROOT%{_libdir}/pt_chown
find  $RPM_BUILD_ROOT%{_datadir}/locale/* -type d -maxdepth 1 | xargs rm -rf

# In case we are cross-compiling, don't bother to remake symlinks and
# fool spec-helper when stripping files
%if "%{name}" != "glibc"
export DONT_SYMLINK_LIBS=1
export PATH=%{_bindir}:$PATH
%endif

EXCLUDE_FROM_STRIP="ld-%{glibcversion}.so libpthread $DEBUG_LIBS"
export EXCLUDE_FROM_STRIP

%if "%{name}" == "glibc"
%define upgradestamp %{_slibdir}/glibc.upgraded
%define broken_link %{_slibdir}/libnss_nis.so.1 %{_slibdir}/libnss_files.so.1 %{_slibdir}/libnss_dns.so.1 %{_slibdir}/libnss_compat.so.1

%pre -p "/sbin/sash --ignore-remaining-args -f"
if [ ! -f %{_slibdir}/libnss_files-%{glibcversion}.so ]; then touch %{upgradestamp}; fi
%ifarch ppc
# FIXME: Get around intermediate breakage on upgrade
if [ -f %{_slibdir}/ld-2.2.4.so ]; then cp %{_slibdir}/ld-2.2.4.so %{_libdir};ln -s %{_libdir}/ld-2.2.4.so %{_libdir}/ld-linux.so.2; ln -sf %{_libdir}/ld-2.2.4.so %{_slibdir}/ld-linux.so.2; fi
%endif

%post
if [[ "$1" = "2" ]]; then
grep -q "^include ld.so.conf.d/\*.conf" /etc/ld.so.conf || {
  echo "include ld.so.conf.d/*.conf" > /etc/ld.so.conf.new
  cat /etc/ld.so.conf >> /etc/ld.so.conf.new
  mv -f /etc/ld.so.conf.new /etc/ld.so.conf
}
fi
/sbin/ldconfig

%ifarch ppc
# FIXME: Get around intermediate breakage on upgrade
if [ -f %{_libdir}/ld-2.2.4.so ]; then
cat > /tmp/ppc-glibc-update.sh <<EOF
-rm %{_slibdir}/ld-linux.so.2
-ln -s %{_slibdir}/ld-2.2.5.so %{_slibdir}/ld-linux.so.2
-rm %{_libdir}/ld-2.2.4.so
-rm %{_libdir}/ld-linux.so.2
EOF
/sbin/sash -f /tmp/ppc-glibc-update.sh
rm -f /tmp/ppc-glibc-update.sh
fi
%endif

if [ "$1" -ge 1 ]; then
  # On upgrade the services doesn't work because libnss couldn't be
  # loaded anymore.
    if [ -f %{upgradestamp} ]; then
	# if X is running define the fontpath to something xfs-independent
	[[ -n "$DISPLAY" ]] && xset fp= /usr/X11R6/lib/X11/fonts/misc
	echo "Restarting all the services of this run level"
	%{_sbindir}/glibc-post-upgrade
	# if X is running, reset the fontpath to its default value
	[[ -n "$DISPLAY" ]] && xset fp default        
    fi
    if [ -f /bin/rm ]; then
      for i in %broken_link; do
        if [ -e $i ] && [ ! -L $i ]; then
          /bin/rm -f $i
	fi
      done
    fi
fi

[[ -x /bin/rm ]] && /bin/rm -f %{upgradestamp}

%postun -p /sbin/ldconfig
%endif

%pre devel
if [ -L %{_includedir}/scsi ]; then
  rm -f %{_includedir}/scsi
fi
if [ -L %{_includedir}/sound ]; then
  rm -f %{_includedir}/sound
fi
if [ -L %{_includedir}/linux ]; then
  rm -f %{_includedir}/linux
fi
if [ -L %{_includedir}/asm ]; then
  rm -f %{_includedir}/asm
fi
if [ -L %{_includedir}/asm-generic ]; then
  rm -f %{_includedir}/asm-generic
fi
%ifarch x86_64
if [ -L %{_includedir}/asm-x86_64 ]; then
  rm -f %{_includedir}/asm-x86_64
fi
if [ -L %{_includedir}/asm-i386 ]; then
  rm -f %{_includedir}/asm-i386
fi
%endif
%ifarch ppc64
if [ -L %{_includedir}/asm-ppc64 ]; then
  rm -f %{_includedir}/asm-ppc64
fi
if [ -L %{_includedir}/asm-ppc ]; then
  rm -f %{_includedir}/asm-ppc
fi
%endif
exit 0

%if "%{name}" == "glibc"
%post devel
cd /boot
rm -f kernel.h
ln -snf kernel.h-%{kheaders_ver} kernel.h
/sbin/service kheader start 2>/dev/null >/dev/null || :
exit 0

%postun devel
if [ $1 = 0 ];then
  if [ -L /boot/kernel.h -a `ls -l /boot/kernel.h 2>/dev/null| awk '{ print $11 }'` = "kernel.h-%{kheader}" ]; then
    rm -f /boot/kernel.h
  fi
fi
exit 0
%endif

%if %{build_doc}
%post doc
%_install_info libc.info

%preun doc
%_remove_install_info libc.info
%endif

%if %{build_utils}
%post utils -p /sbin/ldconfig
%postun utils -p /sbin/ldconfig
%endif

%if %{build_nscd}
%pre -n nscd
%_pre_useradd nscd / /bin/false

%post -n nscd
/sbin/chkconfig --add nscd

%preun -n nscd
if [ $1 = 0 ] ; then
  /sbin/chkconfig --del nscd
fi

%postun -n nscd
%_postun_userdel nscd

if [ "$1" -ge "1" ]; then
  /sbin/service nscd condrestart > /dev/null 2>&1 || :
fi
%endif

%clean
#rm -rf "$RPM_BUILD_ROOT"
#rm -f *.filelist*

#
# glibc
#
%files -f libc.lang -f extralibs.filelist
%defattr(-,root,root)
%if "%{name}" == "glibc"
%verify(not md5 size mtime) %config(noreplace) %{_sysconfdir}/localtime
%verify(not md5 size mtime) %config(noreplace) %{_sysconfdir}/nsswitch.conf
%verify(not md5 size mtime) %config(noreplace) %{_sysconfdir}/ld.so.conf
%dir %{_sysconfdir}/ld.so.conf.d
%config(noreplace) %{_sysconfdir}/rpc
%{_mandir}/man1/*
%{_mandir}/man8/rpcinfo.8*
%{_mandir}/man8/ld.so*
%{_datadir}/locale/locale.alias
/sbin/sln
%dir %{_prefix}/lib/getconf
%{_prefix}/lib/getconf/*
%endif
%{_slibdir}/ld-%{glibcversion}.so
%if "%{arch}" == "i386"
%{_slibdir}/ld-linux.so.2
%endif
%if "%{arch}" == "alpha"
%{_slibdir}/ld-linux.so.2
%endif
%if "%{arch}" == "ppc"
%{_slibdir}/ld-linux.so.2
%{_slibdir}/ld.so.1
%endif
%if "%{arch}" == "ppc64"
%{_slibdir}/ld64.so.1
%endif
%if "%{arch}" == "ia64"
%{_slibdir}/ld-linux-ia64.so.2
%endif
%if "%{arch}" == "x86_64"
%{_slibdir}/ld-linux-x86-64.so.2
%endif
%if "%{arch}" == "m68k"
%{_slibdir}/ld.so.1
%endif
%{_slibdir}/lib*-[.0-9]*.so
%{_slibdir}/lib*.so.[0-9]*
%{_slibdir}/libSegFault.so
%dir %{_libdir}/gconv
%{_libdir}/gconv/*
# Don't package pt_chown. It is only needed if devpts is not used. But
# since we are running kernel 2.4+, that's fine without.
# (and it never actually worked, aka was not setuid, nor executable)
#%{_libdir}/pt_chown
%{_bindir}/catchsegv
%{_bindir}/gencat
%{_bindir}/getconf
%{_bindir}/getent
#%{_bindir}/glibcbug
%{_bindir}/iconv
%{_bindir}/ldd
%if "%{arch}" == "i386"
%{_bindir}/lddlibc4
%endif
%{_bindir}/locale
%{_bindir}/localedef
%{_bindir}/rpcgen
%{_bindir}/sprof
%{_bindir}/tzselect
%{_sbindir}/rpcinfo
%{_sbindir}/iconvconfig
%{_sbindir}/glibc-post-upgrade
%ifarch %{glibc_compat_arches}
%{_libdir}/libnss1*.so
%{_libdir}/libnss*.so.1
%endif

%if %{build_biarch}
/lib/ld-%{glibcversion}.so
%ifarch ppc64
/lib/ld.so.1
%endif
/lib/ld-linux*.so.2
/lib/lib*-[.0-9]*.so
/lib/lib*.so.[0-9]*
/lib/libSegFault.so
%dir %{_prefix}/lib/gconv
%{_prefix}/lib/gconv/*
%endif

#
# ldconfig
#
%if "%{name}" == "glibc"
%files -n ldconfig
%defattr(-,root,root)
/sbin/ldconfig
%{_mandir}/man8/ldconfig*
%endif

#
# glibc-devel
#
%files devel -f devel.filelist
%defattr(-,root,root)
%doc README NEWS INSTALL FAQ BUGS NOTES PROJECTS CONFORMANCE
%doc COPYING COPYING.LIB
%doc documentation/* README.libm
%doc hesiod/README.hesiod
%if "%{name}" == "glibc"
%{_mandir}/man3/*
%endif
%{_libdir}/libbsd-compat.a
%{_libdir}/libbsd.a
%{_libdir}/libc_nonshared.a
%{_libdir}/libg.a
%{_libdir}/libieee.a
%{_libdir}/libmcheck.a
%{_libdir}/libpthread_nonshared.a
%if "%{name}" == "glibc"
%{_libdir}/librpcsvc.a
%endif

%{_includedir}/linux
%{_includedir}/asm
%{_includedir}/asm-generic
%{_includedir}/sound
%if "%{arch}" == "x86_64"
%dir %{_includedir}/asm-i386
%{_includedir}/asm-i386/*.h
%dir %{_includedir}/asm-x86_64
%{_includedir}/asm-x86_64/*.h
%endif
%if "%{arch}" == "ppc64"
%dir %{_includedir}/asm-ppc
%{_includedir}/asm-ppc/*.h
%dir %{_includedir}/asm-ppc64
%{_includedir}/asm-ppc64/*.h
%endif
%if "%{arch}" == "sparc64"
%dir %{_includedir}/asm-sparc
%{_includedir}/asm-sparc/*.h
%dir %{_includedir}/asm-sparc64
%{_includedir}/asm-sparc64/*.h
%endif
%if "%{name}" == "glibc"
/boot/kernel.h-%{kheaders_ver}
%endif

%if %{build_biarch}
%{_prefix}/lib/libbsd-compat.a
%{_prefix}/lib/libbsd.a
%{_prefix}/lib/libc_nonshared.a
%{_prefix}/lib/libg.a
%{_prefix}/lib/libieee.a
%{_prefix}/lib/libmcheck.a
%{_prefix}/lib/libpthread_nonshared.a
%{_prefix}/lib/librpcsvc.a
%endif

#
# glibc-static-devel
#
%files static-devel
%defattr(-,root,root)
%doc COPYING COPYING.LIB
%{_libdir}/libBrokenLocale.a
%{_libdir}/libanl.a
%{_libdir}/libc.a
%{_libdir}/libcrypt.a
%{_libdir}/libdl.a
%{_libdir}/libm.a
%{_libdir}/libnsl.a
%{_libdir}/libpthread.a
%{_libdir}/libresolv.a
%{_libdir}/librt.a
%{_libdir}/libutil.a

%if %{build_biarch}
%{_prefix}/lib/libBrokenLocale.a
%{_prefix}/lib/libanl.a
%{_prefix}/lib/libc.a
%{_prefix}/lib/libcrypt.a
%{_prefix}/lib/libdl.a
%{_prefix}/lib/libm.a
%{_prefix}/lib/libnsl.a
%{_prefix}/lib/libpthread.a
%{_prefix}/lib/libresolv.a
%{_prefix}/lib/librt.a
%{_prefix}/lib/libutil.a
%endif

#
# nptl-devel
#
%if %{build_nptl}
%files -n nptl-devel
%defattr(-,root,root)
%dir %{_libdir}/nptl
%{_libdir}/nptl/*.so
%{_libdir}/nptl/*.a
%dir %{_includedir}/nptl
%{_includedir}/nptl/*
%endif

#
# glibc-doc
#
%if %{build_doc}
%files doc
%defattr(-,root,root)
%{_infodir}/libc.info*
%endif

#
# glibc-doc-pdf
#
%if %{build_pdf_doc}
%files doc-pdf
%defattr(-,root,root)
%doc manual/libc.pdf
%endif

#
# glibc-debug
#
%if %{build_debug}
%files debug
%defattr(-,root,root)
%dir %{_libdir}/debug
%{_libdir}/debug/*.so
%{_libdir}/debug/*.so.*
%endif

#
# glibc-profile
#
%if %{build_profile}
%files profile
%defattr(-,root,root)
%{_libdir}/lib*_p.a
%endif

#
# glibc-utils
#
%if %{build_utils}
%files utils
%defattr(-,root,root)
%{_libdir}/libmemusage.so
%{_libdir}/libpcprofile.so
%{_bindir}/memusage
%{_bindir}/memusagestat
%{_bindir}/mtrace
%{_bindir}/pcprofiledump
%{_bindir}/xtrace
%endif

#
# nscd
#
%if %{build_nscd}
%files -n nscd
%defattr(-,root,root)
%config(noreplace) %{_sysconfdir}/nscd.conf
%config(noreplace) %{_initrddir}/nscd
%{_sbindir}/nscd
%{_sbindir}/nscd_nischeck
%endif

#
# timezone
#
%if %{build_timezone}
%files -n timezone
%defattr(-,root,root)
%{_sbindir}/zdump
%{_sbindir}/zic
%{_mandir}/man1/zdump.1*
%dir %{_datadir}/zoneinfo
%{_datadir}/zoneinfo/*
%endif

#
# glibc-i18ndata
#
%if %{build_i18ndata}
%files i18ndata
%defattr(-,root,root)
%dir %{_datadir}/i18n
%dir %{_datadir}/i18n/charmaps
%{_datadir}/i18n/charmaps/*
%dir %{_datadir}/i18n/locales
%{_datadir}/i18n/locales/*
%endif

%changelog
* Wed Mar 16 2005 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.4-8mdk
- fix initstate_r (#14591)

* Thu Mar 10 2005 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.4-7mdk
- fix package url (MDK #14468, Zeb)
- update to 2.6.11-2mdk kernel headers (inotify 0.20)
- update to stable 2.3-branch (2005/03/01):
  * fix BZs #284, #671, #719, #722, #726, #727, #729, #730, #731,
    #732, #733, #741, #744, #745, #767, #769
  * fix segfault in open_path, aka fix rsync --daemon (BZ #738)
  * fix powerpc64 set/swap context (BZ #700)
  * support -mno-tls-direct-seg-refs builds (BZ #737)
  * update to tz{code,data}2005c (BZ #736)
  * do not allocate potentially large buffers on the stack
  * futimes() should not fail with ENOENT (BZ #633)
  * declare ftruncate for POSIX 2003 (BZ #640)
  * fix rint on powerpc (BZ #602)
  * update ia64 libm (BZ #592)
  * fix round() to round return value to nearest (BZ #626)
  * fix {,q}ecvt{,_r} on denormals (BZ #725)
  * fix i386 stack alignment in clone and linuxthreads (BZ #723)

* Wed Feb 23 2005 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.4-6mdk
- fix fdim() in x86_64 libm, use glibc implementation
- really stick with getconf files in /usr/lib/getconf
- update kernel headers to 2.6.10-3mdk for new inotify
- kernel header fixes (cdp, fddi)

* Thu Feb 10 2005 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.4-5mdk
- kernel headers fixes (christiaan/ppc, directfb/x86_64, usbutils/any)

* Thu Jan 27 2005 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.4-4mdk
- add missing getconf files
- always propagate pgoff_t definition (workaround kernel header)

* Mon Jan 24 2005 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.4-3mdk
- relax __le64 and __be64 definitions in kernel headers

* Fri Jan 21 2005 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.4-2mdk
- update to 2.6.10 kernel headers
- add memory clobbers in asm-i386 syscalls as arguments may be
  pointers to modifiable memory and values need to be reloaded
  (e.g. _llseek() in util-linux)

* Tue Dec 28 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.4-1mdk
- 2.3.4
- fix kernel headers (videodev2.h, blkpg.h on ppc64)
- bring "compat" only to nsswitch.conf
- cosmetics to make check machinery

* Thu Nov 25 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-23mdk
- fix cross bootstrap builds
- enable biarch support on ppc64
- enable tls and nptl on ia64 and ppc64

* Fri Oct  8 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-22mdk
- revert nsswitch.conf change
- fix <linux/ijxuser.h> on non x86 platforms
- reread /etc/localtime even if just mtime has changed (CVS)

* Thu Sep 16 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-21mdk
- add pcc to nptl arches
- fix path to nscd socket
- bring "compat" mode to nsswitch.conf
- fix kernel headers for usbutils rebuild

* Thu Sep  2 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-20mdk
- add ppc to tls arches (Christiaan Welvaart)
- selected fixes from CVS (2004/09/01):
  * fix locking issues in nscd
  * fix some IPv6 related bugs

* Wed Aug 25 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-19mdk
- fix nice
- fix nscd runlevels
- selected fixes from CVS (2004/08/24):
  * add O_NOATIME to linux <fcntl.h> from 2.6.8+ (BZ #341)
  * fix nis nss_compat's initgroups handling
  * fix possible problem with ld.so and brk management (BZ #227)

* Wed Aug 18 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-18mdk
- add missing glibc compat symlinks
- add sparc to TLS arches (Per Oyvind)
- fix <linux/capi.h> standalone inclusion

* Tue Aug 17 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-17mdk
- enable AMD optimized libm for x86_64
- add pow10 and friends in x86_64 libm

* Fri Aug 13 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-16mdk
- some minor build arrangements
- add compat glibc 2.0 for some ancient programs

* Fri Aug 13 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-15mdk
- fix <linux/crc-ccitt.h>
- update from CVS (2004/08/12):
  * fix BZ #150, #198, #217, #218, #219, #230, #231, #232, #262, #263
  * fix pthread_rwlock_timedrdlock on x86_64
  * fix values for -m32 -D_FILE_OFFSET_BITS=64 on x86_64
  * fix psignal() changes from previous CVS syncs
  * fix backtrace in statically linked programs on ia64/x86-64/s390{,x}
  * fix possible buffer overflow in crypt()
  * fix lowmem handling in chroot_canon() (BZ #199)
  * handle more than 6 args correctly on x86_64 makecontext()

* Wed Aug 11 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-14mdk
- update to 2.6.8 kernel headers (fix #10693)
- selected fixes from CVS:
  * make inet_pton() RFC2133 (BZ #295)
  * fix strtold() on 32-bit arches with ldbl-96 (BZ #274)
  * fix pow{,f,l}() on IA-32 and powl() on AMD64 (BZ #258)

* Mon Jul  5 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-13mdk
- fix upgrades for /etc/ld.so.conf.d/*
- update to 2.3.4 CVS snapshot (2004/06/01)
- update to 2.6.6+ kernel headers, I want POSIX message queues
- update patch to handle multiple types of libraries from one ld.so

* Tue May 25 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-12mdk
- Make ldconfig handle "include ld.so.conf.d/*.conf" (2.3.4-cvs)

* Thu Apr 15 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-11mdk
- Enable use of kernel timers for NPTL timer_create()
- Fix mathinline.h again
- alpha & sparc64 updates (Stefan)
- Merge from AMD64 branch:
  * Fix rwlocks on AMD64 with NPTL
  * Various fixes to kernel-headers
  * Really fix build on AMD64 with 2.4 kernel

* Mon Feb 16 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-10mdk
- Fix kernel-headers (___swab64, ix86 ioctl type checking)
- Assorted fixes from CVS:
  * Fix alignment in AMD64 memcpy()
  * Fix tzset() to cap hour in POSIX $TZ rule format to 24, not 23
  * Make stream locking operations really work

* Wed Feb  4 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-9mdk
- Run-time detect whether kernel 2.4.X supports TLS

* Mon Feb  2 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-8mdk
- Enable NPTL for 2.4.25+ kernels too
- Don't load TLS libraries on i586 class processors

* Thu Jan 23 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-7mdk
- Fix NPTL build on AMD64
- Fix ceilf() on AMD64 with new math library

* Thu Jan 22 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-6mdk
- Fix <linux/fb.h> for bootsplash
- Assorted fixes from CVS:
  * Handle 6th argument passed to AMD64 syscalls
  * Add proper unwind information directives to some AMD64 .S files

* Mon Jan 19 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-5mdk
- Fix <linux/compiler-gcc*.h>
- Assorted fixes from CVS:
  * Make strfmon() formatting match the POSIX standard better
  * Fix memory leak in linuxthreads

* Fri Jan 16 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-4mdk
- Fixlets for new rpm
- Regexp fixes from CVS

* Thu Jan  8 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-3mdk
- Kernel 2.6 headers
- Make librt.so a symlink again
- Enable NPTL support for systems with kernel >= 2.5.70
- Alpha fixes from Debian (Stefan)

* Mon Jan  5 2004 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-2mdk
- Fixlets for new sash (Pixel)

* Fri Dec  5 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.3-1mdk
- 2.3.3

* Thu Oct  9 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-15mdk
- Rebuild with latest rpm so that libraries in EXCLUDE_FROM_STRIP are
  kept intact during symbols extraction for -debug package

* Fri Aug 29 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-14mdk
- Patch40: Avoid */lib/i686 compiled libraries to be loaded if the
  host doesn't support CMOV instructions

* Tue Aug 26 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-13mdk
- Patch39: Fix _IO_fwide() for GLIBC_2.0 compatibility (Ulrich Drepper)

* Fri Aug 22 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-12mdk
- Fix <asm/types.h> to mark long long types as GNU __extension__
- Assorted fixes fro current CVS:
  - Patch35: Fix libio for arches without < GLIBC_2.2 compatibility
  - Patch36: Binary compatibility fix for _res@GLIBC_2.0
  - Patch37: Strict aliasing fixes in <ctype.h>
  - Patch38: Fix C++/dlerror/pthread problem

* Tue Aug 12 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-11mdk
- Update kernel-headers to 2.4.22-0.3mdk for new alsa
- Fix kernel-headers to not include <linux/ethtool.h> in <linux/wireless.h>
- Patch34: wcsmbs fixes from current CVS (Ulrich Drepper)

* Tue Jul 29 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-10mdk
- Fix nscd installation
- Patch32: Workaround i586 rtld regression from last release

* Mon Jul 28 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-9mdk
- Update Patch18 (i586-hptiming) to really initilize _dl_hwcap
- Patch32: Add -fno-reorder-block to build -m32 dl-load.c on AMD64
- Patch33: Fix amd64 ldconfig (Jakub Jelinek, CVS)

* Fri Jul 25 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-8mdk
- Update to 2.3.2-CVS (2003/07/04)
- Patch30: Update libm ULPs for cos() and 3.3-hammer branch
- Patch31: SSE fixes from newer CVS (fix i686 libm regression testing)

* Fri Jul 25 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-7mdk
- -fcall-used-g6 on sparc (Per Oyvind Karlsen)
- Patch20: Recognize amd64-*
- Patch24: Add new AMD64 math library
- Patch33: Fix linuxthreads32 tests on AMD64 (Jakub Jelinek, CVS)
- Patch102: Mark GNU extensions in <linux/byteorder/swab*.h>

* Fri Jul 18 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-6mdk
- Enable %%fs on AMD64, kernel contains necessary fixes
- Fix build on biarch platforms, -m32 is not cross-compiling

* Wed Jul  9 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-5mdk
- Don't use /bin/rm if it is not available on the system (1st time install)
- All tests now pass on PPC according to Olivier Thauvin
- Patch32: Add Asia/Beijing alias and other time zones requested by users

* Thu Jun  5 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-4mdk
- All tests should pass on ia64 nowadays too
- Patch31: Reintegrate workaround for kernel bug in tcsetattr. According
  to Stew, this fixes an LSB regression. However, the kernel bug remains...

* Mon May 12 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-3mdk
- Assorted fixes from CVS and RH glibc errata

* Thu Apr  3 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-2mdk
- Patch28: Fix get_proc_path(), aka getconf _NPROCESSORS_ONLN (Jakub Jelinek)

* Thu Apr  3 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.2-1mdk
- Update to 2.3.2-CVS (2003/04/01)

* Sat Mar 15 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.1-12mdk
- Enable cross-compilation

* Wed Mar  5 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.1-11mdk
- Remove useless Requires: libgd1 for glibc-utils
- Patch28: Make errno and _res re-available at link time (Daniel Jacobwitz)

* Mon Feb 17 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.1-10mdk
- Rebuild against latest binutils so that accesses to errno don't bind locally
- Patch25: Various nscd config & script fixlets (RH)
- Patch26: Really do handle HUP signal for nscd reload (RH)
- Patch27: Fix nextafterl() on x86 (CVS)

* Fri Feb 14 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.1-9mdk
- Update kernel headers to 2.4.21-0.pre4.6mdk

* Thu Feb 13 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.1-8mdk
- Ship with libpthread_nonshared.a
- Workaround build with gcc 3.3-hammer, i.e. disable -funit-at-time
- Patch22: Fix struct dqstats (<quota.h>) to match kernel headers
- Patch23: Implement x86-64 access to FPU control word bits (Olaf Flebbe)
- Patch101: Fix <unistd.h> ppc kernel header (Franz Sirl, SuSE 2.3.1-32)
- Update to 2.3.1-CVS (2003/02/12):
  - Add cancellation support
  - Add and fix support for AT_SYSINFO
  - Add nsec resolution for struct stat and struct stat64
  - Fix dlclose, _res, malloc, vfork in linuxthreads, regex once more
  - Fix handling of encodings with //TRANSLIT in bind_textdomain_codeset()

* Wed Jan 22 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.1-7mdk
- Remove obsolete Patch20 (x86_64-mathasm)
- Prelink -r i686 libc.so
- Patch20: Revert latest linuxthreads changes on x86-64 for now
- Patch22: Add yet more regex fixes from current CVS
- Patch24: Handle locale-archive in locale -a. Fix LC_MEASUREMENT
  locale bug (Jakub Jelinek, Andreas Schwab from current CVS)

* Mon Dec 23 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.1-6mdk
- Revert to glibc-2.3.1 sources as of 2002/12/10
- Patch22: Add regexp fixes from current CVS (2002/12/19)
- Patch23: Revert cancellation wrappers from libtphread.so.0(GLIBC_2.3.2)

* Mon Dec 23 2002 Frederic Lepied <flepied@mandrakesoft.com> 2.3.1-5mdk
- Back to Conflicts: initscripts < 6.91-18mdk
- Source13: Inline upgrade script (Fred)

* Thu Dec 19 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.1-4mdk
- Yet another fix to <linux/videodev2.h>
- Update to 2.3.1-CVS (2002/12/19)
  - Regexp fixes
  - Add support for cancellation handling

* Wed Dec 18 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.1-3mdk
- Fix <linux/videodev2.h> yet again

* Tue Dec 17 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.1-2mdk
- PreReq: initscripts >= 6.91-18mdk instead of Conflicts the other way

* Tue Dec 17 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.3.1-1mdk
- Move to 2.3.1-CVS (2002/12/10)
- Update new charsets from Pablo
- Nuke kernel-headers sub package, merge it into glibc-devel
- Patch15: Add glibc-2.2 compatibility to workaround broken programs for now
- Patch17: Enable compatibility with older IBM JDK (Jakub Jelinek)
- Really fix MDK 8.2 -> 9.1 ppc upgrade I messed up earlier (Stew)

* Tue Dec 10 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-22mdk
- Renew and factorize glibc build system
- Fix detection of gcc version for addition of -finline-limit=
- Update Patch6 (exit-during-install) to quit ldconfig only if we are
  installing within DrakX and no extra arguments are used (gc)
- Ship with i686 libthread_db.so.1 otherwise gdb is getting confused
  if i686 libpthread is loaded along with i586 libthread_db.so.1. It
  worked before because libpthread was fully stripped

* Fri Dec  6 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-21mdk
- Enable make check'ing on PPC, it reportedly no longer hangs
- Make a biarch package for x86-64. We do need 32-bit static libraries
  to build biarch gcc and I don't want to mess with a glibc32 package
- Update Patch25 (i386-fix-hwcaps) in order to better match output of
  /proc/cpuinfo concerning SSE and SSE2. In other words, do search in
  */lib/*/sse{,2} instead of */xmm{,2}

* Wed Nov 20 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-20mdk
- Workaround 8.2 -> 9.0 upgrade borkage on PPC (Stew)
- Update Patch21 (ia64-fix-strncpy) yet again with glic-2.3-branch
  implementation as rev 1.9 + Kenneth Chen new changes
- Patch102: Fix <linux/posix_acl.h> to include <asm/atomic.h>
- Patch25: Remove "amd3d" hwcap for now since kernel people decided to
  move it to second hwcap word which is not passed to glibc. Add SSE
  and SSE2 features to HWCAP_IMPORTANT. i.e. SSE2 optimized libraries
  can now be looked into */lib/*/xmm2

* Fri Nov  8 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-19mdk
- Update Patch21 (ia64-fix-strncpy). Also provide a testcase (Ken Chen)
- Really strip only debug symbols and .comment sections from libpthread

* Thu Nov  7 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-18mdk
- Patch21: Fix IA-64 strncpy() (Ken Chen)
- Patch22: Add Itanium2 optimized bzero(), memset(), memcpy()
  functions (Sverre Jarp, 2.3-branch). Also define __bzero().
- Patch23: Add IA-64 libgcc routines for binary compatibility when
  building with gcc 3.X (Jakub Jelinek, 2.3-branch)
- Patch24: Revert latest linuxthreads changes on x86-64 for now
- Rediff Patch16 (hwcap-check-platform), partly merged upstream
- Update to 2.2-branch (CVS snapshot 2002/09/30):
  - Fix ABI compatibility with libc compiled with old tools on powerpc
  - Fix arguments of shmat() in x86-64 syscall definitions
  - Really store errno as a 32-bit value on x86-64
  - Use __cache_line_size to select the correct stride for dcbz on memset/ppc

* Wed Nov  6 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-17mdk
- Add debug sub-package
- Conflicts: glibc < 2.2.5-6mdk for timezone package
- Update kernel headers to 2.4.19-18.2mdk

* Mon Aug 19 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-16mdk
- Patch20: revert additions of __nanosleep in 2.2.6 namespace
- Update Patch7 (share-locale) to fix location of locales on x86-64
- Update to 2.2-branch (CVS snapshot 2002/08/12):
  - Fix statvfs ST_NODIRATIME
  - Fix rewind() after first fwscanf() (PR libc/4070)
  - Fix semctl() on PPC (PR libc/3259)
  - Fix pread()/pwrite()
  - Check for overflow on multiplication in xdr_array() and calloc()
- Merge with SuSE releases:
  - Add x86-64 asm optimized string functions
  - Implement {get,set,make,swap}context on x86-64

* Tue Aug 13 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-15mdk
- Automated rebuild with gcc 3.2-0.3mdk

* Mon Jul 22 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-14mdk
- Patch22: Don't segfault on empty charmap file (Bruno Haible)
- Patch23: Don't use __thread as identifier since it is now a gcc3.3+ keyword

* Sat Jul 20 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-13mdk
- Fix create_asm_headers.sh to correctly translate '-' to '_' as well
- Fix %%post buglets introduced in previous release

* Sat Jul 20 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-12mdk
- Add biarch headers, clean kernel-headers
- Strip libpthread, do ship with i686 librt
- Fix service restart in %%post when xfs is running (Pablo)
- Go back at using ../configure and pass correct host information
- Minimum kernel supported is back to 2.2.5 on ia32 for non-floating stacks
- Merge with SuSE releases:
  - Add some optimized x86-64 math routines
  - Fix lgammal_r implementation
  - Warn about using host caching with nscd, in the config file

* Tue Jul 16 2002 Jeff Garzik <jgarzik@mandrakesoft.com> 2.2.5-11mdk
- Patch25: fix alpha asm for recent binutils (Roland McGrath, via Stefan)

* Tue Jul  9 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-10mdk
- Static-devel'ization
- Explicit Requires: version-release for glibc-devel
- Update kernel-headers to 2.4.18-21mdk for new alsa 0.9.0-rc2

* Fri Jul  5 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-9mdk
- Add nscd user
- Remove merged bits from Patch50 (x86_64-linuxthreads)
- Fix Patch19 (hwcap-check-platform) so that the platform check in
  HWCAP_CHECK is performed even if _dl_platform was NULL. This happens
  for example in a statically linked executable that uses dlopen().

* Wed Jul  3 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-8mdk
- Add %{_bindir}/sln, it's not useless for users
- Don't package pt_chown. It is only needed if devpts is not used. But
  since we are running kernel 2.4+, that's fine without
- Patch19: Skip library that is not of a subarch of running architecture
- Patch20: Define sqrtl() on PPC, should fix OOo link there
- Update to 2.2-branch (CVS snapshot 2002/07/02):
  - Fix libgcc compat on PPC
  - Fix getcontext() on IA-64 to really match David's change
  - Rewrite x86-64 elf_machine_load_address() to not use 32-bit pc
    relative relocations

* Fri Jun 21 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-7mdk
- Sanitize specfile (BuildRequires: perl, url tag, use %%configure)
- Add i686 optimized libraries in /%{_lib}/i686
- Disable tests on ppc for now

* Fri Jun 14 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-6mdk
- Remove -D__USE_STRING_INLINES
- Add Provides: ld.so.1 on PPC
- Remove BuildRequires: gcc = 2.95.3 on PPC
- Make check in %%build stage
- Patch15: Add changes from former Source12 (gb18030) but disable that
  in regression testing
- Patch16: Use old DE.po since the new one from 2002/05/14 is
  incomplete and results in failures for intl checks
- Patch17: Add i386 ULPs for cacosh() tests
- Major specfile reorganization, new subpackages (glibc-i18n,
  glibc-doc, glibc-doc-pdf, timezone)
- Update to 2.2-branch (CVS snapshot 2002/06/09):
  - X86-64 fixes and additions
  - Correct calls to __lseek() in the dynamic linker
  - Fix recovery code in strncpy() on IA-64
  - Correct check for size of alignment value in __posix_memalign()
  - Fix a typo causing only lower 4 bits of each ethernet address byte
    being assigned
- Merge with SuSE releases (2 new patches):
  - Fix linuxthreads for x86-64
  - Enable profiling on x86-64

* Tue May  7 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-5mdk
- Automated rebuild in gcc3.1 environment

* Wed May  1 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-4mdk
- Update kernel-headers to match 2.4.18-13mdk (alsa-headers 0.9.0rc1)
- Patch14: Create lddlibc4 and ld-linux.so.2 files on PPC (Stew)
- Also add lddlibc4 for other arches

* Mon Apr 15 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-3mdk
- Update to 2.2-branch (CVS snapshot 2002/04/14):
  - Fix mktime() again
  - Fix relocation dependency handling
  - Fix symbol lookup for most recent vs. earliest version of a symbol
    (aka. fix undefined atexit symbol problem with VisualWorks Smalltalk)
- Add Requires: libgd1 to glibc-utils
- Update kernel-headers to match 2.4.18-11mdk with alsa-headers
- Per Stew and Andrew Josey's recommendantions, don't obsolete old
  currencies from Euro countries. Aka. revert 2002-02-28 change.

* Thu Apr 11 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-2mdk
- Update to 2.2-branch (CVS snapshot 2002/04/08)
- Update kernel-headers to match 2.4.18-10mdk
- Strip debugging info from all static libraries
- Build with --enable-kernel=2.4.1 on all arches

* Thu Mar 21 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.5-1mdk
- Regenerate Patch9 for new charsets
- Remove ldd-rewrite Patch11 for IA-64 (merged upstream)
- Add glibc-utils package for memusage, mtrace and xtrace
- Update to 2.2-branch (CVS snapshot 2002/03/20):
  - Correctly close the UDP connection right away [PR libc/3120]
  - Fix daylight setting for tzset
  - Fix DST handling for southern hemisphere
  - Fix ftime, aka don't return 1000 in millitm
  - Fix nice return value
  - Provide libc's __{,u}{div,mod}di3 since it is not possible to grab
    it from libgcc.a anymore (gcc-3.1 libgcc.a has all its routines
    .hidden)
  - Store correct collation sequence values
  - Remove some string2.h optimizations for gcc-3.0+

* Thu Mar  7 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.4-25mdk
- 2.4.18-4mdk kernel headers
- Fixup Source11 (make_versionh.sh) for s/kheaders/kheaders_ver/

* Wed Feb  6 2002 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.4-24mdk
- Spec cleanups.
- 3 new patches from glibc-2.2.5:
  - Patch60: Bugfix to pthread_key_delete. It was iterating over the
    thread manager's linked list of threads, behind the thread
    manager's back causing a race. The fix is to have the manager
    iterate over the threads instead, using a new request type for
    doing so. (Kaz Kylheku)
  - Patch61: specific.c (pthread_key_delete): Don't contact the thread
    manager if no threads have been created yet. (Andreas Schwab)
  - Patch62: When sigaction in libpthread is called the first time for
    a signal we don't know whether the old signal handler is SIG_DFL
    or SIG_IGN, so we must return the value that the kernel
    reports. (Andreas Schwab)

* Mon Jan 28 2002 Pablo Saratxaga <pablo@mandrakesoft.com> 2.2.4-23mdk
- replaced the gb18030 support with the one from Thiz Laboratory as
  suggested by Geoffrey Lee

* Mon Jan 14 2002 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-22mdk
- Conflicts with older initscripts (don't do Requires: to don't screwd
  up install requires and it's only needed when upgrade).
- Use /sbin/service --fullrestartall instead of doing in %post.

* Mon Jan 14 2002 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-21mdk
- s|modversion|modversions|; (Thanks a lot Andrej).

* Thu Jan 10 2002 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-20mdk
- Remove netatalk/at.h to avoid conflict with netatalk rpm's.

* Wed Jan  9 2002 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-19mdk
- 2.4.17 kernel headers.

* Wed Dec 19 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-18mdk
- Add rh patch for gcc3 support.

* Wed Dec 19 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-17mdk
- Add rh patches (j.jelinek 2.2.4-19.3):
	- fix inttypes.h typo (#57268)
	- fix glob buffer overflow
- add selected changes from CVS
  - handle DT_RUNPATH properly
  - fix *scanf nan/inf handling
  - fix strndup
  - fix fnmatch - handling at end of bracket expr
  - allow dlfcn.h to be used in C++
  - fix IPv6 reverse lookups
  - avoid SPARC warnings in bits/mathinline.h
- Sync with latest kernel headers.

* Tue Dec  4 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-16mdk
- Fix upgrade to relaunch service only when upgrade between version.
- Rewrote the glibc upgrade %post to do a correct ordering of services.

* Mon Dec  3 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-15mdk
- sync with kernel-headers 2.4.16.

* Thu Nov 29 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-14mdk
- Fix stupidities in version.h generation.

* Thu Nov 29 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-13mdk
- Include more explicit #error in modversion.sh like the one of version.sh.
- Fix %post to restart the service only when is present.

* Wed Nov 21 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-12mdk
- Move the kernel-headers package here.
- Big specs changes to compile with the kernel-headers.

* Tue Nov 13 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-11mdk
- New charset patch from pablo.

* Mon Nov 12 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-10mdk
- Merge with latest rh.
- turn /usr/lib/librt.so into linker script.
- call xtrace with xvt not xterm (snailtalk).

* Wed Oct 31 2001 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.4-9mdk
- Patch14: timer_delete, timer_settime.c: Thread may be NULL for SIGEV_NONE
- Patch13: Protect all communications from and to manager with
  TEMP_FAILURE_RETRY. aka. Fix bug in LinuxThreads where manager and
  threads could get out of synch due to an interrupted read call.

* Wed Oct  3 2001 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.4-8mdk
- Add BuildRequires: tetex-latex
- Use /bin/rm in %%post scriptlet
- Patch11: Enable ldd to know about IA-32 binaries or libraries on IA-64
- Patch12: Define __gwchar_t to wchar_t for C++ in <inttypes.h>

* Tue Sep 18 2001 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.4-7mdk
- Remove Patch200: strnlen() for IA-64 is now fixed upstream,
  and strncpy() has been improved

* Mon Sep 10 2001 Frederic Lepied <flepied@mandrakesoft.com> 2.2.4-6mdk
- fix perror

* Tue Sep  4 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-5mdk
- Merge new_charsets patch with latest release.

* Mon Sep  3 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-4mdk
- Merge with 2.2.4-11 rh release.

* Mon Sep  3 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-3mdk
- Merge with latest rh release.

* Mon Aug 20 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-2mdk
- Add pablo new_charsets patch for 2.2.4.

* Mon Aug 20 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.4-1mdk
- 2.2.4.
- Spec cleanup.

* Tue Aug 14 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.3-8mdk
- Add /usr/lib/gconv to filelist (pixel).

* Tue Jul 31 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.3-7mdk
- Merge with rh patches.

* Sun Jul 29 2001 Giuseppe Ghibò <ghibo@mandrakesoft.com> 2.2.3-6mdk
- fixed typo in Summary (s/librairies/libraries).
- added glibc PDF documentation.

* Thu Jul 26 2001 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.2.3-5mdk
- Reverted strncpy patch for ia64 (caused segfaults in stage1-install/slang)
- Merge with latest rh (2.2.3-14) :
  - kill non-pic code in libm.so
  - fix getdate
  - fix some locales (RH-#49402)
  - add floating stacks on IA-64, Alpha, Sparc (RH-#49308)

* Mon Jul 23 2001 Stew Benedict <sbenedict@mandrakesoft.com> 2.2.3-4mdk
- no -freorder-blocks on PPC, Requires gcc 2.96 bypassed on glibc-devel for PPC

* Fri Jul 20 2001 Frederic Lepied <flepied@mandrakesoft.com> 2.2.3-3mdk
- Merge with latest rh (2.2.3-13).

* Tue May 29 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.3-2mdk
- Add wins to default host of nsswitch.conf (staburet).
- Merge with latest Red Hat (2.2.3-10) :
- fix #include <signal.h> with -D_XOPEN_SOURCE=500 on ia64 (#35968)
- fix a dlclose reldeps handling bug
- some more profiling fixes
- fix tgmath.h

* Mon May 21 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.3-1mdk
- 2.2.3.

* Sun Apr 22 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.2-5mdk
- Upgrade to the rh version of glibc (pre 2.2.3 with fixes).
- This release fix Oracle and JVM problems.

* Wed Feb 21 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.2-4mdk
- Exclude libpthread to be stripped also.

* Tue Feb 20 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.2-3mdk
- Define PATH_VI to /bin/vi and not /usr/bin/vi.

* Sat Feb 17 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.2-2mdk
- Add a __truncate64 for 64 bytes arch.
- Add updated patch from pablo for the new charsets.

* Fri Feb 16 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.2-1mdk
- 2.2.2.

* Tue Feb  6 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.1-7mdk
- Add new charsets from pablo.

* Wed Jan 31 2001 Francis Galiegue <fg@mandrakesoft.com> 2.2.1-6mdk
- Now compiles on ia64

* Sat Jan 27 2001 David BAUDENS <baudens@mandrakesoft.com> 2.2.1-5mdk
- PPC: rebuild with GCC 2.95.3
- PPC: use lower but safer optimizations

* Fri Jan 19 2001 David BAUDENS <baudens@mandrakesoft.com> 2.2.1-4mdk
- PPC: use default optimizations

* Mon Jan 15 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.1-3mdk
- Don't restart the network subsystem service also.

* Mon Jan 15 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.1-2mdk
- Get the getaddrinfo fix from cvs.

* Mon Jan 15 2001 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2.1-1mdk
- Don't restart pcmcia service when upgrading.
- 2.2.1.

* Wed Jan 10 2001 Pablo Saratxaga <pablo@mandrakesoft.com> 2.2-22mdk
- added support for all the extra charsets so iconv() can convert
  between them

* Tue Dec 12 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2-21mdk
- Default without kernel-2.4 (silly me).

* Tue Dec 12 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2-20mdk
- Compile by default with kernel-2.4. enabled (but make it as option).

* Thu Dec  7 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2-18mdk
- Remove useless timezone/{posix,right}.

* Wed Dec  6 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2-17mdk
- Don't include useless /sbin/sln.

* Wed Dec  6 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2-16mdk
- Revert to sash like before.

* Tue Dec  5 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2-15mdk
- Make script executed thought /bin/ash.static and don't depend of bash.

* Tue Dec  5 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2-14mdk
- Make /usr/share/locale default locale path.

* Sat Dec  2 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2-13mdk
- Move ldconfig to his own package.

* Tue Nov 28 2000 David BAUDENS <baudens@mandrakesoft.com> 2.2-12mdk
- Adjust BuildFlags for GCC-2.96 (PPC)

* Sun Nov 26 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2-11mdk
- Remove zic manpages conflicts.

* Sat Nov 25 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2-10mdk
- New manpages from Debian.
- Include everything in zoneinfo/ dir not only [A-Z]* (fix tzselect).
- Don't launch ldconfig if we find DURING_INSTALL env.

* Sat Nov 25 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2-9mdk
- Fix ldconfig with soname (libc-hackers@).

* Thu Nov 23 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2-8mdk
- Provides: Obsoletes: ld.so ldconfig, add ldconfig from glibc.

* Wed Nov 22 2000 Geoffrey Lee <snailtalk@mandrakesoft.com> 2.2-7mdk
- get compiled on alpha. (Stefan.)

* Wed Nov 22 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2-6mdk
- Don't include %%{_includedir} and %%{_infodir} in the file list.
- Put libpcprofile.so libmemusage.so to devel package.
- Fix syntax error in script (thnks: fcrozat).
- Merge debian patch :
  o (glibc-2.2-nss-upgrade.patch.bz2)
	This patch makes future upgrades easier. It resolves problems with
    running daemons having NSS modules upgraded out from under them.

* Mon Nov 20 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.2-5mdk
- If we find broken link after install erase it to make ldconfig
  happy.

* Thu Nov 16 2000 Frederic Lepied <flepied@mandrakesoft.com> 2.2-4mdk
- don't strip ld-2.2.so

- use sash in %%pre because bash needs the libc...
- don't resart netfs on upgrade.

* Tue Nov 14 2000 Frederic Lepied <flepied@mandrakesoft.com> 2.2-3mdk
- added a prereq on /bin/sh.

* Fri Nov 10 2000 Frederic Lepied <flepied@mandrakesoft.com> 2.2-2mdk
- don't abort if a service doesn't restart

* Fri Nov 10 2000 Frederic Lepied <flepied@mandrakesoft.com> 2.2-1mdk
- 2.2
- try to restart the services on upgrade.

* Wed Nov 08 2000 David BAUDENS <baudens@mandrakesoft.com> 2.1.97-4mdk
- Try to optimize for PPC

* Tue Nov 07 2000 David BAUDENS <baudens@mandrakesoft.com> 2.1.97-3mdk
- Fix build on PPC (don't try to use gcc-2.96)

* Tue Nov  7 2000 Frederic Lepied <flepied@mandrakesoft.com> 2.1.97-2mdk
- devel package depends on glibc %%version-%%release
- fixed the __sysconf function not present in dynamic lib.

* Tue Nov  7 2000 Frederic Lepied <flepied@mandrakesoft.com> 2.1.97-1mdk
- 2.1.97

* Thu Oct 26 2000 Frederic Lepied <flepied@mandrakesoft.com> 2.1.95-3mdk
- removed dependency on basesystem (this was doing a prereq loop).

* Wed Oct 25 2000 Frederic Lepied <flepied@mandrakesoft.com> 2.1.95-2mdk
- changed the Prereq basesystem in Requires.
- added Prereq on /sbin/ldconfig

* Wed Oct 18 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.95-1mdk
- 2.1.95.

* Tue Oct 17 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.92-2mdk
- Fix "warning: pointer of type `void *' used in arithmetic" in string2.h.
- Fix pthreads manpages.
- Use @ifnottex instead of @ifinfo in texinfo files.
- Add BIG5_1984 eo_EO locales.
- Make ldd non-executable aware.
- Define VARDB in /var/lib/misc like FHS want.
- Fix some C++ unaligned traps on alpha.
- Add patches from Debian.

* Tue Oct 17 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.92-1mdk
- 2.1.92.

* Tue Oct 10 2000 David BAUDENS <baudens@mandrakesoft.com> 2.1.3-17mdk
- BuildRequires: patch, gettext

* Mon Sep  4 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-16mdk
- Get another security fix from cvs for locales.
- Remove security patch from caldera and get the official one from cvs.

* Sat Sep  2 2000 Pixel <pixel@mandrakesoft.com> 2.1.3-15mdk
- move a hell lot of doc to glibc-devel
- use find_lang for mo files
- little cleanup

* Wed Aug 30 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-14mdk
- Strip glibc and make happy pixel (aka: his breaking my di**k).

* Fri Aug 25 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-13mdk
- Add security patch from caldera on ld.so :
    Remove completely the environement variable when using LD_PRELOAD
    with setuid apps.

* Thu Aug 24 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-12mdk
- Readd manpages.

* Wed Aug  2 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-11mdk
- Don't strip libc.
- Fix info files.

* Fri Jul 21 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-10mdk
- Maros.
- BM.

* Fri Jul 07 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-9mdk
- The threads fix is a wrong patch.

* Thu Jul  6 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-8mdk
- Remove old ChangLog.
- Fix threads (Debian).

* Wed Jun 14 2000 Pablo Saratxaga <pablo@mandrakesoft.com> 2.1.3-7mdk
- added support for a few missing charsets

* Sat Jun  3 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-6mdk
- Make ldd handle non-executable shared objects.
- Fix some C++ unaligned traps on alpha.

* Fri May  5 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-5mdk
- Fix threads.

* Tue Apr 25 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-4mdk
- Fix bad ucontext.h headers conflicts with  ncurses and others library.
- removed iso3166.tab and posixrules from %files section, they are already
  in the filelist (Stefan van der Eijk <s.vandereijk@chello.nl>).
- fix alpha build.

* Fri Apr 14 2000 David BAUDENS <baudens@mandrakesoft.com> 2.1.3-3mdk
- i486 fix
- Comment BuildRequires: egcs (not needed; see 2.1.3-1mdk)

* Wed Apr  5 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-2mdk
- Merge the Adam Lesback <adam@mandrakesoft.com> powerpc change.

* Thu Mar 30 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-1mdk
- Recompile with gcc2.95 and get optimisations back.
- Merge rh patchs.
- Clean-up specs.
- Adjust groups.

* Tue Mar  7 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-0.2mdk
- Compile with egcs.
- glibc2.1.3 final.
- Merge with last rh patchs.

* Thu Feb 17 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-0.1mdk
- Forget also the Serial:.
- Forget the release scheme.

* Wed Feb 16 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 2.1.3-1mdk
- 2.1.3 from CVS.
- Getting the glibc like redhat does (from cvs).
- Spec rewrite.

* Wed Dec 15 1999 Frederic Lepied <flepied@kenobi.mandrakesoft.com>
- add patch for malloc (rd)

* Tue Nov  2 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>
- Add from pablo catalan locales.
- Bzip2 manpages.

* Sat Oct 23 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>
- Last CVS snapshot.

* Thu Oct 21 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>
- Fix stupid thing in %files (thanks pablo).
- Remove glibc-localedata

* Sun Oct 17 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>
- Last CVS snapshot.
- Clean-up of specfile.

* Mon Oct 11 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>
- Add pixel patch to don't lie about k6 optimisations.

* Mon Oct 11 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>
- Add serial

* Fri Oct  8 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>

- Add Pablo (AKA: Mri18n) patch :
    - Support of new encodages in /usr/lib/gconv).
- Merge with rh patch and others.
- Update to snapshot 2.1.3 but keep the version to 2.1.2.
- disable some extra debugging messages form alpha/ioperm.c
- make /etc/localtime a real file instead of a symlink
- add sys/raw.h as anew header file.(rh)
- add the vfork patch for linuxthreads.(rh)

* Thu Sep 09 1999 Thierry Vignaud <tvignaud@mandrakesoft.com>
- 2.1.2final (mainly bug fixes)

* Wed Aug 26 1999 Thierry Vignaud <tvignaud@mandrakesoft.com>
- 2.1.2

* Fri Jul 09 1999 Pablo Saratxaga <pablo@mandrakesoft.com>
- moved locales data to separate package; don't make compilated
  locales (that will be better on separate locales-$LANG
  packages, one for language, more accurate and more numerous); so people
  can choose not to install those, or install exactly those they want.
  glibc-localedata is only needed if you want to manually build locales
  definitions.

* Fri Jul 09 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>
- Fix wrong install entry in dir info files (Patch50).

* Fri Jul  9 1999 Bernhard Rosenkraenzer <bero@mandrakesoft.de>
- 2.1.1final
- add Debian fixes
- enable SMP build

* Wed May 19 1999 Bernhard Rosenkraenzer <bero@mandrakesoft.com>
- 2.1.1pre3

* Fri Apr 30 1999 Bernhard Rosenkraenzer <bero@mandrakesoft.com>
- Mandrake adaptions
- handle RPM_OPT_FLAGS better

* Wed Apr 14 1999 Cristian Gafton <gafton@redhat.com>
- new CVS update - some patches dropped out
- updated obsoletes tag lines
- patch for the ukraine support

* Fri Apr 09 1999 Cristian Gafton <gafton@redhat.com>
- add patch for libstdc++ 2.7.2 (enable __dup, __pipe and __waitpid)
- linuxthread patch from HJLu
- add patch to make nscd respond to SIGHUP by dumping the cache

* Wed Apr 07 1999 Cristian Gafton <gafton@redhat.com>
- updated from cvs tree
- add patch for fstatvfs from HJLu

* Thu Apr 01 1999 Cristian Gafton <gafton@redhat.com>
- opentty fix
- don't call lddlibc4 on sparcs

* Thu Mar 25 1999 Cristian Gafton <gafton@redhat.com>
- version 2.1.1
- make nscd run by default at init
- nscd subpackage
- let the subpackages autoreq their own thing

* Fri Mar 12 1999 Cristian Gafton <gafton@redhat.com>
- version 2.1
- strip binaries installed by default

* Thu Feb 18 1999 Cristian Gafton <gafton@redhat.com>
- updated snapshot
- glibc-crypt might have export problems (who knows?), so we are nosource
  iit for now

* Wed Feb 03 1999 Cristian Gafton <gafton@redhat.com>
- version 2.0.112
- merge glibc-debug into glibc-devel
- new compat add-on

* Wed Jan 13 1999 Cristian Gafton <gafton@redhat.com>
- new glibc-crypt add-on
- version 2.0.109
- handle /etc/localtime separately
- don't include /usr/share in the file list
- don not build glibc-compat on the arm

* Wed Dec 02 1998 Cristian Gafton <gafton@redhat.com>
- build ver 2.0.105 on all four arches
- enabled /usr/include/scsi as part of the glibc package

* Fri Oct 02 1998 Cristian Gafton <gafton@redhat.com>
- first build for 2.0.96