[CMake] How to prevent .lib file to be installed?

Rolf Eike Beer eike at sf-mail.de
Tue Dec 10 16:23:57 EST 2013


Am Dienstag, 10. Dezember 2013, 13:07:07 schrieb Totte Karlsson:
> Hi,
> I'm creating a 'plugin' DLL and want to prevent the associated .lib file
> to be installed (cause its not being used).
> 
> My Install code looks like this now:
> 
> install (TARGETS ${target}
> DESTINATION plugins
> COMPONENT plugins
> )
> 
> and it installs both a .DLL and a .lib file. Any simple fix?

If it is a plugin, i.e. it is only opened using dlopen() or the Windows 
equivalent that I forgot the name, and never linked against, don't use SHARED 
but MODULE in the add_library() call.

Eike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://www.cmake.org/pipermail/cmake/attachments/20131210/ede15aec/attachment.pgp>


More information about the CMake mailing list