blob: c15630459567a79e8ffee06d2ae11c96a68f6adf [file] [log] [blame]
Chris Lattnerbda0b622008-03-15 23:59:48 +00001##===- clang/lib/Basic/Makefile ----------------------------*- Makefile -*-===##
Reid Spencer5f016e22007-07-11 17:01:13 +00002#
3# The LLVM Compiler Infrastructure
4#
Chris Lattner6298b8c2007-12-29 20:02:25 +00005# This file is distributed under the University of Illinois Open Source
6# License. See LICENSE.TXT for details.
Reid Spencer5f016e22007-07-11 17:01:13 +00007#
8##===----------------------------------------------------------------------===##
9#
10# This implements the Basic library for the C-Language front-end.
11#
12##===----------------------------------------------------------------------===##
13
Daniel Dunbarafed0992010-06-08 20:34:18 +000014CLANG_LEVEL := ../..
Reid Spencer5f016e22007-07-11 17:01:13 +000015LIBRARYNAME := clangBasic
Reid Spencer5f016e22007-07-11 17:01:13 +000016
Daniel Dunbarafed0992010-06-08 20:34:18 +000017include $(CLANG_LEVEL)/Makefile
Reid Spencer5f016e22007-07-11 17:01:13 +000018
Daniel Dunbar38474aa2010-01-21 16:56:47 +000019SVN_REVISION := $(shell $(LLVM_SRC_ROOT)/utils/GetSourceVersion $(PROJ_SRC_DIR)/../..)
Douglas Gregorb8d11912009-10-05 20:33:49 +000020
21CPP.Defines += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include \
22 -DSVN_REVISION='"$(SVN_REVISION)"'
23
24$(ObjDir)/.ver-svn .ver: $(ObjDir)/.dir
25 @if [ '$(SVN_REVISION)' != '$(shell cat $(ObjDir)/.ver-svn 2>/dev/null)' ]; then\
26 echo '$(SVN_REVISION)' > $(ObjDir)/.ver-svn; \
27 fi
28$(ObjDir)/.ver-svn: .ver
29$(ObjDir)/Version.o: $(ObjDir)/.ver-svn