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, crux-arm at mikeux dot dyndns dot org
10 source=(ftp://ftp.gnu.org/gnu/$name/$name-$version.tar.bz2 \
11 ftp://ftp.gnu.org/gnu/$name/$name-ports-$version.tar.bz2 \
12 $name-$version-libgcc_eh-1.patch \
13 $name-$version-localedef_segfault-1.patch \
14 $name-$version-cross_hacks-2.patch \
15 $name-$version-nptl_lowlevellock-1.patch \
16 $name-$version-arm_setjmp_fix-1.patch \
17 ftp://ftp.kernel.org/pub/linux/kernel/v2.6/linux-2.6.28.8.tar.bz2 \
18 hosts resolv.conf nsswitch.conf host.conf ld.so.conf)
21 # install build kernel headers
24 make ARCH=arm headers_check
25 make ARCH=arm INSTALL_HDR_PATH=$PKG/usr headers_install
28 mv $name-ports-$version $name-$version/ports
31 patch -p1 -i $SRC/$name-$version-libgcc_eh-1.patch
32 patch -p1 -i $SRC/$name-$version-localedef_segfault-1.patch
33 patch -p1 -i $SRC/$name-$version-cross_hacks-2.patch
34 patch -p1 -i $SRC/$name-$version-nptl_lowlevellock-1.patch
35 patch -p1 -i $SRC/$name-$version-arm_setjmp_fix-1.patch
41 cat > config.cache << EOF
42 libc_cv_forced_unwind=yes
44 libc_cv_gnu89_inline=yes
45 ac_cv_sizeof_long_double=0
48 ../$name-$version/configure --build=$CHOST \
51 --libexecdir=/usr/lib \
52 --with-headers=$PKG/usr/include \
54 --enable-kernel=2.6.0 \
58 --cache-file=config.cache
60 make CC="$CC" CFLAGS="$CFLAGS"
61 make install_root=$PKG install
62 cp $SRC/{hosts,resolv.conf,nsswitch.conf,host.conf,ld.so.conf} $PKG/etc
63 ln -sf ../usr/share/zoneinfo/UTC $PKG/etc/localtime
64 mkdir -p $PKG/etc/ld.so.conf.d $PKG/usr/lib/locale
66 # conflicts with quota
67 rm $PKG/usr/include/rpcsvc/{rquota.h,rquota.x}
68 rm -rf $PKG/usr/share/{info,locale}