Mercurial > audlegacy-plugins
comparison acinclude.m4 @ 2713:182dd0f45cc7
Synchronize acinclude.m4.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Mon, 16 Jun 2008 14:16:06 +0300 |
parents | e48338bffeef |
children | b52eee8523d5 |
comparison
equal
deleted
inserted
replaced
2712:5eef9a0818ab | 2713:182dd0f45cc7 |
---|---|
46 | 46 |
47 | 47 |
48 dnl ** Simple wrapper for AC_ARG_ENABLE | 48 dnl ** Simple wrapper for AC_ARG_ENABLE |
49 dnl ** AUD_ARG_ENABLE([name], [default value], [help string], [if enabled], [if disabled]) | 49 dnl ** AUD_ARG_ENABLE([name], [default value], [help string], [if enabled], [if disabled]) |
50 AC_DEFUN([AUD_ARG_ENABLE], [dnl | 50 AC_DEFUN([AUD_ARG_ENABLE], [dnl |
51 define([Name], [translit([$1], [./-], [___])]) | 51 # _A_ARG_ENABLE($1, $2, $3, $4, $5) |
52 AC_ARG_ENABLE([$1], [$3],, [enable_[]Name=$2]) | 52 define([Name], [translit([$1], [./-], [___])])dnl |
53 AC_ARG_ENABLE([$1], [AS_HELP_STRING([ifelse([$2],[yes],[--disable-$1],[--enable-$1])], [$3])],, [enable_[]Name=$2]) | |
53 if test "x${enable_[]Name}" = "xyes"; then | 54 if test "x${enable_[]Name}" = "xyes"; then |
54 m4_ifvaln([$4], [$4], [:])dnl | 55 m4_ifvaln([$4], [$4], [:])dnl |
55 m4_ifvaln([$5], [else $5])dnl | 56 m4_ifvaln([$5], [else $5])dnl |
56 fi | 57 fi |
57 ]) | 58 ]) |
58 | 59 |
59 | 60 |
60 AC_DEFUN([AUD_ARG_SIMPLE], [dnl | 61 AC_DEFUN([AUD_ARG_SIMPLE], [dnl |
61 define([Name], [translit([$1], [./-], [___])]) | 62 # _A_ARG_SIMPLE($1, $2, $3, $4, $5, $6) |
62 AC_ARG_ENABLE([$1], [$3],, [enable_[]Name=$2]) | 63 define([Name], [translit([$1], [./-], [___])])dnl |
64 AC_ARG_ENABLE([$1], [AS_HELP_STRING([ifelse([$2],[yes],[--disable-$1],[--enable-$1])], [$3])],, [enable_[]Name=$2]) | |
63 if test "x${enable_[]Name}" = "xyes"; then | 65 if test "x${enable_[]Name}" = "xyes"; then |
64 AC_DEFINE([$4], [$5], [$6]) | 66 AC_DEFINE([$4], [$5], [$6]) |
65 fi | 67 fi |
66 AUD_CONDITIONAL([$4], [enable_$1]) | 68 AUD_CONDITIONAL([$4], [enable_$1]) |
67 AC_SUBST([$4]) | 69 AC_SUBST([$4]) |
95 if test "x$cv_gnu_make_command" != "x" ; then | 97 if test "x$cv_gnu_make_command" != "x" ; then |
96 MAKE="$cv_gnu_make_command" | 98 MAKE="$cv_gnu_make_command" |
97 else | 99 else |
98 AC_MSG_ERROR([** GNU make not found. If it is installed, try setting MAKE environment variable. **]) | 100 AC_MSG_ERROR([** GNU make not found. If it is installed, try setting MAKE environment variable. **]) |
99 fi | 101 fi |
100 AC_SUBST([MAKE]) | 102 AC_SUBST([MAKE])dnl |
101 ]) | 103 ])dnl |
102 | 104 |
103 | 105 |
104 dnl *** Define plugin directories | 106 dnl *** Define plugin directories |
105 AC_DEFUN([AUD_DEFINE_PLUGIN_DIR],[ | 107 AC_DEFUN([AUD_DEFINE_PLUGIN_DIR],[dnl |
106 define([Name], [translit([$1], [a-z], [A-Z])])dnl | 108 define([Name], [translit([$1], [a-z], [A-Z])])dnl |
107 if test "x$enable_one_plugin_dir" = "xyes"; then | 109 if test "x$enable_one_plugin_dir" = "xyes"; then |
108 ifdef([aud_plugin_dirs_defined],[], | 110 ifdef([aud_plugin_dirs_defined],[], |
109 [ pluginsubs="\\\"Plugins\\\"" | 111 [ pluginsubs="\\\"Plugins\\\"" |
110 ])dnl | 112 ])dnl |
119 define([aud_def_plugin_dirs_defined],[1])dnl | 121 define([aud_def_plugin_dirs_defined],[1])dnl |
120 ])dnl | 122 ])dnl |
121 | 123 |
122 | 124 |
123 dnl *** Get plugin directories | 125 dnl *** Get plugin directories |
124 AC_DEFUN([AUD_GET_PLUGIN_DIR],[ | 126 AC_DEFUN([AUD_GET_PLUGIN_DIR],[dnl |
125 define([Name], [translit([$1_plugin_dir], [A-Z], [a-z])])dnl | 127 define([Name], [translit([$1_plugin_dir], [A-Z], [a-z])])dnl |
126 define([BigName], [translit([$1], [a-z], [A-Z])])dnl | 128 define([BigName], [translit([$1], [a-z], [A-Z])])dnl |
127 ifdef([aud_get_plugin_dirs_defined], | 129 ifdef([aud_get_plugin_dirs_defined], |
128 [pluginsubs="$pluginsubs,\\\"$1\\\""], | 130 [pluginsubs="$pluginsubs,\\\"$1\\\""], |
129 [pluginsubs="\\\"$1\\\""]) | 131 [pluginsubs="\\\"$1\\\""]) |
186 | 188 |
187 | 189 |
188 dnl SSE2 support | 190 dnl SSE2 support |
189 dnl ============ | 191 dnl ============ |
190 AUD_ARG_ENABLE([sse2], [yes], | 192 AUD_ARG_ENABLE([sse2], [yes], |
191 [ --disable-sse2 Disable SSE2 support (def: enabled)], | 193 [Disable SSE2 support (def: enabled)], |
192 [ | 194 [ |
193 AC_MSG_CHECKING([SSE2 support]) | 195 AC_MSG_CHECKING([SSE2 support]) |
194 aud_my_save_CFLAGS="$CFLAGS" | 196 aud_my_save_CFLAGS="$CFLAGS" |
195 CFLAGS="-msse2" | 197 CFLAGS="-msse2" |
196 AC_TRY_RUN([ | 198 AC_TRY_RUN([ |
213 ]) | 215 ]) |
214 | 216 |
215 dnl AltiVec support | 217 dnl AltiVec support |
216 dnl =============== | 218 dnl =============== |
217 AUD_ARG_ENABLE([altivec], [yes], | 219 AUD_ARG_ENABLE([altivec], [yes], |
218 [ --disable-altivec Disable AltiVec support (def: enabled)], | 220 [Disable AltiVec support (def: enabled)], |
219 [ | 221 [ |
220 AC_CHECK_HEADERS([altivec.h], | 222 AC_CHECK_HEADERS([altivec.h], |
221 [ | 223 [ |
222 AC_DEFINE([HAVE_ALTIVEC], 1, [Define to 1 if your system has AltiVec.]) | 224 AC_DEFINE([HAVE_ALTIVEC], 1, [Define to 1 if your system has AltiVec.]) |
223 AC_DEFINE([HAVE_ALTIVEC_H], 1, [Define to 1 if your system has an altivec.h file.]) | 225 AC_DEFINE([HAVE_ALTIVEC_H], 1, [Define to 1 if your system has an altivec.h file.]) |