|
|
@@ -1999,8 +1999,13 @@ void cmGeneratorTarget::ComputeModuleDefinitionInfo(
|
|
|
info.WindowsExportAllSymbols =
|
|
|
this->Makefile->IsOn("CMAKE_SUPPORT_WINDOWS_EXPORT_ALL_SYMBOLS") &&
|
|
|
this->GetPropertyAsBool("WINDOWS_EXPORT_ALL_SYMBOLS");
|
|
|
+#if defined(_WIN32) && defined(CMAKE_BUILD_WITH_CMAKE)
|
|
|
info.DefFileGenerated =
|
|
|
info.WindowsExportAllSymbols || info.Sources.size() > 1;
|
|
|
+#else
|
|
|
+ // Our __create_def helper is only available on Windows.
|
|
|
+ info.DefFileGenerated = false;
|
|
|
+#endif
|
|
|
if (info.DefFileGenerated) {
|
|
|
info.DefFile = this->ObjectDirectory /* has slash */ + "exports.def";
|
|
|
} else if (!info.Sources.empty()) {
|