void-packages/srcpkgs/kitty/template
2018-06-28 21:22:26 +02:00

45 lines
1.3 KiB
Bash

# Template file for 'kitty'
pkgname=kitty
version=0.11.1
revision=1
python_version=3
hostmakedepends="ncurses pkg-config"
makedepends="gettext-devel glfw-devel harfbuzz-devel libxkbcommon-devel
python3-devel wayland-devel wayland-protocols"
depends="kitty-terminfo"
conf_files="/etc/kitty/kitty.conf"
short_desc="Modern, hackable, featureful, OpenGL based terminal emulator"
maintainer="Julio Galvan <juliogalvan@protonmail.com>"
license="GPL-3.0-or-later"
homepage="https://sw.kovidgoyal.net/kitty/"
distfiles="https://github.com/kovidgoyal/kitty/releases/download/v${version}/kitty-${version}.tar.xz"
checksum=3baf72ee4de8818bbc205fd631f716b60eabc8bd215ec7e834e00a01db7912c4
if [ -n "$CROSS_BUILD" ]; then
hostmakedepends+=" python3-devel wayland-devel wayland-protocols"
fi
do_build() {
if [ -n "$CROSS_BUILD" ]; then
export CFLAGS="-I${XBPS_CROSS_BASE}/usr/include/python3.6m"
sed -i "s|-fpie|-fpie ${CFLAGS}|g" setup.py
fi
case "$XBPS_TARGET_MACHINE" in
*-musl)
sed -i 's/pow10/pow_10/g' kitty/parser.c;;
esac
python3 setup.py linux-package --prefix=${DESTDIR}/usr --verbose
}
do_install() {
vmkdir etc/kitty
cp ${DESTDIR}/usr/share/doc/kitty/html/_downloads/kitty.conf ${DESTDIR}/etc/kitty/
}
kitty-terminfo_package() {
short_desc+=" - terminfo data"
noarch=yes
pkg_install() {
vmove usr/share/terminfo
}
}