From 52e339e0f6b49373cd8515d8900b75df12c6f1b3 Mon Sep 17 00:00:00 2001 From: Matthew Parsons Date: Sun, 14 Sep 2025 16:32:36 -0700 Subject: [PATCH 1/4] More robust pathing, and UTF8. --- bin/git_version.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/git_version.ps1 b/bin/git_version.ps1 index 63f5bce51..933c38bbe 100644 --- a/bin/git_version.ps1 +++ b/bin/git_version.ps1 @@ -1 +1 @@ -'#define GIT_VERSION "{0}"' -f (git describe --always --dirty) | Out-File -FilePath .\src\util\GitVersion.h \ No newline at end of file +'#define GIT_VERSION "{0}"' -f (git describe --always --dirty) | Out-File -FilePath "$PSScriptRoot..\src\util\GitVersion.h" -Encoding utf8 \ No newline at end of file From bcd41c59bf476fa9120300f805fe7199ad44dae8 Mon Sep 17 00:00:00 2001 From: Matthew Parsons Date: Sun, 14 Sep 2025 16:32:36 -0700 Subject: [PATCH 2/4] More robust pathing, and UTF8. --- bin/git_version.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/git_version.ps1 b/bin/git_version.ps1 index 63f5bce51..318d2fd84 100644 --- a/bin/git_version.ps1 +++ b/bin/git_version.ps1 @@ -1 +1 @@ -'#define GIT_VERSION "{0}"' -f (git describe --always --dirty) | Out-File -FilePath .\src\util\GitVersion.h \ No newline at end of file +'#define GIT_VERSION "{0}"' -f (git describe --always --dirty) | Out-File -FilePath "$PSScriptRoot\..\src\util\GitVersion.h" -Encoding utf8 From 8a9a8fb0f8ac02f3989717688b73a8cf255e9c75 Mon Sep 17 00:00:00 2001 From: Matthew Parsons Date: Thu, 2 Oct 2025 00:37:49 -0700 Subject: [PATCH 3/4] Add GitVersion script call to Pre-Build Event for Avara Proj. --- Avara.msvc/Avara.vcxproj | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/Avara.msvc/Avara.vcxproj b/Avara.msvc/Avara.vcxproj index 65cd22e91..bda4ee4c1 100644 --- a/Avara.msvc/Avara.vcxproj +++ b/Avara.msvc/Avara.vcxproj @@ -73,9 +73,17 @@ $(VC_LibraryPath_x64);$(WindowsSDK_LibraryPath_x64);$(VCPKG_ROOT)\installed\x64-windows\debug\lib\manual-link + true $(VC_LibraryPath_x64);$(WindowsSDK_LibraryPath_x64);$(VCPKG_ROOT)\installed\x64-windows\lib\manual-link + true + + + true + + + true true @@ -91,6 +99,12 @@ Console true + + powershell.exe -ExecutionPolicy Bypass -nologo -NoProfile -NonInteractive -File $(SolutionDir)..\bin\git_version.ps1 + + + Specify Git commit for ersatz version tracking. + @@ -107,6 +121,12 @@ true true + + powershell.exe -ExecutionPolicy Bypass -nologo -NoProfile -NonInteractive -File $(SolutionDir)..\bin\git_version.ps1 + + + Specify Git commit for ersatz version tracking. + @@ -126,8 +146,8 @@ SDL2maind.lib;shell32.lib;$(CoreLibraryDependencies);%(AdditionalDependencies) - - + powershell.exe -ExecutionPolicy Bypass -nologo -NoProfile -NonInteractive -File $(SolutionDir)..\bin\git_version.ps1 + Specify Git commit for ersatz version tracking. xcopy /E /Y "$(SolutionDir)..\rsrc\" "$(TargetDir)rsrc\" && xcopy /E /Y "$(SolutionDir)..\levels\" "$(TargetDir)levels\" @@ -156,6 +176,10 @@ xcopy /E /Y "$(SolutionDir)..\rsrc\" "$(TargetDir)rsrc\" && xcopy /E /Y "$(SolutionDir)..\levels\" "$(TargetDir)levels\" + + powershell.exe -ExecutionPolicy Bypass -nologo -NoProfile -NonInteractive -File $(SolutionDir)..\bin\git_version.ps1 + Specify Git commit for ersatz version tracking. + From 6257db68161207c66579beece8ebf745b5a2e2e4 Mon Sep 17 00:00:00 2001 From: Matthew Parsons Date: Fri, 3 Oct 2025 12:02:55 -0700 Subject: [PATCH 4/4] Move pre-build task to AvaraCore. --- Avara.msvc/Avara.vcxproj | 36 ++++++++++++++++++++++++------------ Avara.msvc/AvaraCore.vcxproj | 16 ++++++++++++++-- 2 files changed, 38 insertions(+), 14 deletions(-) diff --git a/Avara.msvc/Avara.vcxproj b/Avara.msvc/Avara.vcxproj index bda4ee4c1..b022293dc 100644 --- a/Avara.msvc/Avara.vcxproj +++ b/Avara.msvc/Avara.vcxproj @@ -73,17 +73,21 @@ $(VC_LibraryPath_x64);$(WindowsSDK_LibraryPath_x64);$(VCPKG_ROOT)\installed\x64-windows\debug\lib\manual-link - true + + $(VC_LibraryPath_x64);$(WindowsSDK_LibraryPath_x64);$(VCPKG_ROOT)\installed\x64-windows\lib\manual-link - true + + - true + + - true + + true @@ -100,10 +104,12 @@ true - powershell.exe -ExecutionPolicy Bypass -nologo -NoProfile -NonInteractive -File $(SolutionDir)..\bin\git_version.ps1 + + - Specify Git commit for ersatz version tracking. + + @@ -122,10 +128,12 @@ true - powershell.exe -ExecutionPolicy Bypass -nologo -NoProfile -NonInteractive -File $(SolutionDir)..\bin\git_version.ps1 + + - Specify Git commit for ersatz version tracking. + + @@ -146,8 +154,10 @@ SDL2maind.lib;shell32.lib;$(CoreLibraryDependencies);%(AdditionalDependencies) - powershell.exe -ExecutionPolicy Bypass -nologo -NoProfile -NonInteractive -File $(SolutionDir)..\bin\git_version.ps1 - Specify Git commit for ersatz version tracking. + + + + xcopy /E /Y "$(SolutionDir)..\rsrc\" "$(TargetDir)rsrc\" && xcopy /E /Y "$(SolutionDir)..\levels\" "$(TargetDir)levels\" @@ -177,8 +187,10 @@ xcopy /E /Y "$(SolutionDir)..\rsrc\" "$(TargetDir)rsrc\" && xcopy /E /Y "$(SolutionDir)..\levels\" "$(TargetDir)levels\" - powershell.exe -ExecutionPolicy Bypass -nologo -NoProfile -NonInteractive -File $(SolutionDir)..\bin\git_version.ps1 - Specify Git commit for ersatz version tracking. + + + + diff --git a/Avara.msvc/AvaraCore.vcxproj b/Avara.msvc/AvaraCore.vcxproj index 7d37fbb11..41b1a85a9 100644 --- a/Avara.msvc/AvaraCore.vcxproj +++ b/Avara.msvc/AvaraCore.vcxproj @@ -91,6 +91,10 @@ Console true + + powershell.exe -ExecutionPolicy Bypass -nologo -NoProfile -NonInteractive -File $(SolutionDir)..\bin\git_version.ps1 + Specify Git commit for ersatz version tracking. + @@ -107,6 +111,10 @@ true true + + powershell.exe -ExecutionPolicy Bypass -nologo -NoProfile -NonInteractive -File $(SolutionDir)..\bin\git_version.ps1 + Specify Git commit for ersatz version tracking. + @@ -125,8 +133,8 @@ shell32.lib;$(CoreLibraryDependencies);%(AdditionalDependencies) - - + powershell.exe -ExecutionPolicy Bypass -nologo -NoProfile -NonInteractive -File $(SolutionDir)..\bin\git_version.ps1 + Specify Git commit for ersatz version tracking. xcopy /E /Y "$(SolutionDir)..\rsrc\" "$(TargetDir)rsrc\" && xcopy /E /Y "$(SolutionDir)..\levels\" "$(TargetDir)levels\" @@ -152,6 +160,10 @@ true $(CoreLibraryDependencies);%(AdditionalDependencies) + + powershell.exe -ExecutionPolicy Bypass -nologo -NoProfile -NonInteractive -File $(SolutionDir)..\bin\git_version.ps1 + Specify Git commit for ersatz version tracking. +