1 # Hey Emacs, this is a -*- makefile -*-
10 SHELL = @CONFIG_SHELL@
14 CPPFLAGS := -I. -I$(topdir) -I$(srcdir) -I$(top_srcdir) @CPPFLAGS@
17 INCLUDEDIR = @includedir@
24 LD_R := @libfirm_cv_prog_ld_r@
27 ifeq (@enable_profile_libfirm@,yes)
36 DISTFILES = $(SOURCES)
37 CFILES = $(filter %.c,$(SOURCES) $(GENFILES))
38 HFILES = $(filter %.h,$(SOURCES) $(GENFILES))
39 OFILES = $(CFILES:.c=.o)
41 TAGFILES = $(CFILES) $(HFILES)
43 LDLIBS=$(LIBS) -lm -lc
45 COMPILE.c = $(CC) -c $(DEFS) $(CPPFLAGS) $(CDEBUG) $(CFLAGS) $(XCFLAGS)
46 COMPILE.s = $(CC) -S $(DEFS) $(CPPFLAGS) $(CDEBUG) $(CFLAGS) $(XCFLAGS)
55 $(CPP) $(DEFS) $(CPPFLAGS) -o $@ $<
58 $(DT) $(DTFLAGS) <$^ >$@ || $(fail)
65 # make target given by $@ recursively in $^ ...
66 ifeq (,$(findstring k,$(MAKEFLAGS)))
67 # ... and immediately stop on errors
69 +@for i in $^ ""; do if test $$i; then $(MAKE) -C $$i $(subst subdir_,,$@) || exit $$?; fi; done
72 # ... and keep going after errors
75 for i in $^ ""; do if test $$i; then $(MAKE) -C $$i $(subst subdir_,,$@) || fail=y; fi; done; \
80 targets = all clean depend echodist echogen echosrc realclean tags install