meson: use _BSD_SOURCE for checking for symbols

pull/241/head
Ariadne Conill 2022-02-21 04:39:49 -06:00
parent ac964d13f3
commit cc4ccc1429
1 changed files with 1 additions and 1 deletions

View File

@ -16,7 +16,7 @@ check_functions = [
]
foreach f : check_functions
if cc.has_function(f.get(1), prefix : '#include <' + f.get(2) + '>') and cc.has_header_symbol(f.get(2), f.get(1))
if cc.has_function(f.get(1), prefix : '#define _BSD_SOURCE\n#include <' + f.get(2) + '>') and cc.has_header_symbol(f.get(2), f.get(1), prefix : '#define _BSD_SOURCE')
cdata.set(f.get(0), 1)
endif
endforeach