# Contributor: Jakub Panek <me@panekj.dev>
# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Sodface <sod@sodface.com>
pkgname=lite-xl
pkgver=2.1.7
pkgrel=0
pkgdesc="Lightweight text editor written in Lua"
url="https://lite-xl.github.io"
arch="all"
license="MIT"
makedepends="
	cmake
	freetype-dev
	lua5.4-dev
	meson
	pcre2-dev
	reproc-dev
	sdl2-dev
	"
subpackages="$pkgname-doc"
source="https://github.com/lite-xl/lite-xl/archive/v$pkgver/lite-xl-$pkgver.tar.gz"
options="!check" # no tests available

build() {
	abuild-meson \
		-Darch_tuple="$CARCH-linux" \
		-Duse_system_lua=true \
		. output
	meson compile -C output
}

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

sha512sums="
0146846e2735651ecaaab4f2340842dd8e576af34778634436df9ffe87d9afd6f2996d429068689138860549225a304ca923220015e70af81e48167773165ef5  lite-xl-2.1.7.tar.gz
"
