X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=meson.build;h=9cbf6a7f7e772adb876053746bd71ab5fd89d2a2;hb=0ac84fceb401f513ef8c49bdf05e34419220e5c8;hp=2c3397d673ebbef6359b76a14ffc436817e1a7f5;hpb=855afe01449690e1ed21f9085718551e5ea09bbd;p=mesa.git diff --git a/meson.build b/meson.build index 2c3397d673e..9cbf6a7f7e7 100644 --- a/meson.build +++ b/meson.build @@ -262,6 +262,7 @@ endif with_intel_vk = _vulkan_drivers.contains('intel') with_amd_vk = _vulkan_drivers.contains('amd') with_freedreno_vk = _vulkan_drivers.contains('freedreno') +with_libresoc_vk = _vulkan_drivers.contains('libre-soc') with_swrast_vk = _vulkan_drivers.contains('swrast') with_any_vk = _vulkan_drivers.length() != 0 @@ -427,8 +428,10 @@ else endif # Android uses emutls for versions <= P/28. For USE_ELF_TLS we need ELF TLS. -if not ['windows', 'freebsd'].contains(host_machine.system()) and (not with_platform_android or get_option('platform-sdk-version') >= 29) +use_elf_tls = false +if not ['windows', 'freebsd', 'openbsd'].contains(host_machine.system()) and (not with_platform_android or get_option('platform-sdk-version') >= 29) pre_args += '-DUSE_ELF_TLS' + use_elf_tls = true endif if with_glx != 'disabled' @@ -949,6 +952,8 @@ elif host_machine.system() == 'windows' else pre_args += ['-D__MSVCRT_VERSION__=0x0700'] endif +elif host_machine.system() == 'openbsd' + pre_args += '-D_ISOC11_SOURCE' endif # Check for generic C arguments @@ -1202,7 +1207,7 @@ if not ['linux'].contains(host_machine.system()) endif endif -foreach h : ['xlocale.h', 'linux/futex.h', 'endian.h', 'dlfcn.h', 'execinfo.h', 'sys/shm.h', 'cet.h'] +foreach h : ['xlocale.h', 'linux/futex.h', 'endian.h', 'dlfcn.h', 'execinfo.h', 'sys/shm.h', 'cet.h', 'pthread_np.h'] if cc.check_header(h) pre_args += '-DHAVE_@0@'.format(h.to_upper().underscorify()) endif @@ -1341,12 +1346,6 @@ if dep_thread.found() and host_machine.system() != 'windows' args : '-D_GNU_SOURCE') pre_args += '-DHAVE_PTHREAD_SETAFFINITY' endif - if cc.has_function( - 'pthread_setaffinity_np', - dependencies : dep_thread, - prefix : '#include ') - pre_args += '-DPTHREAD_SETAFFINITY_IN_NP_HEADER' - endif endif if host_machine.system() != 'windows' dep_expat = dependency('expat', fallback : ['expat', 'expat_dep']) @@ -1849,6 +1848,12 @@ if dep_dl.found() gl_priv_libs += '-ldl' endif +# FIXME: autotools lists this as incomplete +gbm_priv_libs = [] +if dep_dl.found() + gbm_priv_libs += '-ldl' +endif + pkg = import('pkgconfig') if host_machine.system() == 'windows'