lilypond-devel
[Top][All Lists]
Advanced

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

Re: DOCS: include a sample "Makefile"?


From: Jonathan Kulp
Subject: Re: DOCS: include a sample "Makefile"?
Date: Mon, 18 May 2009 13:31:20 -0500
User-agent: Thunderbird 2.0.0.21 (X11/20090409)

Werner LEMBERG wrote:
For the moment I've added a crude method of putting the midi files in
the MIDI/ dir:

   mv PDF/*.midi MIDI/

If there's a way to automate this it would look nicer. Also, it only
works on the "make movements" command.  I tried "make stamitzIV.pdf"
just now and it kept the midi file in the PDF directory. Sigh.

This slight adaptation of the pattern rule does what you want.


%.pdf %.midi: %.ly
        $(LILY_CMD) $<; \
        if test -f "$*.pdf"; then \
          mv "$*.pdf" PDF/; \
        fi; \
        if test -f "$*.midi"; then \
          mv "$*.midi" MIDI/; \
        fi


   Werner


Thanks, Werner.  That works perfectly. :)

I've add that to the file, as well as one final target:

archive:
        tar -cvvf stamitz.tar \
        --exclude=*pdf --exclude=*~ \
        --exclude=*midi --exclude=*.tar \
        ../Stamitz/*


Jon
--
Jonathan Kulp
http://www.jonathankulp.com




reply via email to

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