[CMake] Multiple install section from the same base folder

Eric Noulard eric.noulard at gmail.com
Tue Jul 12 03:41:09 EDT 2011


2011/7/12 Laszlo Papp <lpapp at kde.org>:
> Hi,
>
>> Not sure whether if it's better than your current solution.
>> May be it's a little less painless to write.
>
> Would it make sense to add an option to these install sections so that
> it grabs the files as they are (with subfolders, if any), if you set
> that option or something like that ? That would result the easiest and
> cleanest way in my novice opinion. Is it possible to ask for such a
> feature ?

You mean writing:
install(FILES
   archive/archive.h
   FULLPATH
   DESTINATION ${INCLUDE_INSTALL_DIR}/gluon/player/lib
   COMPONENT Devel)

instead of:

install(FILES
   archive/archive.h
   DESTINATION ${INCLUDE_INSTALL_DIR}/gluon/player/lib/archive
   COMPONENT Devel)

Honestly I do not see any benefit in this, but may be I did not
understand what you meant?

It would be interesting if the file list was coming from file(GLOB ...)
but it has already been discussed here that it's usually a bad idea to
use globbing,
because you may miss appearing or disappearing files.


-- 
Erk
Membre de l'April - « promouvoir et défendre le logiciel libre » -
http://www.april.org


More information about the CMake mailing list