Add Generated Files filter and custom build commands in YAZE.vcxproj

- Introduced a new filter for "Generated Files" to organize generated headers and configuration files.
- Added custom build commands to generate the yaze_config.h file with versioning information for different build configurations (Debug and Release) across multiple platforms (Win32, x64, ARM64).
- Removed an unused header file from the project structure to streamline the codebase.
This commit is contained in:
scawful
2025-09-28 14:41:09 -04:00
parent c2ffbab1bd
commit 8f661eab18

View File

@@ -341,6 +341,9 @@
<Filter Include="Assets\Lib">
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD34}</UniqueIdentifier>
</Filter>
<Filter Include="Generated Files">
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD35}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
<ClInclude Include="incl\yaze.h">
@@ -349,6 +352,9 @@
<ClInclude Include="incl\zelda.h">
<Filter>Public Headers</Filter>
</ClInclude>
<ClInclude Include="build\yaze_config.h">
<Filter>Generated Files</Filter>
</ClInclude>
<ClInclude Include="src\app\rom.h">
<Filter>App</Filter>
</ClInclude>
@@ -505,9 +511,6 @@
<ClInclude Include="src\app\editor\system\shortcut_manager.h">
<Filter>App\Editor\System</Filter>
</ClInclude>
<ClInclude Include="src\app\editor\system\system_editor.h">
<Filter>App\Editor\System</Filter>
</ClInclude>
<ClInclude Include="src\app\editor\system\toast_manager.h">
<Filter>App\Editor\System</Filter>
</ClInclude>
@@ -1011,6 +1014,27 @@
<Filter>Resource Files</Filter>
</None>
</ItemGroup>
<ItemGroup>
<CustomBuild Include="src\yaze_config.h.in">
<Filter>Generated Files</Filter>
</CustomBuild>
</ItemGroup>
<ItemDefinitionGroup>
<CustomBuild>
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">echo #define YAZE_VERSION_MAJOR 0 > "$(ProjectDir)build\yaze_config.h" &amp; echo #define YAZE_VERSION_MINOR 3 >> "$(ProjectDir)build\yaze_config.h" &amp; echo #define YAZE_VERSION_PATCH 1 >> "$(ProjectDir)build\yaze_config.h"</Command>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(ProjectDir)build\yaze_config.h</Outputs>
<Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">echo #define YAZE_VERSION_MAJOR 0 > "$(ProjectDir)build\yaze_config.h" &amp; echo #define YAZE_VERSION_MINOR 3 >> "$(ProjectDir)build\yaze_config.h" &amp; echo #define YAZE_VERSION_PATCH 1 >> "$(ProjectDir)build\yaze_config.h"</Command>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(ProjectDir)build\yaze_config.h</Outputs>
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">echo #define YAZE_VERSION_MAJOR 0 > "$(ProjectDir)build\yaze_config.h" &amp; echo #define YAZE_VERSION_MINOR 3 >> "$(ProjectDir)build\yaze_config.h" &amp; echo #define YAZE_VERSION_PATCH 1 >> "$(ProjectDir)build\yaze_config.h"</Command>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(ProjectDir)build\yaze_config.h</Outputs>
<Command Condition="'$(Configuration)|$(Platform)'=='Release|x64'">echo #define YAZE_VERSION_MAJOR 0 > "$(ProjectDir)build\yaze_config.h" &amp; echo #define YAZE_VERSION_MINOR 3 >> "$(ProjectDir)build\yaze_config.h" &amp; echo #define YAZE_VERSION_PATCH 1 >> "$(ProjectDir)build\yaze_config.h"</Command>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(ProjectDir)build\yaze_config.h</Outputs>
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">echo #define YAZE_VERSION_MAJOR 0 > "$(ProjectDir)build\yaze_config.h" &amp; echo #define YAZE_VERSION_MINOR 3 >> "$(ProjectDir)build\yaze_config.h" &amp; echo #define YAZE_VERSION_PATCH 1 >> "$(ProjectDir)build\yaze_config.h"</Command>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">$(ProjectDir)build\yaze_config.h</Outputs>
<Command Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">echo #define YAZE_VERSION_MAJOR 0 > "$(ProjectDir)build\yaze_config.h" &amp; echo #define YAZE_VERSION_MINOR 3 >> "$(ProjectDir)build\yaze_config.h" &amp; echo #define YAZE_VERSION_PATCH 1 >> "$(ProjectDir)build\yaze_config.h"</Command>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">$(ProjectDir)build\yaze_config.h</Outputs>
</CustomBuild>
</ItemDefinitionGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>