Fix linking against C#-only modules

(cherry picked from commit 7ccc0b83ff)
This commit is contained in:
2023-02-13 20:06:59 +02:00
committed by Wojtek Figat
parent ac368863aa
commit df000bc99e

View File

@@ -799,7 +799,7 @@ namespace Flax.Build
moduleOptions.CompileEnv.PreprocessorDefinitions.Add(dependencyModule.BinaryModuleName.ToUpperInvariant() + "_API=" + toolchain.DllImport);
var dependencyModuleBuild = buildData.FinReferenceBuildModule(moduleName);
if (dependencyModuleBuild != null)
if (dependencyModuleBuild != null && !string.IsNullOrEmpty(dependencyModuleBuild.NativePath))
{
// Link against the referenced binary module
if (toolchain.UseImportLibraryWhenLinking)