void-packages/srcpkgs/kcgi/template

36 lines
943 B
Bash

# Template file for 'kcgi'
pkgname=kcgi
version=0.10.6
revision=1
build_style=gnu-makefile
checkdepends="pkg-config libbsd-devel libcurl-devel"
short_desc="Minimal CGI library for web applications in C"
maintainer="Duncaen <duncaen@voidlinux.eu>"
license="ISC"
homepage="http://kristaps.bsd.lv/kcgi/"
distfiles="http://kristaps.bsd.lv/kcgi/snapshots/kcgi-${version}.tgz"
checksum=beddb1d5cc7c1e6b8cfc240f032bfc1e1654e859f4f2c48cd19d9fc2a56bd254
do_configure() {
local _libc=glibc
case "$XBPS_TARGET_MACHINE" in
*-musl) _libc=musl ;;
esac
if [ -n "$CROSS_BUILD" ]; then
cp "${FILESDIR}/configure.$_libc" configure.local
fi
case "$XBPS_TARGET_MACHINE" in
x86_64*|i686*|armv*) ;;
*) sed -i 's/HAVE_SECCOMP_FILTER=1/HAVE_SECCOMP_FILTER=0/' configure.local ;;
esac
./configure PREFIX=/usr MANDIR=/usr/share/man SBINDIR=/usr/bin
}
do_check() {
make regress
}
post_install() {
sed -n '2,16p' kcgi.c > LICENSE
vlicense LICENSE
}