Hi all,

I have one source pdf file source.pdf, that I want to use pdftk to
split into multiple files such that the n-th file on the target list
is the n-th page from source.pdf

TARGETS = "foo.pdf bar.pdf more_foo.pdf ... "

What I want, is to have a rule like this:

${TARGETS} : source.pdf
    pdftk A=$? cat A# output $@

where # is the position of $@ inside the list ${TARGETS}.  I see a lot
of buildin pattern matching and substitution functions, but I don't
see anything that help find the matching position.

Any idea?

--MZ

Reply via email to