-
Notifications
You must be signed in to change notification settings - Fork 133
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Include rcedit for Windows builds #21
Comments
As a workaround to this issue, I added an extra step before the rest of the steps for Windows builds in the workflow file, that downloads and sets up WINE and recedit. The instructions are these:
It first downloads WINE. I'm not sure if wine-stable is needed, but if wine32 isn't installed, it complains. This solution might not be the most optimized one, so feel free to suggest improvements. It does work properly though. You can see a full example here: https://github.com/Orama-Interactive/Pixelorama/blob/master/.github/workflows/dev-desktop-builds.yml I tried writing these instructions inside a Dockerfile, but so far I didn't manage to make it work. The logic should be similar though. Is it best to do it in the workflow, or if this should be done in the Dockerfile itself? |
I add Wine and RCEdit to integrate the icon, and imagemagick to generate it from a png image (as well as potentially generating the OSX icns with icnsutils, though I haven't gotten there yet) I also generate inline a small script example usage:
Here's the dockerfile: FROM ubuntu:bionic
LABEL author="[email protected]"
ARG GODOT_VERSION=3.2.3
USER root
RUN apt-get update && apt-get install -y --no-install-recommends \
ca-certificates \
git \
python \
python-openssl \
unzip \
wget \
zip \
wine-stable \
wine64 \
imagemagick \
icnsutils \
curl \
--fix-missing \
&& rm -rf /var/lib/apt/lists/*
ENV GODOT_VERSION=$GODOT_VERSION
ENV WINEDEBUG -all
RUN wget https://downloads.tuxfamily.org/godotengine/${GODOT_VERSION}/Godot_v${GODOT_VERSION}-stable_linux_headless.64.zip \
&& wget https://downloads.tuxfamily.org/godotengine/${GODOT_VERSION}/Godot_v${GODOT_VERSION}-stable_export_templates.tpz \
&& mkdir ~/.cache \
&& mkdir -p ~/.config/godot \
&& mkdir -p ~/.local/share/godot/templates/${GODOT_VERSION}.stable \
&& unzip Godot_v${GODOT_VERSION}-stable_linux_headless.64.zip \
&& mv Godot_v${GODOT_VERSION}-stable_linux_headless.64 /usr/local/bin/godot \
&& unzip Godot_v${GODOT_VERSION}-stable_export_templates.tpz \
&& mv templates/* ~/.local/share/godot/templates/${GODOT_VERSION}.stable \
&& rm -f Godot_v${GODOT_VERSION}-stable_export_templates.tpz Godot_v${GODOT_VERSION}-stable_linux_headless.64.zip
RUN wget https://github.com/electron/rcedit/releases/download/v1.1.1/rcedit-x64.exe \
&& mkdir -p /opt/rcedit \
&& mkdir -p /opt/rcedit/bin \
&& mv rcedit-x64.exe /opt/rcedit
RUN mkdir -p /opt/butler
RUN wget -O /opt/butler/butler.zip https://broth.itch.ovh/butler/linux-amd64/LATEST/archive/default
RUN unzip /opt/butler/butler.zip -d /opt/butler
RUN rm -rf /opt/butler/butler.zip
RUN ls /opt/butler
RUN chmod +x /opt/butler/butler
RUN /opt/butler/butler -V
RUN echo "convert \$1 -define icon:auto-resize=256,128,64,48,32,16 /tmp/icon.ico && wine /opt/rcedit/rcedit-x64.exe \$2 --set-icon /tmp/icon.ico" > /opt/rcedit/bin/set-icon
RUN chmod +x /opt/rcedit/bin/set-icon
ENV PATH="/opt/butler/:/opt/rcedit/bin/:${PATH}" I have the Godot version as an arg, so you can build the docker this way: sudo docker build -t xananax/godot-ci:3.2.3 --build-arg GODOT_VERSION=3.2.3 . Is there any interest in a PR? |
this would be nice to have yes :) |
|
Currently, Windows builds generated by godot-ci do not have an icon and the Windows preset options found in
export_presets.cfg
are ignored. To solve this, godot-ci needs to install rcedit (and possibly WINE), and include the paths to these binaries inside Godot's editor settings. See this for more information: https://docs.godotengine.org/en/stable/getting_started/workflow/export/changing_application_icon_for_windows.htmlThe text was updated successfully, but these errors were encountered: