summaryrefslogtreecommitdiffstats
path: root/Help/command/add_library.rst
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2017-04-19 14:47:28 (GMT)
committerKitware Robot <kwrobot@kitware.com>2017-04-19 14:47:31 (GMT)
commit44f0d2d9913595e214048b6d5a2b9ab2e9d1cf46 (patch)
treec95b4621b9a71adc962c9c2e3e3140a0fb73e627 /Help/command/add_library.rst
parent9db9bb27ea3f3dd3db3913c2bc2233f03018d5b0 (diff)
parenteec93bceec5411e4409b5e3ee5dc301fca6fcbfd (diff)
downloadCMake-44f0d2d9913595e214048b6d5a2b9ab2e9d1cf46.zip
CMake-44f0d2d9913595e214048b6d5a2b9ab2e9d1cf46.tar.gz
CMake-44f0d2d9913595e214048b6d5a2b9ab2e9d1cf46.tar.bz2
Merge topic 'objlib-extend'
eec93bce Allow OBJECT libraries to be installed, exported, and imported 93c89bc7 Genex: Allow TARGET_OBJECTS to be used everywhere ac0cf7ff Genex: Reject TARGET_OBJECTS on non-object libraries earlier 8577978c Tests: ExportImport C code should use explicit (void) in prototypes 26cfd039 cmInstallTargetGenerator: Re-order GenerateScriptForConfig logic 25f3f22a cmGlobalGenerator: Add method to check if object file location is known d596c550 cmGeneratorTarget: Add method to get the object file directory 930042f2 cmGeneratorTarget: Factor out a GetTargetObjectNames method ... Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !712
Diffstat (limited to 'Help/command/add_library.rst')
-rw-r--r--Help/command/add_library.rst9
1 files changed, 4 insertions, 5 deletions
diff --git a/Help/command/add_library.rst b/Help/command/add_library.rst
index af75a39..3a76040 100644
--- a/Help/command/add_library.rst
+++ b/Help/command/add_library.rst
@@ -64,7 +64,7 @@ Imported Libraries
::
- add_library(<name> <SHARED|STATIC|MODULE|UNKNOWN> IMPORTED
+ add_library(<name> <SHARED|STATIC|MODULE|OBJECT|UNKNOWN> IMPORTED
[GLOBAL])
An :ref:`IMPORTED library target <Imported Targets>` references a library
@@ -106,10 +106,9 @@ may contain only sources that compile, header files, and other files
that would not affect linking of a normal library (e.g. ``.txt``).
They may contain custom commands generating such sources, but not
``PRE_BUILD``, ``PRE_LINK``, or ``POST_BUILD`` commands. Object libraries
-cannot be imported, exported, installed, or linked. Some native build
-systems may not like targets that have only object files, so consider
-adding at least one real source file to any target that references
-``$<TARGET_OBJECTS:objlib>``.
+cannot be linked. Some native build systems may not like targets that
+have only object files, so consider adding at least one real source file
+to any target that references ``$<TARGET_OBJECTS:objlib>``.
Alias Libraries
^^^^^^^^^^^^^^^