[Top][All Lists]

[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 (X11/20080505)

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

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 $@

This is exactly what I was looking for. Thanks!


reply via email to

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