diff options
author | Felix Fietkau <nbd@openwrt.org> | 2015-03-16 07:51:45 +0000 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2015-03-16 07:51:45 +0000 |
commit | 4ca62eb7a5fa7751c4ca3aed4cd6daf040eaccea (patch) | |
tree | 62287a0861017e34c0ae3a5fabdb756a62b9d9a3 /include | |
parent | b34d1f6b435b05479c3ddee74be1ef428ae7455a (diff) | |
download | master-187ad058-4ca62eb7a5fa7751c4ca3aed4cd6daf040eaccea.tar.gz master-187ad058-4ca62eb7a5fa7751c4ca3aed4cd6daf040eaccea.tar.bz2 master-187ad058-4ca62eb7a5fa7751c4ca3aed4cd6daf040eaccea.zip |
cmake: include external toolchain directory in CMAKE_FIND_ROOT_PATH (fixes #19074)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@44825 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'include')
-rw-r--r-- | include/cmake.mk | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/include/cmake.mk b/include/cmake.mk index 862a6a9b3f..c1fd7d9e51 100644 --- a/include/cmake.mk +++ b/include/cmake.mk @@ -31,6 +31,8 @@ CMAKE_AR:=$(call cmake_tool,$(TARGET_AR)) CMAKE_NM:=$(call cmake_tool,$(TARGET_NM)) CMAKE_RANLIB:=$(call cmake_tool,$(TARGET_RANLIB)) +CMAKE_FIND_ROOT_PATH:=$(STAGING_DIR);$(TOOLCHAIN_DIR)$(if $(CONFIG_EXTERNAL_TOOLCHAIN),;$(CONFIG_TOOLCHAIN_ROOT)) + define Build/Configure/Default (cd $(PKG_BUILD_DIR); \ CFLAGS="$(TARGET_CFLAGS) $(EXTRA_CFLAGS)" \ @@ -53,7 +55,7 @@ define Build/Configure/Default -DCMAKE_AR="$(CMAKE_AR)" \ -DCMAKE_NM="$(CMAKE_NM)" \ -DCMAKE_RANLIB="$(CMAKE_RANLIB)" \ - -DCMAKE_FIND_ROOT_PATH="$(STAGING_DIR);$(TOOLCHAIN_DIR)" \ + -DCMAKE_FIND_ROOT_PATH="$(CMAKE_FIND_ROOT_PATH)" \ -DCMAKE_FIND_ROOT_PATH_MODE_PROGRAM=BOTH \ -DCMAKE_FIND_ROOT_PATH_MODE_LIBRARY=ONLY \ -DCMAKE_FIND_ROOT_PATH_MODE_INCLUDE=ONLY \ |