build(steam): stage steam_api64.dll beside the exe — one file, not the whole SDK
The SDK zip is 24 MB of headers, examples and tools we never build. The runtime dependency is one native library, so scripts/steam-sdk.sh extracts exactly sdk/redistributable_bin/win64/steam_api64.dll into steam/ (gitignored, like ffmpeg/ — the script is the audit trail) and writes steam_appid.txt = 480, Valve's Spacewar app, so SteamAPI.Init() resolves an app id locally before LlamaCasty has one of its own. Two csproj details that would have cost a debugging session: - Link="steam_api64.dll" puts it BESIDE the exe; without Link, None items keep their relative path and it lands in steam/, where the loader does not look. - ExcludeFromSingleFile, for the same reason ffmpeg needed it: a native DLL otherwise gets swallowed into the single-file bundle and cannot be loaded at runtime. steam_appid.txt is Debug-only — Valve's guidance is not to ship it — and the publish output confirms it: dll present at the root, no appid file, exe still 127 MB (proof the DLL was not bundled). Also queued, as asked: preview undo (Ctrl+Z / Ctrl+Shift+Z) in edit mode, noted as the partner to the defaults-vs-current split — undo covers the slip, defaults cover the mess.
This commit is contained in:
@@ -100,6 +100,21 @@
|
||||
<Compile Remove="Controls\DeveloperPanel.xaml.cs" />
|
||||
</ItemGroup>
|
||||
|
||||
<!-- Steamworks runtime (scripts/steam-sdk.sh extracts it; steam/ is gitignored).
|
||||
⛔ Link puts it BESIDE the exe rather than under steam/, because the loader looks there.
|
||||
⛔ ExcludeFromSingleFile matters for the same reason as ffmpeg: a native DLL otherwise
|
||||
gets swallowed into the single-file bundle and the app cannot load it at runtime. -->
|
||||
<ItemGroup>
|
||||
<None Remove="steam\**" />
|
||||
<None Include="steam\steam_api64.dll" Link="steam_api64.dll"
|
||||
CopyToOutputDirectory="PreserveNewest" CopyToPublishDirectory="Always"
|
||||
ExcludeFromSingleFile="true" />
|
||||
<!-- Local-only: lets SteamAPI.Init() resolve an app id outside the Steam client (480 =
|
||||
Valve's Spacewar test app). Never published — Valve's guidance is to omit it. -->
|
||||
<None Include="steam\steam_appid.txt" Link="steam_appid.txt" Condition="'$(Configuration)' == 'Debug'"
|
||||
CopyToOutputDirectory="PreserveNewest" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Include="THIRD-PARTY-NOTICES.txt" CopyToOutputDirectory="PreserveNewest" />
|
||||
<!-- The EULA and privacy policy travel with every copy: they are what the About screen and
|
||||
|
||||
Reference in New Issue
Block a user