@@ -28,10 +28,17 @@ RUN CFLAGS="-Wa,-mrelax-relocations=no -Wa,--compress-debug-sections=none -Wl,--
28
28
COPY scripts/sccache.sh /scripts/
29
29
RUN sh /scripts/sccache.sh
30
30
31
+ ENV HOSTS=x86_64-unknown-linux-musl
32
+
31
33
ENV RUST_CONFIGURE_ARGS \
32
34
--musl-root-x86_64=/usr/local/x86_64-linux-musl \
33
35
--enable-extended \
34
- --disable-docs
36
+ --disable-docs \
37
+ --set target.x86_64-unknown-linux-musl.crt-static=false \
38
+ --build $HOSTS \
39
+ --set target.x86_64-unknown-linux-musl.cc=x86_64-linux-musl-gcc \
40
+ --set target.x86_64-unknown-linux-musl.cxx=x86_64-linux-musl-g++ \
41
+ --set target.x86_64-unknown-linux-musl.linker=x86_64-linux-musl-gcc
35
42
36
43
# Newer binutils broke things on some vms/distros (i.e., linking against
37
44
# unknown relocs disabled by the following flag), so we need to go out of our
@@ -42,12 +49,4 @@ ENV RUST_CONFIGURE_ARGS \
42
49
ENV CFLAGS_x86_64_unknown_linux_musl="-Wa,-mrelax-relocations=no -Wa,--compress-debug-sections=none \
43
50
-Wl,--compress-debug-sections=none"
44
51
45
- ENV HOSTS=x86_64-unknown-linux-musl \
46
- CC_x86_64_unknown_linux_musl=x86_64-linux-musl-gcc \
47
- CXX_x86_64_unknown_linux_musl=x86_64-linux-musl-g++
48
-
49
- # Musl defaults to static libs but we need them to be dynamic for host toolchain.
50
- # The toolchain will produce static libs by default.
51
- ENV RUSTFLAGS="-C target-feature=-crt-static"
52
-
53
- ENV SCRIPT python2.7 ../x.py dist --host $HOSTS --target $HOSTS
52
+ ENV SCRIPT python2.7 ../x.py dist --build $HOSTS
0 commit comments