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/v2.6/linux-2.6.35.tar.gz \
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-2.6.35
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_gnu89_inline=yes
37 libc_cv_ctors_header=yes
38 libc_cv_c_cleanup=yes
39 ac_cv_sizeof_long_double=0
40 EOF
41
42 ../$name-$version/configure --build=$CHOST \
43 --host=$CTARGET \
44 --prefix=/usr \
45 --libexecdir=/usr/lib \
46 --with-headers=$PKG/usr/include \
47 --with-tls \
48 --enable-kernel=2.6.0 \
49 --enable-add-ons \
50 --disable-profile \
51 --without-gd \
52 --with-__thread \
53 --enable-obsolete-rpc
54
55 make CC="$CC" CFLAGS="$CFLAGS"
56 make install_root=$PKG install
57
58 cp $SRC/{hosts,resolv.conf,nsswitch.conf,host.conf,ld.so.conf} $PKG/etc
59 ln -sf ../usr/share/zoneinfo/UTC $PKG/etc/localtime
60 mkdir -p $PKG/etc/ld.so.conf.d $PKG/usr/lib/locale
61
62 rm -rf $PKG/usr/share/{info,locale} \
63 $PKG/usr/bin/tzselect \
64 $PKG/usr/sbin/z{dump,ic}
65 }