| 1 |
# Private macros for the TeX Live (TL) tree. |
| 2 |
# Copyright (C) 2011 Peter Breitenlohner <[email protected]> |
| 3 |
# |
| 4 |
# This file is free software; the copyright holder |
| 5 |
# gives unlimited permission to copy and/or distribute it, |
| 6 |
# with or without modifications, as long as this notice is preserved. |
| 7 |
|
| 8 |
# KPSE_MKTEX_PREPARE |
| 9 |
# ------------------ |
| 10 |
# AC_DEFUN'ed so it can enforce inclusion of this file. |
| 11 |
AC_DEFUN([KPSE_MKTEX_PREPARE], []) |
| 12 |
|
| 13 |
# KPSE_WITH_MKTEX(PROG, YES-OR-NO, TEXT, STEM) |
| 14 |
# -------------------------------------------- |
| 15 |
# Provide configure options --enable-mktex*-default and normalize result. |
| 16 |
m4_define([KPSE_WITH_MKTEX], |
| 17 |
[AC_ARG_ENABLE([$1-default], |
| 18 |
AS_HELP_STRING([--]m4_if([$2], [yes], [dis], [en])[able-$1-default], |
| 19 |
m4_if([$2], [yes], |
| 20 |
[do not ])[run $1 if $3 missing], |
| 21 |
m4_eval(kpse_indent_26+2)))[]dnl |
| 22 |
]) # KPSE_WITH_MKTEX |
| 23 |
|
| 24 |
# KPSE_MKTEX_DEFINE(PROG, YES-OR-NO, TEXT, STEM) |
| 25 |
# ---------------------------------------------- |
| 26 |
# Normalize --enable-mktex*-default configure option and build defines. |
| 27 |
m4_define([KPSE_MKTEX_DEFINE], |
| 28 |
[AS_CASE([$enable_$1_default], |
| 29 |
[yes | no], , |
| 30 |
[enable_$1_default=$2]) |
| 31 |
AS_IF([test "x$enable_$1_default" = xyes], |
| 32 |
[AC_DEFINE([MAKE_$4_BY_DEFAULT], 1, |
| 33 |
[Define to 1 if you want to run $1 if $3 is missing, |
| 34 |
and to 0 if you don't])], |
| 35 |
[AC_DEFINE([MAKE_$4_BY_DEFAULT], 0)]) |
| 36 |
]) # KPSE_MKTEX_DEFINE |