aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/main.cpp b/src/main.cpp
index a295eba..1265d3d 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -300,6 +300,8 @@ struct MicrosoftBuildTool
char umIncludePath[_TINYDIR_PATH_MAX];
// empty if not found
char ucrtIncludePath[_TINYDIR_PATH_MAX];
+ // empty if not found
+ char sharedIncludePath[_TINYDIR_PATH_MAX];
bool found()
{
@@ -314,7 +316,7 @@ static MicrosoftBuildTool locateLatestMicrosoftBuildTool()
if (execResult && execResult.unwrap().exitCode == 0)
{
auto &str = execResult.unwrap().execStdout;
- sscanf(execResult.unwrap().execStdout.c_str(), "%d %[^\r\n] %[^\r\n] %[^\r\n] %[^\r\n] %[^\r\n] %[^\r\n] %[^\r\n]",
+ sscanf(execResult.unwrap().execStdout.c_str(), "%d %[^\r\n] %[^\r\n] %[^\r\n] %[^\r\n] %[^\r\n] %[^\r\n] %[^\r\n] %[^\r\n]",
&result.version,
result.binPath,
result.vsLibPath,
@@ -322,7 +324,8 @@ static MicrosoftBuildTool locateLatestMicrosoftBuildTool()
result.ucrtLibPath,
result.vsIncludePath,
result.umIncludePath,
- result.ucrtIncludePath);
+ result.ucrtIncludePath,
+ result.sharedIncludePath);
}
return result;
}
@@ -341,7 +344,7 @@ static void appendMicrosoftBuildToolToPathEnv()
fprintf(stderr, "Warning: Failed to add microsoft build tools to PATH env\n");
}
- if (_putenv_s("INCLUDE", join({ msBuildTool.vsIncludePath, msBuildTool.umIncludePath, msBuildTool.ucrtIncludePath }, ';')) != 0)
+ if (_putenv_s("INCLUDE", join({ msBuildTool.vsIncludePath, msBuildTool.umIncludePath, msBuildTool.ucrtIncludePath, msBuildTool.sharedIncludePath }, ';')) != 0)
fprintf(stderr, "Warning: Failed to add microsoft build libraries to INCLUDE env\n");
if (_putenv_s("LIB", join({ msBuildTool.vsLibPath, msBuildTool.umLibPath, msBuildTool.ucrtLibPath }, ';')) != 0)