3 default_options : ['warning_level=3', 'werror=true', 'cpp_std=c++14', 'optimization=s'],
6 meson_version : '>=0.49',
9 add_project_arguments('-DDEMO_DIR="@0@/example/resource/"'.format(meson.current_source_dir()), language : 'cpp')
11 inc = [include_directories('inc')]
12 config_dir = include_directories('.')
15 config_h = configuration_data()
17 if get_option('thread') == true
18 config_h.set10('LOTTIE_THREAD_SUPPORT', true)
20 config_h.set('thread_local', true)
23 if get_option('module') == true
24 config_h.set10('LOTTIE_IMAGE_MODULE_SUPPORT', true)
26 if meson.get_compiler('cpp').get_id() != 'msvc'
31 if host_machine.system() == 'darwin'
33 elif host_machine.system() == 'windows'
38 if get_option('moduledir') != ''
39 config_h.set_quoted('LOTTIE_IMAGE_MODULE_PLUGIN',
40 get_option('prefix') / get_option('moduledir') / lib_prefix + 'rlottie-image-loader' + lib_suffix)
42 config_h.set_quoted('LOTTIE_IMAGE_MODULE_PLUGIN', lib_prefix + 'rlottie-image-loader' + lib_suffix)
46 if get_option('cache') == true
47 config_h.set10('LOTTIE_CACHE_SUPPORT', true)
50 if get_option('log') == true
51 config_h.set10('LOTTIE_LOGGING_SUPPORT', true)
54 if get_option('dumptree') == true
55 config_h.set10('LOTTIE_LOGGING_SUPPORT', true)
56 config_h.set10('LOTTIE_DUMP_TREE_SUPPORT', true)
62 configuration: config_h
69 if get_option('example') == true
73 if get_option('test') == true
78 if get_option('cmake') == true and host_machine.system() != 'windows'
79 cmake_bin = find_program('cmake', required: false)
81 cmake = import('cmake')
82 cmake.write_basic_package_version_file(
83 version: meson.project_version(),
87 cmakeconf = configuration_data()
88 cmakeconf.set('VERSION', meson.project_version())
90 cmake.configure_package_config_file(
91 input: meson.current_source_dir() + '/cmake/rlottieConfig.cmake.in',
93 configuration: cmakeconf,
101 rlottie version : @0@
110 meson.project_version(),
111 get_option('buildtype'),
112 get_option('thread'),
113 get_option('module'),
115 get_option('example'),
117 get_option('prefix'),