Skip to content

ReStreet: FIFA Street (2012) recompiled for Windows PC, with online play, a launcher with friends, chat and rooms. Bring your own game.

Build installer with archived validated SDK and compiler dependencies

SamuelitoDaVila16349ea19c47
diff --git a/Installer/BuildSetup.ps1 b/Installer/BuildSetup.ps1
index c48137b..b9d7c14 100644
--- a/Installer/BuildSetup.ps1
+++ b/Installer/BuildSetup.ps1
@@ -28,7 +28,7 @@ New-Item -ItemType Directory -Path (Join-Path $stage 'tools') | Out-Null
Copy-Item -LiteralPath (Join-Path $root 'tools\extract-xiso.exe') -Destination (Join-Path $stage 'tools')
New-Item -ItemType Directory -Path (Join-Path $stage 'payload\Game') -Force | Out-Null
Copy-Item -LiteralPath (Join-Path $root 'payload\Game\fifastreet.toml') -Destination (Join-Path $stage 'payload\Game')
-dotnet publish (Join-Path $projectRoot 'Launcher\FifaStreetLauncher\FifaStreetLauncher.csproj') -c Release -r win-x64 --self-contained true -p:PublishSingleFile=true -p:IncludeNativeLibrariesForSelfExtract=true -o (Join-Path $stage 'payload')
+dotnet publish (Join-Path $projectRoot 'Launcher\FifaStreetLauncher\FifaStreetLauncher.csproj') -c Release -r win-x64 --self-contained true -p:PublishSingleFile=true -p:IncludeNativeLibrariesForSelfExtract=true -p:RuntimeFrameworkVersion=8.0.31 -o (Join-Path $stage 'payload')
if ($LASTEXITCODE -ne 0) { throw 'Falha ao publicar o launcher.' }
Get-ChildItem -LiteralPath (Join-Path $stage 'payload') -Filter '*.pdb' | Remove-Item
@@ -125,7 +125,7 @@ $bundle = Join-Path $root 'FifaStreetSetupTool\bundle.zip'
if (Test-Path -LiteralPath $bundle) { Remove-Item -LiteralPath $bundle }
[IO.Compression.ZipFile]::CreateFromDirectory($stage, $bundle, [IO.Compression.CompressionLevel]::Optimal, $false)
$publish = Join-Path $stage 'published'
-dotnet publish (Join-Path $root 'FifaStreetSetupTool\FifaStreetSetupTool.csproj') -c Release -r win-x64 --self-contained true -p:PublishSingleFile=true -p:IncludeNativeLibrariesForSelfExtract=true -o $publish
+dotnet publish (Join-Path $root 'FifaStreetSetupTool\FifaStreetSetupTool.csproj') -c Release -r win-x64 --self-contained true -p:PublishSingleFile=true -p:IncludeNativeLibrariesForSelfExtract=true -p:RuntimeFrameworkVersion=8.0.31 -o $publish
if ($LASTEXITCODE -ne 0) { throw 'Falha ao publicar instalador.' }
$Output = [IO.Path]::GetFullPath($Output)
New-Item -ItemType Directory -Path (Split-Path $Output -Parent) -Force | Out-Null
diff --git a/ci/build-installer.ps1 b/ci/build-installer.ps1
index cdf2ff6..aceed21 100644
--- a/ci/build-installer.ps1
+++ b/ci/build-installer.ps1
@@ -1,129 +1,40 @@
$ErrorActionPreference = 'Stop'
$PSNativeCommandUseErrorActionPreference = $true
-$env:RUNNER_TEMP = $env:TEMP
-$vswhere = "${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe"
-$vs = & $vswhere -latest -products * -requires Microsoft.VisualStudio.Component.VC.Tools.x86.x64 -property installationPath
-if (-not $vs) { throw 'Visual Studio C++ build tools are required.' }
-& (Join-Path $vs 'Common7\Tools\Launch-VsDevShell.ps1') -Arch amd64 -HostArch amd64
-$env:PATH = "C:\Program Files\LLVM\bin;C:\Program Files\CMake\bin;$env:PATH"
-$ErrorActionPreference = 'Stop'
-if (-not (Get-Command cmake.exe -ErrorAction SilentlyContinue)) {
- choco install cmake --installargs 'ADD_CMAKE_TO_PATH=System' -y
-}
-if (-not (Get-Command ninja.exe -ErrorAction SilentlyContinue)) {
- choco install ninja -y
-}
-if (-not (Test-Path 'C:\Program Files\LLVM\bin\clang.exe')) {
- choco install llvm -y
-}
-cmake --version
-ninja --version
-& 'C:\Program Files\LLVM\bin\clang.exe' --version
-dotnet --info
-
-
-$ErrorActionPreference = 'Stop'
-git -c core.autocrlf=false clone --recursive https://github.com/rexglue/rexglue-sdk.git ReXGlue
-if ($LASTEXITCODE -ne 0) { throw 'ReXGlue clone failed.' }
-git -C ReXGlue config core.autocrlf false
-if ($LASTEXITCODE -ne 0) { throw 'Unable to configure ReXGlue line endings.' }
-git -C ReXGlue checkout c94f5ebdcb3c9d1a460ca48e04f9758448f8d518
-if ($LASTEXITCODE -ne 0) { throw 'Pinned ReXGlue checkout failed.' }
-git -C ReXGlue -c core.autocrlf=false submodule update --init --recursive
-if ($LASTEXITCODE -ne 0) { throw 'ReXGlue submodule update failed.' }
-# The project checkout can convert the patch itself to CRLF on Windows.
-$patch = Join-Path $PWD 'patches/rexglue-local-changes.patch'
-$patchText = [System.IO.File]::ReadAllText($patch).Replace("`r`n", "`n")
-[System.IO.File]::WriteAllText($patch, $patchText, [System.Text.UTF8Encoding]::new($false))
-git -C ReXGlue apply --check ../patches/rexglue-local-changes.patch
-if ($LASTEXITCODE -ne 0) { throw 'ReXGlue patch validation failed.' }
-git -C ReXGlue apply ../patches/rexglue-local-changes.patch
-if ($LASTEXITCODE -ne 0) { throw 'ReXGlue patch application failed.' }
-
-
-$ErrorActionPreference = 'Stop'
-cmake -S ReXGlue --preset win-amd64
-cmake --build ReXGlue/out/build/win-amd64 --config Release --parallel 2
-cmake --install ReXGlue/out/build/win-amd64 --config Release
-
-
-$ErrorActionPreference = 'Stop'
-$out = (Resolve-Path '.').Path.Replace('\','/')
-
-cmake -S ReXGlue -B ReXGlue/out/build/win-amd64-vulkan -G "Ninja Multi-Config" `
- -DCMAKE_C_COMPILER=clang `
- -DCMAKE_CXX_COMPILER=clang++ `
- "-DCMAKE_C_FLAGS=-mssse3" `
- "-DCMAKE_CXX_FLAGS=-mssse3" `
- -DREXGLUE_USE_VULKAN=ON `
- -DREXGLUE_USE_D3D12=OFF `
- -DREXGLUE_BUILD_TESTS=OFF `
- -DREXGLUE_ENABLE_PERF_COUNTERS=ON `
- "-DREXGLUE_OUTPUT_DIRECTORY=$out/ReXGlue/out/win-amd64-vulkan"
-
-cmake --build ReXGlue/out/build/win-amd64-vulkan --config Release --parallel 2
-
-
-$ErrorActionPreference = 'Stop'
-$out = (Resolve-Path '.').Path.Replace('\','/')
-
-cmake -S ReXGlue -B ReXGlue/out/build/win-amd64-d3d12 -G "Ninja Multi-Config" `
- -DCMAKE_C_COMPILER=clang `
- -DCMAKE_CXX_COMPILER=clang++ `
- "-DCMAKE_C_FLAGS=-mssse3" `
- "-DCMAKE_CXX_FLAGS=-mssse3" `
- -DREXGLUE_USE_VULKAN=OFF `
- -DREXGLUE_USE_D3D12=ON `
- -DREXGLUE_BUILD_TESTS=OFF `
- -DREXGLUE_ENABLE_PERF_COUNTERS=ON `
- "-DREXGLUE_OUTPUT_DIRECTORY=$out/ReXGlue/out/win-amd64-d3d12"
-
-cmake --build ReXGlue/out/build/win-amd64-d3d12 --config Release --parallel 2
-
-
-$ErrorActionPreference = 'Stop'
-New-Item -ItemType Directory -Force -Path Installer/tools | Out-Null
-$zip = Join-Path $env:RUNNER_TEMP 'extract-xiso.zip'
-$dir = Join-Path $env:RUNNER_TEMP 'extract-xiso'
-Invoke-WebRequest `
- -Uri 'https://github.com/XboxDev/extract-xiso/releases/download/build-202609111233/extract-xiso-Win64_Release.zip' `
- -OutFile $zip
-Expand-Archive -LiteralPath $zip -DestinationPath $dir -Force
-$exe = Get-ChildItem -LiteralPath $dir -Recurse -Filter 'extract-xiso.exe' | Select-Object -First 1
-if (-not $exe) { throw 'extract-xiso.exe was not found in the downloaded archive.' }
-Copy-Item -LiteralPath $exe.FullName -Destination 'Installer/tools/extract-xiso.exe' -Force
-
-
-# Package the exact validated runtime pairs from the migrated release.
+$inputs = Join-Path $PWD '.ci-inputs'
+New-Item -ItemType Directory -Force -Path $inputs | Out-Null
+$archive = Join-Path $inputs 'inputs.zip'
+$url = "$env:CI_API_V4_URL/projects/$env:CI_PROJECT_ID/packages/generic/validated-build-inputs/v0.3.0/inputs.zip"
+Invoke-WebRequest -Uri $url -Headers @{ 'JOB-TOKEN' = $env:CI_JOB_TOKEN } -OutFile $archive
+$expected = 'f754c863c879008d3e31b8cb83b3f4070ec65455ea8a718b2625b2f195507b83'
+if ((Get-FileHash -LiteralPath $archive -Algorithm SHA256).Hash.ToLower() -ne $expected) { throw 'Validated build input checksum mismatch.' }
+Expand-Archive -LiteralPath $archive -DestinationPath $inputs
+# Restore the unchanged public SDK and toolchain; no game code or data is included.
+New-Item -ItemType Directory -Force -Path ReXGlue/out/install, ReXGlue/out/win-amd64, ReXGlue/include, ReXGlue/thirdparty, Installer/tools | Out-Null
+Copy-Item -LiteralPath (Join-Path $inputs 'sdk') -Destination ReXGlue/out/install/win-amd64 -Recurse
+Copy-Item -Path (Join-Path $inputs 'sdk/bin/*') -Destination ReXGlue/out/win-amd64
+Copy-Item -Path (Join-Path $inputs 'sdk/lib/*.lib') -Destination ReXGlue/out/win-amd64
+Copy-Item -LiteralPath (Join-Path $inputs 'sdk/include/rex') -Destination ReXGlue/include -Recurse
+Copy-Item -LiteralPath (Join-Path $inputs 'licenses/ReXGlue.txt') -Destination ReXGlue/LICENSE
+Copy-Item -Path (Join-Path $inputs 'licenses/ReXGlue-thirdparty/*') -Destination ReXGlue/thirdparty -Recurse
+Copy-Item -LiteralPath (Join-Path $inputs 'tools/extract-xiso.exe') -Destination Installer/tools/extract-xiso.exe
foreach ($backend in @('D3D12', 'Vulkan')) {
$directory = Join-Path $PWD "ReXGlue/out/win-amd64-$($backend.ToLower())/Release"
- foreach ($file in @('rexruntime.dll', 'rexgpu-xenos.dll')) {
- $url = "$env:CI_API_V4_URL/projects/$env:CI_PROJECT_ID/packages/generic/validated-backends/v0.3.0/$backend-$file"
- Invoke-WebRequest -Uri $url -Headers @{ 'JOB-TOKEN' = $env:CI_JOB_TOKEN } -OutFile (Join-Path $directory $file)
- }
+ New-Item -ItemType Directory -Force -Path $directory | Out-Null
+ Copy-Item -Path (Join-Path $inputs "sdk/backends/$backend/*") -Destination $directory
}
-$ErrorActionPreference = 'Stop'
-New-Item -ItemType Directory -Force -Path dist | Out-Null
-$clangRoot = 'C:\Program Files\LLVM\lib\clang'
-$clangVersion = (Get-ChildItem -LiteralPath $clangRoot -Directory |
- Sort-Object { [version]$_.Name } -Descending |
- Select-Object -First 1).Name
-if (-not $clangVersion) { throw 'Unable to determine the installed Clang resource version.' }
-$ninja = (Get-Command ninja.exe -ErrorAction Stop).Source
-./Installer/BuildSetup.ps1 `
- -Output "$PWD/dist/FifaStreet-Setup.exe" `
- -LLVMRoot 'C:\Program Files\LLVM' `
- -CMakeRoot 'C:\Program Files\CMake' `
- -NinjaPath $ninja `
- -ClangResourceVersion $clangVersion
-if (-not (Test-Path 'dist/FifaStreet-Setup.exe')) {
- throw 'FifaStreet-Setup.exe was not created.'
+foreach ($name in @('rexruntime.lib', 'rexgpu-xenos.lib')) {
+ Copy-Item -LiteralPath (Join-Path $inputs "sdk/lib/$name") -Destination ReXGlue/out/win-amd64-vulkan/Release
}
-Get-FileHash 'dist/FifaStreet-Setup.exe' -Algorithm SHA256 |
- ForEach-Object { "$($_.Hash.ToLower()) FifaStreet-Setup.exe" } |
- Set-Content -Encoding ascii 'dist/FifaStreet-Setup.exe.sha256'
-
-
+$compiler = Join-Path $inputs 'compiler'
+New-Item -ItemType Directory -Force -Path (Join-Path $compiler 'doc/cmake') | Out-Null
+Copy-Item -LiteralPath (Join-Path $inputs 'licenses/CMake.rst') -Destination (Join-Path $compiler 'doc/cmake/LICENSE.rst')
+$env:PATH = "$(Join-Path $compiler 'bin');$env:PATH"
+New-Item -ItemType Directory -Force -Path dist | Out-Null
+./Installer/BuildSetup.ps1 -Output "$PWD/dist/FifaStreet-Setup.exe" -LLVMRoot $compiler -CMakeRoot $compiler -NinjaPath (Join-Path $compiler 'bin/ninja.exe') -ClangResourceVersion '23'
+if (-not (Test-Path -LiteralPath 'dist/FifaStreet-Setup.exe')) { throw 'Installer was not created.' }
+Get-FileHash -LiteralPath 'dist/FifaStreet-Setup.exe' -Algorithm SHA256 |
+ ForEach-Object { "$($_.Hash.ToLower()) FifaStreet-Setup.exe" } |
+ Set-Content -Encoding ascii 'dist/FifaStreet-Setup.exe.sha256'
$packageUrl = "$env:CI_API_V4_URL/projects/$env:CI_PROJECT_ID/packages/generic/installer-builds/$env:CI_COMMIT_SHA"
foreach ($file in @('FifaStreet-Setup.exe', 'FifaStreet-Setup.exe.sha256')) {
Invoke-RestMethod -Method Put -Uri "$packageUrl/$file" -Headers @{ 'JOB-TOKEN' = $env:CI_JOB_TOKEN } -InFile (Join-Path $PWD "dist/$file") -ContentType 'application/octet-stream' | Out-Null
diff --git a/docs/GITLAB.md b/docs/GITLAB.md
index 619973a..1c26f33 100644
--- a/docs/GITLAB.md
+++ b/docs/GITLAB.md
@@ -4,7 +4,7 @@ The repository, commit history, backup branch and experimental version tags have
The GitLab pipeline checks PowerShell syntax on each commit. The Windows installer build is manual: open **Build > Pipelines** and start `build-installer`. It requires available GitLab Windows runner capacity and CI minutes. Installers and checksums are uploaded to the generic package registry under `installer-builds`, identified by commit hash. The small checksum artifact is also retained for 30 days. New builds do not replace the historical release automatically.
-The build uses the recorded ReXGlue revision and project patch in an isolated CI checkout. It retains the exact validated v0.3.0 graphics DLL pairs and their existing hash checks, downloading them from the project's `validated-backends` generic package. Upstream SDK and tool downloads still use their original GitHub locations.
+The installer build compiles the launcher and installer from current source. It reuses the exact public SDK, graphics DLLs and compiler toolchain embedded in the validated v0.3.0 installer, downloading the dependency archive from the project's `validated-build-inputs` generic package and checking its SHA-256 before extraction. Existing backend hash checks remain enabled. It does not rebuild ReXGlue or revalidate gameplay. Developers rebuilding the SDK should follow `BUILDING.md` and regenerate the validated dependency archive only after testing.
Packaging uses the cover images tracked in the repository and accepts explicit LLVM, CMake, Ninja and Clang resource paths. It no longer depends on Samuel's local game directory or Miniconda installation.