OSDN Git Service

radeonsi: initial WIP SI code
[android-x86/external-mesa.git] / src / gallium / drivers / radeon / Makefile
1
2 TOP = ../../../..
3 include $(TOP)/configs/current
4
5 include Makefile.sources
6
7 LIBNAME = radeon
8
9 LIBRARY_INCLUDES = -I$(TOP)/include
10
11 TBLGEN = $(LLVM_BINDIR)/llvm-tblgen
12
13 CXXFLAGS+= $(LLVM_CXXFLAGS)
14
15 include ../../Makefile.template
16
17 CXXFLAGS := $(filter-out -DDEBUG, $(CXXFLAGS))
18
19 tablegen = $(TBLGEN) -I $(LLVM_INCLUDEDIR) $1 $2 -o $3
20
21 gen: $(GENERATED_SOURCES)
22
23 SIRegisterInfo.td: SIGenRegisterInfo.pl
24         $(PERL) $^ > $@
25
26 SIRegisterGetHWRegNum.inc: SIGenRegisterInfo.pl
27         $(PERL) $^ $@ > /dev/null
28
29 R600ShaderPatterns.td: AMDGPUGenShaderPatterns.pl
30         $(PERL) $^ C > $@
31         
32 R600RegisterInfo.td: R600GenRegisterInfo.pl
33         $(PERL) $^ > $@
34
35 AMDGPUInstrEnums.td: AMDGPUGenInstrEnums.pl
36         $(PERL) $^ td > $@
37
38 AMDGPUInstrEnums.h.include: AMDGPUGenInstrEnums.pl
39         $(PERL) $^ h > $@
40
41 AMDGPUInstrEnums.include: AMDGPUGenInstrEnums.pl
42         $(PERL) $^ inc > $@
43
44
45 AMDILGenRegisterInfo.inc: *.td
46         $(call tablegen, -gen-register-info, AMDIL.td, $@)
47
48 AMDILGenInstrInfo.inc: *.td
49         $(call tablegen, -gen-instr-info, AMDIL.td, $@)
50
51 AMDILGenAsmWriter.inc: *.td
52         $(call tablegen, -gen-asm-writer, AMDIL.td, $@)
53
54 AMDILGenDAGISel.inc: *.td
55         $(call tablegen, -gen-dag-isel, AMDIL.td, $@)
56
57 AMDILGenCallingConv.inc: *.td
58         $(call tablegen, -gen-callingconv, AMDIL.td, $@)
59
60 AMDILGenSubtargetInfo.inc: *.td
61         $(call tablegen, -gen-subtarget, AMDIL.td, $@)
62
63 AMDILGenEDInfo.inc: *.td
64         $(call tablegen, -gen-enhanced-disassembly-info, AMDIL.td, $@)
65
66 AMDILGenIntrinsics.inc: *.td
67         $(call tablegen, -gen-tgt-intrinsic, AMDIL.td, $@)
68
69 AMDILGenCodeEmitter.inc: *.td
70         $(call tablegen, -gen-emitter, AMDIL.td, $@)
71
72 LOADER_LIBS=$(shell llvm-config --libs bitreader asmparser)
73 loader: loader.o libradeon.a
74         gcc -o loader -L/usr/local/lib $(LDFLAGS) loader.o libradeon.a $(LLVM_LIBS) $(LOADER_LIBS) -lpthread -ldl -lstdc++ -lm
75
76 # FIXME: Remove when this driver is converted to automake.
77 all: default