[2] | 1 | # This file is part of MKF. |
---|
| 2 | # |
---|
| 3 | # MKF is free software; you can redistribute it and/or modify |
---|
| 4 | # it under the terms of the GNU General Public License as published by |
---|
| 5 | # the Free Software Foundation; either version 2 of the License, or |
---|
| 6 | # (at your option) any later version. |
---|
| 7 | # |
---|
| 8 | # MKF is distributed in the hope that it will be useful, |
---|
| 9 | # but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
| 10 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
| 11 | # GNU General Public License for more details. |
---|
| 12 | # |
---|
| 13 | # You should have received a copy of the GNU General Public License |
---|
| 14 | # along with MKF; if not, write to the Free Software |
---|
| 15 | # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
---|
| 16 | # |
---|
| 17 | # Copyright (c) 2004 Alexandre Becoulet <alexandre.becoulet@epita.fr> |
---|
| 18 | |
---|
| 19 | _if_var_eq cmd_pdflatex |
---|
| 20 | var_define cmd_pdflatex pdflatex |
---|
| 21 | _end_if |
---|
| 22 | |
---|
| 23 | _if_in_path {PVAR,cmd_pdflatex} |
---|
| 24 | |
---|
| 25 | msg_info pdflatex ({PVAR,cmd_pdflatex}) found |
---|
| 26 | var_define use_pdflatex pdflatex |
---|
| 27 | |
---|
| 28 | _if_var_eq mkf_pretty_print yes |
---|
| 29 | command_add tex pdf echo " LATEX (pdf) {SRC,.*\.c} -> {OUT}" |
---|
| 30 | _end_if |
---|
| 31 | command_add tex pdf {PVAR,cmd_pdflatex} {JVAR,opt_pdflatex} {SRC,.*\.tex} |
---|
| 32 | |
---|
| 33 | _else |
---|
| 34 | msg_error can't find pdflatex |
---|
| 35 | _end_if |
---|
| 36 | |
---|
| 37 | _if_var_eq cmd_dia |
---|
| 38 | var_define cmd_dia dia |
---|
| 39 | _end_if |
---|
| 40 | |
---|
| 41 | _if_in_path {PVAR,cmd_dia} |
---|
| 42 | |
---|
| 43 | msg_info dia ({PVAR,cmd_dia}) found |
---|
| 44 | var_define use_dia dia |
---|
| 45 | |
---|
| 46 | _if_var_eq mkf_pretty_print yes |
---|
| 47 | command_add dia eps echo " DIA (to eps) {SRC,.*\.dia} -> {OUT}" |
---|
| 48 | _end_if |
---|
| 49 | command_add dia eps dia -n -t eps {SRC,.*\.dia} >& /dev/null |
---|
| 50 | |
---|
| 51 | _else |
---|
| 52 | msg_error can't find dia |
---|
| 53 | _end_if |
---|
| 54 | |
---|
| 55 | _if_var_eq cmd_epstopdf |
---|
| 56 | var_define cmd_epstopdf epstopdf |
---|
| 57 | _end_if |
---|
| 58 | |
---|
| 59 | _if_in_path {PVAR,cmd_epstopdf} |
---|
| 60 | |
---|
| 61 | msg_info epstopdf ({PVAR,cmd_epstopdf}) found |
---|
| 62 | var_define use_epstopdf epstopdf |
---|
| 63 | |
---|
| 64 | command_add eps pdf epstopdf {SRC,.*\.eps} --outfile={OUT} >& /dev/null |
---|
| 65 | _if_var_eq mkf_pretty_print yes |
---|
| 66 | command_add eps pdf echo " EPSTOPDF {SRC,.*\.eps} -> {OUT}" |
---|
| 67 | _end_if |
---|
| 68 | |
---|
| 69 | _else |
---|
| 70 | msg_error can't find epstopdf |
---|
| 71 | _end_if |
---|
| 72 | |
---|