#!/bin/sh set -o errexit # Reading system configuration informations, functions and package versions. source ../sysinfos source ../functions source ../packages-list PACKAGE=${1} shift CONFIGURE_OPTS=${*} # Manually applying patches apply_patch ${PACKAGE}-branch_update-1.patch ${PACKAGE} case "${HVL_TARGET}" in "x86_64") # Apply the following patch so that GCC links to /lib instead of /lib64: apply_patch ${PACKAGE}-pure64-1.patch ${PACKAGE} ;; esac cd ${LFS_TMP}/${PACKAGE} # Applying a sed substitution that will suppress the installation of # libiberty.a. We want to use the Binutils version of libiberty.a sed -i 's/install_to_$(INSTALL_DEST) //' libiberty/Makefile.in cd ${LFS_TMP}/${PACKAGE}-build ../${PACKAGE}/configure \ --prefix=/usr \ --sysconfdir=/etc \ ${CONFIGURE_OPTS} make make install ldconfig ln -svf ../usr/bin/cpp /lib ln -svf gcc /usr/bin/cc exit $?