Date: Tuesday, November 22, 2016 @ 17:40:23 Author: anthraxx Revision: 196550
archrelease: copy trunk to community-staging-i686, community-staging-x86_64 Added: ziproxy/repos/community-staging-i686/ ziproxy/repos/community-staging-i686/PKGBUILD (from rev 196549, ziproxy/trunk/PKGBUILD) ziproxy/repos/community-staging-i686/build-fix.patch (from rev 196549, ziproxy/trunk/build-fix.patch) ziproxy/repos/community-staging-i686/ziproxy.install (from rev 196549, ziproxy/trunk/ziproxy.install) ziproxy/repos/community-staging-i686/ziproxy.logrotate (from rev 196549, ziproxy/trunk/ziproxy.logrotate) ziproxy/repos/community-staging-i686/ziproxy.xinetd (from rev 196549, ziproxy/trunk/ziproxy.xinetd) ziproxy/repos/community-staging-x86_64/ ziproxy/repos/community-staging-x86_64/PKGBUILD (from rev 196549, ziproxy/trunk/PKGBUILD) ziproxy/repos/community-staging-x86_64/build-fix.patch (from rev 196549, ziproxy/trunk/build-fix.patch) ziproxy/repos/community-staging-x86_64/ziproxy.install (from rev 196549, ziproxy/trunk/ziproxy.install) ziproxy/repos/community-staging-x86_64/ziproxy.logrotate (from rev 196549, ziproxy/trunk/ziproxy.logrotate) ziproxy/repos/community-staging-x86_64/ziproxy.xinetd (from rev 196549, ziproxy/trunk/ziproxy.xinetd) --------------------------------------------+ community-staging-i686/PKGBUILD | 61 +++++++++++++++++++++++++++ community-staging-i686/build-fix.patch | 44 +++++++++++++++++++ community-staging-i686/ziproxy.install | 16 +++++++ community-staging-i686/ziproxy.logrotate | 13 +++++ community-staging-i686/ziproxy.xinetd | 14 ++++++ community-staging-x86_64/PKGBUILD | 61 +++++++++++++++++++++++++++ community-staging-x86_64/build-fix.patch | 44 +++++++++++++++++++ community-staging-x86_64/ziproxy.install | 16 +++++++ community-staging-x86_64/ziproxy.logrotate | 13 +++++ community-staging-x86_64/ziproxy.xinetd | 14 ++++++ 10 files changed, 296 insertions(+) Copied: ziproxy/repos/community-staging-i686/PKGBUILD (from rev 196549, ziproxy/trunk/PKGBUILD) =================================================================== --- community-staging-i686/PKGBUILD (rev 0) +++ community-staging-i686/PKGBUILD 2016-11-22 17:40:23 UTC (rev 196550) @@ -0,0 +1,61 @@ +# $Id$ +# Maintainer: Sergej Pupykin <pupykin.s+a...@gmail.com> +# Contributor: Yejun Yang yejunx AT gmail DOT com + +pkgname=ziproxy +pkgver=3.3.0 +pkgrel=8 +pkgdesc="forwarding, non-caching, compressing HTTP proxy server" +arch=('i686' 'x86_64') +url="http://ziproxy.sourceforge.net/" +license=('GPL2') +depends=('giflib' 'libpng' 'libjpeg' 'zlib' 'jasper' 'libsasl') +backup=(etc/ziproxy/ziproxy.conf + etc/ziproxy/bo_exception.list + etc/ziproxy/http.passwd + etc/ziproxy/noprocess.list + etc/ziproxy/replace.list + etc/xinetd.d/ziproxy + var/lib/ziproxy/error/400.html + var/lib/ziproxy/error/404.html + var/lib/ziproxy/error/407.html + var/lib/ziproxy/error/408.html + var/lib/ziproxy/error/409.html + var/lib/ziproxy/error/500.html + var/lib/ziproxy/error/503.html) +install=ziproxy.install +source=(http://downloads.sourceforge.net/project/ziproxy/ziproxy/ziproxy-$pkgver/ziproxy-$pkgver.tar.bz2 + ziproxy.logrotate + ziproxy.xinetd + build-fix.patch) +md5sums=('a8fda01591d455bb23c64c9c5ed3980d' + 'feb35264391c790cedd5e995182b5ff5' + '3d2f9208b5ab6738c136049e1fd2e433' + '353850d5a45f2382c11e673e0de38b72') + +prepare() { + cd "$srcdir"/$pkgname-$pkgver + sed -i '1,1i#include <string.h>' src/qparser.c + patch -p1 <"$srcdir"/build-fix.patch +} + +build() { + cd "$srcdir"/$pkgname-$pkgver + [ -f Makefile ] || ./configure --prefix=/usr --with-jasper + make +} + +package() { + cd "$srcdir"/$pkgname-$pkgver + make DESTDIR="$pkgdir" install + + install -d "$pkgdir"/var/lib/ziproxy/error + install -d "$pkgdir"/etc/conf.d + + sed -i 's#var/ziproxy#var/lib/ziproxy#' etc/ziproxy/ziproxy.conf + cp -a etc/ziproxy "$pkgdir"/etc/ziproxy + install -m644 var/ziproxy/error/* "$pkgdir"/var/lib/ziproxy/error + echo "ZIPROXY_ARGS=\"-c /etc/ziproxy/ziproxy.conf\"" >"$pkgdir"/etc/conf.d/ziproxy + install -Dm0644 "$srcdir"/ziproxy.logrotate "$pkgdir"/etc/logrotate.d/ziproxy + install -Dm0644 "$srcdir"/ziproxy.xinetd "$pkgdir"/etc/xinetd.d/ziproxy +} Copied: ziproxy/repos/community-staging-i686/build-fix.patch (from rev 196549, ziproxy/trunk/build-fix.patch) =================================================================== --- community-staging-i686/build-fix.patch (rev 0) +++ community-staging-i686/build-fix.patch 2016-11-22 17:40:23 UTC (rev 196550) @@ -0,0 +1,44 @@ +diff -wbBur ziproxy-3.3.0/src/image.c ziproxy-3.3.0.my/src/image.c +--- ziproxy-3.3.0/src/image.c 2013-01-04 20:48:50.000000000 +0400 ++++ ziproxy-3.3.0.my/src/image.c 2014-09-30 18:26:38.277455333 +0400 +@@ -93,6 +93,10 @@ + #define MIN_INSIZE_TO_JPEG 600 + #define MIN_INSIZE_TO_JP2K 800 + ++ ++#define false 0 ++#define true !!0 ++ + //Forwards. There are more utility functions, but they're used only once. + static raw_bitmap *new_raw_bitmap(); + +@@ -905,7 +909,7 @@ + desc.size=insize; + desc.x.pos=0; + +- if ((GifFile = DGifOpen((void*)&desc, &gif_mem_input)) == NULL) ++ if ((GifFile = DGifOpen((void*)&desc, &gif_mem_input, NULL)) == NULL) + return( IMG_RET_ERR_UNKNOWN + IMG_RET_FLG_WHILE_DECOMP);//more possible reasons + + bmp = new_raw_bitmap(); +@@ -1083,7 +1087,7 @@ + } + bmp->pal_bpp = bmp->bpp; + +- DGifCloseFile(GifFile); ++ DGifCloseFile(GifFile, NULL); + return IMG_RET_OK; + } + +diff -wbBur ziproxy-3.3.0/src/qparser.c ziproxy-3.3.0.my/src/qparser.c +--- ziproxy-3.3.0/src/qparser.c 2013-01-04 20:48:50.000000000 +0400 ++++ ziproxy-3.3.0.my/src/qparser.c 2014-09-30 18:28:34.772237049 +0400 +@@ -32,7 +33,7 @@ + // #ifdef __GLIBC__ + // #define _GNU_SOURCE + // #else +-#define QP_BUILD_STRNDUP ++//#define QP_BUILD_STRNDUP + // #endif + + #include <string.h> Copied: ziproxy/repos/community-staging-i686/ziproxy.install (from rev 196549, ziproxy/trunk/ziproxy.install) =================================================================== --- community-staging-i686/ziproxy.install (rev 0) +++ community-staging-i686/ziproxy.install 2016-11-22 17:40:23 UTC (rev 196550) @@ -0,0 +1,16 @@ +# https://wiki.archlinux.org/index.php/UID_and_GID_List +# 0:15 = root:proxy + +post_install() { + getent group proxy >/dev/null || groupadd -r -g 15 proxy + getent passwd proxy >/dev/null || useradd -r -d /var/empty -g 15 -u 15 proxy + mkdir -p /var/log/ziproxy && \ + chown -R 0:15 /var/log/ziproxy && \ + chmod -R ug+w /var/log/ziproxy +} + +post_upgrade() { + mkdir -p /var/log/ziproxy && \ + chown -R 0:15 /var/log/ziproxy && \ + chmod -R ug+w /var/log/ziproxy +} Copied: ziproxy/repos/community-staging-i686/ziproxy.logrotate (from rev 196549, ziproxy/trunk/ziproxy.logrotate) =================================================================== --- community-staging-i686/ziproxy.logrotate (rev 0) +++ community-staging-i686/ziproxy.logrotate 2016-11-22 17:40:23 UTC (rev 196550) @@ -0,0 +1,13 @@ +/var/log/ziproxy/access.log { + su root proxy + weekly + missingok + rotate 10 + compress + delaycompress + ifempty + nomail + postrotate + killall -HUP ziproxy 1>/dev/null 2>/dev/null || true + endscript +} Copied: ziproxy/repos/community-staging-i686/ziproxy.xinetd (from rev 196549, ziproxy/trunk/ziproxy.xinetd) =================================================================== --- community-staging-i686/ziproxy.xinetd (rev 0) +++ community-staging-i686/ziproxy.xinetd 2016-11-22 17:40:23 UTC (rev 196550) @@ -0,0 +1,14 @@ +service ziproxy +{ + port = 3128 + type = UNLISTED + disable = yes + socket_type = stream + wait = no + user = proxy + server = /usr/bin/ziproxy + server_args = -i + bind = 0.0.0.0 + log_on_success += HOST DURATION + log_on_failure += HOST +} Copied: ziproxy/repos/community-staging-x86_64/PKGBUILD (from rev 196549, ziproxy/trunk/PKGBUILD) =================================================================== --- community-staging-x86_64/PKGBUILD (rev 0) +++ community-staging-x86_64/PKGBUILD 2016-11-22 17:40:23 UTC (rev 196550) @@ -0,0 +1,61 @@ +# $Id$ +# Maintainer: Sergej Pupykin <pupykin.s+a...@gmail.com> +# Contributor: Yejun Yang yejunx AT gmail DOT com + +pkgname=ziproxy +pkgver=3.3.0 +pkgrel=8 +pkgdesc="forwarding, non-caching, compressing HTTP proxy server" +arch=('i686' 'x86_64') +url="http://ziproxy.sourceforge.net/" +license=('GPL2') +depends=('giflib' 'libpng' 'libjpeg' 'zlib' 'jasper' 'libsasl') +backup=(etc/ziproxy/ziproxy.conf + etc/ziproxy/bo_exception.list + etc/ziproxy/http.passwd + etc/ziproxy/noprocess.list + etc/ziproxy/replace.list + etc/xinetd.d/ziproxy + var/lib/ziproxy/error/400.html + var/lib/ziproxy/error/404.html + var/lib/ziproxy/error/407.html + var/lib/ziproxy/error/408.html + var/lib/ziproxy/error/409.html + var/lib/ziproxy/error/500.html + var/lib/ziproxy/error/503.html) +install=ziproxy.install +source=(http://downloads.sourceforge.net/project/ziproxy/ziproxy/ziproxy-$pkgver/ziproxy-$pkgver.tar.bz2 + ziproxy.logrotate + ziproxy.xinetd + build-fix.patch) +md5sums=('a8fda01591d455bb23c64c9c5ed3980d' + 'feb35264391c790cedd5e995182b5ff5' + '3d2f9208b5ab6738c136049e1fd2e433' + '353850d5a45f2382c11e673e0de38b72') + +prepare() { + cd "$srcdir"/$pkgname-$pkgver + sed -i '1,1i#include <string.h>' src/qparser.c + patch -p1 <"$srcdir"/build-fix.patch +} + +build() { + cd "$srcdir"/$pkgname-$pkgver + [ -f Makefile ] || ./configure --prefix=/usr --with-jasper + make +} + +package() { + cd "$srcdir"/$pkgname-$pkgver + make DESTDIR="$pkgdir" install + + install -d "$pkgdir"/var/lib/ziproxy/error + install -d "$pkgdir"/etc/conf.d + + sed -i 's#var/ziproxy#var/lib/ziproxy#' etc/ziproxy/ziproxy.conf + cp -a etc/ziproxy "$pkgdir"/etc/ziproxy + install -m644 var/ziproxy/error/* "$pkgdir"/var/lib/ziproxy/error + echo "ZIPROXY_ARGS=\"-c /etc/ziproxy/ziproxy.conf\"" >"$pkgdir"/etc/conf.d/ziproxy + install -Dm0644 "$srcdir"/ziproxy.logrotate "$pkgdir"/etc/logrotate.d/ziproxy + install -Dm0644 "$srcdir"/ziproxy.xinetd "$pkgdir"/etc/xinetd.d/ziproxy +} Copied: ziproxy/repos/community-staging-x86_64/build-fix.patch (from rev 196549, ziproxy/trunk/build-fix.patch) =================================================================== --- community-staging-x86_64/build-fix.patch (rev 0) +++ community-staging-x86_64/build-fix.patch 2016-11-22 17:40:23 UTC (rev 196550) @@ -0,0 +1,44 @@ +diff -wbBur ziproxy-3.3.0/src/image.c ziproxy-3.3.0.my/src/image.c +--- ziproxy-3.3.0/src/image.c 2013-01-04 20:48:50.000000000 +0400 ++++ ziproxy-3.3.0.my/src/image.c 2014-09-30 18:26:38.277455333 +0400 +@@ -93,6 +93,10 @@ + #define MIN_INSIZE_TO_JPEG 600 + #define MIN_INSIZE_TO_JP2K 800 + ++ ++#define false 0 ++#define true !!0 ++ + //Forwards. There are more utility functions, but they're used only once. + static raw_bitmap *new_raw_bitmap(); + +@@ -905,7 +909,7 @@ + desc.size=insize; + desc.x.pos=0; + +- if ((GifFile = DGifOpen((void*)&desc, &gif_mem_input)) == NULL) ++ if ((GifFile = DGifOpen((void*)&desc, &gif_mem_input, NULL)) == NULL) + return( IMG_RET_ERR_UNKNOWN + IMG_RET_FLG_WHILE_DECOMP);//more possible reasons + + bmp = new_raw_bitmap(); +@@ -1083,7 +1087,7 @@ + } + bmp->pal_bpp = bmp->bpp; + +- DGifCloseFile(GifFile); ++ DGifCloseFile(GifFile, NULL); + return IMG_RET_OK; + } + +diff -wbBur ziproxy-3.3.0/src/qparser.c ziproxy-3.3.0.my/src/qparser.c +--- ziproxy-3.3.0/src/qparser.c 2013-01-04 20:48:50.000000000 +0400 ++++ ziproxy-3.3.0.my/src/qparser.c 2014-09-30 18:28:34.772237049 +0400 +@@ -32,7 +33,7 @@ + // #ifdef __GLIBC__ + // #define _GNU_SOURCE + // #else +-#define QP_BUILD_STRNDUP ++//#define QP_BUILD_STRNDUP + // #endif + + #include <string.h> Copied: ziproxy/repos/community-staging-x86_64/ziproxy.install (from rev 196549, ziproxy/trunk/ziproxy.install) =================================================================== --- community-staging-x86_64/ziproxy.install (rev 0) +++ community-staging-x86_64/ziproxy.install 2016-11-22 17:40:23 UTC (rev 196550) @@ -0,0 +1,16 @@ +# https://wiki.archlinux.org/index.php/UID_and_GID_List +# 0:15 = root:proxy + +post_install() { + getent group proxy >/dev/null || groupadd -r -g 15 proxy + getent passwd proxy >/dev/null || useradd -r -d /var/empty -g 15 -u 15 proxy + mkdir -p /var/log/ziproxy && \ + chown -R 0:15 /var/log/ziproxy && \ + chmod -R ug+w /var/log/ziproxy +} + +post_upgrade() { + mkdir -p /var/log/ziproxy && \ + chown -R 0:15 /var/log/ziproxy && \ + chmod -R ug+w /var/log/ziproxy +} Copied: ziproxy/repos/community-staging-x86_64/ziproxy.logrotate (from rev 196549, ziproxy/trunk/ziproxy.logrotate) =================================================================== --- community-staging-x86_64/ziproxy.logrotate (rev 0) +++ community-staging-x86_64/ziproxy.logrotate 2016-11-22 17:40:23 UTC (rev 196550) @@ -0,0 +1,13 @@ +/var/log/ziproxy/access.log { + su root proxy + weekly + missingok + rotate 10 + compress + delaycompress + ifempty + nomail + postrotate + killall -HUP ziproxy 1>/dev/null 2>/dev/null || true + endscript +} Copied: ziproxy/repos/community-staging-x86_64/ziproxy.xinetd (from rev 196549, ziproxy/trunk/ziproxy.xinetd) =================================================================== --- community-staging-x86_64/ziproxy.xinetd (rev 0) +++ community-staging-x86_64/ziproxy.xinetd 2016-11-22 17:40:23 UTC (rev 196550) @@ -0,0 +1,14 @@ +service ziproxy +{ + port = 3128 + type = UNLISTED + disable = yes + socket_type = stream + wait = no + user = proxy + server = /usr/bin/ziproxy + server_args = -i + bind = 0.0.0.0 + log_on_success += HOST DURATION + log_on_failure += HOST +}