termux-packages/x11-packages/libxkbcommon/disable_tests.patch

210 lines
6.6 KiB
Diff
Raw Normal View History

2018-09-28 16:14:26 +02:00
diff -uNr libxkbcommon-xkbcommon-0.8.2/meson.build libxkbcommon-xkbcommon-0.8.2.mod/meson.build
--- libxkbcommon-xkbcommon-0.8.2/meson.build 2018-08-05 08:55:39.000000000 +0300
+++ libxkbcommon-xkbcommon-0.8.2.mod/meson.build 2018-09-28 17:13:05.819072368 +0300
@@ -263,205 +263,6 @@
2018-09-10 00:42:26 +02:00
)
endif
-
-# Tests
-test_env = environment()
-test_env.set('XKB_LOG_LEVEL', 'debug')
-test_env.set('XKB_LOG_VERBOSITY', '10')
-test_env.set('top_srcdir', meson.source_root())
-test_env.set('MALLOC_PERTURB_', '15')
-test_env.set('MallocPreScribble', '1')
-test_env.set('MallocScribble', '1')
-# Some tests need to use unexported symbols, so we link them against
-# the internal copy of libxkbcommon with all symbols exposed.
-libxkbcommon_test_internal = static_library(
- 'xkbcommon-test-internal',
- 'test/common.c',
- 'test/test.h',
- 'test/evdev-scancodes.h',
- include_directories: include_directories('src'),
- link_with: libxkbcommon_internal,
-)
-test_dep = declare_dependency(
- include_directories: include_directories('src'),
- link_with: libxkbcommon_test_internal,
-)
2018-09-28 16:14:26 +02:00
-if get_option('enable-x11')
- x11_test_dep = declare_dependency(
- link_with: libxkbcommon_x11_internal,
- dependencies: [
- test_dep,
- xcb_dep,
- xcb_xkb_dep,
- ],
- )
-endif
2018-09-10 00:42:26 +02:00
-test(
- 'keysym',
- executable('test-keysym', 'test/keysym.c', dependencies: test_dep),
- env: test_env,
-)
-test(
- 'keymap',
- executable('test-keymap', 'test/keymap.c', dependencies: test_dep),
- env: test_env,
-)
-test(
- 'filecomp',
- executable('test-filecomp', 'test/filecomp.c', dependencies: test_dep),
- env: test_env,
-)
-test(
- 'context',
- executable('test-context', 'test/context.c', dependencies: test_dep),
- env: test_env,
-)
-test(
- 'rules-file',
- executable('test-rules-file', 'test/rules-file.c', dependencies: test_dep),
- env: test_env,
-)
-test(
- 'stringcomp',
- executable('test-stringcomp', 'test/stringcomp.c', dependencies: test_dep),
- env: test_env,
-)
-test(
- 'buffercomp',
- executable('test-buffercomp', 'test/buffercomp.c', dependencies: test_dep),
- env: test_env,
-)
-test(
- 'log',
- executable('test-log', 'test/log.c', dependencies: test_dep),
- env: test_env,
-)
-test(
- 'atom',
- executable('test-atom', 'test/atom.c', dependencies: test_dep),
- env: test_env,
-)
-test(
- 'utf8',
- executable('test-utf8', 'test/utf8.c', dependencies: test_dep),
- env: test_env,
-)
-test(
- 'state',
- executable('test-state', 'test/state.c', dependencies: test_dep),
- env: test_env,
-)
-test(
- 'keyseq',
- executable('test-keyseq', 'test/keyseq.c', dependencies: test_dep),
- env: test_env,
-)
-test(
- 'rulescomp',
- executable('test-rulescomp', 'test/rulescomp.c', dependencies: test_dep),
- env: test_env,
-)
-test(
- 'compose',
- executable('test-compose', 'test/compose.c', dependencies: test_dep),
- env: test_env,
-)
-test(
- 'symbols-leak-test',
- find_program('test/symbols-leak-test.bash'),
- env: test_env,
-)
-if get_option('enable-x11')
- test(
- 'x11',
2018-09-28 16:14:26 +02:00
- executable('test-x11', 'test/x11.c', dependencies: x11_test_dep),
2018-09-10 00:42:26 +02:00
- env: test_env,
- )
- # test/x11comp is meant to be run, but it is (temporarily?) disabled.
- # See: https://github.com/xkbcommon/libxkbcommon/issues/30
2018-09-28 16:14:26 +02:00
- executable('test-x11comp', 'test/x11comp.c', dependencies: x11_test_dep)
2018-09-10 00:42:26 +02:00
-endif
-
-
2018-09-28 16:14:26 +02:00
-# Fuzzing target programs.
-executable('fuzz-keymap', 'fuzz/keymap/target.c', dependencies: test_dep)
-executable('fuzz-compose', 'fuzz/compose/target.c', dependencies: test_dep)
-
-
2018-09-10 00:42:26 +02:00
-# Demo programs.
-executable('rmlvo-to-kccgst', 'test/rmlvo-to-kccgst.c', dependencies: test_dep)
-executable('print-compiled-keymap', 'test/print-compiled-keymap.c', dependencies: test_dep)
-if cc.has_header('linux/input.h')
- executable('interactive-evdev', 'test/interactive-evdev.c', dependencies: test_dep)
-endif
-if get_option('enable-x11')
2018-09-28 16:14:26 +02:00
- executable('interactive-x11', 'test/interactive-x11.c', dependencies: x11_test_dep)
2018-09-10 00:42:26 +02:00
-endif
-if get_option('enable-wayland')
- wayland_client_dep = dependency('wayland-client', version: '>=1.2.0', required: false)
- wayland_protocols_dep = dependency('wayland-protocols', version: '>=1.7', required: false)
- wayland_scanner_dep = dependency('wayland-scanner', required: false)
- if not wayland_client_dep.found() or not wayland_protocols_dep.found() or not wayland_scanner_dep.found()
- error('''The Wayland demo programs require wayland-client >= 1.2.0, wayland-protocols >= 1.7 which were not found.
-You can disable the Wayland demo programs with -Denable-wayland=false.''')
- endif
-
- wayland_scanner = find_program(wayland_scanner_dep.get_pkgconfig_variable('wayland_scanner'))
- wayland_scanner_code_gen = generator(
- wayland_scanner,
- output: '@BASENAME@-protocol.c',
- arguments: ['code', '@INPUT@', '@OUTPUT@'],
- )
- wayland_scanner_client_header_gen = generator(
- wayland_scanner,
- output: '@BASENAME@-client-protocol.h',
- arguments: ['client-header', '@INPUT@', '@OUTPUT@'],
- )
- wayland_protocols_datadir = wayland_protocols_dep.get_pkgconfig_variable('pkgdatadir')
- xdg_shell_xml = join_paths(wayland_protocols_datadir, 'unstable/xdg-shell/xdg-shell-unstable-v6.xml')
- xdg_shell_sources = [
- wayland_scanner_code_gen.process(xdg_shell_xml),
- wayland_scanner_client_header_gen.process(xdg_shell_xml),
- ]
- executable('interactive-wayland', 'test/interactive-wayland.c', xdg_shell_sources, dependencies: [test_dep, wayland_client_dep])
-endif
-
-
-# Benchmarks.
-libxkbcommon_bench_internal = static_library(
- 'xkbcommon-bench-internal',
- 'bench/bench.c',
- 'bench/bench.h',
- link_with: libxkbcommon_test_internal,
-)
-bench_dep = declare_dependency(
- include_directories: include_directories('src'),
- link_with: libxkbcommon_bench_internal,
-)
-bench_env = environment()
-bench_env.set('top_srcdir', meson.source_root())
-benchmark(
- 'key-proc',
- executable('bench-key-proc', 'bench/key-proc.c', dependencies: bench_dep),
- env: bench_env,
-)
-benchmark(
- 'rules',
- executable('bench-rules', 'bench/rules.c', dependencies: bench_dep),
- env: bench_env,
-)
-benchmark(
- 'rulescomp',
- executable('bench-rulescomp', 'bench/rulescomp.c', dependencies: bench_dep),
- env: bench_env,
-)
-benchmark(
- 'compose',
- executable('bench-compose', 'bench/compose.c', dependencies: bench_dep),
- env: bench_env,
-)
-
-
# Documentation.
if get_option('enable-docs')
doxygen = find_program('doxygen', required: false)