Merge remote branch 'origin/master' into radeon-rewrite
[mesa.git] / configs / linux-llvm
1 # -*-makefile-*-
2 # Configuration for Linux and LLVM with debugging info
3
4 include $(TOP)/configs/linux
5
6 CONFIG_NAME = linux-llvm
7
8 GALLIUM_AUXILIARY_DIRS += gallivm
9
10 OPT_FLAGS = -g -ansi -pedantic
11 DEFINES += -DDEBUG -DDEBUG_MATH -DMESA_LLVM=1
12
13 LLVM_VERSION := $(shell llvm-config --version)
14
15 ifeq ($(LLVM_VERSION),)
16 $(warning Could not find LLVM! Make Sure 'llvm-config' is in the path)
17 MESA_LLVM=0
18 else
19 MESA_LLVM=1
20 $(info Using LLVM version: $(LLVM_VERSION))
21 endif
22
23 ifeq ($(MESA_LLVM),1)
24 # LLVM_CFLAGS=`llvm-config --cflags`
25 LLVM_CXXFLAGS=`llvm-config --cxxflags backend bitreader engine ipo` -Wno-long-long
26 LLVM_LDFLAGS=`llvm-config --ldflags backend bitreader engine ipo`
27 LLVM_LIBS=`llvm-config --libs backend bitreader engine ipo`
28 MKLIB_OPTIONS=-cplusplus
29 else
30 LLVM_CFLAGS=
31 LLVM_CXXFLAGS=
32 endif
33
34 LD = g++
35 GL_LIB_DEPS = $(LLVM_LDFLAGS) $(LLVM_LIBS) $(EXTRA_LIB_PATH) -lX11 -lXext -lm -lpthread -lstdc++