Skip to content

Commit

Permalink
Fix swhere (#236)
Browse files Browse the repository at this point in the history
Co-authored-by: Matthew Asplund <mwasplund@outlook.com>
  • Loading branch information
mwasplund and Matthew Asplund authored Jan 13, 2024
1 parent 67589b7 commit d0c23e8
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
14 changes: 7 additions & 7 deletions Source/GenerateSharp/Swhere.Core/SwhereManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -187,12 +187,12 @@ private static async Task DiscoverGCCAsync(LocalUserConfig userConfig)
var cppCompilerPath = await WhereIsUtilities.FindExecutableAsync("g++");

var gccSDK = userConfig.EnsureSDK("GCC");
gccSDK.SourceDirectories.Clear();
gccSDK.SourceDirectories = new List<Path>();
gccSDK.SetProperties(
new Dictionary<string, string>()
{
{ "CCompiler", cCompilerPath.ToString() },
{ "CppCompiler", cppCompilerPath.ToString() },
{ "CCompiler", cCompilerPath.ToString() },
{ "CppCompiler", cppCompilerPath.ToString() },
});
}

Expand All @@ -204,13 +204,13 @@ private static async Task DiscoverClangAsync(LocalUserConfig userConfig)
var archiverPath = await WhereIsUtilities.FindExecutableAsync("ar");

var clangSDK = userConfig.EnsureSDK("Clang");
clangSDK.SourceDirectories.Clear();
clangSDK.SourceDirectories = new List<Path>();
clangSDK.SetProperties(
new Dictionary<string, string>()
{
{ "CCompiler", cCompilerPath.ToString() },
{ "CppCompiler", cppCompilerPath.ToString() },
{ "Archiver", archiverPath.ToString() },
{ "CCompiler", cCompilerPath.ToString() },
{ "CppCompiler", cppCompilerPath.ToString() },
{ "Archiver", archiverPath.ToString() },
});
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ public IList<Path> SourceDirectories
}
else
{
throw new InvalidOperationException("No SDKs.");
throw new InvalidOperationException("No SourceDirectories.");
}
}
set
Expand Down

0 comments on commit d0c23e8

Please sign in to comment.