diff --git a/{{cookiecutter.project_slug}}/.github/workflows/package.yml b/{{cookiecutter.project_slug}}/.github/workflows/package.yml index ddf0912..951e433 100644 --- a/{{cookiecutter.project_slug}}/.github/workflows/package.yml +++ b/{{cookiecutter.project_slug}}/.github/workflows/package.yml @@ -55,8 +55,7 @@ jobs: - name: Checkout repository uses: actions/checkout@v3 - name: Build package - # NOTE: Github actions fuck up Docker's ENTRYPOINT, hence this atrocity - run: set +e; cd /opt/quasi-msys2/env; . /opt/quasi-msys2/env/all.src; cd -; WINEPATH="Z:/ucrt64/bin;C:/Program Files (x86)/NSIS" PKG_CONFIG_PATH="Z:/ucrt64/lib/pkgconfig" CC=gcc-wrapper wine busybox sh -c 'export HOME="C:/users/root"; ./package.sh windows' + run: msys2 -c "./package.sh windows" - name: Archive package uses: actions/upload-artifact@v3 with: diff --git a/{{cookiecutter.project_slug}}/package.sh b/{{cookiecutter.project_slug}}/package.sh index a7c1c5e..a3b3e8c 100755 --- a/{{cookiecutter.project_slug}}/package.sh +++ b/{{cookiecutter.project_slug}}/package.sh @@ -30,8 +30,10 @@ case $1 in windows) do_build {% if cookiecutter.backend != "raylib" %} - ntldd -R bin/* | grep ucrt64 | awk -F '=> ' '{ print $2 }' | awk '{ print $1 }' | xargs -I deps cp deps bin + ntldd -R bin/* | grep ucrt64 | awk -F '=> ' '{ print $2 }' | awk '{ print $1 }' | sed 's/\\/\\\\/g' | xargs -I deps cp deps bin {% endif %} + (cd "$TEMP"; convert "$OLDPWD/package/icon.png" -define icon:auto-resize=16,32,48,64,256 icon.ico) + (cd "$TEMP"; convert -resize 150x57 -extent 150x57 -gravity center -background white -alpha remove -alpha off "$OLDPWD/package/icon.png" BMP2:icon.bmp) makensis package/installer.nsi ;; diff --git a/{{cookiecutter.project_slug}}/package/installer.nsi b/{{cookiecutter.project_slug}}/package/installer.nsi index f88e6bb..6fe26fc 100644 --- a/{{cookiecutter.project_slug}}/package/installer.nsi +++ b/{{cookiecutter.project_slug}}/package/installer.nsi @@ -1,8 +1,5 @@ !include MUI2.nsh -!system 'convert icon.png -define icon:auto-resize=16,32,48,64,256 %TEMP%/icon.ico' -!system 'convert -resize 150x57 -extent 150x57 -gravity center -background white -alpha remove -alpha off icon.png BMP2:%TEMP%/icon.bmp' - !define MUI_PRODUCT "{{cookiecutter.project_name | reject('in', ('<', '>', ':', '"', '/', '\\', '|', '?', '*')) | join('')}}" !define MUI_FILE "{{cookiecutter.project_slug}}"