[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


From: Stepan Kasal
Subject: Re: .DELETE_ON_ERROR ?
Date: Wed, 11 May 2005 08:51:47 +0200
User-agent: Mutt/1.4.1i


On Tue, May 10, 2005 at 10:29:58PM -0600, Bob Proulx wrote:
> > Could Automake possibly add this target to all generated's?
> Is your goal to limit the amount of editing you need to
> do?

No, that's not my goal.

I'm not concerned about _my_, now when I know.  I was thinking
about people who don't know all the details of make, yet they suppose that
it'll do the right thing.  They could benefit if we switch on the correct
behaviour by default.

I knew that make removes the target if it is interrupted.  I kind of
supposed that it does the same if a command failed.
When I looked at the manual of GNU make, I read: ``yeah, we know that
would be the right behaviour, but we cannot enable it by default
because of bug compatibility.''  I understand that.
But I think this doesn't apply to Automake; Automake should try to
enable the correct behaviour by default.

> How much control of the generator do you have?  You could make it a
> wrapper for the real generator.  Have it delete the target on error.

Actually, the only error I observed was that I screwed the path and the
generator wasn't found.

>   foo.h: foo.x
>       $(GENERATOR) foo.x >foo.h || { rm -f foo.h ; exit 1 ;}

I was thinking about creating foo.h.tmp and renaming it.
This is more elegant solution, thanks.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]