1google_benchmark = subproject('google-benchmark') 2google_benchmark_dep = google_benchmark.get_variable('google_benchmark_dep') 3 4ttf_parser_dep = null_dep 5if get_option('experimental_api') and add_languages('rust', required: false, native: true) 6 ttf_parser_dep = subproject('ttf-parser').get_variable('ttf_parser_dep') 7endif 8 9benchmark('perf', executable('perf', 'perf.cc', 10 dependencies: [ 11 google_benchmark_dep, freetype_dep, 12 13 # the last two, thread and dl, aren't nice as ttf-parser isn't no_std yet 14 # https://github.com/RazrFalcon/ttf-parser/issues/29 15 ttf_parser_dep, thread_dep, cpp.find_library('dl'), 16 ], 17 cpp_args: ttf_parser_dep.found() ? ['-DHAVE_TTFPARSER'] : [], 18 include_directories: [incconfig, incsrc], 19 link_with: [libharfbuzz], 20 install: false, 21), workdir: meson.current_source_dir() / '..', timeout: 100) 22