#!/bin/sh # Reading system configuration informations, functions and package versions. source ../sysinfos source ../functions source ../packages-list # Applying patches (if any) apply_patches ${1} && # Saves CFLAGS and CXXFLAGS, and clears them. save_flags_no_optimizations cd ${LFS_TMP}/${1} && # Configure options: # --disable-profile # Builds the libraries without profiling information. # --enable-add-ons # Use all the add-ons it finds. # crypt and localdata are now part of glibc. # --enable-kernel=2.x.x # Compile the library for support of linux 2.6.x kernels. # The kernel version specified must not be newer than the # version of the kernel running on the build machine. # --without-gd # Prevents the build of the memusagestat program, which # strangely enough insists on linking against the host's # libraries (libgd, libpng, libz, and so forth). cd ${LFS_TMP}/${1}-build && BUILD_CC=gcc CC=${CROSS_COMPILE}gcc AR=${CROSS_COMPILE}ar RANLIB=${CROSS_COMPILE}ranlib AS=${CROSS_COMPILE}as LD=${CROSS_COMPILE}ld \ ../${1}/configure \ --prefix=/usr \ --host=${TARGET} \ --with-headers=${SYSROOT}/usr/include \ --enable-add-ons \ --enable-kernel=${GLIBC_KERNEL_VERSION} \ --disable-profile \ --without-gd \ --without-cvs \ --without-selinux && # --enable-threads=posix \ # --enable-static-nss \ # --enable-add-ons \ # --disable-sanity-checks \ # --without-__thread \ make && make install_root=${SYSROOT} install # Return last error exit $?