Clean trailing whitespace
[hvlinux.git] / stage2 / pkg / gcc
index c73c30d..edcfe46 100644 (file)
@@ -1,45 +1,33 @@
 #!/bin/bash
 
-CC="gcc -Wl,-rpath-link,/lib -isystem /usr/include"
-CXX="g++ -Wl,-rpath-link,/lib -isystem /usr/include"
-
-CONFIGURE_OPTS="\
-    --libexecdir=/usr/lib \
-    --enable-shared \
-    --enable-threads=posix \
-    --enable-__cxa_atexit \
-    --enable-c99 \
-    --enable-long-long \
-    --enable-clocale=gnu \
-    --enable-languages=c,c++ \
-    --disable-multilib \
-    --disable-libstdcxx-pch \
-    ${CONFIGURE_OPTS}"
-
-hvpatch()
+hvconfig_pre()
 {
-    # Manually applying patches if specified
-    if [ -n "${GCC_PATCHES}" ]; then
-        for p in ${GCC_PATCHES}; do
-            apply_patch ${PACKAGE}-${p}.patch ${PACKAGE}
-        done
-    fi
+    export CC="gcc -Wl,-rpath-link,/lib -isystem /usr/include"
+    export CXX="g++ -Wl,-rpath-link,/lib -isystem /usr/include"
 
-    case "${HVL_TARGET}" in
-        "x86_64")
-            # Apply the following patch so that GCC links to /lib instead of /lib64:
-            apply_patch ${PACKAGE}-pure64-2.patch ${PACKAGE}
-           ;;
-    esac
-}
+    CONFIGURE_OPTS+=" \
+        --libexecdir=/usr/lib \
+        --enable-shared \
+        --enable-threads=posix \
+        --enable-__cxa_atexit \
+        --enable-c99 \
+        --enable-long-long \
+        --enable-clocale=gnu \
+        --enable-languages=c,c++ \
+        --disable-multilib \
+        --disable-libstdcxx-pch"
 
-hvconfig_pre()
-{
     # 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) //' ${LFS_TMP}/${PACKAGE}/libiberty/Makefile.in
 }
 
+hvconfig_post()
+{
+    unset CC
+    unset CXX
+}
+
 hvbuild_post()
 {
     ln -svf ../usr/bin/cpp /lib