1 ##===- lib/Target/SparcV9/Makefile -------------------------*- Makefile -*-===##
3 # The LLVM Compiler Infrastructure
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.
8 ##===----------------------------------------------------------------------===##
11 DIRS = RegAlloc LiveVar
13 ExtraSource = SparcV9.burm.cpp
15 include $(LEVEL)/Makefile.common
17 ifdef ENABLE_OPTIMIZED
23 SparcV9.burg.in1 : $(SourceDir)/SparcV9.burg.in
24 $(CXX) -E -I$(LLVM_SRC_ROOT)/include $(DEBUG_FLAG) -x c++ $< | $(SED) '/^#/d' | $(SED) 's/Ydefine/#define/' > $@
26 SparcV9.burm : SparcV9.burg.in1
27 $(CXX) -E -I$(LLVM_SRC_ROOT)/include $(DEBUG_FLAG) -x c++ $< | $(SED) '/^#/d' | $(SED) 's/^Xinclude/#include/' | $(SED) 's/^Xdefine/#define/' > $@
29 SparcV9.burm.cpp: SparcV9.burm
30 @echo "Burging `basename $<`"
33 $(BUILD_OBJ_DIR)/Debug/SparcV9.burm.lo: SparcV9.burm.cpp
36 $(BUILD_OBJ_DIR)/Release/SparcV9.burm.lo: SparcV9.burm.cpp
39 $(BUILD_OBJ_DIR)/Profile/SparcV9.burm.lo: SparcV9.burm.cpp
42 $(BUILD_OBJ_DIR)/Depend/SparcV9.burm.d: $(BUILD_OBJ_DIR)/Depend/.dir
45 TARGET_NAME := SparcV9
47 TABLEGEN_FILES := $(notdir $(wildcard $(SourceDir)/*.td))
49 # Make sure that tblgen is run, first thing.
50 $(SourceDepend): $(TARGET_NAME)CodeEmitter.inc
52 $(TARGET_NAME)CodeEmitter.cpp:: $(TARGET_NAME)CodeEmitter.inc
54 $(TARGET_NAME)CodeEmitter.inc:: $(SourceDir)/$(TARGET_NAME).td $(TABLEGEN_FILES) $(TBLGEN)
55 @echo "Tblgen'ing `basename $<`"
56 $(TBLGEN) -I $(SourceDir) $< -gen-emitter -o $@
59 $(RM) -f $(TARGET_NAME)CodeEmitter.inc SparcV9.burg.in1 SparcV9.burm SparcV9.burm.cpp