1 --- systemd-236.orig/meson.build 2017-12-14 23:09:57.000000000 +0100
2 +++ systemd-236/meson.build 2018-01-01 21:03:50.570757021 +0100
3 @@ -260,10 +260,12 @@ cc = meson.get_compiler('c')
4 pkgconfig = import('pkgconfig')
5 check_compilation_sh = find_program('tools/meson-check-compilation.sh')
7 -cxx = find_program('c++', required : false)
9 - # Used only for tests
10 - add_languages('cpp')
11 +if get_option('tests') != 'false'
12 + cxx = find_program('c++', required : false)
14 + # Used only for tests
15 + add_languages('cpp')
19 foreach arg : ['-Wextra',
20 @@ -2388,48 +2390,51 @@ executable('systemd-sulogin-shell',
21 install_dir : rootlibexecdir)
23 ############################################################
24 +if want_tests == 'false'
25 + message('Not compiling because tests is set to false')
27 + foreach tuple : tests
29 + link_with = tuple[1].length() > 0 ? tuple[1] : [libshared]
30 + dependencies = tuple[2]
31 + condition = tuple.length() >= 4 ? tuple[3] : ''
32 + type = tuple.length() >= 5 ? tuple[4] : ''
33 + defs = tuple.length() >= 6 ? tuple[5] : []
34 + incs = tuple.length() >= 7 ? tuple[6] : includes
37 -foreach tuple : tests
39 - link_with = tuple[1].length() > 0 ? tuple[1] : [libshared]
40 - dependencies = tuple[2]
41 - condition = tuple.length() >= 4 ? tuple[3] : ''
42 - type = tuple.length() >= 5 ? tuple[4] : ''
43 - defs = tuple.length() >= 6 ? tuple[5] : []
44 - incs = tuple.length() >= 7 ? tuple[6] : includes
47 - name = sources[0].split('/')[-1].split('.')[0]
48 - if type.startswith('timeout=')
49 - timeout = type.split('=')[1].to_int()
52 + name = sources[0].split('/')[-1].split('.')[0]
53 + if type.startswith('timeout=')
54 + timeout = type.split('=')[1].to_int()
58 - if condition == '' or conf.get(condition) == 1
62 - include_directories : incs,
63 - link_with : link_with,
64 - dependencies : dependencies,
66 - install_rpath : rootlibexecdir,
67 - install : install_tests,
68 - install_dir : join_paths(testsdir, type))
69 + if condition == '' or conf.get(condition) == 1
73 + include_directories : incs,
74 + link_with : link_with,
75 + dependencies : dependencies,
77 + install_rpath : rootlibexecdir,
78 + install : install_tests,
79 + install_dir : join_paths(testsdir, type))
82 - message('@0@ is a manual test'.format(name))
83 - elif type == 'unsafe' and want_tests != 'unsafe'
84 - message('@0@ is an unsafe test'.format(name))
86 + message('@0@ is a manual test'.format(name))
87 + elif type == 'unsafe' and want_tests != 'unsafe'
88 + message('@0@ is an unsafe test'.format(name))
98 + message('Not compiling @0@ because @1@ is not true'.format(name, condition))
101 - message('Not compiling @0@ because @1@ is not true'.format(name, condition))
107 test_libsystemd_sym = executable(
108 'test-libsystemd-sym',