diff --git a/.github/workflows/windows_release.yml b/.github/workflows/windows_release.yml index 0b40e1e..bcecc60 100644 --- a/.github/workflows/windows_release.yml +++ b/.github/workflows/windows_release.yml @@ -37,10 +37,26 @@ jobs: python -m pip install --upgrade pip python -m pip install "conan>=2,<3" conan --version - # Fresh runners have no default profile; host==build for MSVC. - if (-not (Test-Path "$env:USERPROFILE\.conan2\profiles\default")) { - conan profile detect --force - } + # Fresh runners: detect MSVC (windows-latest is currently 195 / VS 18). + conan profile detect --force + $default = Join-Path $env:USERPROFILE ".conan2\profiles\default" + $verLine = Select-String -Path $default -Pattern 'compiler.version=' | Select-Object -First 1 + $msvcVer = ($verLine.Line -split '=')[1].Trim() + if (-not $msvcVer) { throw "could not read compiler.version from default profile" } + # Host profile matching the runner (repo win-x86_64 still pins 194 for local Tower). + $p = Join-Path $env:USERPROFILE ".conan2\profiles\win-ci" + @" + [settings] + arch=x86_64 + build_type=Release + compiler=msvc + compiler.cppstd=23 + compiler.runtime=dynamic + compiler.version=$msvcVer + os=Windows + "@.Trim() | Set-Content -Path $p -Encoding ascii + Write-Host "win-ci MSVC version=$msvcVer" + Get-Content $p - name: Resolve version id: ver @@ -61,7 +77,9 @@ jobs: - name: Build Windows x86_64 shell: cmd run: | - call windowsinstall\conan_init_x86_64.bat + call .\conan\export_libs.bat + if errorlevel 1 exit /b 1 + conan install . -of=build-x86_64 --build=missing -pr:h=win-ci -pr:b=default if errorlevel 1 exit /b 1 call windowsinstall\build_x86_64.bat if errorlevel 1 exit /b 1 diff --git a/docs/windows-runner.md b/docs/windows-runner.md index b0d7bbe..3e6e551 100644 --- a/docs/windows-runner.md +++ b/docs/windows-runner.md @@ -13,10 +13,14 @@ File: `.github/workflows/windows_release.yml` | | | |---|---| | Trigger | every push to `main`, plus `workflow_dispatch` | -| Runner | `windows-latest` (GitHub-hosted) | -| Build | `windowsinstall/conan_init_x86_64.bat` + `build_x86_64.bat` | +| Runner | `windows-latest` (GitHub-hosted, MSVC ~195) | +| Build | Conan profile `win-ci` (detected) + `windowsinstall/build_x86_64.bat` | | Output | prerelease tag **`windows-continuous`** with a portable zip | +Local Tower Windows can keep using `windowsinstall/conan_init_x86_64.bat` +(`conan/profiles/win-x86_64`, MSVC 194). CI generates a `win-ci` profile for +whatever MSVC `windows-latest` ships. + ## GitHub remote Recommended remote name: `github` diff --git a/linuxinstall/install-local.sh b/linuxinstall/install-local.sh new file mode 100644 index 0000000..36f51ac --- /dev/null +++ b/linuxinstall/install-local.sh @@ -0,0 +1,30 @@ +#!/usr/bin/env bash +# Install a built InfiniPaint binary from this repo into ~/.local +set -euo pipefail +ROOT="$(cd "$(dirname "$0")/.." && pwd)" +BIN="${1:-$ROOT/build/Release/infinipaint}" +PREFIX="${HOME}/.local" +APPDIR="${PREFIX}/share/infinipaint" + +[[ -x "$BIN" ]] || { echo "missing binary: $BIN" >&2; exit 1; } + +mkdir -p "$APPDIR" "${PREFIX}/bin" "${PREFIX}/share/applications" +install -m755 "$BIN" "${APPDIR}/infinipaint" +rm -rf "${APPDIR}/data" +cp -a "${ROOT}/assets/data" "${APPDIR}/data" +ln -sfn "${APPDIR}/infinipaint" "${PREFIX}/bin/infinipaint" + +cat > "${PREFIX}/share/applications/com.infinipaint.infinipaint-fork.desktop" </dev/null 2>&1 || true