@@ -21,14 +21,9 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
21
21
libssl-dev \
22
22
pkg-config
23
23
24
- RUN curl -o /usr/local/bin/sccache \
25
- https://s3.amazonaws.com/rust-lang-ci/rust-ci-mirror/2017-05-12-sccache-x86_64-unknown-linux-musl && \
26
- chmod +x /usr/local/bin/sccache
27
-
28
- RUN curl -OL https://github.com/Yelp/dumb-init/releases/download/v1.2.0/dumb-init_1.2.0_amd64.deb && \
29
- dpkg -i dumb-init_*.deb && \
30
- rm dumb-init_*.deb
31
- ENTRYPOINT ["/usr/bin/dumb-init" , "--" ]
24
+ # dumb-init
25
+ COPY scripts/dumb-init.sh /scripts/
26
+ RUN sh /scripts/dumb-init.sh
32
27
33
28
WORKDIR /tmp
34
29
@@ -38,23 +33,11 @@ RUN ./build-rumprun.sh
38
33
COPY cross/build-arm-musl.sh /tmp/
39
34
RUN ./build-arm-musl.sh
40
35
41
- # originally from
42
- # https://downloads.openwrt.org/snapshots/trunk/ar71xx/generic/OpenWrt-Toolchain-ar71xx-generic_gcc-5.3.0_musl-1.1.16.Linux-x86_64.tar.bz2
43
- RUN mkdir /usr/local/mips-linux-musl
44
- RUN curl -L https://s3.amazonaws.com/rust-lang-ci/rust-ci-mirror/OpenWrt-Toolchain-ar71xx-generic_gcc-5.3.0_musl-1.1.16.Linux-x86_64.tar.bz2 | \
45
- tar xjf - -C /usr/local/mips-linux-musl --strip-components=2
46
- RUN for file in /usr/local/mips-linux-musl/bin/mips-openwrt-linux-*; do \
47
- ln -s $file /usr/local/bin/`basename $file`; \
48
- done
36
+ COPY cross/install-mips-musl.sh /tmp/
37
+ RUN ./install-mips-musl.sh
49
38
50
- # Note that this originally came from:
51
- # https://downloads.openwrt.org/snapshots/trunk/malta/generic/OpenWrt-Toolchain-malta-le_gcc-5.3.0_musl-1.1.15.Linux-x86_64.tar.bz2
52
- RUN mkdir /usr/local/mipsel-linux-musl
53
- RUN curl -L https://s3.amazonaws.com/rust-lang-ci/libc/OpenWrt-Toolchain-malta-le_gcc-5.3.0_musl-1.1.15.Linux-x86_64.tar.bz2 | \
54
- tar xjf - -C /usr/local/mipsel-linux-musl --strip-components=2
55
- RUN for file in /usr/local/mipsel-linux-musl/bin/mipsel-openwrt-linux-*; do \
56
- ln -s $file /usr/local/bin/`basename $file`; \
57
- done
39
+ COPY cross/install-mipsel-musl.sh /tmp/
40
+ RUN ./install-mipsel-musl.sh
58
41
59
42
ENV TARGETS=asmjs-unknown-emscripten
60
43
ENV TARGETS=$TARGETS,wasm32-unknown-emscripten
@@ -80,3 +63,10 @@ ENV RUST_CONFIGURE_ARGS \
80
63
--musl-root-armhf=/usr/local/arm-linux-musleabihf \
81
64
--musl-root-armv7=/usr/local/armv7-linux-musleabihf
82
65
ENV SCRIPT python2.7 ../x.py dist --target $TARGETS
66
+
67
+ # sccache
68
+ COPY scripts/sccache.sh /scripts/
69
+ RUN sh /scripts/sccache.sh
70
+
71
+ # init
72
+ ENTRYPOINT ["/usr/bin/dumb-init" , "--" ]
0 commit comments