[CMake] Yet another install() vs. exclude_from_all thread

Michael Hertling mhertling at online.de
Wed Apr 28 08:14:32 EDT 2010


On 04/27/2010 04:53 PM, Daniel Hornung wrote:
> On 2010-04-27 14:42, Michael Hertling wrote:
>> Are you sure this behaviour isn't the expected one?
>>
>> "make install" w.r.t. targets means:
>>
>> 1) Build any target that "install" depends on, especially "all",
>>    but right not the excluded-from-all targets, and afterwards,
>> 2) install any target which is scheduled for installation by
>>    INSTALL(TARGET ...) *and* already built; see "OPTIONAL".
> 
> Hmm, you're right indeed :)
> 
> So it was mainly me wishing for another make syntax ;)  Maybe I should look into
> components...

Yes, perhaps, components suit your needs better, but note: They do not
result in targets which can be triggered on the command line directly;
thus, you must use "cmake -D COMPONENT=... -P cmake_install.cmake" to
install, or define appropriate installation targets by yourself. In
either case, "make install" still does everything.

Regards,

Michael


More information about the CMake mailing list