diff options
author | Deniz Bahadir <dbahadir@benocs.com> | 2017-11-23 11:59:20 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2018-03-01 14:24:24 (GMT) |
commit | 51249e69eaab33fe43805b9fe2262b4ddab01b56 (patch) | |
tree | 1a33d55faf49c0bd9107ea4be7ac8efa756ebea2 /Source/cmTargetLinkLibrariesCommand.cxx | |
parent | e22c45d4c97c713734b8349132fa881f602f7ae3 (diff) | |
download | CMake-51249e69eaab33fe43805b9fe2262b4ddab01b56.zip CMake-51249e69eaab33fe43805b9fe2262b4ddab01b56.tar.gz CMake-51249e69eaab33fe43805b9fe2262b4ddab01b56.tar.bz2 |
objlib: Allow `OBJECT` libraries to link to other libraries.
The proper way to use libraries is now through `target_link_libraries`
for things such as usage requirements, compile definitions, include
directories, etc. To facilitate this, allow `OBJECT` libraries to "link"
to other libraries.
Co-Author: Ben Boeckel <ben.boeckel@kitware.com>
Issue: #14778
Diffstat (limited to 'Source/cmTargetLinkLibrariesCommand.cxx')
-rw-r--r-- | Source/cmTargetLinkLibrariesCommand.cxx | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/Source/cmTargetLinkLibrariesCommand.cxx b/Source/cmTargetLinkLibrariesCommand.cxx index 9e4575a..47c29db 100644 --- a/Source/cmTargetLinkLibrariesCommand.cxx +++ b/Source/cmTargetLinkLibrariesCommand.cxx @@ -94,16 +94,6 @@ bool cmTargetLinkLibrariesCommand::InitialPass( return true; } - // OBJECT libraries are not allowed on the LHS of the command. - if (this->Target->GetType() == cmStateEnums::OBJECT_LIBRARY) { - std::ostringstream e; - e << "Object library target \"" << args[0] << "\" " - << "may not link to anything."; - this->Makefile->IssueMessage(cmake::FATAL_ERROR, e.str()); - cmSystemTools::SetFatalErrorOccured(); - return true; - } - // Having a UTILITY library on the LHS is a bug. if (this->Target->GetType() == cmStateEnums::UTILITY) { std::ostringstream e; |