summaryrefslogtreecommitdiff
path: root/Help/prop_tgt/ENABLE_EXPORTS.rst
diff options
context:
space:
mode:
Diffstat (limited to 'Help/prop_tgt/ENABLE_EXPORTS.rst')
-rw-r--r--Help/prop_tgt/ENABLE_EXPORTS.rst27
1 files changed, 18 insertions, 9 deletions
diff --git a/Help/prop_tgt/ENABLE_EXPORTS.rst b/Help/prop_tgt/ENABLE_EXPORTS.rst
index 581c2b90c..0b1064ab4 100644
--- a/Help/prop_tgt/ENABLE_EXPORTS.rst
+++ b/Help/prop_tgt/ENABLE_EXPORTS.rst
@@ -7,16 +7,25 @@ Normally an executable does not export any symbols because it is the
final program. It is possible for an executable to export symbols to
be used by loadable modules. When this property is set to true CMake
will allow other targets to "link" to the executable with the
-:command:`TARGET_LINK_LIBRARIES` command. On all platforms a target-level
+:command:`target_link_libraries` command. On all platforms a target-level
dependency on the executable is created for targets that link to it.
-For DLL platforms an import library will be created for the exported
-symbols and then used for linking. All Windows-based systems
-including Cygwin are DLL platforms. For non-DLL platforms that
-require all symbols to be resolved at link time, such as macOS, the
-module will "link" to the executable using a flag like
-``-bundle_loader``. For other non-DLL platforms the link rule is simply
-ignored since the dynamic loader will automatically bind symbols when
-the module is loaded.
+Handling of the executable on the link lines of the loadable modules
+varies by platform:
+
+* On Windows-based systems (including Cygwin) an "import library" is
+ created along with the executable to list the exported symbols.
+ Loadable modules link to the import library to get the symbols.
+
+* On macOS, loadable modules link to the executable itself using the
+ ``-bundle_loader`` flag.
+
+* On AIX, a linker "import file" is created along with the executable
+ to list the exported symbols for import when linking other targets.
+ Loadable modules link to the import file to get the symbols.
+
+* On other platforms, loadable modules are simply linked without
+ referencing the executable since the dynamic loader will
+ automatically bind symbols when the module is loaded.
This property is initialized by the value of the variable
:variable:`CMAKE_ENABLE_EXPORTS` if it is set when a target is created.