garbage variable in GNUmakefile.in

Started by Daniel Gustafssonover 7 years ago3 messages
#1Daniel Gustafsson
daniel@yesql.se
1 attachment(s)

I happened to notice that there is a variable 'garbage' in GNUmakefile.in,
which was defined in 32163099d7c43a0244f463eb4e525c711e6e97a3 ~18 years ago,
but which seems to not be used? Is 'garbage' a special make variable or is a
leftover which can be removed?

cheers ./daniel

Attachments:

garbage.diffapplication/octet-stream; name=garbage.diff; x-unix-mode=0644Download
diff --git a/GNUmakefile.in b/GNUmakefile.in
index 973fef54fb..563c83b5a2 100644
--- a/GNUmakefile.in
+++ b/GNUmakefile.in
@@ -78,7 +78,6 @@ GNUmakefile: GNUmakefile.in $(top_builddir)/config.status
 
 distdir	= postgresql-$(VERSION)
 dummy	= =install=
-garbage = =*  "#"*  ."#"*  *~*  *.orig  *.rej  core  postgresql-*
 
 dist: $(distdir).tar.gz $(distdir).tar.bz2
 	rm -rf $(distdir)
#2Tom Lane
tgl@sss.pgh.pa.us
In reply to: Daniel Gustafsson (#1)
Re: garbage variable in GNUmakefile.in

Daniel Gustafsson <daniel@yesql.se> writes:

I happened to notice that there is a variable 'garbage' in GNUmakefile.in,
which was defined in 32163099d7c43a0244f463eb4e525c711e6e97a3 ~18 years ago,
but which seems to not be used? Is 'garbage' a special make variable or is a
leftover which can be removed?

It's not a special make variable, so far as I can find in the gmake manual.

It looks like the idea was to list filename patterns that could be subject
to automatic removal during "make clean", but Peter backed off listing it
in the clean target and then forgot to remove the variable.

I couldn't find any contemporaneous discussion in the archives, but I do
vaguely recall that at some point --- maybe not just then --- we talked
about having such auto removal and decided it was a bad idea. Editor
backup filenames, for instance, vary depending on your weapon of choice;
and core file names vary too, these days. So there's a project policy
that we wouldn't enable any such removal by the makefiles. (These days
people would probably turn to git commands for such cleanup, anyway.)

In short, yeah, I think we could nuke that. But maybe Peter remembers
it differently.

regards, tom lane

#3Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Tom Lane (#2)
Re: garbage variable in GNUmakefile.in

On 07/08/2018 16:06, Tom Lane wrote:

In short, yeah, I think we could nuke that. But maybe Peter remembers
it differently.

It's all obsolete with git clean anyway.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services