[CMake] dependencies of cross compiliations

Torsten Robitzki Torsten at Robitzki.de
Sat Nov 10 04:35:47 EST 2018



> Am 09.11.2018 um 15:55 schrieb Miller Henry <MillerHenry at JohnDeere.com>:
> 
> There are two options. Each with pros and cons.
> 
> The first what you are doing now, except you use external project https://cmake.org/cmake/help/v3.12/module/ExternalProject.html to build the host tools instead of add_custom_command. It otherwise has all the cons you mention, but are they significant (this is a question that is different for each project)?  Going back to the manual build for host before the target isn’t bad, though it is harder to teach.

I think for the example use case, this will work best. Especially, if there are source files (for example constants) are shared among both platforms.

Thanks,

Torsten


More information about the CMake mailing list