diff --git a/.github/workflows/graphix-native.yml b/.github/workflows/graphix-native.yml index 306b25ad127a7..7ed96b84cf695 100644 --- a/.github/workflows/graphix-native.yml +++ b/.github/workflows/graphix-native.yml @@ -7,7 +7,7 @@ on: package_version: description: New Graphix.Native prerelease version required: true - default: 3.4.16-graphix.1 + default: 3.4.16-graphix.3 type: string permissions: @@ -47,6 +47,8 @@ jobs: - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 with: persist-credentials: false + - name: Verify public package documentation + run: ./build-scripts/Test-GraphixReleaseDocumentation.ps1 -PackageVersion $env:PACKAGE_VERSION - name: Install Linux development dependencies if: runner.os == 'Linux' shell: bash diff --git a/GRAPHIX.md b/GRAPHIX.md index 4ca3a59c604d5..c7fc4b867942a 100644 --- a/GRAPHIX.md +++ b/GRAPHIX.md @@ -193,3 +193,25 @@ the full suite but passed focused, and a multisampled text/stroke rendering comparison differs by 47/255 with Graphix 3.4.16 while passing with SDL 3.4.14. These findings are being investigated separately, not attributed to this window fix or waived. These Graphix changes were prepared with AI assistance. + +## 2026-09-07: public NuGet distribution preparation + +Prepared the first public NuGet release as `Graphix.Native 3.4.16-graphix.3`, +with the separate managed binding `Graphix-CS 3.4.16.1`. The entry-point READMEs +now describe direct NuGet.org installation instead of requiring temporary +Actions artifacts. The package workflow remains build/test-only; publication +is a separate, explicitly authorized operation on the exact verified package. + +This release preparation changes documentation and packaging checks, not the +native implementation, headers or tests from `0c23f43af6884849165ebf21ba1d14fa2d6cdf51`. +The old package versions are not overwritten. Native builds are +repeated because runtime provenance records the new package version and the +release source commit. + +A permanent documentation check rejected the previous README for lacking the +public package URL and pinned installation command, then passed with the new +documentation. It runs before each CI native build and during direct package +assembly. Six matching-RID builds, all six CTest suites and both real Windows +maximum-size regression runs remain mandatory before publication. This entry +records release preparation, not a completed publication or new runtime test +results. These changes were prepared with AI assistance. diff --git a/README.md b/README.md index 43a2a0a897cf7..2795041f49467 100644 --- a/README.md +++ b/README.md @@ -33,11 +33,27 @@ contributions to Graphix. - Upstream history and tags are retained. Updates are deliberate and versioned, not automatic tracking of SDL's development branch. -Graphix adds a versioned native-only NuGet build recipe and an explicit -six-RID GitHub Actions workflow. The window-sizing defect remains unfixed. -No NuGet publication or complete cross-platform certification is claimed. +Graphix adds a versioned native-only NuGet build recipe, an explicit +six-RID GitHub Actions workflow and the Windows maximum-size correction. +Build and test evidence is scoped to the recorded scenarios, not a claim of +complete cross-platform or GPU certification. See [GRAPHIX.md](GRAPHIX.md) for the change record and verification status. +## Install the native runtime + +The public package feed is [NuGet.org](https://www.nuget.org/packages/Graphix.Native/3.4.16-graphix.3): + +```powershell +dotnet add package Graphix.Native --version 3.4.16-graphix.3 +``` + +This prerelease package contains Windows, Linux and macOS native assets for +x64 and ARM64. It provides no managed API. C# applications can use the separate +[Graphix-CS 3.4.16.1 binding](https://www.nuget.org/packages/Graphix-CS/3.4.16.1). +Do not combine Graphix.Native with another package supplying the same SDL3 +native libraries. Normal restore needs no GitHub authentication, Actions +artifact download or local package feed. + ## Building SDL's [installation guide](INSTALL.md) and [CMake guide](docs/README-cmake.md) @@ -49,6 +65,9 @@ For versioned native artifacts, use the The manually dispatched `Graphix native packages` workflow builds and tests Windows, Linux and macOS on x64 and ARM64, then assembles a NuGet artifact only if all six jobs pass. It does not publish packages or create GitHub releases. +Public NuGet publication is a separate, explicitly authorized step using the +exact verified artifact. CI artifact retention does not limit the public +package feed. Never replace the contents of an already-used package version. ## License and provenance diff --git a/build-scripts/Pack-GraphixNative.ps1 b/build-scripts/Pack-GraphixNative.ps1 index 36683e66b83c5..c8971295985de 100644 --- a/build-scripts/Pack-GraphixNative.ps1 +++ b/build-scripts/Pack-GraphixNative.ps1 @@ -9,6 +9,7 @@ param( $ErrorActionPreference = 'Stop' Set-StrictMode -Version Latest $graphixRoot = Split-Path -Parent $PSScriptRoot +& (Join-Path $PSScriptRoot 'Test-GraphixReleaseDocumentation.ps1') -PackageVersion $PackageVersion $nativeRoot = Join-Path $graphixRoot "out/graphix/$PackageVersion" $packageRoot = Join-Path $graphixRoot 'out/packages' $packagePath = Join-Path $packageRoot "Graphix.Native.$PackageVersion.nupkg" diff --git a/build-scripts/Test-GraphixReleaseDocumentation.ps1 b/build-scripts/Test-GraphixReleaseDocumentation.ps1 new file mode 100644 index 0000000000000..b348bc92a5c2e --- /dev/null +++ b/build-scripts/Test-GraphixReleaseDocumentation.ps1 @@ -0,0 +1,25 @@ +# Graphix release contract: both entry-point READMEs describe the public package. +[CmdletBinding()] +param( + [Parameter(Mandatory)] + [ValidatePattern('^3\.4\.16-graphix\.[1-9][0-9]*$')] + [string] $PackageVersion +) + +$ErrorActionPreference = 'Stop' +Set-StrictMode -Version Latest +$graphixRoot = Split-Path -Parent $PSScriptRoot +$packageUrl = "https://www.nuget.org/packages/Graphix.Native/$PackageVersion" +$installCommand = "dotnet add package Graphix.Native --version $PackageVersion" +foreach ($relativePath in @('README.md', 'packaging/Graphix.Native/README.md')) { + $readme = Get-Content -LiteralPath (Join-Path $graphixRoot $relativePath) -Raw + if (-not $readme.Contains($packageUrl, [StringComparison]::Ordinal) -or + -not $readme.Contains($installCommand, [StringComparison]::Ordinal)) { + throw "$relativePath must document public NuGet installation of Graphix.Native $PackageVersion." + } + if ($readme -match 'No NuGet publication|not an already published NuGet feed|Publication and the downstream feed remain separate decisions') { + throw "$relativePath still describes unpublished-only distribution." + } +} + +Write-Output "Public Graphix.Native $PackageVersion documentation contract passed." diff --git a/packaging/Graphix.Native/README.md b/packaging/Graphix.Native/README.md index f85bcc3b886c5..c9a0b27340767 100644 --- a/packaging/Graphix.Native/README.md +++ b/packaging/Graphix.Native/README.md @@ -5,23 +5,38 @@ Cerneala. SDL was originally authored by Sam Lantinga and developed by the SDL contributors. Graphix is not an official or endorsed SDL release. This package preserves SDL3's C API, ABI and native library filenames. The -`SDL3-CS` managed binding remains a separate dependency. Do not combine this +`Graphix-CS` managed binding remains a separate dependency. Do not combine this package with another package supplying the same native SDL3 libraries. The package contains Windows, Linux and macOS runtime assets for x64 and ARM64, under NuGet's `runtimes//native/` layout. It does not provide a managed API, SDL_shadercross or other SDL companion libraries. +## Installation + +Install [Graphix.Native 3.4.16-graphix.3 from NuGet.org](https://www.nuget.org/packages/Graphix.Native/3.4.16-graphix.3): + +```powershell +dotnet add package Graphix.Native --version 3.4.16-graphix.3 +``` + +This is a prerelease package. Its exact version can be restored directly; +package browsers may require their prerelease filter to show it. C# consumers +can use the separate [Graphix-CS 3.4.16.1](https://www.nuget.org/packages/Graphix-CS/3.4.16.1) +managed binding. Do not reference both Graphix-CS and SDL3-CS in one application. +Normal restore uses NuGet.org and does not require GitHub authentication, +temporary CI artifacts or a local package feed. + ## Building the package From the Graphix repository, build each RID on its matching operating system: ```powershell -./build-scripts/Build-GraphixNative.ps1 -RuntimeIdentifier win-x64 -PackageVersion 3.4.16-graphix.1 +./build-scripts/Build-GraphixNative.ps1 -RuntimeIdentifier win-x64 -PackageVersion 3.4.16-graphix.3 ``` Repeat for `win-arm64`, `linux-x64`, `linux-arm64`, `osx-x64` and `osx-arm64`, -collecting the outputs under `out/graphix/3.4.16-graphix.1//`. +collecting the outputs under `out/graphix/3.4.16-graphix.3//`. Linux builds require a matching-architecture runner. Windows ARM64 builds require the ARM64 MSVC tools. CMake and platform development dependencies are required; building alone does not run or certify the native tests. @@ -34,8 +49,10 @@ GPU behavior. The manual `Graphix native packages` workflow performs those build/test steps on six matching-architecture runners and packages only after all six pass. -Its outputs are GitHub Actions artifacts retained for 30 days, not a permanent -NuGet feed. Publication and the downstream feed remain separate decisions. +It also runs the real Windows-driver maximum-size regression on both Windows +architectures. Its GitHub Actions artifacts are retained for 30 days for build +verification. Public NuGet publication is a separate, explicitly authorized +step using the exact verified artifact, not a dependency on artifact retention. The initial recipe uses Ubuntu 24.04 for both Linux architectures and a macOS 12.0 deployment target for both macOS architectures, matching the prior @@ -46,14 +63,14 @@ These are build settings, not proof of runtime support on every older OS. After collecting all six builds of the same commit: ```powershell -./build-scripts/Pack-GraphixNative.ps1 -PackageVersion 3.4.16-graphix.1 +./build-scripts/Pack-GraphixNative.ps1 -PackageVersion 3.4.16-graphix.3 ``` -The pack script checks the complete RID set, source commit and binary hashes. +The pack script checks the public installation documentation, complete RID +set, source commit and binary hashes. It writes to `out/packages/` and refuses to overwrite an existing package of the same version. A changed native build requires a new package version. -These commands describe local packaging, not an already published NuGet feed. The original zlib license is retained as `LICENSE.txt`; the original SDL README is retained as `README-SDL.md`. Per-RID `provenance/` manifests record the source commit and native hashes. At runtime, `SDL_GetRevision()` includes the Graphix