meson: Fix oss4 header checks

Otherwise, oss4 ends up getting built when force-disabled.
This commit is contained in:
Nirbheek Chauhan 2018-08-01 03:18:58 +05:30
parent 1c645f83f6
commit 248342f942

View file

@ -1,13 +1,12 @@
have_oss4 = true have_oss4 = false
oss4_option = get_option('oss4') oss4_option = get_option('oss4')
if not oss4_option.disabled() if not oss4_option.disabled()
have_oss4 = true
message('Checking headers needed for Open Sound System 4 plugin...') message('Checking headers needed for Open Sound System 4 plugin...')
foreach hdr : ['fcntl.h', 'sys/ioctl.h', 'sys/stat.h', 'sys/types.h'] foreach hdr : ['fcntl.h', 'sys/ioctl.h', 'sys/stat.h', 'sys/types.h']
if have_oss4 if have_oss4 and not cc.has_header(hdr)
if not cc.has_header(hdr)
have_oss4 = false have_oss4 = false
endif endif
endif
endforeach endforeach
if not have_oss4 and oss4_option.enabled() if not have_oss4 and oss4_option.enabled()