On the master branch @ 10dab907e73ba984deb813e20f6e3fc9ec359a17, the x86_64 assembly check in both the Autotools and CMake build systems can fail depending on externally provided flags. For example:
$ env CFLAGS="-Wall -Werror" ./configure --with-asm=x86_64
<snip>
checking for x86_64 assembly availability... no
configure: error: x86_64 assembly requested but not available
or
$ env CFLAGS="-Wall -Werror" cmake -B build -DSECP256K1_ASM=x86_64
<snip>
-- Performing Test HAVE_X86_64_ASM
-- Performing Test HAVE_X86_64_ASM - Failed
CMake Error at CMakeLists.txt:111 (message):
x86_64 assembly requested but not available.
-- Configuring incomplete, errors occurred!
The same issue occurs in CI jobs that build on Windows using clang-cl.
This PR fixes both build systems.