From 2248baf52ef79c73a99230ab1363fca0f1059588 Mon Sep 17 00:00:00 2001
From: Martchus <martchus@gmx.net>
Date: Fri, 28 Jul 2017 23:11:35 +0200
Subject: [PATCH] Use GCC from Git checkout

---
 build_gcc.sh | 18 ++----------------
 1 file changed, 2 insertions(+), 16 deletions(-)

diff --git a/build_gcc.sh b/build_gcc.sh
index 1eb07b8..1b7c782 100755
--- a/build_gcc.sh
+++ b/build_gcc.sh
@@ -27,8 +27,6 @@ fi
 # GCC mirror
 GCC_MIRROR="ftp://ftp.fu-berlin.de/unix/languages/gcc"
 
-require wget
-
 pushd $OSXCROSS_BUILD_DIR &>/dev/null
 
 function remove_locks()
@@ -40,21 +38,9 @@ source $BASE_DIR/tools/trap_exit.sh
 
 if [ ! -f "have_gcc_${GCC_VERSION}_${OSXCROSS_TARGET}" ]; then
 
-pushd $OSXCROSS_TARBALL_DIR &>/dev/null
-if [[ $GCC_VERSION != *-* ]]; then
-  wget -c "$GCC_MIRROR/releases/gcc-$GCC_VERSION/gcc-$GCC_VERSION.tar.bz2"
-else
-  wget -c "$GCC_MIRROR/snapshots/$GCC_VERSION/gcc-$GCC_VERSION.tar.bz2"
-fi
-popd &>/dev/null
-
-echo "cleaning up ..."
-rm -rf gcc* 2>/dev/null
-
-extract "$OSXCROSS_TARBALL_DIR/gcc-$GCC_VERSION.tar.bz2" 1
-echo ""
+ln -s "$GCC_CHECKOUT" gcc-$GCC_VERSION
 
-pushd gcc*$GCC_VERSION* &>/dev/null
+pushd gcc-$GCC_VERSION &>/dev/null
 
 rm -f $OSXCROSS_TARGET_DIR/bin/*-gcc*
 rm -f $OSXCROSS_TARGET_DIR/bin/*-g++*
-- 
2.13.3

