I tested that older compilers don't refuse this option:
- gcc 4.8 (as that's the default in CentOS 7)
- llvm 3.8 (year 2016 is enough, I hope)
'-Werror=implicit-function-declaration', # Probably messed up includes; implicit functions are evil!
'-fvisibility=hidden',
'-DHAVE_ASPRINTF=' + have_asprintf.to_int().to_string(),
+
+ # libuv handles have aliasing problems; see:
+ # https://github.com/libuv/libuv/pull/2588/files#diff-04c6e90faac2675aa89e2176d2eec7d8
+ # https://github.com/libuv/libuv/issues/1230#issuecomment-569030944
+ # Performance impact in our case seems OK:
+ # https://gitlab.labs.nic.cz/knot/knot-resolver/-/merge_requests/962#note_147407
+ '-fno-strict-aliasing',
+
language: 'c',
)