[CMake] Cross Compiling

Daniel Stonier d.stonier at gmail.com
Mon Jan 4 03:00:30 EST 2010


The more I use cmake, the more I find it difficult to bend in to shape to
cross compile. The original design doesn't seem to be designed for anything
more than windows-linux or linux-windows cross compiles.

Some things I'm having to currently work around by creating my own
cross-compiling set of modules. My host is an amd64 linux and my target is
an arm linux.

- You can't set CMAKE_SYSTEM_NAME to anything useful other than Linux, which
of course doesn't trigger the cross-compile variable CROSS_COMPILING because
the host is the same.
- There is no distinction between install prefixes for the target and the
host. Sometimes I'd like to put various build tools on the host system at
the same time as libs and binaries on the target root.
- Debian packaging in cpack will only ever put things in /usr, regardless of
cross-compiles or different CMAKE_INSTALL_PREFIX. Refer again to above
comment.

Having some useful autotools install style variables (--prefix and
--exec-prefix), someway of utilising of proper gnu tuples (e.g.
arm-unknown-linux-gnueabi) would make things alot easier.

Is this planned or is this something that could use a nudge to move into a
useful direction?

Do many other people cross-compile much with cmake?

-- 
Phone : +82-10-5400-3296 (010-5400-3296)
HomePage: http://snorriheim.dnsdojo.com/
Yujin Robot: http://www.yujinrobot.com/
Projects: http://snorriheim.dnsdojo.com/redmine/projects
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20100104/03e2361f/attachment.htm>


More information about the CMake mailing list