[PATCH] D41621: [cmake] Fix path problems when cross compiling.
Don Hinton via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Dec 28 21:32:03 PST 2017
hintonda created this revision.
hintonda added reviewers: EricWF, compnerd, phosek, beanz.
Herald added a subscriber: mgorny.
When cross compiling, users can set CMAKE_FIND_ROOT_PATH to
the sysroot of the TARGET system which adds the sysroot prefix to the
paths used in the FIND_XXX commands. Since these FIND_PATH commands
use absolute paths found on the HOST system, pass
NO_CMAKE_FIND_ROOT_PATH to keep the prefix from being added.
https://reviews.llvm.org/D41621
Files:
CMakeLists.txt
Index: CMakeLists.txt
===================================================================
--- CMakeLists.txt
+++ CMakeLists.txt
@@ -329,7 +329,8 @@
PATHS ${LLVM_MAIN_SRC_DIR}/projects/libcxx/include
${LLVM_MAIN_SRC_DIR}/runtimes/libcxx/include
NO_DEFAULT_PATH
-)
+ NO_CMAKE_FIND_ROOT_PATH
+ )
if ((NOT LIBUNWIND_STANDALONE_BUILD OR HAVE_LIBCXX) AND
IS_DIRECTORY "${LIBUNWIND_LIBCXX_INCLUDES_INTERNAL}")
set(LIBUNWIND_CXX_INCLUDE_PATHS_DEFAULT "${LIBUNWIND_LIBCXX_INCLUDES_INTERNAL}")
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D41621.128313.patch
Type: text/x-patch
Size: 510 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20171229/2cfd4d55/attachment.bin>
More information about the cfe-commits
mailing list