6 changed files with 290 additions and 7 deletions
@ -0,0 +1,128 @@
@@ -0,0 +1,128 @@
|
||||
version: 1 |
||||
|
||||
AppDir: |
||||
path: @APPDIR_PATH@ |
||||
|
||||
app_info: |
||||
id: org.zrythm.Zrythm |
||||
name: zrythm@DASH_TRIAL@ |
||||
icon: zrythm |
||||
version: @ZRYTHM_PKG_VERSION@ |
||||
exec: usr/bin/zrythm |
||||
exec_args: --appimage-runtime-path=$APPDIR $@ |
||||
|
||||
apt: |
||||
arch: amd64 |
||||
sources: |
||||
- sourceline: 'deb [arch=amd64] http://archive.ubuntu.com/ubuntu/ focal main' |
||||
key_url: 'http://keyserver.ubuntu.com/pks/lookup?op=get&search=0x3b4fe6acc0b21f32' |
||||
- sourceline: 'deb [arch=amd64] http://archive.ubuntu.com/ubuntu/ focal universe' |
||||
- sourceline: 'deb [arch=amd64] http://archive.ubuntu.com/ubuntu/ focal-updates main' |
||||
- sourceline: 'deb [arch=amd64] http://archive.ubuntu.com/ubuntu/ focal-updates universe' |
||||
|
||||
include: |
||||
# can also add paths to deb files here |
||||
- libglib2.0-0 |
||||
- libgtk-3-0 |
||||
- libgdk-pixbuf2.0-common |
||||
#- liblilv-0-0 |
||||
- libpulse0 |
||||
- libxcb-shm0 |
||||
- libxcb1 |
||||
- coreutils |
||||
- bash |
||||
- librsvg2-common |
||||
- gettext |
||||
- guile-2.2-libs |
||||
- libcurl3-gnutls |
||||
- libsndfile1 |
||||
- libxcb-render0 |
||||
- libasound2 |
||||
- libgtksourceview-3.0-common |
||||
- libgtksourceview-3.0-1 |
||||
- graphviz |
||||
- librubberband2 |
||||
- libx11-6 |
||||
- libfftw3-3 |
||||
- libsamplerate0 |
||||
- libyaml-0-2 |
||||
- libxxhash0 |
||||
- shared-mime-info |
||||
- breeze-icon-theme |
||||
exclude: |
||||
- dpkg |
||||
|
||||
files: |
||||
include: |
||||
- /etc/mime.types |
||||
- /usr/lib/zrythm/carla/libcarla_host-plugin.so |
||||
exclude: |
||||
- usr/bin/gio* |
||||
- usr/bin/glib-compile-schemas |
||||
- usr/bin/glib-compile-resources |
||||
- usr/bin/gsettings |
||||
- usr/bin/gapplication |
||||
- usr/bin/gresource |
||||
- usr/bin/gobject-query |
||||
- usr/bin/gtester |
||||
- usr/share/icons/breeze |
||||
- usr/share/icons/ubuntu-* |
||||
- usr/share/icons/Humanity* |
||||
- usr/share/doc/lib* |
||||
- usr/share/doc/coreutils |
||||
- usr/share/doc/gettext-base |
||||
- usr/share/doc/adwaita-icon-theme |
||||
- bin/systemctl |
||||
- bin/cp |
||||
- bin/mv |
||||
- bin/vdir |
||||
- bin/ls |
||||
- bin/dir |
||||
- bin/date |
||||
- bin/touch |
||||
- usr/lib/x86_64-linux-gnu/guile/2.2/ccache |
||||
|
||||
after_bundle: |
||||
# this is executed after the packages and files are added |
||||
- echo $APPDIR |
||||
- mv $APPDIR/usr/lib/zrythm/carla/libcarla_host-plugin.so $APPDIR/usr/lib/x86_64-linux-gnu/ |
||||
- patchelf --remove-rpath $APPDIR/usr/bin/zrythm |
||||
- patchelf --replace-needed /usr/lib/zrythm/carla/libcarla_host-plugin.so libcarla_host-plugin.so $APPDIR/usr/bin/zrythm |
||||
|
||||
after_runtime: |
||||
# workaround for missing libcrypt.so.1 (version 2) on arch based system |
||||
- echo $APPDIR |
||||
- mkdir -p $APPDIR/lib/x86_64-linux-gnu |
||||
- rm -f $APPDIR/lib/x86_64-linux-gnu/libcrypt.so.1 || true |
||||
- ln -s /usr/lib/libcrypt.so.2 $APPDIR/lib/x86_64-linux-gnu/libcrypt.so.1 |
||||
|
||||
test: |
||||
fedora: |
||||
image: fedora:32 |
||||
command: "./AppRun --version" |
||||
use_host_x: True |
||||
archlinux: |
||||
image: archlinux |
||||
command: "./AppRun --version" |
||||
use_host_x: True |
||||
debian-sid: |
||||
image: debian:sid |
||||
command: "./AppRun --version" |
||||
use_host_x: True |
||||
|
||||
runtime: |
||||
path_mappings: |
||||
- /usr/lib/x86_64-linux-gnu/gdk-pixbuf-2.0:$APPDIR/usr/lib/x86_64-linux-gnu/gdk-pixbuf-2.0 |
||||
- /usr/lib/gdk-pixbuf-2.0:$APPDIR/usr/lib/x86_64-linux-gnu/gdk-pixbuf-2.0 |
||||
#- /usr/lib/zrythm:$APPDIR/usr/lib/zrythm |
||||
env: |
||||
GDK_PIXBUF_MODULEDIR: '${APPDIR}/usr/lib/x86_64-linux-gnu/gdk-pixbuf-2.0/2.10.0/loaders' |
||||
GDK_PIXBUF_MODULE_FILE: '${APPDIR}/usr/lib/x86_64-linux-gnu/gdk-pixbuf-2.0/2.10.0/loaders.cache' |
||||
GTK_DATA_PREFIX: '${APPDIR}/usr' |
||||
GTK_EXE_PREFIX: '${APPDIR}/usr' |
||||
GTK_PATH: '${APPDIR}/usr' |
||||
|
||||
AppImage: |
||||
update-information: None |
||||
sign-key: None |
||||
arch: x86_64 |
@ -0,0 +1,73 @@
@@ -0,0 +1,73 @@
|
||||
#!@BASH@ |
||||
|
||||
set -xe |
||||
|
||||
# args: |
||||
# 1: output package (.AppImage) path |
||||
# 2: appimage-builder.yml path |
||||
# 3: zrythm source tarball path |
||||
# 4: private dir |
||||
|
||||
out_pkg="$1" |
||||
appimage_builder_yml="$2" |
||||
zrythm_src_tarball="$3" |
||||
private_dir="$4" |
||||
|
||||
appdir_root="@APPDIR_PATH@" |
||||
inner_dir="@ZRYTHM_INNER_DIR_NAME@" |
||||
zrythm_src_tarball_filename="@ZRYTHM_SOURCE_TARBALL_FILENAME@" |
||||
|
||||
appimage_filename=`basename "$out_pkg"` |
||||
|
||||
rm -rf "$appdir_root" |
||||
rm -rf "$private_dir" |
||||
mkdir -p "$private_dir" |
||||
cp "$appimage_builder_yml" "$private_dir"/ |
||||
cp "$zrythm_src_tarball" "$private_dir"/ |
||||
|
||||
tar xf "$zrythm_src_tarball" -C "$private_dir" |
||||
pushd "$private_dir" |
||||
pushd "$inner_dir" |
||||
|
||||
# configure |
||||
PATH="$PATH:/home/build/.local/bin" \ |
||||
@MESON_BIN@ build --prefix=/usr \ |
||||
-Dpkg_config_path=@LIBRARY_PKG_CONFIG_PATH@:@CARLA_PKG_CONFIG_PATH@ \ |
||||
-Dtests=true -Ddseg_font=true -Dmanpage=true \ |
||||
-Dbuildtype=debugoptimized -Dlsp_dsp=enabled \ |
||||
-Dstatic_lsp_dsp=true -Dsdl=enabled \ |
||||
-Dfallback_version=@ZRYTHM_PKG_VERSION@ \ |
||||
-Drtaudio=auto -Drtmidi=auto -Dguile=enabled \ |
||||
-Dcarla=enabled -Dgraphviz=enabled \ |
||||
-Dtrial_ver=@TRIAL_TRUE_FALSE@ \ |
||||
-Dextra_debug_info=true \ |
||||
-Dphone_home=enabled \ |
||||
-Dinstaller_ver=true \ |
||||
-Dappimage=true \ |
||||
-Dcarla_binaries_dir=@CARLA_FULL_BINS_PATH@ |
||||
|
||||
# build |
||||
ninja -C build |
||||
|
||||
# install in AppDir |
||||
DESTDIR="$appdir_root" ninja -C build install |
||||
|
||||
# also copy required lib |
||||
cp "@CARLA_FULL_BINS_PATH@/libcarla_host-plugin.so" \ |
||||
"$appdir_root"/usr/lib/zrythm/carla/ |
||||
|
||||
popd # zrythm tarball inner dir |
||||
|
||||
# create appimage from AppDir |
||||
appimage-builder --recipe ./appimage-builder.yml --skip-test |
||||
|
||||
# test that appimage works |
||||
./"$appimage_filename" --version |
||||
|
||||
# run lint |
||||
appimagelint "$appimage_filename" |
||||
|
||||
popd # private dir |
||||
|
||||
# copy AppImage from private dir to dest |
||||
cp "$private_dir"/"$appimage_filename" "$out_pkg" |
@ -0,0 +1,71 @@
@@ -0,0 +1,71 @@
|
||||
# Copyright (C) 2021 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/>. |
||||
|
||||
appimage_conf = configuration_data () |
||||
appimage_conf.merge_from (global_conf) |
||||
appimage_conf.set ( |
||||
'BUILT_ZPLUGINS_DIR', zplugins_installation.full_path ()) |
||||
appimage_conf.set ( |
||||
'CARLA_DESTDIR', carla_installation.full_path ()) |
||||
appimage_conf.set ( |
||||
'CARLA_PKG_CONFIG_PATH', carla_pkgconfig_path) |
||||
appimage_conf.set ( |
||||
'CARLA_FULL_BINS_PATH', |
||||
carla_installation.full_path () + carla_prefix / 'carla') |
||||
appimage_conf.set ( |
||||
'APPDIR_PATH', '/tmp/AppDir') |
||||
|
||||
find_program ('appimage-builder') |
||||
|
||||
make_appimage_pkg = configure_file ( |
||||
output: 'make_appimage.sh', |
||||
input: 'make_appimage.sh.in', |
||||
configuration: appimage_conf, |
||||
) |
||||
|
||||
appimage_builder_yml = configure_file ( |
||||
output: 'appimage-builder.yml', |
||||
input: 'appimage-builder.yml.in', |
||||
configuration: appimage_conf, |
||||
) |
||||
|
||||
appimage_pkg_filename = run_command ( |
||||
get_pkg_filename, 'APPIMAGE', dash_trial).stdout ().strip () |
||||
appimage_pkg = custom_target ( |
||||
'appimage-pkg', |
||||
output: appimage_pkg_filename, |
||||
input: [ |
||||
appimage_builder_yml, zrythm_src_tarball, |
||||
], |
||||
command: [ |
||||
make_appimage_pkg, '@OUTPUT@', '@INPUT0@', '@INPUT1@', |
||||
'@PRIVATE_DIR@', |
||||
], |
||||
depends: [ |
||||
carla_installation, |
||||
lsp_dsp_lib_installation, |
||||
zplugins_installation, |
||||
], |
||||
console: true, |
||||
install: true, |
||||
install_dir: get_option ('prefix'), |
||||
) |
||||
|
||||
run_target ( |
||||
'appimage', |
||||
command: [ 'echo', 'done' ], |
||||
depends: appimage_pkg) |
Loading…
Reference in new issue