configure.ac: add macro MPD_DEFINE_CONDITIONAL

This commit is contained in:
Max Kellermann
2014-12-21 23:25:48 +01:00
parent 7afe63aa06
commit 373706c92b
3 changed files with 46 additions and 86 deletions

View File

@@ -0,0 +1,8 @@
dnl Wrapper for AC_DEFINE and AM_CONDITIONAL
dnl
dnl Parameters: varname1, varname2, description
AC_DEFUN([MPD_DEFINE_CONDITIONAL], [dnl
AM_CONDITIONAL($2, test x$[]$1 = xyes)
if test x$[]$1 = xyes; then
AC_DEFINE($2, 1, [Define to enable $3])
fi])