[CMake] cross compiling for QNX (ross hennessy)

Kito.Berg-Taylor at dlr.de Kito.Berg-Taylor at dlr.de
Wed Mar 25 04:58:52 EDT 2009


I've been using QNX and cmake together for a few weeks, and I've yet to
have the problem that you indicated. In my QNX toolchain file I use the
line:

SET( CMAKE_AR
"${QNX_HOST}/usr/bin/ntox86-ar${HOST_EXECUTABLE_SUFFIX}"      CACHE PATH
"QNX ar Program" )

-kito

Message: 5
Date: Wed, 25 Mar 2009 14:10:30 +1100
From: ross hennessy <roscoh at gmail.com>
Subject: [CMake] cross compiling for QNX
To: CMake at cmake.org
Message-ID:
	<a88af6570903242010s4d01dddak309d43e1c2ca6b93 at mail.gmail.com>
Content-Type: text/plain; charset="iso-8859-1"

I'm having a problem creating a toolchain file for use with cmake 2.6.3.
I'd
like to generate a UnixMakefile compatible with the QNX Momentics cross
platform development tools. The problem is cmake doesn't seem to find
the
archiver which is named ntox86-ar.exe (as QNX runs on multiple platforms
there are many different versions of the archiver for each target). No
placement of SET(CMAKE_AR "ntox86-ar.exe") in the toolchain file seems
to
help. There is two solutions that I have found so far, neither of which
I'm
particularly happy with. They are -

1) making a copy of ntox86-ar.exe in the momentics install and renaming
it
to ar.exe (which is obviously what cmake is looking for, but totally
wrong
in the context of using a system which is designed for many targets)
2) modifying the QNX.cmake file in the platforms directory and adding
the
above SET command (again I would have to modify this every time I wanted
to
build for a new target)

I would like to be able to specify this in the toolchain file as it is
my
understanding that this is what this file is intended for. Am I doing
something wrong here, or is this the expected behaviour of cmake?

Thanks, Ross
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://www.cmake.org/pipermail/cmake/attachments/20090325/4484af7a/atta
chment-0001.htm>


More information about the CMake mailing list