Alper Nebi Yasak 73aed233b2 meson: Use neon_opt to control building neon files
Using the have_neon boolean to enable NEON code means we have to either
fully enable it or fully disable it. When using -Dneon=runtime, ideally
only the parts that support runtime checks would be built for NEON, and
those that don't would be built without NEON. Though, there are no
longer any runtime checks for NEON anywhere, so it's equivalent to 'no'
with a warning.

In general, we should use have_* variables to indicate compiler support,
and *_opt options to choose if and how we want to utilize that. Use
neon_opt to control NEON compilation and avoid modifying have_neon which
now would fully refer to compiler support.

Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
2024-12-30 14:18:44 -05:00

22 lines
482 B
Meson

pffft_sources = [
'src/pffft.c',
]
pffft_cflags = [ '-D_GNU_SOURCE' ]
if not have_inline_sse or (have_arm and neon_opt != 'yes') or (have_mips and host_machine.endian() == 'little') or have_mips64
pffft_cflags += [ '-DPFFFT_SIMD_DISABLE' ]
endif
libpffft = static_library('libpffft',
pffft_sources,
dependencies: common_deps,
include_directories: webrtc_inc,
c_args : common_cflags + pffft_cflags
)
pffft_dep = declare_dependency(
link_with: libpffft
)