Fix arm rootfs for user installed compilers (#2047)
author박세희/동작제어Lab(SR)/Principal Engineer/삼성전자 <saehie.park@samsung.com>
Mon, 23 Jul 2018 05:48:34 +0000 (14:48 +0900)
committerGitHub Enterprise <noreply-CODE@samsung.com>
Mon, 23 Jul 2018 05:48:34 +0000 (14:48 +0900)
This will fix sysroot option in cmake configure time try_compile to work correctly

Signed-off-by: SaeHie Park <saehie.park@samsung.com>
cmake/config/config_armv7l-linux.cmake

index 8e514d4..e092596 100644 (file)
@@ -12,7 +12,7 @@ set(CMAKE_CXX_COMPILER arm-linux-gnueabihf-g++)
 # where is the target environment
 set(ROOTFS_ARM $ENV{ROOTFS_ARM})
 if(NOT EXISTS "${ROOTFS_ARM}/lib/arm-linux-gnueabihf")
-  set(ROOTFS_ARM "${CMAKE_SOURCE_DIR}/tools/cross/rootfs/arm")
+  set(ROOTFS_ARM "${CMAKE_CURRENT_LIST_DIR}/../../tools/cross/rootfs/arm")
 endif()
 
 set(CMAKE_SYSROOT ${ROOTFS_ARM})