Skip to content

Commit

Permalink
Rollup merge of rust-lang#40617 - TimNN:dist-update-gcc, r=alexcrichton
Browse files Browse the repository at this point in the history
Update gcc used for dist-x86-linux builds

GCC 4.7 is too old to build LLVM 4.0, so this PR updates to 4.8.

r? @alexcrichton (I'll ping you again once travis is green and the test commit is removed).
  • Loading branch information
frewsxcv authored Mar 22, 2017
2 parents 2de14f6 + 88d5645 commit c5f3bf1
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
1 change: 1 addition & 0 deletions src/ci/docker/dist-x86-linux/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ RUN yum upgrade -y && yum install -y \
curl \
bzip2 \
gcc \
gcc-c++ \
make \
glibc-devel \
perl \
Expand Down
12 changes: 7 additions & 5 deletions src/ci/docker/dist-x86-linux/build-gcc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,14 @@ set -ex

source shared.sh

curl https://ftp.gnu.org/gnu/gcc/gcc-4.7.4/gcc-4.7.4.tar.bz2 | tar xjf -
cd gcc-4.7.4
GCC=4.8.5

curl https://ftp.gnu.org/gnu/gcc/gcc-$GCC/gcc-$GCC.tar.bz2 | tar xjf -
cd gcc-$GCC
./contrib/download_prerequisites
mkdir ../gcc-build
cd ../gcc-build
hide_output ../gcc-4.7.4/configure \
hide_output ../gcc-$GCC/configure \
--prefix=/rustroot \
--enable-languages=c,c++
hide_output make -j10
Expand All @@ -27,5 +29,5 @@ ln -nsf gcc /rustroot/bin/cc

cd ..
rm -rf gcc-build
rm -rf gcc-4.7.4
yum erase -y gcc binutils
rm -rf gcc-$GCC
yum erase -y gcc gcc-c++ binutils

0 comments on commit c5f3bf1

Please sign in to comment.