aboutsummaryrefslogtreecommitdiffstats
path: root/m4
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2009-03-28 21:48:07 +0100
committerMax Kellermann <max@duempel.org>2009-03-28 21:48:07 +0100
commit87e0b1adc48557af5a469a38d65a4e3c2d6a7637 (patch)
treee16509788bdf2acd66bf843cdaf47ee40e736335 /m4
parent33aeac4fcbc1f7a53304d1677b5ac01bb4ce3766 (diff)
downloadmpd-87e0b1adc48557af5a469a38d65a4e3c2d6a7637.tar.gz
mpd-87e0b1adc48557af5a469a38d65a4e3c2d6a7637.tar.xz
mpd-87e0b1adc48557af5a469a38d65a4e3c2d6a7637.zip
configure.ac: added M4 function MPD_AUTO_PKG() for ALSA
MPD_AUTO_PKG() runs pkg-config and then forwards control to MPD_AUTO_RESULT(). This is a commonly used short cut.
Diffstat (limited to 'm4')
-rw-r--r--m4/mpd_auto.m410
1 files changed, 10 insertions, 0 deletions
diff --git a/m4/mpd_auto.m4 b/m4/mpd_auto.m4
index 635f41560..58ea63796 100644
--- a/m4/mpd_auto.m4
+++ b/m4/mpd_auto.m4
@@ -38,3 +38,13 @@ AC_DEFUN([MPD_AUTO_RESULT], [
MPD_AUTO_DISABLED([$name], [$feature], [$msg])
fi
])
+
+AC_DEFUN([MPD_AUTO_PKG], [
+ if eval "test x`echo '$'enable_$1` != xno"; then
+ PKG_CHECK_MODULES([$2], [$3],
+ [eval "found_$1=yes"],
+ [eval "found_$1=no"])
+ fi
+
+ MPD_AUTO_RESULT([$1], [$4], [$5])
+])