blob: 3dfcda889d8a14b6022c7fe220abeda66adc07c8 [file] [log] [blame]
Misha Brukman5dfe3a92004-06-21 16:55:25 +00001##===- lib/Target/PowerPC/Makefile -------------------------*- Makefile -*-===##
2#
3# The LLVM Compiler Infrastructure
4#
5# This file was developed by the LLVM research group and is distributed under
6# the University of Illinois Open Source License. See LICENSE.TXT for details.
7#
8##===----------------------------------------------------------------------===##
9LEVEL = ../../..
Chris Lattner017fdcb2004-07-15 02:33:38 +000010LIBRARYNAME = powerpc
Misha Brukman5dfe3a92004-06-21 16:55:25 +000011include $(LEVEL)/Makefile.common
12
Misha Brukman2f947862004-08-05 18:34:15 +000013TARGET = PowerPC
14
Misha Brukman5dfe3a92004-06-21 16:55:25 +000015# Make sure that tblgen is run, first thing.
16$(SourceDepend): PowerPCGenRegisterInfo.h.inc PowerPCGenRegisterNames.inc \
17 PowerPCGenRegisterInfo.inc PowerPCGenInstrNames.inc \
Misha Brukman039ba762004-07-16 20:31:13 +000018 PowerPCGenInstrInfo.inc
Misha Brukman5dfe3a92004-06-21 16:55:25 +000019
Misha Brukman2f947862004-08-05 18:34:15 +000020TDFILES = $(SourceDir)/$(TARGET).td $(wildcard $(SourceDir)/*.td) \
21 $(SourceDir)/../Target.td
22
23$(TARGET)GenRegisterNames.inc:: $(TDFILES) $(TBLGEN)
24 @echo "Building $(TARGET).td register names with tblgen"
Misha Brukman5dfe3a92004-06-21 16:55:25 +000025 $(VERB) $(TBLGEN) -I $(BUILD_SRC_DIR) $< -gen-register-enums -o $@
26
Misha Brukman2f947862004-08-05 18:34:15 +000027$(TARGET)GenRegisterInfo.h.inc:: $(TDFILES) $(TBLGEN)
28 @echo "Building $(TARGET).td register information header with tblgen"
Misha Brukman5dfe3a92004-06-21 16:55:25 +000029 $(VERB) $(TBLGEN) -I $(BUILD_SRC_DIR) $< -gen-register-desc-header -o $@
30
Misha Brukman2f947862004-08-05 18:34:15 +000031$(TARGET)GenRegisterInfo.inc:: $(TDFILES) $(TBLGEN)
32 @echo "Building $(TARGET).td register information implementation with tblgen"
Misha Brukman5dfe3a92004-06-21 16:55:25 +000033 $(VERB) $(TBLGEN) -I $(BUILD_SRC_DIR) $< -gen-register-desc -o $@
34
Misha Brukman2f947862004-08-05 18:34:15 +000035$(TARGET)GenInstrNames.inc:: $(TDFILES) $(TBLGEN)
36 @echo "Building $(TARGET).td instruction names with tblgen"
Misha Brukman5dfe3a92004-06-21 16:55:25 +000037 $(VERB) $(TBLGEN) -I $(BUILD_SRC_DIR) $< -gen-instr-enums -o $@
38
Misha Brukman2f947862004-08-05 18:34:15 +000039$(TARGET)GenInstrInfo.inc:: $(TDFILES) $(TBLGEN)
40 @echo "Building $(TARGET).td instruction information with tblgen"
Misha Brukman5dfe3a92004-06-21 16:55:25 +000041 $(VERB) $(TBLGEN) -I $(BUILD_SRC_DIR) $< -gen-instr-desc -o $@
42
Misha Brukman5dfe3a92004-06-21 16:55:25 +000043clean::
44 $(VERB) rm -f *.inc