From 27ead9d4b77c3f84dd07e762aae3e2473beeb423 Mon Sep 17 00:00:00 2001 From: Brad King Date: Fri, 15 May 2020 09:20:11 -0400 Subject: VS: Compute managed type from an existing configuration It is not clear how multiple configurations should be handled here, but using an existing configuration is at least better than the empty configuration. --- Source/cmVisualStudio10TargetGenerator.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Source/cmVisualStudio10TargetGenerator.cxx b/Source/cmVisualStudio10TargetGenerator.cxx index 4e1cc55..df960b5 100644 --- a/Source/cmVisualStudio10TargetGenerator.cxx +++ b/Source/cmVisualStudio10TargetGenerator.cxx @@ -4134,7 +4134,8 @@ void cmVisualStudio10TargetGenerator::WriteProjectReferences(Elem& e0) } // Don't reference targets that don't produce any output. - if (dt->GetManagedType("") == cmGeneratorTarget::ManagedType::Undefined) { + if (dt->GetManagedType(this->Configurations[0]) == + cmGeneratorTarget::ManagedType::Undefined) { e2.Element("ReferenceOutputAssembly", "false"); e2.Element("CopyToOutputDirectory", "Never"); } -- cgit v0.12