aboutsummaryrefslogtreecommitdiff
path: root/props.lv2/meson.build
diff options
context:
space:
mode:
authorGravatar Hanspeter Portner <dev@open-music-kontrollers.ch>2018-05-15 22:02:51 +0200
committerGravatar Hanspeter Portner <dev@open-music-kontrollers.ch>2018-05-15 22:02:51 +0200
commitfa8b53c0bd512e6d4683632af926ec66603a8e6b (patch)
tree01297766dcfeb633ae50a3dbb4e869cf817d276b /props.lv2/meson.build
parent759b8343b93000c0dbfc819d38560ff2b0945e07 (diff)
parent59e990002f9b3d801a2891c42db4bd1e51ebfa89 (diff)
downloadchim.lv2-fa8b53c0bd512e6d4683632af926ec66603a8e6b.zip
chim.lv2-fa8b53c0bd512e6d4683632af926ec66603a8e6b.tar.gz
chim.lv2-fa8b53c0bd512e6d4683632af926ec66603a8e6b.tar.bz2
chim.lv2-fa8b53c0bd512e6d4683632af926ec66603a8e6b.tar.xz
Merge commit '59e990002f9b3d801a2891c42db4bd1e51ebfa89'
Diffstat (limited to 'props.lv2/meson.build')
-rw-r--r--props.lv2/meson.build59
1 files changed, 59 insertions, 0 deletions
diff --git a/props.lv2/meson.build b/props.lv2/meson.build
new file mode 100644
index 0000000..cbaef78
--- /dev/null
+++ b/props.lv2/meson.build
@@ -0,0 +1,59 @@
+project('props.lv2', 'c', default_options : [
+ 'buildtype=release',
+ 'warning_level=1',
+ 'werror=false',
+ 'b_lto=true',
+ 'c_std=c11'])
+
+add_project_arguments('-D_GNU_SOURCE', language : 'c')
+
+conf_data = configuration_data()
+cc = meson.get_compiler('c')
+
+cp = find_program('cp')
+clone = [cp, '@INPUT@', '@OUTPUT@']
+
+m_dep = cc.find_library('m')
+lv2_dep = dependency('lv2', version : '>=1.14.0')
+
+inc_dir = []
+
+inst_dir = join_paths(get_option('libdir'), 'lv2', meson.project_name())
+
+dsp_srcs = [join_paths('test', 'props.c')]
+
+c_args = ['-fvisibility=hidden',
+ '-ffast-math']
+
+mod = shared_module('props', dsp_srcs,
+ c_args : c_args,
+ include_directories : inc_dir,
+ name_prefix : '',
+ dependencies : [m_dep, lv2_dep],
+ install : true,
+ install_dir : inst_dir)
+
+version = run_command('cat', 'VERSION').stdout().strip().split('.')
+conf_data.set('MAJOR_VERSION', version[0])
+conf_data.set('MINOR_VERSION', version[1])
+conf_data.set('MICRO_VERSION', version[2])
+
+suffix = mod.full_path().strip().split('.')[-1]
+conf_data.set('MODULE_SUFFIX', '.' + suffix)
+
+configure_file(input : join_paths('test', 'manifest.ttl.in'), output : 'manifest.ttl',
+ configuration : conf_data,
+ install : true,
+ install_dir : inst_dir)
+custom_target('props_ttl',
+ input : join_paths('test', 'props.ttl'),
+ output : 'props.ttl',
+ command : clone,
+ install : true,
+ install_dir : inst_dir)
+custom_target('chunk_bin',
+ input : join_paths('test', 'chunk.bin'),
+ output : 'chunk.bin',
+ command : clone,
+ install : true,
+ install_dir : inst_dir)