Sign inSign up

mtsuyama/rl78

By mtsuyama

•Updated almost 5 years ago

A compile environment for RL78/G13

Image
1

1.0K

mtsuyama/rl78 repository overview

Dockerfile

FROM ubuntu:bionic as builder

RUN apt update&&\
    apt install -y texinfo libgmp-dev libmpfr-dev libmpc-dev diffutils automake zlib1g-dev make gzip curl gcc g++ &&\
    mkdir /tmp/gcc-4.9.4 &&\
    mkdir /tmp/binutils-2.25.1 &&\
    mkdir /tmp/newlib-2.2.0 &&\
    curl -L https://ftp.gnu.org/gnu/gcc/gcc-4.9.4/gcc-4.9.4.tar.gz |\
    tar -xz -C /tmp/gcc-4.9.4 --strip-components=1 &&\
    curl -L https://ftp.gnu.org/gnu/binutils/binutils-2.25.1.tar.gz |\
    tar -xz -C /tmp/binutils-2.25.1 --strip-components=1 &&\
    curl -L ftp://sourceware.org/pub/newlib/newlib-2.2.0.tar.gz |\
    tar -xz -C /tmp/newlib-2.2.0 --strip-components=1
WORKDIR /tmp/binutils-2.25.1/build
RUN ../configure --target=rl78-elf --prefix=/usr/local/rl78-elf --disable-nls --with-system-zlib &&\
    make -j4 &&\
    make install
ENV PATH=$PATH:/usr/local/rl78-elf/bin:/usr/local/rl78-elf/rl78-elf/bin
WORKDIR /tmp/gcc-4.9.4/build
RUN ../configure --prefix=/usr/local/rl78-elf --target=rl78-elf --enable-languages=c --disable-libssp --with-newlib --disable-nls --disable-threads --disable-libgomp --disable-libmudflap --disable-libstdcxx-pch --disable-multilib --enable-lto --with-system-zlib &&\
    make -j4 &&\
    make install
WORKDIR /tmp/newlib-2.2.0/build
RUN ../configure --target=rl78-elf --prefix=/usr/local/rl78-elf &&\
    make -j4 &&\
    make install
WORKDIR /tmp/gcc-4.9.4/build
RUN ../configure --prefix=/usr/local/rl78-elf --target=rl78-elf --enable-languages=c,c++ --disable-libssp --with-newlib --disable-nls --disable-threads --disable-libgomp --disable-libmudflap --disable-libstdcxx-pch --disable-multilib --enable-lto --with-system-zlib &&\
    make -j4 &&\
    make install


FROM ubuntu:bionic as final
COPY --from=builder /usr/local/rl78-elf /usr/local/rl78-elf
WORKDIR /workdir
RUN apt update &&\
apt install -y clang libboost1.65-dev make libmpc3
ENV PATH=$PATH:/usr/local/rl78-elf/bin:/usr/local/rl78-elf/rl78-elf/bin


Tag summary

Content type

Image

Digest

Size

328.7 MB

Last updated

almost 5 years ago

docker pull mtsuyama/rl78