Add Docker+Wine Windows cross-build from Linux CI

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Michael-A-SloanandCursor committed 2026-05-15 11:16:09 -04:00
1 parent 2e36b189cf
commit 56f1f058ae
8 files changed
+184 -24

No files matched your search

+34
View File
@@ -0,0 +1,34 @@
# Build Windows PyInstaller bundle from Linux using Wine + Windows Python.
# Used by: build/ci/docker-build-windows.sh
FROM ubuntu:22.04
ENV DEBIAN_FRONTEND=noninteractive
ENV WINEARCH=win64
ENV WINEPREFIX=/root/.wine
ENV WINEDEBUG=-all
RUN dpkg --add-architecture i386 \
&& apt-get update \
&& apt-get install -y --no-install-recommends \
wine64 wine32 winbind \
wget curl ca-certificates unzip zip \
python3 python3-pip python3-venv \
xvfb \
&& rm -rf /var/lib/apt/lists/*
# Initialize Wine (needed for silent Python install)
RUN wineboot --init && sleep 10 || true
# Install Windows Python 3.12 into the Wine prefix
RUN wget -q https://www.python.org/ftp/python/3.12.7/python-3.12.7-amd64.exe -O /tmp/python-installer.exe \
&& wine64 /tmp/python-installer.exe /quiet InstallAllUsers=0 PrependPath=0 Include_pip=1 TargetDir=C:\\Python312 \
&& rm /tmp/python-installer.exe
ENV WIN_PY="wine64 C:\\Python312\\python.exe"
WORKDIR /src
COPY build/ci/docker-entrypoint-win.sh /docker-entrypoint-win.sh
RUN chmod +x /docker-entrypoint-win.sh
ENTRYPOINT ["/docker-entrypoint-win.sh"]