Added dist rule in PHONY pseudo-rule when appropriate

This commit is contained in:
Pierre Pronchery 2006-07-06 02:06:57 +00:00
parent e2420f5a43
commit 4a12741528

View File

@ -64,10 +64,14 @@ static int _makefile_write(Configure * configure, Config * config, FILE * fp,
|| _write_uninstall(configure->prefs, config, fp) != 0)
return 1;
if(!(configure->prefs->flags & PREFS_n))
fprintf(fp, "%s%s%s", "\n.PHONY: all",
fprintf(fp, "%s%s%s%s%s", "\n.PHONY: all",
config_get(config, "", "subdirs") != NULL
? " subdirs" : "",
" clean distclean install uninstall\n");
" clean distclean",
config_get(config, "", "package") != NULL
&& config_get(config, "", "version") != NULL
? " dist" : "",
" install uninstall\n");
return 0;
}