On Fri, Jun 4, 2010 at 11:17 PM,  <[email protected]> wrote:
> Trying to use vpath w/implicit pattern rule.  Why does
> case B fail?
>
>  # test makefile:
>
>    /tmp/test0 $ cat makefile    # simple test pattern rule
>    %.foo: %.bar
>            tac < $<    > $@
>
>    vpath %.bar /tmp/test0/src
>
>  # dependency/source file:
>
>    /tmp/test0 $ ls /tmp/test0/src
>    x.bar
>
>  # case A: success w/vpath:
...
>  # case B: why does this fail?:
>
>    /tmp/test0/tgt $ rm x.foo; cd ..
>    /tmp/test0 $ make tgt/x.foo
>    make: *** No rule to make target `tgt/x.foo'.  Stop.

Given the directive
   vpath %.bar /tmp/test0/src

the prerequisite of tgt/x.bar will match and be searched for in
"/tmp/test0/src/tgt/x.bar".  That is, the directory path from the
prerequisite is kept.


Philip Guenther

_______________________________________________
Help-make mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-make

Reply via email to