*** empty log message ***
[libfirm] / Makefile
1 # Hey, emacs, this is a -*- makefile -*-
2 #
3 # Copyright (C) 1998 - 2001 by Universitaet Karlsruhe
4 # All rights reserved.
5 # Author: Goetz Lindenmaier
6 #
7 # Main Makefile
8
9 # This makefile makes firm and/or the testprograms.
10
11 SUBDIRS = ir testprograms
12
13 ifeq (,($MAKE))
14 MAKE = /usr/bin/make -k
15 endif
16
17 #MAKE = ${MAKE:-/usr/bin/make} #  Vorschlag Uwe
18 #MAKE = /usr/bin/make -k
19 #SHELL   = /bin/sh
20
21 .PHONY: default all clean realclean install depend ir testprograms
22
23 # Makes the intermediate representation and bundles it into a
24 # library
25 ir:
26         $(MAKE) -C ir
27 # Makes the library, i.e., compiles and bundles the intermediate
28 # representation and extracts the necessary headers into directory
29 # include.
30 lib:    ir
31         $(MAKE) -C ir lib
32
33 # Makes the testprograms.
34 testprograms:
35         $(MAKE) -C testprograms
36
37 # Makes everything
38 all:    TAGS ir lib testprograms
39
40
41 clean:
42         for i in $(SUBDIRS); do  $(MAKE) -C $$i clean; done
43
44 realclean:
45         for i in $(SUBDIRS); do  $(MAKE) -C $$i realclean; done
46         rm -f libfirm.a core include/*.h TAGS
47
48 TAGFILES = $(shell find . -name '*.c' -o -name '*.h')
49
50 TAGS:   $(TAGFILES)
51         etags -C $(TAGFILES)