[libpng17] Make ARM NEON support work at compile time (not just configure time).

This moves the test on __ARM_NEON__ into pngconf.h to avoid issues when
using a compiler that compiles for multiple architectures at one time.
This commit is contained in:
John Bowler
2013-06-06 14:57:14 -05:00
committed by Glenn Randers-Pehrson
parent 30662f5e92
commit b88c94208a
5 changed files with 37 additions and 9 deletions

View File

@@ -165,12 +165,6 @@ logunsupported = 1
@# endif
@#endif
# This changes the default for the ARM NEON optimizations according to
# __ARM_NEON__
@#ifdef __ARM_NEON__
@# define PNG_ARM_NEON_SUPPORTED
@#endif
# IN DEVELOPMENT
# These are currently experimental features; define them if you want (NOTE:
# experimental options must be disabled before they are defined in this file!)
@@ -236,6 +230,8 @@ option SET_OPTION disabled
# These options are specific to the ARM NEON hardware optimizations:
#
# ARM_NEON: the optimization itself
# ARM_NEON_NOT: disable the optimization even on systems that apparently support
# it (where the compiler defines __ARM_NEON__).
# ARM_NEON_API: allow the optimization to be switched on with png_set_hardware
# ARM_NEON_CHECK: compile a run-time check to see if Neon extensions are
setting ZLIB_VERNUM default @ZLIB_VERNUM
@@ -243,6 +239,7 @@ setting ZLIB_VERNUM default @ZLIB_VERNUM
# png_set_hardware API.
option ARM_NEON disabled,
sets FILTER_OPTIMIZATIONS png_init_filter_functions_neon
option ARM_NEON_NOT disabled
option ARM_NEON_API disabled enables SET_OPTION ARM_NEON
option ARM_NEON_CHECK disabled enables ARM_NEON