Skip to content

Commit

Permalink
proper import of nmake.substitution.props
Browse files Browse the repository at this point in the history
  • Loading branch information
van800 committed Mar 5, 2025
1 parent 0b6c576 commit 20fb9c8
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 24 deletions.
26 changes: 26 additions & 0 deletions misc/msvs/nmake.substitution.props
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
<?xml version="1.0" encoding="utf-8"?>
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<!-- NMake is Windows only, so we need to wrap everything useful for non-windows msbuild -->
<PropertyGroup>
<LocalDebuggerCommand Condition="'$(LocalDebuggerCommand)' == ''">$(NMakeOutput)</LocalDebuggerCommand>
<DefaultPlatformToolset>$(PlatformToolset)</DefaultPlatformToolset>
</PropertyGroup>

<Target Name="Build">
<Exec Command="$(NMakeBuildCommandLine)"/>
</Target>
<Target Name="Rebuild">
<Exec Command="$(NMakeReBuildCommandLine)"/>
</Target>
<Target Name="Clean">
<Exec Command="$(NMakeCleanCommandLine)"/>
</Target>

<ItemDefinitionGroup>
<ClCompile>
<PreprocessorDefinitions>
$(NMakePreprocessorDefinitions)
</PreprocessorDefinitions>
</ClCompile>
</ItemDefinitionGroup>
</Project>
27 changes: 3 additions & 24 deletions misc/msvs/props.template
Original file line number Diff line number Diff line change
Expand Up @@ -11,38 +11,17 @@
<NMakeAssemblySearchPath>$(NMakeAssemblySearchPath)</NMakeAssemblySearchPath>
<NMakeForcedUsingAssemblies>$(NMakeForcedUsingAssemblies)</NMakeForcedUsingAssemblies>
<AdditionalOptions>%%OPTIONS%% $(AdditionalOptions)</AdditionalOptions>

<PlatformToolset>%%PlatformToolset%%</PlatformToolset>
<!-- NMake is Windows only, so we need to wrap everything useful for non-windows msbuild -->
<PropertyGroup Condition="'$(OS)' != 'Windows_NT'">
<LocalDebuggerCommand Condition="'$(LocalDebuggerCommand)' == ''">$(NMakeOutput)</LocalDebuggerCommand>
<DefaultPlatformToolset>$(PlatformToolset)</DefaultPlatformToolset>
</PropertyGroup>

<Target Name="Build" Condition="'$(OS)' != 'Windows_NT'">
<Exec Command="$(NMakeBuildCommandLine)"/>
</Target>
<Target Name="Rebuild" Condition="'$(OS)' != 'Windows_NT'">
<Exec Command="$(NMakeReBuildCommandLine)"/>
</Target>
<Target Name="Clean" Condition="'$(OS)' != 'Windows_NT'">
<Exec Command="$(NMakeCleanCommandLine)"/>
</Target>

<ItemDefinitionGroup Condition="'$(OS)' != 'Windows_NT'">
<ClCompile>
<PreprocessorDefinitions>
$(NMakePreprocessorDefinitions)
</PreprocessorDefinitions>
</ClCompile>
</ItemDefinitionGroup>
</PropertyGroup>
<PropertyGroup Condition="%%CONDITION%%">
%%PROPERTIES%%
</PropertyGroup>
<ItemGroup Condition="%%CONDITION%%">
%%EXTRA_ITEMS%%
</ItemGroup>

<!-- NMake is Windows only, so we need to wrap everything useful for non-windows msbuild -->
<Import Project="$(MSBuildProjectDirectory)/misc/msvs/nmake.substitution.props" Condition="'$(GodotConfiguration)|$(GodotPlatform)'=='%%VSCONF%%' And '$(OS)' != 'Windows_NT'" />
</Project>
<!-- CHECKSUM
%%HASH%%
Expand Down

0 comments on commit 20fb9c8

Please sign in to comment.