scsh-make/examples/makefile-tex.scm

41 lines
1.1 KiB
Scheme
Raw Normal View History

2005-02-15 13:42:14 -05:00
(define clean-files
(list "manual.dvi" "manual.pdf" "manual.ps" "manual.log" "manual.aux"
"another-manual.dvi" "another-manual.ps" "another-manual.pdf"))
(define file-set
(makefile
(once "manual.dvi"
("manual.tex")
(run (latex ,($<))))
(file "manual.pdf"
("manual.dvi")
(run (dvipdfm -o ,($@) ,($<))))
(file "manual.ps"
("manual.dvi")
(run (dvips -o ,($@) ,($<))))
(file "another-manual.dvi"
("manual.dvi")
(create-symlink ($<) ($@)))
(file "another-manual.ps"
("another-manual.dvi")
(run (dvips -o ,($@) ,($<))))
(file "another-manual.pdf"
("another-manual.dvi")
(run (dvipdfm -o ,($@) ,($<))))
;;
;; fake install
;;
(always "install"
("manual.ps" "manual.dvi" "manual.pdf"
"another-manual.dvi" "another-manual.ps" "another-manual.pdf")
(for-each (lambda (f) (display ">>> ") (display f) (newline)) ($+))
(display "install done.\n"))
;;
;; clean files
;;
(always "clean"
()
(for-each (lambda (f)
(delete-filesys-object (expand-file-name f (cwd))))
clean-files))))