On Tue, 2008-09-30 at 19:42 +0100, Noah Slater wrote:
> my idea was that they could configure the build process by
> exporting variables based on pattern rules like this:
> 
>   dir/dir/index.html: author = jim bob
> 
> When trying to create a set of rules for the distributed makefiles I
> initially
> had the software changing into the output directory to doing something
> similar to this:
> 
>   %.html: $(src)/%.txt
>       $(info example making html from txt)
> 
> The idea being that this would match the following:
> 
>   dir/dir/index.html: $(src)/dir/dir/index.txt


Have you considered using VPATH?  It looks to me (based on this example;
I didn't try to get the tarball) that you have a good fit for it here.
Try rewriting your rule like this:

        VPATH := $(src)

        %.html: %.txt
                $(info example making $@ from $<)

and see if that works.




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

Reply via email to