Merge topic 'fix-CMP0022-language-propagation'

31b3bbd7 Merge branch 'backport-fix-CMP0022-language-propagation' into fix-CMP0022-language-propagation
40b9cd0f CMP0022: Fix link language propagation in NEW behavior
42bbf130 CMP0022: Fix link language propagation in NEW behavior
This commit is contained in:
Brad King 2014-05-19 10:38:42 -04:00 committed by CMake Topic Stage
commit 87eab93ad6
2 changed files with 8 additions and 8 deletions

View File

@ -6481,11 +6481,6 @@ void cmTargetInternals::ComputeLinkInterface(cmTarget const* thisTarget,
}
}
}
if(thisTarget->LinkLanguagePropagatesToDependents())
{
// Targets using this archive need its language runtime libraries.
iface.Languages = impl->Languages;
}
}
}
}
@ -6497,9 +6492,14 @@ void cmTargetInternals::ComputeLinkInterface(cmTarget const* thisTarget,
impl = thisTarget->GetLinkImplementation(config, headTarget);
iface.ImplementationIsInterface = true;
iface.WrongConfigLibraries = impl->WrongConfigLibraries;
if(thisTarget->LinkLanguagePropagatesToDependents())
}
if(thisTarget->LinkLanguagePropagatesToDependents())
{
// Targets using this archive need its language runtime libraries.
if(cmTarget::LinkImplementation const* impl =
thisTarget->GetLinkImplementation(config, headTarget))
{
// Targets using this archive need its language runtime libraries.
iface.Languages = impl->Languages;
}
}

View File

@ -1,4 +1,4 @@
cmake_minimum_required (VERSION 2.6)
cmake_minimum_required (VERSION 3.0)
project(testf C CXX Fortran)
if(NOT DEFINED CMake_TEST_NESTED_MAKE_PROGRAM AND NOT CMAKE_GENERATOR MATCHES "Visual Studio")
set(CMake_TEST_NESTED_MAKE_PROGRAM "${CMAKE_MAKE_PROGRAM}")