kcgi: update to 0.10.6.
This commit is contained in:
parent
b602ad6b77
commit
2a0382b0cc
4 changed files with 91 additions and 22 deletions
srcpkgs/kcgi
26
srcpkgs/kcgi/files/configure.glibc
Normal file
26
srcpkgs/kcgi/files/configure.glibc
Normal file
|
@ -0,0 +1,26 @@
|
|||
HAVE_ARC4RANDOM=0
|
||||
HAVE_CAPSICUM=0
|
||||
HAVE_ERR=1
|
||||
HAVE_EXPLICIT_BZERO=1
|
||||
HAVE_GETPROGNAME=0
|
||||
HAVE_INFTIM=0
|
||||
HAVE_MD5=0
|
||||
HAVE_MEMMEM=1
|
||||
HAVE_MEMRCHR=1
|
||||
HAVE_MEMSET_S=0
|
||||
HAVE_PATH_MAX=1
|
||||
HAVE_PLEDGE=0
|
||||
HAVE_PROGRAM_INVOCATION_SHORT_NAME=1
|
||||
HAVE_REALLOCARRAY=0
|
||||
HAVE_RECALLOCARRAY=0
|
||||
HAVE_SANDBOX_INIT=0
|
||||
HAVE_SECCOMP_FILTER=1
|
||||
HAVE_SOCK_NONBLOCK=1
|
||||
HAVE_STRLCAT=0
|
||||
HAVE_STRLCPY=0
|
||||
HAVE_STRNDUP=1
|
||||
HAVE_STRNLEN=1
|
||||
HAVE_STRTONUM=0
|
||||
HAVE_SYSTRACE=0
|
||||
HAVE_ZLIB=0
|
||||
HAVE___PROGNAME=1
|
26
srcpkgs/kcgi/files/configure.musl
Normal file
26
srcpkgs/kcgi/files/configure.musl
Normal file
|
@ -0,0 +1,26 @@
|
|||
HAVE_ARC4RANDOM=0
|
||||
HAVE_CAPSICUM=0
|
||||
HAVE_ERR=1
|
||||
HAVE_EXPLICIT_BZERO=0
|
||||
HAVE_GETPROGNAME=0
|
||||
HAVE_INFTIM=0
|
||||
HAVE_MD5=0
|
||||
HAVE_MEMMEM=1
|
||||
HAVE_MEMRCHR=1
|
||||
HAVE_MEMSET_S=0
|
||||
HAVE_PATH_MAX=1
|
||||
HAVE_PLEDGE=0
|
||||
HAVE_PROGRAM_INVOCATION_SHORT_NAME=1
|
||||
HAVE_REALLOCARRAY=0
|
||||
HAVE_RECALLOCARRAY=0
|
||||
HAVE_SANDBOX_INIT=0
|
||||
HAVE_SECCOMP_FILTER=1
|
||||
HAVE_SOCK_NONBLOCK=1
|
||||
HAVE_STRLCAT=1
|
||||
HAVE_STRLCPY=1
|
||||
HAVE_STRNDUP=1
|
||||
HAVE_STRNLEN=1
|
||||
HAVE_STRTONUM=0
|
||||
HAVE_SYSTRACE=0
|
||||
HAVE_ZLIB=0
|
||||
HAVE___PROGNAME=1
|
22
srcpkgs/kcgi/patches/sandbox-musl.patch
Normal file
22
srcpkgs/kcgi/patches/sandbox-musl.patch
Normal file
|
@ -0,0 +1,22 @@
|
|||
--- sandbox-seccomp-filter.c.orig
|
||||
+++ sandbox-seccomp-filter.c
|
||||
@@ -106,7 +106,9 @@
|
||||
SC_ALLOW(recvmsg),
|
||||
#endif
|
||||
SC_ALLOW(read),
|
||||
+ SC_ALLOW(readv),
|
||||
SC_ALLOW(write),
|
||||
+ SC_ALLOW(writev),
|
||||
SC_ALLOW(close),
|
||||
#ifdef __NR_shutdown /* not defined on archs that go via socketcall(2) */
|
||||
SC_ALLOW(shutdown),
|
||||
@@ -158,7 +160,9 @@
|
||||
SC_ALLOW(time),
|
||||
#endif
|
||||
SC_ALLOW(read),
|
||||
+ SC_ALLOW(readv),
|
||||
SC_ALLOW(write),
|
||||
+ SC_ALLOW(writev),
|
||||
SC_ALLOW(close),
|
||||
#ifdef __NR_fcntl64 /* only noted on arm */
|
||||
SC_ALLOW(fcntl64),
|
|
@ -1,37 +1,32 @@
|
|||
# Template file for 'kcgi'
|
||||
pkgname=kcgi
|
||||
version=0.9.5
|
||||
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="Juan RP <xtraeme@voidlinux.eu>"
|
||||
maintainer="Duncaen <duncaen@voidlinux.eu>"
|
||||
license="ISC"
|
||||
homepage="http://kristaps.bsd.lv/kcgi/"
|
||||
distfiles="http://kristaps.bsd.lv/kcgi/snapshots/kcgi-${version}.tgz"
|
||||
checksum=08bf47ff932032dc901c9a2c25bffbdbb23a445795fe4fee44b82f5e2d76707f
|
||||
checksum=beddb1d5cc7c1e6b8cfc240f032bfc1e1654e859f4f2c48cd19d9fc2a56bd254
|
||||
|
||||
post_extract() {
|
||||
do_configure() {
|
||||
local _libc=glibc
|
||||
case "$XBPS_TARGET_MACHINE" in
|
||||
*-musl)
|
||||
sed -i 's/u_int/uint/g' md5.c md5.h
|
||||
sed -i '/_DECLS/d' md5.h
|
||||
sed -i '/#include <string.h>/a\ #include <unistd.h>' auth.c parent.c httpauth.c
|
||||
sed -i '/#include <stdlib.h>/a\ #include <unistd.h>' sandbox.c
|
||||
sed -i '/#include <time.h>/a\ #include <sys/types.h>' datetime.c
|
||||
;;
|
||||
*-musl) _libc=musl ;;
|
||||
esac
|
||||
# do not build new kutil_log(3) interface
|
||||
sed -i '/logging.[co]/d' GNUmakefile
|
||||
sed -i '/CC.*-o/s/$/ $(LDFLAGS)/' GNUmakefile
|
||||
sed -n '2,16p' kcgi.c > LICENSE
|
||||
if [ -n "$CROSS_BUILD" ]; then
|
||||
cp "${FILESDIR}/configure.$_libc" configure.local
|
||||
fi
|
||||
./configure PREFIX=/usr MANDIR=/usr/share/man SBINDIR=/usr/bin
|
||||
}
|
||||
|
||||
do_install() {
|
||||
make \
|
||||
PREFIX=${DESTDIR}/usr \
|
||||
SBINDIR=${DESTDIR}/usr/bin \
|
||||
MAN3DIR=${DESTDIR}/usr/share/man/man3 \
|
||||
MAN8DIR=${DESTDIR}/usr/share/man/man8 \
|
||||
install
|
||||
do_check() {
|
||||
make regress
|
||||
}
|
||||
|
||||
post_install() {
|
||||
sed -n '2,16p' kcgi.c > LICENSE
|
||||
vlicense LICENSE
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue