Meson WrapDB for Google's cityhash.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

meson.build 764B

123456789101112131415161718192021222324
  1. conf = configuration_data()
  2. cc = meson.get_compiler('cpp')
  3. if cc.links('int main(){if(__builtin_expect(1<0,0)){}}', name: '__builtin_expect')
  4. conf.set('HAVE_BUILTIN_EXPECT', 1)
  5. endif
  6. foreach include : ['dlfcn', 'inttypes', 'memory', 'stdint', 'stdlib', 'strings', 'string', 'sys/stat', 'sys/types', 'unistd']
  7. conf.set10('HAVE_' + include.underscorify().to_upper() + '_H', cc.has_header(include + '.h'))
  8. endforeach
  9. # use stdio.h as a proxy for all ANSI C header files
  10. conf.set('STDC_HEADERS', cc.has_header('stdio.h'))
  11. if build_machine.endian() == 'big'
  12. conf.set('WORDS_BIGENDIAN', 1)
  13. endif
  14. if not cc.links('inline void foo() {} int main() { foo(); }', name: 'inline')
  15. conf.set('inline', '')
  16. endif
  17. configure_file(output: 'config.h', configuration: conf)