On 7/3/2013 11:12 AM, Stephen Kelly wrote:
> I can invoke cmake like this:
>
> cmake .. -DCMAKE_TOOLCHAIN_FILE=../ArmToolchain.cmake \
> -DCMAKE_SYSROOT=/home/stephen/rpi/rasp-pi-rootfs/ \
> -DCMAKE_MAKE_PROGRAM=/usr/bin/make \
> -DCMAKE_INSTALL_PREFIX=/opt/myproject
>
> Question: Should the installation be to
>
> /opt/myproject
>
> on the host, or to
>
> /home/stephen/rpi/rasp-pi-rootfs/opt/myproject
>
> on the host?
I view the sysroot as a toolchain thing, not a target root.
If a project wants to install inside the sysroot it can set
CMAKE_INSTALL_PREFIX to point there. The user may want to
install in $HOME/somewhere while the toolchain sysroot is
a root-owned directory that cannot be modified by the user.
We already have
$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${install_dest}
so I don't think we need another level.
> However, that leaves the question of how to install outside the sysroot. An
> option would be something like a new CMAKE_HOST_INSTALL_PREFIX:
How do install() invocations distinguish which prefix to use?
Does this tie into your multi-toolchain work?
-Brad
--
Powered by www.kitware.com
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Please keep messages on-topic and check the CMake FAQ at:
http://www.cmake.org/Wiki/CMake_FAQ
Follow this link to subscribe/unsubscribe:
http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers