Commit 4516ba97 authored by Peter Seiderer's avatar Peter Seiderer Committed by Peter Hutterer
Browse files

meson.build: enable CPP include check only in case CPP compiler is available



Drop hard meson C++/CPP dependency, only needed for the build-time
header inclusion test, build the test only in case C++/CPP compiler
is available.
Signed-off-by: Peter Seiderer's avatarPeter Seiderer <ps.report@gmx.net>
Signed-off-by: Peter Hutterer's avatarPeter Hutterer <peter.hutterer@who-t.net>
parent fc029e3f
Pipeline #14966 passed with stages
in 29 minutes and 3 seconds
project('libinput', 'c', 'cpp', project('libinput', 'c',
version : '1.12.3', version : '1.12.3',
license : 'MIT/Expat', license : 'MIT/Expat',
default_options : [ 'c_std=gnu99', 'warning_level=2' ], default_options : [ 'c_std=gnu99', 'warning_level=2' ],
...@@ -651,12 +651,14 @@ executable('test-build-linker', ...@@ -651,12 +651,14 @@ executable('test-build-linker',
include_directories : [includes_src, includes_include], include_directories : [includes_src, includes_include],
dependencies : [ dep_libinput, dep_libinput_util ], dependencies : [ dep_libinput, dep_libinput_util ],
install : false) install : false)
# test including from C++ # test including from C++ (in case CPP compiler is available)
executable('test-build-cxx', if add_languages('cpp', required: false)
'test/build-cxx.cc', executable('test-build-cxx',
dependencies : [dep_udev], 'test/build-cxx.cc',
include_directories : [includes_src, includes_include], dependencies : [dep_udev],
install : false) include_directories : [includes_src, includes_include],
install : false)
endif
# This is the test suite runner, we allow disabling that one because of # This is the test suite runner, we allow disabling that one because of
# dependencies # dependencies
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment