blob: d0c1588e117ea69371b884444040ff89f7064567 [file] [log] [blame]
Anton Korobeynikove9ffb5b2008-03-23 08:57:20 +00001##===- tools/llvmcc/Makefile -------------------------------*- Makefile -*-===##
2#
3# The LLVM Compiler Infrastructure
4#
5# This file is distributed under the University of Illinois Open
6# Source License. See LICENSE.TXT for details.
7#
8##===----------------------------------------------------------------------===##
9LEVEL = ../..
10TOOLNAME = llvmc2
11BUILT_SOURCES = Tools.inc
12LINK_COMPONENTS = support system
13REQUIRES_EH := 1
14
15include $(LEVEL)/Makefile.common
16
17TOOLS_TARGET=default
18ifeq ($(TOOLS_TARGET), default)
19 TOOLS_SOURCE=Example.td
20else
21 TOOLS_SOURCE=ExampleWithOpt.td
22endif
23
24# TOFIX: integrate this part into Makefile.rules?
25# The degree of horrorshowness in that file is too much for me atm.
26$(ObjDir)/Tools.inc.tmp: $(TOOLS_SOURCE) $(ObjDir)/.dir
27 $(Echo) "Building LLVMCC configuration library with tblgen"
28 $(Verb) $(TableGen) -gen-llvmcc -o $@ $<
29
30Tools.inc : $(ObjDir)/Tools.inc.tmp
31 $(Verb) $(CMP) -s $@ $< || $(CP) $< $@
32