summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
author11rcombs <rodger.combs@gmail.com>2014-01-26 18:14:53 -0600
committer11rcombs <rodger.combs@gmail.com>2014-01-26 18:14:53 -0600
commitc933a8ee96cd2a6bb0219df126a725e03f041665 (patch)
tree518b7ec10c52dd271e58fa7beebebc88d059438b /configure.ac
parent0270668b51a37e7632a79fee22cb783bfce71571 (diff)
downloadlibass-c933a8ee96cd2a6bb0219df126a725e03f041665.tar.bz2
libass-c933a8ee96cd2a6bb0219df126a725e03f041665.tar.xz
Check for YASM in configure
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac27
1 files changed, 19 insertions, 8 deletions
diff --git a/configure.ac b/configure.ac
index f7e6527..c623c09 100644
--- a/configure.ac
+++ b/configure.ac
@@ -46,17 +46,10 @@ AC_ARG_ENABLE([fontconfig], AS_HELP_STRING([--disable-fontconfig],
AC_ARG_ENABLE([harfbuzz], AS_HELP_STRING([--disable-harfbuzz],
[disable HarfBuzz support @<:@default=check@:>@]))
AC_ARG_ENABLE([asm], AS_HELP_STRING([--disable-asm],
- [disable compiling with ASM @<:@default=enabled@:>@]),
+ [disable compiling with ASM @<:@default=check@:>@]),
[asm=false],
[asm=true])
-AM_CONDITIONAL([ASM], [test x$asm = xtrue])
-
-AM_COND_IF([ASM],
- [AC_DEFINE(CONFIG_ASM, 1, [ASM enabled])],
- [AC_DEFINE(CONFIG_ASM, 0, [ASM disabled])]
- )
-
test "${ASFLAGS+set}" = set || ASFLAGS=""
AC_SUBST([ASFLAGS], ["$ASFLAGS"])
@@ -83,6 +76,24 @@ case $host in
WIN32=true ;;
esac
+if test x$INTEL = xtrue ; then
+ if test x$asm = xtrue ; then
+ AC_CHECK_PROG(YASM_CHECK,yasm,yes)
+ if test x$YASM_CHECK != xyes ; then
+ AC_MSG_WARN(YASM was not found; ASM functions are disabled.)
+ AC_MSG_WARN(Install yasm for a significantly faster libass build.)
+ asm=false
+ fi
+ fi
+fi
+
+AM_CONDITIONAL([ASM], [test x$asm = xtrue])
+
+AM_COND_IF([ASM],
+ [AC_DEFINE(CONFIG_ASM, 1, [ASM enabled])],
+ [AC_DEFINE(CONFIG_ASM, 0, [ASM enabled])]
+ )
+
AM_CONDITIONAL([INTEL], [test x$INTEL = xtrue])
AM_CONDITIONAL([X86], [test x$X86 = xtrue])
AM_CONDITIONAL([X64], [test x$X64 = xtrue])