1 # Hey Emacs, this is a -*- makefile -*-
12 # partial linking of a subdir's $(OFILES) into one file
15 $(LD) $(LDFLAGS) -r -o $@ $^
17 clean: subdir_clean local_clean
20 $(RM) $(OFILES) subdir.o core
22 realclean: subdir_realclean local_clean
23 $(RM) $(GENFILES) .depend TAGS
25 depend: subdir_depend local_depend
27 local_depend: $(CFILES) $(filter %.h,$(SOURCES) $(GENFILES))
28 ifeq ($(strip $(CFILES)),)
31 $(CC) -M $(DEFS) $(CPPFLAGS) $(filter %.c,$^) >.depend || { $(RM) .depend; false; }
35 # Recurse into $(subdirs) for $(targets)
36 $(addprefix subdir_,$(targets)): $(subdirs)
39 Makefile: $(srcdir)/Makefile.in $(topdir)/config.status
41 CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= ./config.status >&2
44 tags: subdir_tags local_tags
46 local_tags: $(TAGFILES)
50 install: subdir_install local_install
52 ifneq ($(strip $(INSTALL_HEADERS)),)
53 $(INSTALL) -m u+rw,a+r $(addprefix $(srcdir)/,$(INSTALL_HEADERS)) $(INCLUDEDIR)
55 ifneq ($(strip $(INSTALL_LIBS)),)
56 $(INSTALL) -m u+rw,a+r $(addprefix $(topdir)/,$(INSTALL_LIBS)) $(LIBDIR)
59 # include dependencies