build: Support all `Standard targets' for users.
[mes.git] / build-aux / GNUmakefile.in
index 35b0d5d501667238a137a75e2cc6705ce4ee5330..f90e0c1d5085af73734776a5600e9f85bd2064b1 100644 (file)
 # You should have received a copy of the GNU General Public License
 # along with GNU Mes.  If not, see <http://www.gnu.org/licenses/>.
 
-PHONY_TARGETS:= all all-go build check clean clean-go default dist doc help install\
-install-info man gcc mes src/mes mes-gcc mes-tcc uninstall
+PHONY_TARGETS:=\
+ ${top_builddest}src/mes\
+ TAGS\
+ all-go\
+ all\
+ build\
+ check\
+ clean-go\
+ clean\
+ default\
+ dist\
+ distclean\
+ doc\
+ dvi\
+ gcc\
+ generate-ChangeLog\
+ help\
+ html\
+ info\
+ install-dvi\
+ install-html\
+ install-pdf\
+ install-ps\
+ install-strip\
+ install\
+ installcheck\
+ installdirs\
+ maintainer-clean\
+ man\
+ mes-gcc\
+ mes-tcc\
+ mes\
+ mostlyclean\
+ pdf\
+ ps\
+ uninstall\
+#
+
 .PHONY: $(PHONY_TARGETS)
 
 default: all
 
+cleaning-p:=$(filter clean%, $(MAKECMDGOALS))$(filter %clean, $(MAKECMDGOALS))
+
+ifndef cleaning-p
 $(PHONY_TARGETS):
        $(MAKE) -C $(srcdir) $@
+endif
+
+clean:
+       git clean -dfx
+
 
 include .config.make
 config.make:=$(PWD)/.config.make