# Contributor: Rasmus Thomsen <oss@cogitri.dev>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=tilix
pkgver=1.9.6
pkgrel=4
pkgdesc="Tiling terminal emulator for Linux"
url="https://gnunn1.github.io/tilix-web/"
arch="x86_64 aarch64 loongarch64"
license="MPL-2.0"
depends="adwaita-icon-theme gsettings-desktop-schemas libsecret dbus:org.freedesktop.Secrets vte3"
makedepends="
	appstream
	dconf-dev
	desktop-file-utils
	gdk-pixbuf
	glib-dev
	gtkd-dev
	ldc
	libsecret-dev
	libx11-dev
	meson
	po4a
	"
options="!check" # no tests
subpackages="$pkgname-doc $pkgname-lang"
source="https://github.com/gnunn1/tilix/archive/$pkgver/tilix-$pkgver.tar.gz
	musl-hacks.patch
	dont-use-libunwind.patch
	0001-meson.build-add-allinst-when-compiling-2210.patch
	"

build() {
	export LDFLAGS="$LDFLAGS -L--no-export-dynamic"
	abuild-meson . output
	meson compile -C output
}

package() {
	DESTDIR="$pkgdir" meson install --no-rebuild -C output
}

sha512sums="
2d51e8c0203863573e52c7bf68a66ba4ec58f929ecebf90bb68bae3f15d9f745f956fc524b7dd23d1804d5130dd0bf39ff834d262042375448e53714021338f6  tilix-1.9.6.tar.gz
3347bfebb0e4d011d9b17f31ed15ec79e503de76185757165c7c13daa6e8b566eb0ad3a7cf32775ee4bc6102da1fa593d3dd0ff57767748c911ec46ad53d4bc3  musl-hacks.patch
4a1ccc6011d64b78a7f2a93ca91eec36004c5e5d4e826efc115f860c3013bd52477324b586340e18849bce445c56d7d8b909393694ec43a3b11d0c85e6ad59c3  dont-use-libunwind.patch
b079297efaa500081523c2c7800fef26c3f4204fc57dcbe384e56a026b69a1ce471b1c97dd5620e87ac9e0b1bbde3bd46ab6fb0f0e3ee14c8fd4bcff78cad156  0001-meson.build-add-allinst-when-compiling-2210.patch
"
