At Sunday 08 August 2010, Ralf Wildenhues wrote: > > > 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. I'll revert it, and add back a proper FIXME.
> > > 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 Should be "tgt1 tgt2 tgt3 tgt4", right? > and the list of dependencies. Should be "dep1 dep2 dep3 dep4", right? > extract_makefile_deps can extract that. I still don't understand how this qualifies as an objection to my proposal. > 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. Added a FIXME comment about that too. Regards, Stefano