3 # Enable source repositories, which are disabled by default on Ubuntu >= 18.04
4 RUN sed -i 's/^# deb-src/deb-src/' /etc/apt/sources.list
6 COPY scripts/cross-apt-packages.sh /tmp/
7 RUN bash /tmp/cross-apt-packages.sh
9 # Required for cross-build gcc
10 RUN apt-get update && \
11 apt-get install -y --no-install-recommends \
16 COPY scripts/illumos-toolchain.sh /tmp/
18 RUN bash /tmp/illumos-toolchain.sh x86_64 sysroot
19 RUN bash /tmp/illumos-toolchain.sh x86_64 binutils
20 RUN bash /tmp/illumos-toolchain.sh x86_64 gcc
22 COPY scripts/sccache.sh /scripts/
23 RUN sh /scripts/sccache.sh
25 COPY scripts/cmake.sh /scripts/
29 AR_x86_64_unknown_illumos=x86_64-illumos-ar \
30 CC_x86_64_unknown_illumos=x86_64-illumos-gcc \
31 CXX_x86_64_unknown_illumos=x86_64-illumos-g++
33 ENV HOSTS=x86_64-unknown-illumos
35 ENV RUST_CONFIGURE_ARGS --enable-extended --disable-docs
36 ENV SCRIPT python3 ../x.py dist --host $HOSTS --target $HOSTS