meson: Fix nasm detection
meson: Fix nasm detection

nasm -v can actually fail for example on macOS, where nasm could be a
stub executable that forwards commands to the real nasm, but if the real
nasm is not installed, fails.
This would lead to a confusing error message due to the out of bounds
array access, to avoid that, explicitly check the exit code.

videolan/dav1d