[PATCH] D119804: [docs] HowToCrossCompileLLVM.rst: update cmake options

Siwei Zhang via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 14 18:52:07 PST 2022


fourdim updated this revision to Diff 408687.
fourdim added a comment.

Update the format.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D119804/new/

https://reviews.llvm.org/D119804

Files:
  llvm/docs/HowToCrossCompileLLVM.rst


Index: llvm/docs/HowToCrossCompileLLVM.rst
===================================================================
--- llvm/docs/HowToCrossCompileLLVM.rst
+++ llvm/docs/HowToCrossCompileLLVM.rst
@@ -40,7 +40,7 @@
 
 The CMake options you need to add are:
 
- * ``-DCMAKE_CROSSCOMPILING=True``
+ * ``-DCMAKE_SYSTEM_NAME=<target-system>``
  * ``-DCMAKE_INSTALL_PREFIX=<install-dir>``
  * ``-DLLVM_TABLEGEN=<path-to-host-bin>/llvm-tblgen``
  * ``-DCLANG_TABLEGEN=<path-to-host-bin>/clang-tblgen``
@@ -48,6 +48,8 @@
  * ``-DLLVM_TARGET_ARCH=ARM``
  * ``-DLLVM_TARGETS_TO_BUILD=ARM``
 
+Note: ``CMAKE_CROSSCOMPILING`` is always set automatically when ``CMAKE_SYSTEM_NAME`` is set. Don't put ``-DCMAKE_CROSSCOMPILING=TRUE`` in your options.
+
 If you're compiling with GCC, you can use architecture options for your target,
 and the compiler driver will detect everything that it needs:
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D119804.408687.patch
Type: text/x-patch
Size: 879 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220215/f37fa634/attachment.bin>


More information about the llvm-commits mailing list