X-Git-Url: http://plrg.eecs.uci.edu/git/?a=blobdiff_plain;f=docs%2FCMake.rst;h=b9e473fab2b2bce8176c7209c3d2c8cbe61d923d;hb=dc374b5eb4f7cc5415cde4b9f3412ac2877b6817;hp=6c94e8d416487dd509aa796527846bf805d3e960;hpb=f16cb03bc182a6168bacabb9e60e21805b8b5b0a;p=oota-llvm.git diff --git a/docs/CMake.rst b/docs/CMake.rst index 6c94e8d4164..b9e473fab2b 100644 --- a/docs/CMake.rst +++ b/docs/CMake.rst @@ -26,7 +26,7 @@ Quick start We use here the command-line, non-interactive CMake interface. #. `Download `_ and install - CMake. Version 2.8 is the minimum required. + CMake. Version 2.8.8 is the minimum required. #. Open a shell. Your development tools must be reachable from this shell through the PATH environment variable. @@ -59,6 +59,36 @@ We use here the command-line, non-interactive CMake interface. environment variable, for instance. You can force CMake to use a given build tool, see the `Usage`_ section. +#. After CMake has finished running, proceed to use IDE project files or start + the build from the build directory: + + .. code-block:: console + + $ cmake --build . + + The ``--build`` option tells ``cmake`` to invoke the underlying build + tool (``make``, ``ninja``, ``xcodebuild``, ``msbuild``, etc). + + The underlying build tool can be invoked directly either of course, but + the ``--build`` option is portable. + +#. After LLVM has finished building, install it from the build directory: + + .. code-block:: console + + $ cmake --build . --target install + + The ``--target`` option with ``install`` parameter in addition to + the ``--build`` option tells ``cmake`` to build the ``install`` target. + + It is possible to set a different install prefix at installation time + by invoking the ``cmake_install.cmake`` script generated in the + build directory: + + .. code-block:: console + + $ cmake -DCMAKE_INSTALL_PREFIX=/tmp/llvm -P cmake_install.cmake + .. _Basic CMake usage: .. _Usage: @@ -240,6 +270,15 @@ LLVM-specific variables **LLVM_ENABLE_WERROR**:BOOL Stop and fail build, if a compiler warning is triggered. Defaults to OFF. +**LLVM_ABI_BREAKING_CHECKS**:STRING + Used to decide if LLVM should be built with ABI breaking checks or + not. Allowed values are `WITH_ASSERTS` (default), `FORCE_ON` and + `FORCE_OFF`. `WITH_ASSERTS` turns on ABI breaking checks in an + assertion enabled build. `FORCE_ON` (`FORCE_OFF`) turns them on + (off) irrespective of whether normal (`NDEBUG` based) assertions are + enabled or not. A version of LLVM built with ABI breaking checks + is not ABI compatible with a version built without it. + **LLVM_BUILD_32_BITS**:BOOL Build 32-bits executables and libraries on 64-bits systems. This option is available only on some 64-bits unix systems. Defaults to OFF. @@ -429,7 +468,7 @@ and uses them to build a simple application ``simple-tool``. add_definitions(${LLVM_DEFINITIONS}) # Now build our tools - add_excutable(simple-tool tool.cpp) + add_executable(simple-tool tool.cpp) # Find the libraries that correspond to the LLVM components # that we wish to use