Skip to content

Commit

Permalink
Update MIPS toolchain URL and installation procedure
Browse files Browse the repository at this point in the history
After unpacking, remove documentation and deduplicate identical binaries
by using hardlinks to save space.
  • Loading branch information
Joakim Nohlgård authored and kaspar030 committed Jul 18, 2019
1 parent af1f432 commit f0921c7
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -117,16 +117,19 @@ ENV PATH ${PATH}:/opt/gcc-arm-none-eabi-7-2018-q2-update/bin

# Install MIPS binary toolchain
# For updates: https://www.mips.com/develop/tools/codescape-mips-sdk/ (select "Codescape GNU Toolchain")
RUN mkdir -p /opt && \
wget -q https://codescape.mips.com/components/toolchain/2016.05-03/Codescape.GNU.Tools.Package.2016.05-03.for.MIPS.MTI.Bare.Metal.CentOS-5.x86_64.tar.gz -O- \
| tar -C /opt -xz && \
ARG MIPS_VERSION=2017.10-08
RUN echo 'Installing mips-mti-elf toolchain from mips.com' >&2 && \
mkdir -p /opt && \
curl -L 'https://codescape.mips.com/components/toolchain/${MIPS_VERSION}/Codescape.GNU.Tools.Package.${MIPS_VERSION}.for.MIPS.MTI.Bare.Metal.CentOS-6.x86_64.tar.gz' -o - \
| tar -C /opt -zx && \
echo 'Removing documentation and translations' >&2 && \
rm -rf /opt/mips-mti-elf/*/share/{doc,info,man,locale} && \
echo 'Deduplicating binaries' >&2 && \
echo 'Deduplicating binaries' && \
cd /opt/mips-mti-elf/*/mips-mti-elf/bin && \
for f in *; do rm "$f" && ln "../../bin/mips-mti-elf-$f" "$f"; done && cd -
for f in *; do test -f "../../bin/mips-mti-elf-$f" && ln -f "../../bin/mips-mti-elf-$f" "$f"; done && cd -

ENV MIPS_ELF_ROOT /opt/mips-mti-elf/${MIPS_VERSION}

ENV MIPS_ELF_ROOT /opt/mips-mti-elf/2016.05-03
ENV PATH ${PATH}:${MIPS_ELF_ROOT}/bin

# Install RISC-V binary toolchain
Expand Down

0 comments on commit f0921c7

Please sign in to comment.