Skip to content
This repository was archived by the owner on Feb 8, 2026. It is now read-only.

Commit 9e0fa6f

Browse files
committed
fix: update Dockerfile to use Ubuntu base image and install necessary dependencies for multi-target builds
1 parent fc4de01 commit 9e0fa6f

1 file changed

Lines changed: 17 additions & 6 deletions

File tree

Dockerfile

Lines changed: 17 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,34 @@
11
# --- Étape 1 : build avec rust:1.88 + nightly via rust-toolchain.toml ---
2-
FROM rust:1.88 AS builder
2+
FROM ubuntu:18.04 AS builder
33

4-
# Prérequis systèmes pour Linux32/64 et Windows32/64
5-
RUN dpkg --add-architecture i386 \
6-
&& apt-get update \
4+
# Set timezone to avoid interactive prompts
5+
ENV DEBIAN_FRONTEND=noninteractive
6+
ENV TZ=UTC
7+
8+
# Install Rust and dependencies
9+
RUN apt-get update \
710
&& apt-get install -y --no-install-recommends \
811
build-essential \
12+
curl \
13+
ca-certificates \
914
gcc-multilib g++-multilib \
1015
gcc-mingw-w64-i686 g++-mingw-w64-i686 \
1116
gcc-mingw-w64-x86-64 g++-mingw-w64-x86-64 \
1217
liblua5.1-0-dev \
13-
curl git pkg-config musl-dev \
18+
git pkg-config \
1419
&& rm -rf /var/lib/apt/lists/*
1520

21+
# Install Rust manually
22+
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
23+
ENV PATH="/root/.cargo/bin:${PATH}"
24+
1625
WORKDIR /build
1726
COPY rust-toolchain.toml .
1827
COPY . .
1928

20-
# Compilation du workspace pour chaque target
29+
# Add targets and build
30+
RUN rustup target add i686-unknown-linux-gnu x86_64-unknown-linux-gnu i686-pc-windows-gnu x86_64-pc-windows-gnu
31+
2132
RUN echo "→ build Linux 32-bits" \
2233
&& cargo build --release --target i686-unknown-linux-gnu \
2334
\

0 commit comments

Comments
 (0)