#!/bin/bash
-CC="gcc -isystem /usr/include"
-LDFLAGS="-Wl,-rpath-link,/lib"
-
-CONFIGURE_OPTS="\
- --libdir=/usr/lib \
- --enable-shared \
- --disable-multilib \
- ${CONFIGURE_OPTS}"
-
hvconfig_pre()
{
+ export CC="gcc -isystem /usr/include"
+ export LDFLAGS="-Wl,-rpath-link,/lib"
+
+ CONFIGURE_OPTS+=" \
+ --libdir=/usr/lib \
+ --enable-shared \
+ --disable-multilib"
+
case "${HVL_TARGET}" in
"x86_64")
- # Libiberty uses gcc -print-multi-os-directory to determine where to
- # install libiberty.a. Because our temporary GCC is still
- # multilib-aware, the command returns ../lib64 which causes the archive
- # to be installed into /usr/lib64. The following sed will prevent this:
- sed -i 's%\(^MULTIOSDIR = \).*%\1 ../lib%' \
- ${LFS_TMP}/${PACKAGE}/libiberty/Makefile.in
-
# This adds 64 bit support to Binutils.
- CONFIGURE_OPTS="${CONFIGURE_OPTS} --enable-64-bit-bfd"
+ CONFIGURE_OPTS+=" --enable-64-bit-bfd"
;;
esac
}
+hvconfig_post()
+{
+ unset CC
+ unset LDFLAGS
+}
+
hvbuild()
{
make configure-host
make tooldir=/usr
make tooldir=/usr install
}
-
-hvbuild_post()
-{
- # Install the libiberty header file that is needed by some packages:
- cp -v ../${PACKAGE}/include/libiberty.h /usr/include
-}