Lines Matching full:makefile
2 LLVM Makefile Guide
11 This document provides *usage* information about the LLVM makefile system. While
12 loosely patterned after the BSD makefile system, LLVM has taken a departure from
13 BSD in order to implement additional features needed by LLVM. Although makefile
15 that the features needed by LLVM and the ``Makefile`` norm are too great to use
17 portable makefile processor. LLVM unabashedly makes heavy use of the features of
19 ``make``, it is recommended that you read the `GNU Makefile Manual
30 The LLVM Makefile System is the component of LLVM that is responsible for
39 The LLVM Makefile System is quite generous. It not only builds its own software,
42 ``configure`` script and a ``Makefile`` is assumed to be a project that uses the
43 LLVM Makefile system. Building software that uses LLVM does not require the
44 LLVM Makefile System nor even placement in the ``llvm/projects``
47 compiles itself using the same features of the makefile system as used for
57 To use the makefile system, you simply create a file named ``Makefile`` in your
59 that you select determine what the makefile system will do. These variables
60 enable rules and processing in the makefile system that automatically Do The
66 Setting variables alone is not enough. You must include into your Makefile
67 additional files that provide the rules of the LLVM Makefile system. The various
70 ``Makefile``
74 ``Makefile``. This is the file first read by ``make``. It has three
78 #. ``include $(LEVEL)/Makefile.common`` --- include the LLVM Makefile system.
79 #. Override Variables --- Override variables set by the LLVM Makefile system.
81 .. _$(LEVEL)/Makefile.common:
83 ``Makefile.common``
86 Every project must have a ``Makefile.common`` file at its top source
89 #. It includes the project's configuration makefile to obtain values determined
91 `$(LEVEL)/Makefile.config`_ file.
97 #. It includes the standard rules for the LLVM Makefile system,
98 `$(LLVM_SRC_ROOT)/Makefile.rules`_. This file is the *guts* of the LLVM
99 ``Makefile`` system.
101 .. _$(LEVEL)/Makefile.config:
103 ``Makefile.config``
106 Every project must have a ``Makefile.config`` at the top of its *build*
108 pattern provided by the ``Makefile.config.in`` file located at the top of the
112 ``$(LLVM_OBJ_ROOT)/Makefile.config``.
114 .. _$(LLVM_SRC_ROOT)/Makefile.rules:
116 ``Makefile.rules``
119 This file, located at ``$(LLVM_SRC_ROOT)/Makefile.rules`` is the heart of the
120 LLVM Makefile System. It provides all the logic, dependencies, and rules for
123 ``Makefile.rules`` is included.
128 User ``Makefile``\s need not have comments in them unless the construction is
130 makefile system. Makefile comments are invoked with the pound (``#``) character.
138 build with the LLVM makefile system. In general, each directory you provide will
146 Normally, the makefile system will build all the software into a single
152 .. code-block:: makefile
162 Makefile system will infer the source files from the contents of the source
172 <writing-an-llvm-pass-makefile>`_ has an example of why you might want to do
185 use the ``LOADABLE_MODULE`` variable in your ``Makefile``. For example, to build
189 .. code-block:: makefile
213 .. code-block:: makefile
249 .. code-block:: makefile
268 Makefile system. Any target can be invoked from any directory but not all are
278 ``check-local`` \ Run a local test suite. Generally this is only defined in the ``Makefile`` of the project's ``test`` directory.
286 ``printvars`` ``all`` Prints variables defined by the makefile system (for debugging).
314 it exists and has a ``Makefile``. A warning is produced otherwise. If
326 This target should be implemented by the ``Makefile`` in the project's ``test``
337 Makefile builds. The cleaning rules have been made guarded so they shouldn't go
391 This utility target checks to see if the ``Makefile`` in the object directory is
392 older than the ``Makefile`` in the source directory and copies it if so. It also
394 ``Makefile.config`` file similarly. Users may overload this target to ensure
402 makefile variables so that you can double check how things are set.
446 Variables are used to tell the LLVM Makefile System what to do and to obtain
447 information from it. Variables are also used internally by the LLVM Makefile
450 internal to the LLVM Makefile System and should not be relied upon nor
451 modified. The sections below describe how to use the LLVM Makefile
458 `$(LEVEL)/Makefile.common`_. These variables provide input to the LLVM make
532 in each makefile as it is used to find the top level and thus the other
596 config files, etc.). If not specified, the makefile system will infer the
601 set this if your local ``Makefile`` specifies additional suffix match
620 by the makefile. For example, this will pass ``-v`` to the GCC compilers
631 Tells the Makefile system to produce detailed output of what it is doing
638 LLVM makefile system. These variables can be set in several ways:
643 * In the Makefile (only *after* the inclusion of `$(LEVEL)/Makefile.common`_).
765 Variables listed in the table below can be used by the user's Makefile but
790 The LLVM Makefile System output command. This provides the ``llvm[n]``
811 Full path of the ``Makefile.config`` file.
814 Full path of the ``Makefile.config.in`` file.
847 Variables listed below are used by the LLVM Makefile System and considered
850 .. code-block:: makefile