From 308f215fc3dd5f94cbc5d7ad664c50e3d005a114 Mon Sep 17 00:00:00 2001 From: Thulinma Date: Wed, 4 Jan 2023 02:06:27 +0100 Subject: [PATCH] Fix Mac builds in Meson Change-Id: I973208fc9bebcd593dee81841f6e125b589c8fea --- meson.build | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/meson.build b/meson.build index 79bfc7d3..c5fa7869 100644 --- a/meson.build +++ b/meson.build @@ -1,4 +1,4 @@ -project('mistserver', 'cpp', default_options: ['cpp_std=gnu++03']) +project('mistserver', 'cpp', default_options: ['cpp_std=c++98']) add_project_arguments(['-funsigned-char', '-D_LARGEFILE_SOURCE','-Wno-sign-compare', '-Wparentheses', '-Wno-non-virtual-dtor', '-Wno-strict-aliasing'], language: 'cpp') # Ensures the "mist" directory is in the include path @@ -50,7 +50,7 @@ option_defines = [ int_opt.format('UDP_API_PORT', get_option('UDP_API_PORT')), ] -if not get_option('NOSHM') +if not get_option('NOSHM') and host_machine.system() != 'darwin' option_defines += '-DSHM_ENABLED=1' else message('Shared memory use is turned OFF') @@ -134,10 +134,10 @@ if usessl endif libsrt = false -if not get_option('NOSRT') +if not get_option('NOSRT') and host_machine.system() != 'darwin' libsrt = dependency('srt', fallback: ['libsrt', 'srt_dep']) endif -have_srt = not get_option('NOSRT') and libsrt.found() +have_srt = not get_option('NOSRT') and host_machine.system() != 'darwin' and libsrt.found() librist = false if not get_option('NORIST') @@ -149,7 +149,7 @@ have_librist = not get_option('NORIST') and librist.found() mist_deps += dependency('threads') # Add rt dependency when using shared memory -if not get_option('NOSHM') +if not get_option('NOSHM') and host_machine.system() != 'darwin' mist_deps += ccpp.find_library('rt', required : true) endif