Skip to content

Commit 2ae6471

Browse files
author
Maxim Egorushkin
committed
Update meson.build.
1 parent 71ac6ca commit 2ae6471

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

meson.build

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
project(
66
'atomic_queue', 'cpp',
77
license : 'MIT License',
8-
default_options : ['cpp_std=gnu++14', 'buildtype=release', 'b_ndebug=if-release']
8+
default_options : ['cpp_std=c++14', 'buildtype=release', 'b_ndebug=if-release']
99
)
1010

1111
threads_dep = dependency('threads')
@@ -15,6 +15,7 @@ atomic_queue_dep = declare_dependency(include_directories : ['include'], depende
1515
if get_option('tests')
1616
unit_test_framework_dep = dependency('boost', modules : ['unit_test_framework'])
1717

18+
# Tests still compile with C++14, but benchmarks and example require C++17.
1819
tests_exe = executable(
1920
'tests',
2021
'src/tests.cc',
@@ -26,6 +27,7 @@ if get_option('tests')
2627
'example',
2728
'src/example.cc',
2829
dependencies : [atomic_queue_dep],
30+
cpp_args: ['-std=c++17']
2931
)
3032
test('example', example_exe)
3133
endif
@@ -48,6 +50,7 @@ if get_option('benchmarks')
4850
['src/benchmarks.cc', 'src/cpu_base_frequency.cc', 'src/huge_pages.cc'],
4951
include_directories : ['src'],
5052
dependencies : [atomic_queue_dep, dl_dep, xenium_dep, boost_dep, tbb_dep, moodycamel_dep],
53+
cpp_args: ['-std=c++17']
5154
)
5255
benchmark('benchmarks', benchmarks_exe)
5356
endif
@@ -65,6 +68,6 @@ install_headers(
6568
pkg = import('pkgconfig')
6669
pkg.generate(
6770
name: 'atomic_queue',
68-
description: 'C++14 multiple-producer-multiple-consumer lock-free queues based on circular buffers',
71+
description: 'C++14 concurrent lock-free low-latency queue',
6972
libraries: [threads_dep]
7073
)

0 commit comments

Comments
 (0)