Skip to content

Commit 08b9aca

Browse files
committed
fix scons not found on Windows
1 parent 372bab6 commit 08b9aca

File tree

1 file changed

+23
-1
lines changed

1 file changed

+23
-1
lines changed

gdext.vcxproj

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,17 @@
2020
<GodotTemplate>template_release</GodotTemplate>
2121
</PropertyGroup>
2222

23+
<ItemGroup Label="ProjectConfigurations">
24+
<ProjectConfiguration Include="Debug|x64">
25+
<Configuration>Debug</Configuration>
26+
<Platform>x64</Platform>
27+
</ProjectConfiguration>
28+
<ProjectConfiguration Include="Release|x64">
29+
<Configuration>Release</Configuration>
30+
<Platform>x64</Platform>
31+
</ProjectConfiguration>
32+
</ItemGroup>
33+
2334
<!-- Windows -->
2435
<PropertyGroup Condition="'$(Platform)'=='windows-x86_32'">
2536
<GodotPlatform>windows</GodotPlatform>
@@ -98,18 +109,29 @@
98109
<PlatformToolset Condition="'$(GodotPlatform)'=='android'">Clang_Linux</PlatformToolset>
99110
<PlatformToolset Condition="'$(GodotPlatform)'=='web'">Clang_Linux</PlatformToolset>
100111
<!-- Fallback when platform is not matched -->
101-
<PlatformToolset Condition="'$(PlatformToolset)'==''">Unknown</PlatformToolset>
112+
<PlatformToolset Condition="'$(PlatformToolset)'==''">v143</PlatformToolset>
113+
<DefaultPlatformToolset>$(PlatformToolset)</DefaultPlatformToolset>
102114

103115
<NMakeWorkingDirectory>$(RepoRoot)</NMakeWorkingDirectory>
104116
<NMakeOutput Condition="'$(NMakeOutput)' == ''">dylib</NMakeOutput> <!--any non empty value required for automatic run configuration generation in Rider -->
105117
<LocalDebuggerWorkingDirectory Condition="'$(LocalDebuggerWorkingDirectory)' == ''">$(NMakeWorkingDirectory)/demo</LocalDebuggerWorkingDirectory>
106118
<LocalDebuggerCommandArguments>--editor</LocalDebuggerCommandArguments>
107119
<NMakeIncludeSearchPath>$(RepoRoot)/godot-cpp/gen/include;$(RepoRoot)/godot-cpp/include;$(RepoRoot)/godot-cpp/gdextension;$(NMakeIncludeSearchPath);</NMakeIncludeSearchPath>
120+
</PropertyGroup>
121+
122+
<PropertyGroup Condition="!$(IsWindows)" Label="Configuration">
108123
<!-- Commands executed by Build/Rebuild/Clean in the IDE (Rider, VS) -->
109124
<NMakeBuildCommandLine>scons platform=$(GodotPlatform) arch=$(Arch) target=$(GodotTemplate) $(BuildType)</NMakeBuildCommandLine>
110125
<NMakeReBuildCommandLine>scons --clean platform=$(GodotPlatform) arch=$(Arch) target=$(GodotTemplate) &amp;&amp; scons platform=$(GodotPlatform) arch=$(Arch) target=$(GodotTemplate)</NMakeReBuildCommandLine>
111126
<NMakeCleanCommandLine>scons --clean platform=$(GodotPlatform) arch=$(Arch) target=$(GodotTemplate)</NMakeCleanCommandLine>
112127
</PropertyGroup>
128+
129+
<PropertyGroup Condition="$(IsWindows)" Label="Configuration">
130+
<NMakeBuildCommandLine>cmd /V /C set "PATH=$(PATH)" ^&amp; scons platform=$(GodotPlatform) arch=$(Arch) target=$(GodotTemplate) $(BuildType)</NMakeBuildCommandLine>
131+
<NMakeReBuildCommandLine>cmd /V /C set "PATH=$(PATH)" ^&amp; scons --clean platform=$(GodotPlatform) arch=$(Arch) target=$(GodotTemplate) ^&amp; scons platform=$(GodotPlatform) arch=$(Arch) target=$(GodotTemplate)</NMakeReBuildCommandLine>
132+
<NMakeCleanCommandLine>cmd /V /C set "PATH=$(PATH)" ^&amp; scons --clean platform=$(GodotPlatform) arch=$(Arch) target=$(GodotTemplate)</NMakeCleanCommandLine>
133+
</PropertyGroup>
134+
113135
<Import Project="$(VCTargetsPath)/Microsoft.Cpp.props" Condition="$(IsWindows)"/>
114136
<ImportGroup Label="ExtensionSettings">
115137
</ImportGroup>

0 commit comments

Comments
 (0)