[MPlayer-dev-eng] [PATCH] Fix 'make distclean'

Reimar Döffinger Reimar.Doeffinger at stud.uni-karlsruhe.de
Tue Feb 3 14:01:43 CET 2009


On Tue, Feb 03, 2009 at 01:32:01PM +0100, Diego Biurrun wrote:
> On Tue, Feb 03, 2009 at 02:02:37AM +0200, Georgi Petrov wrote:
> > On Tue, Feb 3, 2009 at 1:53 AM, Reimar Döffinger
> > <Reimar.Doeffinger at stud.uni-karlsruhe.de> wrote:
> > > On Tue, Feb 03, 2009 at 12:31:43AM +0100, Diego Biurrun wrote:
> > >> You have to run configure again after distclean.  Everything else is
> > >> undefined behavior.
> > >
> > > I'd be thankful if you could find time to make things more reliable, two suggestions:
> > > 1) Ignore rm failure
> > 
> > This one will be enough to perform correct distclean at least on my
> > environment.
> 
> No, it would *not* be correct in your environment as it would not
> remove the binaries as it is supposed to.  It might run without
> returning an error.  In this case, this is opposite from running
> correctly.

Well, in ordinary usage this only happens when they were already
removed.
While it would actually make things worse for this case, clean could
just remove _all_ exesuf, i.e. mplayer, mplayer.exe and whatever,
because the current method will fail to clean stuff when you first
cross-compiled for mingw and then configured for linux.

> Errors are not to be ignored.  The fact that distclean printed an error
> should tell you something.

If MPlayer did not create a new folder in the current directory, there
would not be an error and it would still fail to delete e.g. mplayer.exe.
If you know a way to make "make" record the error but still delete all
the other files that would of course be preferable. Not being able to
easily get rid of all those .o files just because you can't/don't want
to run configure is a bit annoying...
Also I think that "make distclean" should work as well as possible
without having to run configure, because that takes _ages_ on MinGW.



More information about the MPlayer-dev-eng mailing list