Joerg Schilling <[EMAIL PROTECTED]> wrote: > Gunnar Ritter <[EMAIL PROTECTED]> wrote: > > Joerg Schilling <[EMAIL PROTECTED]> wrote: > > > Any makefile that uses $< in an explicit rule is dubtlessly broken if it > > > claims to be portable and authors of free software usually claim to > > > write portable software. > > _If_ they claim that. Otherwise they rely on documented behavior of > > GNU make. This is quite different from "the authors implement code > > that matches GNU make bugs", as you were writing previously. > The GNU make documentation claims that $< is the name of the first dependency. > > This is not complatible with the POSIX standard which defines $< to be the > name of the implicit source that caused an iplicit rule inference rule) > to be chosen.
The exact text in the "info" documentation for GNU make 3.80 is | `$<' | The name of the first prerequisite. If the target got its | commands from an implicit rule, this will be the first | prerequisite added by the implicit rule (*note Implicit Rules::). It could be more precise but I do not see a conflict here. The first sentence refers to the behavior unspecified by POSIX, and the second sentence adds the POSIX behavior. > Now, if GNU tar would be at least compliant to it's own documentation..... > > test: x1 > test: x2 > echo $< > > prints x2 and not x1. > > > Please try to prove your claims again...... Yes, that is indeed not the documented behavior, since it is also claimed that "multiple lines of prerequisites for the same target [...] are appended appropriately". I now realize that there should probably have been a colon in your previous example at the respective place | test.o test.x | test.o: test.bla.xx | echo xifying $< | xify -o $@ $< so yes, there is a bug here in either GNU make or its documentation. I apologize, but the amount of typos in your texts and the sheer noise you make about alleged GNU bugs even if all what you have is suspicions (such as in the discussion about blocking of cpio archives in RPM files we had on the GNU bug-tar list a few months ago) makes it hard do detect when you are actually correct. Gunnar _______________________________________________ opensolaris-discuss mailing list opensolaris-discuss@opensolaris.org