CRUX-ARM : Home

Home :: Documentation :: Download :: Development :: Community :: Ports :: Packages :: Bugs :: Links :: About :: Donors
glibc: updated to 2.16.0
[crossrootfs.git] / glibc / Pkgfile
1 # Description: The C library used in the GNU system
2 # URL: http://www.gnu.org/software/libc/
3 # Maintainer: CRUX System Team, core-ports at crux dot nu
4 # Arch Maintainer: CRUX-ARM System Team, devel at crux-arm dot nu
5 # Depends on:
6
7 name=glibc
8 version=2.16.0
9 release=1
10 source=(http://ftp.gnu.org/gnu/glibc/glibc-$version.tar.xz \
11 ftp://ftp.gnu.org/gnu/$name/$name-ports-$version.tar.bz2 \
12 ftp://ftp.kernel.org/pub/linux/kernel/v3.0/linux-3.5.4.tar.xz \
13 $name-resolv_assert.patch
14 $name-strtod_integer_overflow.patch
15 hosts resolv.conf nsswitch.conf host.conf ld.so.conf)
16
17 build() {
18 # install build kernel headers
19 cd linux-3.5.4
20 make mrproper
21 make ARCH=arm headers_check
22 make ARCH=arm INSTALL_HDR_PATH=$PKG/usr headers_install
23
24 cd $SRC
25 mv $name-ports-$version $name-$version/ports
26
27 pushd $name-$version
28 patch -p1 -i $SRC/$name-resolv_assert.patch
29 patch -p1 -i $SRC/$name-strtod_integer_overflow.patch
30 popd
31
32 mkdir build
33 cd build
34
35 cat > config.cache << EOF
36 libc_cv_forced_unwind=yes
37 libc_cv_ctors_header=yes
38 libc_cv_c_cleanup=yes
39 EOF
40
41 ../$name-$version/configure --build=$CHOST \
42 --host=$CTARGET \
43 --prefix=/usr \
44 --libexecdir=/usr/lib \
45 --with-headers=$PKG/usr/include \
46 --with-tls \
47 --enable-kernel=2.6.25 \
48 --enable-add-ons \
49 --disable-profile \
50 --without-gd \
51 --with-__thread \
52 --enable-obsolete-rpc
53
54 make CC="$CC" CFLAGS="$CFLAGS"
55 make install_root=$PKG install
56
57 cp $SRC/{hosts,resolv.conf,nsswitch.conf,host.conf,ld.so.conf} $PKG/etc
58 ln -sf ../usr/share/zoneinfo/UTC $PKG/etc/localtime
59 mkdir -p $PKG/etc/ld.so.conf.d $PKG/usr/lib/locale
60
61 rm -rf $PKG/usr/share/{info,locale} \
62 $PKG/usr/bin/tzselect \
63 $PKG/usr/sbin/z{dump,ic}
64 }