From 92ed1e1d931afb524fb64f85047a5b43cf3e3dd9 Mon Sep 17 00:00:00 2001 From: Roger Freitas Pereira Date: Wed, 19 Jun 2024 17:43:51 -0300 Subject: [PATCH] Carla: update to 2.5.8. --- srcpkgs/Carla-bridge-win | 1 + srcpkgs/Carla/template | 100 ++++++++++++++++++++++++++++++++++++--- 2 files changed, 94 insertions(+), 7 deletions(-) create mode 120000 srcpkgs/Carla-bridge-win mode change 100644 => 100755 srcpkgs/Carla/template diff --git a/srcpkgs/Carla-bridge-win b/srcpkgs/Carla-bridge-win new file mode 120000 index 00000000000000..817012ce210c37 --- /dev/null +++ b/srcpkgs/Carla-bridge-win @@ -0,0 +1 @@ +Carla \ No newline at end of file diff --git a/srcpkgs/Carla/template b/srcpkgs/Carla/template old mode 100644 new mode 100755 index 9dee10b94a1f2a..3af215bc7429b4 --- a/srcpkgs/Carla/template +++ b/srcpkgs/Carla/template @@ -1,7 +1,7 @@ # Template file for 'Carla' pkgname=Carla -version=2.5.1 -revision=4 +version=2.5.8 +revision=1 archs="x86_64* i686* aarch64* arm*" build_style=gnu-makefile pycompile_dirs="usr/share/carla" @@ -16,19 +16,60 @@ maintainer="Orphaned " license="GPL-2.0-or-later" homepage="https://kx.studio/Applications:Carla" distfiles="https://github.com/falkTX/Carla/archive/v${version}.tar.gz" -checksum=c47eea999b2880bde035fbc30d7b42b49234a81327127048a56967ec884dfdba +checksum=4ec96d06342ff28da4b80d4a76bc08fcaa5703726f96e5174afcdc4f7fc6195d python_version=3 +build_options="win linux32" +build_options_default="" +desc_option_win="Enable building windows bridge" +desc_option_linux32="Enable building linux32 bridge" + +subpackages="Carla-devel" + +if [ -z "$CROSS_BUILD" ]; then + case "$XBPS_TARGET_MACHINE" in + x86_64) + build_options_default+=" win linux32" + subpackages+=" Carla-bridge-win" + ;; + i686) + build_options_default+=" win" + subpackages+=" Carla-bridge-win" + ;; + esac +fi + +if [ "$CROSS_BUILD" ]; then + hostmakedepends+=" Carla-devel qt5-host-tools" +fi + +if [ "$build_option_win" ]; then + case $XBPS_TARGET_MACHINE in + x86_64) + hostmakedepends+=" cross-x86_64-w64-mingw32 wine-tools" + makedepends+=" wine-devel" + ;; + i686) + hostmakedepends+=" cross-i686-w64-mingw32 wine-tools" + makedepends+=" wine-devel" + ;; + esac +fi + +if [ "$build_option_linux32" ]; then + case $XBPS_TARGET_MACHINE in + x86_64) + makedepends+=" gcc-multilib freetype-devel-32bit libX11-devel-32bit" + ;; + esac +fi + case $XBPS_TARGET_MACHINE in x86_64* | i686*);; *) make_build_args+=" NOOPT=true" make_install_args+=" NOOPT=true";; esac -if [ "$CROSS_BUILD" ]; then - hostmakedepends+=" Carla-devel" -fi - if [ "$XBPS_TARGET_LIBC" = "musl" ]; then makedepends+=" libexecinfo-devel musl-fts-devel" export LDFLAGS="-lfts" @@ -45,6 +86,27 @@ pre_build() { make ${make_build_args} features } +post_build() { + if [ "$build_option_win" ]; then + case $XBPS_TARGET_MACHINE in + x86_64) + CXXFLAGS="" CFLAGS="" LDFLAGS="" \ + make ${makejobs} ${make_build_args} win64 CC="x86_64-w64-mingw32-gcc" CXX="x86_64-w64-mingw32-g++" + make ${make_build_args} wine64 + ;; + i686) + CXXFLAGS="" CFLAGS="" LDFLAGS="" \ + make ${makejobs} ${make_build_args} win32 CC="i686-w64-mingw32-gcc" CXX="i686-w64-mingw32-g++" + make ${make_build_args} wine32 + ;; + esac + fi + + if [ "$build_option_linux32" ]; then + make posix32 + fi +} + post_install() { vbin bin/carla-lv2-export } @@ -57,3 +119,27 @@ Carla-devel_package() { vmove usr/include } } + +Carla-bridge-win_package() { + lib32mode=full + lib32symlinks="carla/carla-bridge-win32.exe + carla/carla-discovery-win32.exe + carla/jackbridge-wine32.dll + vst/carla.vst/carla-bridge-win32.exe + vst/carla.vst/carla-carla-win32.exe + vst/carla.vst/jackbridge-wine32.dll + lv2/carla.lv2/carla-bridge-win32.exe + lv2/carla.lv2/carla-carla-win32.exe + lv2/carla.lv2/jackbridge-wine32.dll" + + depends="Carla>=${version} wine" + short_desc+=" - windows bridge" + pkg_install() { + vmove usr/lib/carla/*.exe + vmove usr/lib/carla/*.dll + vmove usr/lib/vst/carla.vst/*.exe + vmove usr/lib/vst/carla.vst/*.dll + vmove usr/lib/lv2/carla.lv2/*.exe + vmove usr/lib/lv2/carla.lv2/*.dll + } +}