mirror of
https://github.com/wolfpld/tracy
synced 2025-05-02 21:53:52 +00:00
detect MSVC usage
previous check tested for compiler ID, fixed the detection to an specific MSVC macro and the current C++ version so it does not override an user specified version
This commit is contained in:
parent
45c4dc5124
commit
b48ab72cf0
@ -1,4 +1,4 @@
|
|||||||
project('tracy', ['cpp'], version: '0.11.0', meson_version: '>=1.1.0')
|
project('tracy', ['cpp'], version: '0.11.1', meson_version: '>=1.3.0', default_options : ['cpp_std=c++11'])
|
||||||
|
|
||||||
# internal compiler flags
|
# internal compiler flags
|
||||||
tracy_compile_args = []
|
tracy_compile_args = []
|
||||||
@ -189,8 +189,9 @@ tracy_public_include_dirs = include_directories('public')
|
|||||||
|
|
||||||
compiler = meson.get_compiler('cpp')
|
compiler = meson.get_compiler('cpp')
|
||||||
override_options = []
|
override_options = []
|
||||||
if compiler.get_id() != 'msvc' and compiler.get_id() != 'clang-cl'
|
# MSVC c++ lib does not work properly with C++11 and compilation may fail
|
||||||
override_options += 'cpp_std=c++11'
|
if compiler.has_define('_MSC_VER') and get_option('cpp_std') == 'c++11'
|
||||||
|
override_options += 'cpp_std=c++14'
|
||||||
endif
|
endif
|
||||||
|
|
||||||
tracy_compile_args += tracy_common_args
|
tracy_compile_args += tracy_common_args
|
||||||
|
Loading…
x
Reference in New Issue
Block a user