-config: FORCE
- @cd config; ${MAKE} config
- @echo
- @echo "The Undernet IRC daemon is now hopefully configured for your setup."
- @echo "Next run 'make' to build the server."
- @echo
+${srcdir}/aclocal.m4: acinclude.m4
+ cd ${srcdir} && aclocal
+
+${srcdir}/configure: configure.in aclocal.m4
+ cd ${srcdir} && autoconf
+
+# autoheader might not change config.h.in, so touch a stamp file.
+${srcdir}/config.h.in: stamp-h.in
+${srcdir}/stamp-h.in: configure.in aclocal.m4 acconfig.h
+ cd ${srcdir} && autoheader
+ echo timestamp > ${srcdir}/stamp-h.in
+
+config.h: stamp-h
+stamp-h: config.h.in config.status
+ ./config.status
+
+Makefile: Makefile.in config.status
+ ./config.status
+
+doc/Makefile: doc/Makefile.in config.status
+ ./config.status