From 71fcad80d395e5ff59e72bc127736c3f7602e6d7 Mon Sep 17 00:00:00 2001 From: Aleksey Selihov <1+faumaray@noreply@void.com> Date: Thu, 3 Dec 2026 08:09:44 +0000 Subject: [PATCH] chore(build): containers, toolchains and portability fixes --- Dockerfile.mingw | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 Dockerfile.mingw diff --git a/Dockerfile.mingw b/Dockerfile.mingw new file mode 100644 index 0000000..df9acd3 --- /dev/null +++ b/Dockerfile.mingw @@ -0,0 +1,29 @@ +# MinGW-w64 cross-build environment for VoidLibrary (Windows x64 from Linux). +# +# Uses the LLVM-MinGW toolchain (Clang + libc++ + MinGW-w64 runtime), which is +# new enough for the C++26 features this project uses. Reflection is not +# available on Clang, so the reflection-only tests are skipped exactly as on +# any non-reflecting compiler. + +FROM mstorsjo/llvm-mingw:latest + +ARG CMAKE_VERSION=4.2.3 + +# The base image is Ubuntu 24.04 with CMake 3.28; Void requires CMake 4. +RUN apt-get update \ + && apt-get install -y --no-install-recommends ca-certificates curl git \ + && rm -rf /var/lib/apt/lists/* + +RUN curl -fsSL -o /tmp/cmake.tar.gz \ + "https://github.com/Kitware/CMake/releases/download/v${CMAKE_VERSION}/cmake-${CMAKE_VERSION}-linux-x86_64.tar.gz" \ + && tar -xzf /tmp/cmake.tar.gz -C /opt \ + && ln -sf "/opt/cmake-${CMAKE_VERSION}-linux-x86_64/bin/cmake" /usr/local/bin/cmake \ + && ln -sf "/opt/cmake-${CMAKE_VERSION}-linux-x86_64/bin/ctest" /usr/local/bin/ctest \ + && ln -sf "/opt/cmake-${CMAKE_VERSION}-linux-x86_64/bin/cpack" /usr/local/bin/cpack \ + && rm /tmp/cmake.tar.gz + +ENV PATH="/opt/llvm-mingw/bin:${PATH}" + +WORKDIR /src + +CMD ["bash"]