X-Git-Url: http://www.project-moonshot.org/gitweb/?a=blobdiff_plain;f=Makefile;h=cfcb30c03196ba87e4fa76ee379d711ec0cf06ae;hb=refs%2Fheads%2Feap-chbind2;hp=11c6a7545bf42be89e01cc97505fd9471e448b1d;hpb=448e18f357919baac6987bed3fd1160d05acbaca;p=freeradius.git diff --git a/Makefile b/Makefile index 11c6a75..cfcb30c 100644 --- a/Makefile +++ b/Makefile @@ -21,9 +21,9 @@ export DESTDIR := $(R) # And over-ride all of the other magic. include scripts/boiler.mk -.PHONY: test -test: +test: build.raddb @$(MAKE) -C raddb/certs + @$(MAKE) -C src/tests tests # # The $(R) is a magic variable not defined anywhere in this source. @@ -116,24 +116,33 @@ distclean: clean # Automatic remaking rules suggested by info:autoconf#Automatic_Remaking # ###################################################################### -.PHONY: reconfig -reconfig: - @$(MAKE) $(MFLAGS) -C src reconfig - @$(MAKE) configure - @$(MAKE) src/include/autoconf.h.in - -configure: configure.in aclocal.m4 - $(AUTOCONF) - -.PHONY: src/include/autoconf.h.in -src/include/autoconf.h.in: - $(AUTOHEADER) +CONFIGURE_IN_FILES := $(shell find . -name configure.in -print) +CONFIGURE_FILES := $(patsubst %.in,%,$(CONFIGURE_IN_FILES)) + +# Configure files depend on "in" files, and on the top-level macro files +# If there are headers, run auto-header, too. +src/%configure: src/%configure.in acinclude.m4 aclocal.m4 + @echo AUTOCONF $@ + @cd $(dir $@) && $(AUTOCONF) -I $(top_builddir) -I $(top_builddir)/m4 -I ./m4 + @if grep AC_CONFIG_HEADERS $@ >/dev/null; then\ + echo AUTOHEADER $@ \ + cd $(dir $@) && $(AUTOHEADER); \ + fi + +# "%configure" doesn't match "configure" +configure: configure.in $(wildcard ac*.m4) + @echo AUTOCONF $@ + @$(AUTOCONF) + +src/include/autoconf.h.in: configure.in + @echo AUTOHEADER $@ + @$(AUTOHEADER) + +reconfig: $(CONFIGURE_FILES) src/include/autoconf.h.in config.status: configure ./config.status --recheck -configure.in: - .PHONY: check-includes check-includes: scripts/min-includes.pl `find . -name "*.c" -print`