From: Alexander Kanavin Date: Wed, 23 Jan 2019 16:17:39 +0000 (+0100) Subject: cmake: do not look into native sysroot in the nativesdk environment X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7ea988887c577aa6c62bdada8db7218d852d9edd;p=thirdparty%2Fopenembedded%2Fopenembedded-core-contrib.git cmake: do not look into native sysroot in the nativesdk environment I am not sure why we do this in the first place, but it is causing cmake to erroneously pick up items from the native sysroot when building for the target and the target item is missing, for example: https://autobuilder.yoctoproject.org/typhoon/#/builders/59/builds/198/steps/7/logs/step2c Note that for executable programs this variable is not referred to, as set by set( CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER ) in the same file. (From OE-Core rev: cd1c0a0631ad128b25e97f047750579caead051a) Signed-off-by: Alexander Kanavin Signed-off-by: Richard Purdie --- diff --git a/meta/recipes-devtools/cmake/cmake/OEToolchainConfig.cmake b/meta/recipes-devtools/cmake/cmake/OEToolchainConfig.cmake index 8a0fb4cb12e..398069eef28 100644 --- a/meta/recipes-devtools/cmake/cmake/OEToolchainConfig.cmake +++ b/meta/recipes-devtools/cmake/cmake/OEToolchainConfig.cmake @@ -5,7 +5,7 @@ set( CMAKE_ASM_FLAGS ${CMAKE_C_FLAGS} CACHE STRING "" FORCE ) set( CMAKE_LDFLAGS_FLAGS ${CMAKE_CXX_FLAGS} CACHE STRING "" FORCE ) set( CMAKE_SYSROOT $ENV{OECORE_TARGET_SYSROOT} ) -set( CMAKE_FIND_ROOT_PATH $ENV{OECORE_TARGET_SYSROOT} $ENV{OECORE_NATIVE_SYSROOT} ) +set( CMAKE_FIND_ROOT_PATH $ENV{OECORE_TARGET_SYSROOT} ) set( CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER ) set( CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY ) set( CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY )