[CMake] How to install files produced by custom targets

2013-09-06 Thread Lucas Soltic
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

Re: [CMake] How to install files produced by custom targets

2013-09-06 Thread Petr Kmoch
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

Re: [CMake] How to install files produced by custom targets

2013-09-06 Thread Petr Kmoch
I just wanted to point out the existence of CMAKE_BUILD_TOOL, as it's related. In your case, however, you're probably better off hardcoding 'make'. It should actually be done the same way you run 'make' in your custom command creating the library. On Fri, Sep 6, 2013 at 2:08 PM, Lucas Soltic