-
Notifications
You must be signed in to change notification settings - Fork 1
/
Dockerfile
24 lines (18 loc) · 945 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# Image which has both devkitPro/devkitARM as well as rust. based on https://github.com/devkitPro/docker/blob/master/devkitarm/Dockerfile
# parallel build requiring DOCKER_BUILDKIT=1
FROM devkitpro/devkitarm as base
ENV RUST_TOOLCHAIN nightly-2021-03-25
FROM base as env
RUN git clone https://github.com/vivlim/3ds-rust-env.git /build --single-branch --branch ${RUST_TOOLCHAIN}
RUN cd /build && git submodule init && git submodule update
RUN cd /build/rust-3ds-fork && git submodule init && git submodule update
FROM base as rust
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain ${RUST_TOOLCHAIN}
ENV PATH=${PATH}:/root/.cargo/bin
RUN apt update && apt install build-essential -y
RUN cargo install xargo
# copy in everything from the other image
COPY --from=env /build /build
ENV DEVKITARM=${DEVKITPRO}/devkitARM
# build the hello world app, resulting in std being built & baked into the image
RUN cd /build/app && make