Lines Matching full:cmake

11 `CMake <http://www.cmake.org/>`_ is a cross-platform build-generator tool. CMake
16 :doc:`CMake` pages. This page is intended for users doing more complex builds.
18 Many of the examples below are written assuming specific CMake Generators.
19 Unless otherwise explicitly called out these commands should work with any CMake
23 utilized by using a CMake cache. A CMake cache is essentially a configuration
25 for Clang are located in :code:`/clang/cmake/caches` within the monorepo. They
26 can be passed to CMake using the :code:`-C` flag as demonstrated in the examples
32 The Clang CMake build system supports bootstrap (aka multi-stage) builds. At a
38 then use that just-built clang to build clang again. In CMake this simplest form
44 $ cmake -G Ninja -DCMAKE_BUILD_TYPE=Release \
51 configurations for each stage. The next series of examples utilize CMake cache
54 By default, only a few CMake options will be passed between stages.
57 CMake option, each variable separated by a ";". As example:
61 $ cmake -G Ninja -DCMAKE_BUILD_TYPE=Release \
68 CMake options starting by ``BOOTSTRAP_`` will be passed only to the stage2 build.
70 For example, the following CMake call will enabled '-fno-addrsig' only during
75 …$ cmake [..] -DBOOTSTRAP_CMAKE_CXX_FLAGS='-fno-addrsig' -DBOOTSTRAP_CMAKE_C_FLAGS='-fno-addrsig' …
93 configuration the Apple Clang build settings are contained in CMake Cache files.
98 $ cmake -G Ninja -C <path to source>/clang/cmake/caches/Apple-stage1.cmake <path to source>/llvm
101 This CMake invocation configures the stage1 host compiler, and sets
102 CLANG_BOOTSTRAP_CMAKE_ARGS to pass the Apple-stage2.cmake cache script to the
107 based on the settings in Apple-stage2.cmake.
127 Our PGO.cmake cache automates that whole process. You can use it for
128 configuration with CMake with the following command:
132 $ cmake -G Ninja -C <path to source>/clang/cmake/caches/PGO.cmake \
139 optimizations. For example, to run a CMake configuration for a PGO build
144 $ cmake -G Ninja -C <path to source>/clang/cmake/caches/PGO.cmake \
152 (use the CLANG_PGO_TRAINING_DATA option) or a CMake project (use the
161 $ cmake -G Ninja -C <path to source>/clang/cmake/caches/PGO.cmake \
165 The BOOTSTRAP\_ prefixes tells CMake to pass the variables on to the instrumented
198 builtins and runtime libraries. You can use the :code:`CLANG_PGO_TRAINING_DEPS` CMake
201 .. code-block:: cmake
243 at the binary level. There are also CMake caches available to build
247 it with BOLT, use the following CMake configuration:
251 $ cmake <path to source>/llvm -C <path to source>/clang/cmake/caches/BOLT.cmake
265 that optimizes the resulting binary with BOLT, use the following CMake
270 $ cmake -G Ninja <path to source>/llvm \
271 -C <path to source>/clang/cmake/caches/BOLT-PGO.cmake \
301 $ cmake -G Ninja -C <path to source>/clang/cmake/caches/3-stage.cmake <path to source>/llvm