automake-patches
[Top][All Lists]
Advanced

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

Re: [PATCH] Modernize, improve and/or extend tests `colon*.test.


From: Ralf Wildenhues
Subject: Re: [PATCH] Modernize, improve and/or extend tests `colon*.test.
Date: Sun, 8 Aug 2010 16:44:01 +0200
User-agent: Mutt/1.5.20 (2010-04-22)

* Stefano Lattarini wrote on Sun, Aug 08, 2010 at 04:38:08PM CEST:
> At Sunday 08 August 2010, Ralf Wildenhues wrote:
> > * Stefano Lattarini wrote on Thu, Aug 05, 2010 at 01:54:20PM CEST:
> > > Ping on this?  It seems to me that most issues with this patch
> > > had already been solved, so it's probably a pity to let it
> > > bitrotting here...
> > 
> > Well, I'd prefer the extract_dependencies script approach
> I like the idea, too, but as I said I'd prefer to leave for a later 
> patch.

That's fine of course.  Just leave the corresponding code unchanged
then.

> > which would be more correct and not the complicated perl script
> > which wasn't as correct.
> Why not as correct?
> 
> You said in a previous mail:
>  """
>    A shell function in defs.in 'extract_makefile_deps TARGET FILE'
>    that contains a sed script similar to extract_makefile_var that
>    does what you want, and respects backslash-newline?
>  """
> But why should that function preserve backslash-newline occurrences?
> Is not this an internal detail due to automatical line-wrapping by
> Automake, which we should therefore ignore?

No, it is an official API of 'make' that we program against.  With

 tgt1 tgt2 \
      tgt3 : dep1 dep2 \
      dep3 \
             dep4

Posix is perfectly clear about the list of targets and the list of
dependencies.  extract_makefile_deps can extract that.

You're then still relying on not having $(macros) in the lists, so
there is still an internal detail there, but I don't know how to avoid
that easily.

An even much more better check would be to only check semantics, i.e.,
that some target is actually updated when some dependency is outdated.

Cheers,
Ralf



reply via email to

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