X-Git-Url: https://tinc-vpn.org/git/browse?a=blobdiff_plain;f=src%2Fmeson.build;h=b1796af2a9a8228f9cf04960a4c0c000e7cea76d;hb=0530bf8704f92e9741d969d6576bf8e2bbf026be;hp=e37c2db0d4c38f648cf298ffdac9e232ec2bed26;hpb=33f0918cde36accb606271c379bc8e75973e9d59;p=tinc diff --git a/src/meson.build b/src/meson.build index e37c2db0..b1796af2 100644 --- a/src/meson.build +++ b/src/meson.build @@ -15,6 +15,14 @@ foreach attr : ['malloc', 'nonnull', 'warn_unused_result'] cc.has_function_attribute(attr) endforeach +if cc.compiles(''' + _Static_assert(1, "ok"); + int main(void) { return 0; } +''') + cdata.set('HAVE_STATIC_ASSERT', 1, + description: 'C11 _Static_assert()') +endif + check_headers = [ 'alloca.h', 'arpa/inet.h',