* Rich Felker [2014-02-06 20:07:55 -0500]: > On Fri, Feb 07, 2014 at 02:01:36AM +0100, Szabolcs Nagy wrote: > > +dirhack: > > + mkdir -p $(sort $(dir $(OBJS))) crt include lib tools > > How does this avoid having the $(M) source root from $(OBJS)? objs have no $(M) prefix > > include/bits: > > @test "$(ARCH)" || { echo "Please set ARCH in config.mak before running make." ; exit 1 ; } > > - ln -sf ../arch/$(ARCH)/bits $@ > > + ln -sf ../$(M)/arch/$(ARCH)/bits $@ > > Having ../ prior to a possibly-absolute path $(M) seems wrong. this was problematic for other reasons too so i create the arch/... dir and symlink locally attached second try (fixes install, dirs, symlink) for in-tree builds it creates spurious '.mark' files otherwise the same make should work in-tree and out-of-tree