2016-10-11 21:21:40 +02:00
|
|
|
FROM ubuntu:16.04
|
|
|
|
|
2017-07-09 17:01:27 +02:00
|
|
|
COPY scripts/cross-apt-packages.sh /scripts/
|
|
|
|
RUN sh /scripts/cross-apt-packages.sh
|
|
|
|
|
|
|
|
# Ubuntu 16.04 (this container) ships with make 4, but something in the
|
2017-01-29 06:25:11 +01:00
|
|
|
# toolchains we build below chokes on that, so go back to make 3
|
2017-07-09 17:01:27 +02:00
|
|
|
COPY scripts/make3.sh /scripts/
|
|
|
|
RUN sh /scripts/make3.sh
|
2017-01-29 06:25:11 +01:00
|
|
|
|
2017-07-09 17:01:27 +02:00
|
|
|
COPY scripts/crosstool-ng.sh /scripts/
|
|
|
|
RUN sh /scripts/crosstool-ng.sh
|
2017-01-29 06:25:11 +01:00
|
|
|
|
2017-07-09 17:01:27 +02:00
|
|
|
COPY scripts/rustbuild-setup.sh /scripts/
|
|
|
|
RUN sh /scripts/rustbuild-setup.sh
|
2017-01-29 06:25:11 +01:00
|
|
|
USER rustbuild
|
|
|
|
WORKDIR /tmp
|
|
|
|
|
2017-05-12 20:18:34 +02:00
|
|
|
COPY dist-armhf-linux/arm-linux-gnueabihf.config dist-armhf-linux/build-toolchains.sh /tmp/
|
2017-04-01 16:18:43 +02:00
|
|
|
RUN ./build-toolchains.sh
|
2017-01-29 06:25:11 +01:00
|
|
|
|
2017-03-17 20:52:44 +01:00
|
|
|
USER root
|
|
|
|
|
2017-07-09 17:01:27 +02:00
|
|
|
COPY scripts/sccache.sh /scripts/
|
|
|
|
RUN sh /scripts/sccache.sh
|
2017-03-22 19:33:07 +01:00
|
|
|
|
2017-04-01 16:18:43 +02:00
|
|
|
ENV PATH=$PATH:/x-tools/arm-unknown-linux-gnueabihf/bin
|
2016-12-12 20:36:52 +01:00
|
|
|
|
2017-04-01 16:18:43 +02:00
|
|
|
ENV CC_arm_unknown_linux_gnueabihf=arm-unknown-linux-gnueabihf-gcc \
|
|
|
|
AR_arm_unknown_linux_gnueabihf=arm-unknown-linux-gnueabihf-ar \
|
|
|
|
CXX_arm_unknown_linux_gnueabihf=arm-unknown-linux-gnueabihf-g++
|
2016-10-11 21:21:40 +02:00
|
|
|
|
2017-04-01 16:18:43 +02:00
|
|
|
ENV HOSTS=arm-unknown-linux-gnueabihf
|
2017-01-16 23:15:12 +01:00
|
|
|
|
2018-02-11 23:52:44 +01:00
|
|
|
ENV RUST_CONFIGURE_ARGS --enable-extended
|
2017-01-16 23:15:12 +01:00
|
|
|
ENV SCRIPT python2.7 ../x.py dist --host $HOSTS --target $HOSTS
|