John Criswell | 7a73b80 | 2003-06-30 21:59:07 +0000 | [diff] [blame] | 1 | #===-- Makefile.config - Local configuration for LLVM ------*- makefile -*--==== |
| 2 | # |
| 3 | # This file is included by Makefile.common. It defines paths and other |
| 4 | # values specific to a particular installation of LLVM. |
| 5 | #===-----------------------------------------------------------------------==== |
| 6 | |
| 7 | # |
| 8 | # Target operating system for which LLVM will be compiled. |
| 9 | # |
| 10 | OS=@OS@ |
| 11 | |
John Criswell | 7659545 | 2003-07-01 22:07:39 +0000 | [diff] [blame] | 12 | # |
| 13 | # Target hardware architecture |
| 14 | # |
| 15 | ARCH=@ARCH@ |
| 16 | |
John Criswell | 7a73b80 | 2003-06-30 21:59:07 +0000 | [diff] [blame] | 17 | # Path to the C++ compiler to use. This is an optional setting, which defaults |
| 18 | # to whatever your gmake defaults to. |
| 19 | # |
| 20 | # Under Linux, for some reason the compiler driver wants to search the PATH to |
| 21 | # find the system assembler, which breaks if the LLVM assembler is in our path. |
| 22 | # Hack it to use the assembler in /usr/bin directly. |
| 23 | # |
| 24 | CXX = @CXX@ |
| 25 | |
| 26 | # We have the same problem with the CC binary, which use used by testcases for |
| 27 | # native builds. |
| 28 | # |
| 29 | CC := @CC@ |
| 30 | |
| 31 | # |
| 32 | # Compilation flags for the C and C++ compilers. |
| 33 | # |
John Criswell | b103e61 | 2003-07-02 16:53:44 +0000 | [diff] [blame] | 34 | |
| 35 | # |
| 36 | # Removing the compiler flags for now. They interfere with the test suite |
| 37 | # (which has its own autoconf stuff), and we don't use -DHAVE_CONFIG_H anyway. |
| 38 | # |
| 39 | #CPPFLAGS+=@DEFS@ |
| 40 | #CCFLAGS+=@DEFS@ |
John Criswell | b812e76 | 2003-07-01 15:02:59 +0000 | [diff] [blame] | 41 | LDFLAGS+=@LDFLAGS@ |
John Criswell | 49bf862 | 2003-06-30 22:33:53 +0000 | [diff] [blame] | 42 | |
| 43 | # |
| 44 | # Removed since it prevents the tests from working properly. |
| 45 | # |
John Criswell | b812e76 | 2003-07-01 15:02:59 +0000 | [diff] [blame] | 46 | #LIBS+=@LIBS@ |
John Criswell | 7a73b80 | 2003-06-30 21:59:07 +0000 | [diff] [blame] | 47 | |
| 48 | # |
| 49 | # Libraries needed by tools |
| 50 | # |
| 51 | TOOLLINKOPTS=@LIBS@ |
| 52 | |
| 53 | # |
| 54 | # Path to the archiver program. |
| 55 | # |
| 56 | AR_PATH = @AR@ |
| 57 | |
| 58 | # |
| 59 | # The pathnames of the Flex and Bison programs, respectively. |
| 60 | # |
| 61 | BISON = @YACC@ |
| 62 | FLEX = @LEX@ |
| 63 | |
| 64 | # |
| 65 | # Paths to miscellaneous programs. |
| 66 | # |
John Criswell | 7f33695 | 2003-09-06 14:44:17 +0000 | [diff] [blame] | 67 | RPWD = @RPWD@ |
John Criswell | 7a73b80 | 2003-06-30 21:59:07 +0000 | [diff] [blame] | 68 | SED = @SED@ |
| 69 | RM = @RM@ |
| 70 | ECHO = @ECHO@ |
John Criswell | 0057e32 | 2003-07-22 19:17:35 +0000 | [diff] [blame] | 71 | MKDIR = @abs_top_srcdir@/autoconf/mkinstalldirs |
John Criswell | 7a73b80 | 2003-06-30 21:59:07 +0000 | [diff] [blame] | 72 | DATE = @DATE@ |
| 73 | MV = @MV@ |
| 74 | INSTALL = @INSTALL@ |
| 75 | DOT = @DOT@ |
| 76 | ETAGS = @ETAGS@ |
| 77 | |
| 78 | # |
| 79 | # Determine the target for which LLVM should generate code. |
| 80 | # |
| 81 | LLVMGCCARCH := @target@/3.4-llvm |
| 82 | |
| 83 | # Path to directory where object files should be stored during a build. |
| 84 | # Set OBJ_ROOT to "." if you do not want to use a separate place for |
| 85 | # object files. |
| 86 | # |
| 87 | #OBJ_ROOT = . |
John Criswell | 7f33695 | 2003-09-06 14:44:17 +0000 | [diff] [blame] | 88 | OBJ_ROOT := . |
John Criswell | 7a73b80 | 2003-06-30 21:59:07 +0000 | [diff] [blame] | 89 | |
| 90 | # Path to location for LLVM front-end this should only be specified here if you |
| 91 | # want to override the value set in Makefile.$(uname) |
| 92 | # |
| 93 | LLVMGCCDIR := @LLVMGCCDIR@ |
| 94 | |
| 95 | # When this setting is set to true, programs in the llvm/test/Programs hierarchy |
| 96 | # are not recompiled from source code. Instead, the bytecode for the file is |
| 97 | # pulled from the BYTECODE_REPOSITORY directory. This can be useful when disk |
| 98 | # space is limited or when you just don't want to spend time running the C |
| 99 | # frontend. |
| 100 | # |
| 101 | #USE_PRECOMPILED_BYTECODE := 1 |
| 102 | @UPB@ |
| 103 | |
| 104 | # This path specifies the cannonical location of bytecode files for compiled |
| 105 | # versions of the test/Programs/* programs. This is used as the bytecode source |
| 106 | # when USE_PRECOMPILED_BYTECODE is specified or when source code is not |
| 107 | # available for the program (such as SPEC). |
| 108 | # |
| 109 | BYTECODE_REPOSITORY := @BCR@ |
| 110 | |
| 111 | # Path to location for purify, this is only needed if you build with |
| 112 | # ENABLE_PURIFY=1 |
| 113 | # |
| 114 | PURIFY = @PURIFY@ |
| 115 | |
| 116 | # |
| 117 | # SPEC benchmarks: |
| 118 | # Set the USE_SPEC variable to enable the use of the SPEC benchmarks. |
| 119 | # You must provide the SPEC benchmarks on your own. |
| 120 | # |
| 121 | @USE_SPEC@ |
| 122 | |
| 123 | # |
| 124 | # Path to the SPEC benchmarks. If you have the SPEC benchmarks, place the |
| 125 | # path here. |
| 126 | # |
| 127 | #SPEC_ROOT := /home/vadve/shared/benchmarks/speccpu2000/benchspec |
| 128 | SPEC_ROOT := @SPEC_ROOT@ |
| 129 | |
| 130 | # |
| 131 | # Path to the PAPI code. This is used by the reoptimizer only. |
| 132 | # |
| 133 | #PAPIDIR := /home/vadve/shared/papi-2.3.4.1 |
| 134 | PAPIDIR := @PAPIDIR@ |
| 135 | |
| 136 | # These are options that can either be enabled here, or can be enabled on the |
| 137 | # make command line (ie, make ENABLE_PROFILING=1) |
| 138 | # |
| 139 | |
| 140 | # When ENABLE_OPTIMIZED is enabled, Release builds of all of the LLVM code are |
| 141 | # turned on, and Debug builds are turned off. |
| 142 | # |
| 143 | #ENABLE_OPTIMIZED = 1 |
| 144 | @ENABLE_OPTIMIZED@ |
| 145 | |
| 146 | # When ENABLE_PROFILING is enabled, the llvm source base is built with profile |
| 147 | # information to allow gprof to be used to get execution frequencies. |
| 148 | # |
| 149 | #ENABLE_PROFILING = 1 |
John Criswell | 7a73b80 | 2003-06-30 21:59:07 +0000 | [diff] [blame] | 150 | |
| 151 | # |
Misha Brukman | e967650 | 2003-07-02 21:20:04 +0000 | [diff] [blame] | 152 | # This option tells the Makefiles to produce verbose output. |
John Criswell | 7a73b80 | 2003-06-30 21:59:07 +0000 | [diff] [blame] | 153 | # It essentially prints the commands that make is executing |
| 154 | # |
| 155 | #VERBOSE = 1 |
John Criswell | 7a73b80 | 2003-06-30 21:59:07 +0000 | [diff] [blame] | 156 | |
| 157 | # When ENABLE_PURIFY is set to 1, the LLVM tools are linked with purify (which |
| 158 | # must be locally installed) to allow for some automated memory error debugging. |
| 159 | # |
| 160 | #ENABLE_PURIFY = 1 |
| 161 | @ENABLE_PURIFY@ |
| 162 | |
| 163 | # |
| 164 | # Enable JIT for this platform |
| 165 | # |
| 166 | @JIT@ |
| 167 | |
| 168 | # |
| 169 | # Disable LLC diffs for testing. |
| 170 | # |
| 171 | @DISABLE_LLC_DIFFS@ |
| 172 | |
John Criswell | 7f33695 | 2003-09-06 14:44:17 +0000 | [diff] [blame] | 173 | ########################################################################### |
| 174 | # Directory Configuration |
| 175 | # This section of the Makefile determines what is where. To be |
| 176 | # specific, there are several locations that need to be defined: |
| 177 | # |
| 178 | # o LLVM_SRC_ROOT : The root directory of the LLVM source code. |
| 179 | # o LLVM_OBJ_ROOT : The root directory containing the built LLVM code. |
| 180 | # |
| 181 | # o BUILD_SRC_DIR : The directory containing the code to build. |
| 182 | # o BUILD_SRC_ROOT : The root directory of the code to build. |
| 183 | # |
| 184 | # o BUILD_OBJ_DIR : The directory in which compiled code will be placed. |
| 185 | # o BUILD_OBJ_ROOT : The root directory in which compiled code is placed. |
| 186 | # |
| 187 | ########################################################################### |
| 188 | |
| 189 | # |
| 190 | # Set the object build directory. By default, it is the current directory. |
| 191 | # |
| 192 | ifndef BUILD_OBJ_DIR |
| 193 | BUILD_OBJ_DIR := $(subst //,/,$(shell $(RPWD))) |
| 194 | endif |
| 195 | |
| 196 | # |
| 197 | # Set the root of the object directory. |
| 198 | # |
| 199 | ifndef BUILD_OBJ_ROOT |
| 200 | BUILD_OBJ_ROOT := $(subst //,/,$(shell cd $(BUILD_OBJ_DIR)/$(LEVEL); $(RPWD))) |
| 201 | endif |
| 202 | |
| 203 | # |
| 204 | # Set the source build directory. That is almost always the current directory. |
| 205 | # |
| 206 | ifndef BUILD_SRC_DIR |
| 207 | BUILD_SRC_DIR := $(subst //,/,@abs_top_srcdir@/$(patsubst $(BUILD_OBJ_ROOT)%,%,$(BUILD_OBJ_DIR))) |
| 208 | endif |
| 209 | |
| 210 | # |
| 211 | # Set the source root directory. |
| 212 | # |
| 213 | ifndef BUILD_SRC_ROOT |
| 214 | BUILD_SRC_ROOT := $(subst //,/,@abs_top_srcdir@) |
| 215 | endif |
| 216 | |
| 217 | # |
| 218 | # Set the LLVM object directory. |
| 219 | # |
| 220 | ifndef LLVM_OBJ_ROOT |
| 221 | ifdef LLVM_SRC_ROOT |
| 222 | LLVM_OBJ_ROOT := $(shell cd $(LLVM_SRC_ROOT); $(RPWD)) |
| 223 | else |
| 224 | LLVM_OBJ_ROOT := $(BUILD_OBJ_ROOT) |
| 225 | endif |
| 226 | endif |
| 227 | |
| 228 | # |
| 229 | # Set the LLVM source directory. |
| 230 | # It is typically the root directory of what we're compiling now. |
| 231 | # |
| 232 | ifndef LLVM_SRC_ROOT |
| 233 | LLVM_SRC_ROOT := $(BUILD_SRC_ROOT) |
| 234 | endif |
| 235 | |
John Criswell | 613758d | 2003-09-11 18:03:50 +0000 | [diff] [blame] | 236 | # |
| 237 | # Set SourceDir for backwards compatbility. |
| 238 | # |
| 239 | ifndef SourceDir |
| 240 | SourceDir=$(BUILD_SRC_DIR) |
| 241 | endif |
| 242 | |