1 project('ladish', 'c', 'cpp',
3 license : 'GPL-2.0-only')
5 data_dir = get_option('prefix') / 'share' / 'ladish'
6 locale_dir = get_option('prefix') / 'share' / 'locale'
7 dbus_name_base = 'org.ladish'
8 dbus_base_path = '/org/ladish'
12 # This block handles building from git source tree
13 # version.h is generated during build
14 git_version = run_command(['git', 'rev-parse', '--short', 'HEAD']).stdout().strip()
16 configure_file(output : 'version.h',
18 'GIT_VERSION' : '"@0@"'.format(git_version)
22 # Tarballs already have version.h,
23 # Just copy the file in this case
24 configure_file(output : 'version.h',
30 configure_file(output : 'config.h',
32 'PACKAGE_VERSION' : '"@0@"'.format(meson.project_version()),
33 'BASE_NAME' : '"@0@"'.format(meson.project_name()),
34 'DATA_DIR' : '"@0@"'.format(data_dir),
35 'LOCALE_DIR' : '"@0@"'.format(locale_dir),
36 'DBUS_NAME_BASE' : '"@0@"'.format(dbus_name_base),
37 'DBUS_BASE_PATH' : '"@0@"'.format(dbus_base_path),
42 cc = meson.get_compiler('c')
44 inc = include_directories(meson.build_root().split('/')[-1])
45 lash_inc = include_directories('lash_compat/liblash')
47 jack_dep = dependency('jack')
48 dbus_dep = dependency('dbus-1')
49 cdbus_dep = dependency('cdbus-1')
52 cc.find_library('dl'),
53 cc.find_library('util'),
62 pkg_mod = import('pkgconfig')
71 if get_option('liblash').enabled()
72 subdir('lash_compat/liblash')
75 if get_option('gladish').enabled()
80 install_data(['AUTHORS', 'README.adoc', 'NEWS'], install_dir : data_dir)
82 install_data('ladish_control',
83 install_dir : get_option('prefix') / 'bin')
85 jmcore = executable('jmcore', 'jmcore.c',
87 link_with : [commonlib],
90 ladiconfd = executable('ladiconfd', 'conf.c',
92 link_with : [commonlib],