[CMake] How to install files produced by custom targets
Petr Kmoch
petr.kmoch at gmail.com
Fri Sep 6 06:58:19 EDT 2013
Hi Lucas,
you could look into install(CODE ...) or its escaping-hell-avoiding
brother, install(SCRIPT ...). The code/script could then be something like
execute_process(COMMAND make install ...) or perhaps even
execute_process(COMMAND ${CMAKE_BUILD_TOOL} install ...).
Petr
On Fri, Sep 6, 2013 at 11:44 AM, Lucas Soltic <lucas.soltic at orange.fr>wrote:
> Hello,
>
> Considering that I have a custom target that outputs some libraries and
> these libraries were built using configure+make. The custom library is
> based on autotools. Configure + make are executed by a custom command in
> the custom target.
>
> Is it possible to add a CMake install rule that will execute 'make
> install' on my custom library? So that the install process is automatically
> handled.
>
> I'm asking that because at the moment I'm finding very hard to install a
> custom library only with classical CMake install rules, because I cannot
> know in advance the names of all the outputs because they have suffixes
> depending on the library version. And I would prefer to avoid hardcoding
> these versions, so that I can easily update my library.
>
> Regards,
> Lucas
> --
>
> Powered by www.kitware.com
>
> Please keep messages on-topic and check the CMake FAQ at:
> http://www.cmake.org/Wiki/CMake_FAQ
>
> Kitware offers various services to support the CMake community. For more
> information on each offering, please visit:
>
> CMake Support: http://cmake.org/cmake/help/support.html
> CMake Consulting: http://cmake.org/cmake/help/consulting.html
> CMake Training Courses: http://cmake.org/cmake/help/training.html
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Follow this link to subscribe/unsubscribe:
> http://www.cmake.org/mailman/listinfo/cmake
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20130906/801154ea/attachment-0001.htm>
More information about the CMake
mailing list