Lines Matching full:cmake
27 * `CMake <https://cmake.org>`_
48 By default they are auto-detected: if CMake can find the dependency it will be
50 CMake flag to ``On`` or ``Off`` to force the dependency to be enabled or
52 CMake configuration error.
55 | Feature | Description | CMake Flag |
78 $ pkgin install swig python38 cmake ninja-build
79 $ brew install swig cmake ninja
150 Building LLDB with CMake
161 CMake is a cross-platform build-generator tool. CMake does not build the
164 may be used as well. Please also read `Building LLVM with CMake
165 <https://llvm.org/docs/CMake.html>`_.
170 Create a new directory for your build-tree. From there run CMake and point it
175 $ cmake -G Ninja -DLLVM_ENABLE_PROJECTS="clang;lldb" [<cmake options>] path/to/llvm-project/llvm
180 require ``lld``. Add it to the list in order to run all tests. Once CMake is done,
205 Run CMake with ``-B`` pointing to a new directory for the provided
212 $ cmake -B /path/to/llvm-build -G Ninja \
214 [<more cmake options>] /path/to/llvm-project/llvm
217 Now run CMake a second time with ``-B`` pointing to a new directory for the
220 looks for the path to its CMake modules in ``LLVM_DIR``. If you use a separate
222 (CMake variables are case-sensitive!):
226 $ cmake -B /path/to/lldb-build -G Ninja \
227 -DLLVM_DIR=/path/to/llvm-build/lib/cmake/llvm \
228 [<more cmake options>] /path/to/llvm-project/lldb
237 supported since `CMake version 3.14
238 <https://cmake.org/cmake/help/v3.14/release/3.14.html#command-line>`_
242 Common CMake options
245 Following is a description of some of the most important CMake variables which
247 the CMake command line.
250 debug info enabled -- pass two additional arguments to cmake before running
255 $ cmake -G Ninja \
267 $ cmake -G Ninja \
281 Although the following CMake variables are by no means Windows specific, they
292 statically to the location specified in the ``PYTHON_HOME`` CMake variable,
305 $ cmake -G Ninja^
314 cmake twice and generate the output into two different folders. One for
322 $ cmake -G "Visual Studio 16 2019" -A x64 -T host=x64 <cmake variables> <path to root of llvm source tree>
347 CMake caches
350 CMake caches allow to store common sets of configuration options in the form of
351 CMake scripts and can be useful to reproduce builds for particular use-cases
353 A cache is passed to CMake with the ``-C`` flag, following the absolute path to
355 currently available caches in the `lldb/cmake/caches/
356 <https://github.com/llvm/llvm-project/tree/main/lldb/cmake/caches>`_
370 $ cmake -B /path/to/lldb-build -G Ninja \
371 -C /path/to/llvm-project/lldb/cmake/caches/Apple-lldb-macOS.cmake \
386 $ cmake -B /path/to/llvm-build -G Ninja \
387 -C /path/to/llvm-project/lldb/cmake/caches/Apple-lldb-base.cmake \
393 $ cmake -B /path/to/lldb-build \
394 -C /path/to/llvm-project/lldb/cmake/caches/Apple-lldb-Xcode.cmake \
395 -DLLVM_DIR=/path/to/llvm-build/lib/cmake/llvm \
398 $ cmake --build /path/to/lldb-build --target check-lldb
403 supported since `CMake version 3.14
404 <https://cmake.org/cmake/help/v3.14/release/3.14.html#command-line>`_
444 of CMake at this time. Please refer to `CMake's documentation <https://cmake.org/cmake/help/latest/manual/cmake-toolchains.7.html>`_
473 further by passing the appropriate cmake options, such as:
486 If you find that CMake is finding a version of an optional dependency that
498 2. If you need a host build too, or already have one, you can tell CMake where
505 Either way, the most important cmake options when cross-compiling are:
507 * ``CMAKE_SYSTEM_NAME`` and ``CMAKE_SYSTEM_PROCESSOR``: This tells CMake what
527 * ``CMAKE_LIBRARY_ARCHITECTURE`` : Affects the cmake search path when looking
532 CMake documentation.
534 You can of course also specify the usual cmake options like
556 cmake <path-to-monorepo>/llvm-project/llvm -G Ninja \
576 tools. Install the compiler as in example 1 then run CMake as follows:
580 cmake <path-to-monorepo>/llvm-project/llvm -G Ninja \
623 The NDK also contains a cmake toolchain file, which makes configuring the build
637 -DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK_HOME/build/cmake/android.toolchain.cmake \
692 cmake, specify ``-DLLDB_USE_SYSTEM_DEBUGSERVER=ON``.