help-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: make: target-depending prerequisites?


From: Yves
Subject: Re: make: target-depending prerequisites?
Date: Mon, 26 May 2008 14:59:22 +0200
User-agent: Thunderbird 2.0.0.14 (X11/20080505)


I think it would be a cleaner solution if you skipped those variables
and instead wrote something like this:

-8<-----------------------------------------
texfiles = main1.tex main2.tex

all_pdf = $(texfiles:.tex=.pdf)

all: $(all_pdf)

main1.pdf: section1.tex section3.tex

main2.pdf: section2.tex section1.tex

$(all_pdf): main%.pdf: main%.tex
        @echo "All prerequisites:" $^
        touch $@
-8<-----------------------------------------

This is exactly what I was looking for. Thanks!

Yves


reply via email to

[Prev in Thread] Current Thread [Next in Thread]