a highly automated and intuitive digital audio workstation
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

203 lines
5.5 KiB

# Copyright (C) 2019-2022 Alexandros Theodotou <alex at zrythm dot org>
#
# This file is part of Zrythm
#
# Zrythm is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Zrythm is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with Zrythm. If not, see <https://www.gnu.org/licenses/>.
app_id = 'org.zrythm.Zrythm'
gschema = configure_file (
input: gen_gschema_wrap,
output: app_id + '.gschema.xml',
command: [
'@INPUT0@', '@OUTPUT@', app_id,
],
install: true,
install_dir: schemasdir)
# install fonts if needed
if get_option('dseg_font')
install_subdir (
'fonts/DSEG14-Classic-MINI',
install_dir: fontsdir)
endif
#install samples
install_data (
'samples/klick/square_emphasis.wav',
install_dir: samplesdir)
install_data (
'samples/klick/square_normal.wav',
install_dir: samplesdir)
zrythm_launcher_config = configuration_data ()
zrythm_launcher_config.set (
'SCHEMAS_DIR', schemasdir)
zrythm_launcher_config.set ('BIN_DIR', bindir)
zrythm_launcher_config.set (
'PROGRAM_NAME_LOWERCASE', prog_name_lowercase)
zrythm_launcher_config.set (
'ZRYTHM_LIBDIR', zrythm_libdir)
zrythm_launcher_config.set (
'ZRYTHM_CARLA_LIBDIR', zrythm_libdir / 'carla')
zrythm_launcher_config.set ('LIBDIR', libdir)
zrythm_launcher_config.set (
'LD_LIBRARY_PATH_ENV',
os_darwin ? 'DYLD_LIBRARY_PATH' : 'LD_LIBRARY_PATH')
zrythm_launcher_config.set ('FLATPAK_BUILD', flatpak_build ? '1' : '0')
# install desktop file and launcher scripts
if os_gnu or os_freebsd or os_darwin
zrythm_launcher = configure_file (
input: 'zrythm_launch.in',
output: prog_name_lowercase + '_launch',
configuration: zrythm_launcher_config,
install: true,
install_dir: bindir,
install_mode: 'r-xr-xr-x')
endif
if os_gnu or os_freebsd
zrythm_gdb = configure_file (
input: 'zrythm_gdb.in',
output: prog_name_lowercase + '_gdb',
configuration: zrythm_launcher_config,
install: true,
install_dir: bindir,
install_mode: 'r-xr-xr-x')
zrythm_gdb = configure_file (
input: 'zrythm_valgrind.in',
output: prog_name_lowercase + '_valgrind',
configuration: zrythm_launcher_config,
install: true,
install_dir: bindir,
install_mode: 'r-xr-xr-x')
# desktop entry
desktop_file = configure_file (
input: 'zrythm.desktop.in',
output: 'zrythm.desktop.in',
configuration: zrythm_launcher_config)
localized_desktop_file = i18n.merge_file (
input: desktop_file,
output: app_id + '.desktop',
type: 'desktop',
1 year ago
po_dir: meson_build_root / 'po',
install: true,
install_dir: datadir / 'applications',
)
1 year ago
run_target (
'gen-desktop-file',
command: [ 'echo', 'Generated desktop file' ],
depends: localized_desktop_file)
desktop_utils = find_program (
'desktop-file-validate', required: false)
if desktop_utils.found()
test ('Validate desktop file', desktop_utils,
args: [localized_desktop_file]
)
endif
# appdata
appdata_file_in_unformatted = custom_target (
'appdata-xml-in-tmp',
input: gen_appdata_xml_wrap,
output: '@0@.appdata.xml.in.in'.format (app_id),
command: [
gen_appdata_xml_wrap,
meson_build_root / '@OUTPUT@', app_id,
])
appdata_file_in = custom_target (
'appdata-xml-in',
input: appdata_file_in_unformatted,
output: '@0@.appdata.xml.in'.format (app_id),
command: [
xmllint, '--format', '--output', '@OUTPUT@',
'@INPUT@',
])
appdata_file = i18n.merge_file (
input: appdata_file_in,
output: '@0@.appdata.xml'.format (app_id),
type: 'xml',
1 year ago
po_dir: meson_build_root / 'po',
install: true,
install_dir: datadir / 'metainfo',
)
1 year ago
run_target (
'gen-appdata-xml',
command: [ 'echo', 'Generated appdata.xml' ],
depends: appdata_file)
# Validate the appdata file
appstream_util = find_program (
'appstream-util', required: false)
if appstream_util.found ()
test ('appstream-util-validate-appdata',
appstream_util,
suite: 'data',
args: [
'validate-relax', '--nonet',
appdata_file.full_path()
],
depends: [
appdata_file,
],
)
endif
appstreamcli = find_program (
'appstreamcli', required: false)
if appstreamcli.found ()
test ('appstream-cli-validate-appdata',
appstreamcli,
suite: 'data',
args: [
'validate',
appdata_file.full_path()
],
depends: [
appdata_file,
],
)
endif
endif # gnu or freebsd
if os_darwin
zrythm_gdb = configure_file (
input: 'zrythm_lldb.in',
output: prog_name_lowercase + '_lldb',
configuration: zrythm_launcher_config,
install: true,
install_dir: bindir,
install_mode: 'r-xr-xr-x')
endif
subdir ('icon-themes')
# Zrythm project MIME type
install_data (
'org.zrythm.Zrythm-mime.xml',
install_dir: datadir / 'mime/packages')
# GtkSourceView styles
install_data (
'gtksourceview-monokai-extended.xml',
install_dir: sourceviewstylesdir,
rename: 'monokai-extended-zrythm.xml')
# css themes
subdir ('css-themes')
subdir ('scripts')
subdir ('windows')