[libpng15] Fixed PNG_ALIGN(ED)_MEMORY and add ability to turn off ARM_NEON

runtime checks
This commit is contained in:
John Bowler
2013-02-19 10:20:06 -06:00
committed by Glenn Randers-Pehrson
parent 1b69de718e
commit d19ad72e28
7 changed files with 73 additions and 32 deletions

View File

@@ -172,15 +172,22 @@ AC_SUBST([binconfigs])
AC_SUBST([AM_CCASFLAGS], [-Wa,--noexecstack])
AC_ARG_ENABLE([arm-neon],
AC_HELP_STRING([--enable-arm-neon], [Enable ARM NEON optimizations]),
[if test "${enableval}" = yes; then
AC_DEFINE([PNG_FILTER_OPTIMIZATIONS],
[png_init_filter_functions_neon],
[ARM NEON filter initialization function])
AC_DEFINE([PNG_ALIGNED_MEMORY_SUPPORTED], [1],
[Align row buffers])
fi])
AM_CONDITIONAL([PNG_ARM_NEON], [test "${enable_arm_neon:-no}" = yes])
AS_HELP_STRING([[[--enable-arm-neon]]],
[Enable ARM NEON optimizations: use 'always' to turn off run-time checks]),
[if test "${enableval}" = "yes" -o "${enableval}" = "always"; then
AC_DEFINE([PNG_FILTER_OPTIMIZATIONS],
[png_init_filter_functions_neon],
[ARM NEON filter initialization function])
AC_DEFINE([PNG_ALIGNED_MEMORY_SUPPORTED], [1],
[Align row buffers])
if test "${enableval}" = "always"; then
AC_DEFINE([PNG_NO_ARM_NEON_CHECK], [],
[Turn off run-time checking for ARM NEON support])
fi
fi])
AM_CONDITIONAL([PNG_ARM_NEON], [test "${enable_arm_neon:-no}" != "no"])
AC_MSG_NOTICE([[Extra options for compiler: $PNG_COPTS]])
# Config files, substituting as above
AC_CONFIG_FILES([Makefile libpng.pc:libpng.pc.in])