summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalVisualStudioGenerator.cxx
diff options
context:
space:
mode:
authorZsolt Parragi <zsolt.parragi@cancellar.hu>2017-01-28 16:10:02 (GMT)
committerBrad King <brad.king@kitware.com>2017-01-30 13:54:49 (GMT)
commit4dde0bc8ef1d953b8e4b13a2e465d756b5274933 (patch)
tree6726a93d79b18e7cf8487ebba9568633d87294de /Source/cmGlobalVisualStudioGenerator.cxx
parentb30ac988d02d00f7423870799d59272a553ab9e9 (diff)
downloadCMake-4dde0bc8ef1d953b8e4b13a2e465d756b5274933.zip
CMake-4dde0bc8ef1d953b8e4b13a2e465d756b5274933.tar.gz
CMake-4dde0bc8ef1d953b8e4b13a2e465d756b5274933.tar.bz2
VS: Fix WINDOWS_EXPORT_ALL_SYMBOLS for external objects
Teach Visual Studio generators to include external object files in the list of objects whose symbols are to be exported. The Makefile and Ninja generators already did this.
Diffstat (limited to 'Source/cmGlobalVisualStudioGenerator.cxx')
-rw-r--r--Source/cmGlobalVisualStudioGenerator.cxx8
1 files changed, 8 insertions, 0 deletions
diff --git a/Source/cmGlobalVisualStudioGenerator.cxx b/Source/cmGlobalVisualStudioGenerator.cxx
index 5edb81f..cc2536c 100644
--- a/Source/cmGlobalVisualStudioGenerator.cxx
+++ b/Source/cmGlobalVisualStudioGenerator.cxx
@@ -856,6 +856,14 @@ void cmGlobalVisualStudioGenerator::AddSymbolExportCommand(
std::string objFile = obj_dir + map_it->second;
objs.push_back(objFile);
}
+ std::vector<cmSourceFile const*> externalObjectSources;
+ gt->GetExternalObjects(externalObjectSources, configName);
+ for (std::vector<cmSourceFile const*>::const_iterator it =
+ externalObjectSources.begin();
+ it != externalObjectSources.end(); ++it) {
+ objs.push_back((*it)->GetFullPath());
+ }
+
gt->UseObjectLibraries(objs, configName);
for (std::vector<std::string>::iterator it = objs.begin(); it != objs.end();
++it) {