diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2018-02-24 19:58:07 +0000 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2018-02-24 19:58:07 +0000 |
commit | 99abbc5e5a6ecd3fc981b45646fd8cb5d320377b (patch) | |
tree | da76713365257a445f3ae3b95470917f59d46728 /www-servers/varnish | |
parent | 4935506e9a5cbfabd37c64093eac5f36c2ff0017 (diff) |
gentoo resync : 24.02.2018
Diffstat (limited to 'www-servers/varnish')
-rw-r--r-- | www-servers/varnish/Manifest | 3 | ||||
-rw-r--r-- | www-servers/varnish/files/varnish-5.2.0-fix-import.patch | 66 | ||||
-rw-r--r-- | www-servers/varnish/varnish-5.2.1.ebuild | 103 |
3 files changed, 172 insertions, 0 deletions
diff --git a/www-servers/varnish/Manifest b/www-servers/varnish/Manifest index 6b870d1fdb4d..46cfde2105cc 100644 --- a/www-servers/varnish/Manifest +++ b/www-servers/varnish/Manifest @@ -1,4 +1,5 @@ AUX fix-build-x86.patch 871 BLAKE2B 2d08a9e541ce5cc23910124d6bba677bd17287e7158f20395d61bcae3c92fb1a813244051561af71a8482ad47d22659df37f8bd00a54df169e84d4c2ce7a7bd2 SHA512 b46ab9cbfc5e7e4a75d1caf624fab453338531a19a8653550347fc233652199977ea907ba79e4db7822cb5c24f12f48aa765e4d582ba1bbd43edaf88d6b05d7c +AUX varnish-5.2.0-fix-import.patch 1743 BLAKE2B 7b5e428653b419219a3001a95f57bf4b473a1d11c47e66f821a77e90b235467847a356e4c08c5a95e2f33e78e0d1c95ddcd4d461ad28867b4827b99e2573a0ad SHA512 bb64ddd0c15279b448a091b20aff4b36270b42b4d3e7389f98d0c9e54303d47d676eb90e1735e614bcede788466c291a8f809bdea733ddef8ad4f24bd645daf0 AUX varnishd.confd-r4 519 BLAKE2B 18d867add08324ad9ea8b829a747e21c450d6c1f724e18c4318d21ba1647250073d443ea63d721585dc2a274d490a9fb76f14d5e725cc62f483b45be45220463 SHA512 98c8901e53f3c6adb908b9eb01fd441ea53f3c54d4a79aecb1fb1eddfa2fc93de3d0de403a4464a9baff15873b3a20623837e3a37cb225e924a329e32b9e37d6 AUX varnishd.initd-r4 1573 BLAKE2B 79a6583ea337857c58eafcf6dff5cd9646a871116adca6aa5a956bf25b8474394d850afb3c296cc5c920bad0176ca144a486b7202d3a94e7ab7e4688c552be5d SHA512 5ac7867e85cbd721f903c524ed4b524423d9dada4acfeefb0e543214a208828df5cc4efe2f012991bea6b38c2b223c24b17d3890ec4ed2c57d2b441b8e5a6900 AUX varnishd.logrotate-r2 470 BLAKE2B c44ccd8198458031b977e3d0d1b6ef1a0c824554b7b1d9745e6bbbcddb7cf1c9ba23bd72472361bfda803f9691276433f3af422819aa3e6e8e5436f66cc47097 SHA512 51cc6d46ff7439de93977ab87dfb0af399458c1e446475696f73342ae7a0c1a8ca8fc6e79e593659f1af30716a5f8a1ee5e3b1f5e7b35df40b45d47e7b0f2ffd @@ -10,7 +11,9 @@ AUX varnishncsa.initd 716 BLAKE2B 33fd6b044ab50aef629fa4501eb4a78bd3d690db52b86a DIST varnish-4.0.5.tgz 1947888 BLAKE2B d921dc6f2abae7b0bd1816470fd41f8555c02a02607b49bf8f36a0b778dd926ea0f5e8cf8a60aaceb097bd4193e22fc7d718c1f13a4f8502b57b797277c66f5a SHA512 a08259f6f9c6fffa188b26c1f8c630de5e6d2f6d52f6efa9d5d8239cdd8721c53e2be3379f8100efb537e74416eadd6c865f4cc687db1c5a9f757bb3f73abeda DIST varnish-4.1.8.tgz 2254772 BLAKE2B acadf4079d58bb8f0dc5e24713aba7f2786ca6f06a683465b1564bacd986e209d858f9a3100cfb7586fa5d17f7e5f4d8425ece10c609bb3412d3adafa6ad0d05 SHA512 c642359118d87e8713d2ccf817da317a454a0f9ae6f7a07da1d10b5076aa7e5d7dcc203ef71ae19d56b7592db0c66b4ca96cb43d5fa0e6aa588d1dc8e03e026e DIST varnish-5.1.3.tgz 2643223 BLAKE2B 85bae87785da1284d7d916b8948a0984eea9cf07e96012255435ba04c28e8078e5dad893946bbc12da6cbe9326699458f0e3af6be55cb5e7bba4e622724ddac2 SHA512 a10c317dc38ddff139ca8153f6388955df449c3abeb4d4f069b632ba2b32064a2827ab05fa8515994b251a68507fc3a7bf4e08eacc991fc03283ab234b9efd0a +DIST varnish-5.2.1.tgz 2827676 BLAKE2B 6f50a55a9b16d137eaec59aea98a0179b808bb67fc3de26c9b0924b9937a3688b7f9db45d2f0a71be2b7c6f77bfd47cd22e7b898348b5236114572b5bb33ff22 SHA512 2e979983c7f2325e289768752cc474dc3032c3420de65ccfd5871098c076aecf18e962b04308ecb1860f542fd6f6418dc79220fdd6cf4a75f7476a733faa589c EBUILD varnish-4.0.5.ebuild 2053 BLAKE2B fe89edbd9be61d6e0d9492f92b66778373eda0dca0d05af3d4ab6400b93ad977ce2611e79c4588e5ac67364332524799514b4e205db5f7747bfc362f882a810c SHA512 b25494d96fdc186add8c86f4d97fd8357f9d98fff6f466db32a5f5fe1f6670bb421206edc859a00978f27f23ece1d15f34a09a1619195e426245d8c18f779a75 EBUILD varnish-4.1.8.ebuild 2211 BLAKE2B 67e3be2c4749a707de437f0bdd20298e816e4beca0fae142ae2fa06ae5f47dc6f0fd197260e5e60ae1bc308c3d506d16de91e13431fb62bf6b4cff3a68edcbc3 SHA512 50406243450dff96b7d50684fd0be71dd972b03afccdd3d550b13f45ac04732e0eadd92bc42512a8b4196759125be93f8e4bb09ebd606ee7343c0a75dce96836 EBUILD varnish-5.1.3.ebuild 2216 BLAKE2B 42c69830b206782e10cec132b863c1fa2bcac9f6af27bb5266230571fdbdc5cfd17504a571f271e6668848fb59c040b53d05ccc80ea3a8bee554ae05b131c58e SHA512 1e93b34978c8f554520f673f7bdc6a8acca307735fcd4361aeb125887a9efb9912a9aaba7f4d0a6d61ad768b903d8ed46bf43f8b546d346c4b16783d231047d1 +EBUILD varnish-5.2.1.ebuild 2270 BLAKE2B 4d6f096b4cfecb61fee72d9e184f498fb99ef8bff52be08d43ec751433990b407ba7897c9301de62d37e487da0a1b90e1352c400ecaec0acb318047ec1d4db1f SHA512 605b4d2f480aad4644a1363b4190053143e3d0eaf0de20eec35cd85cb43e9c40f590f1d2a592ad0cce9824317cc2562bb2b91d08a37c254ce5e3835b7348dfb8 MISC metadata.xml 1258 BLAKE2B 7022b186f4fcffa296f034811c1bc037c29f6d21b990d2c80771cca9243ed8406341908a2ee32ded7ac97573b6a809798cadbb9aa6c9ad9f100a7b7e251fb720 SHA512 052377552103c4ee337e931cc84d5e86d1381473484bb2f1133143219cb3d9ba9b4a78cdd411f3523c424f7637df51bbd2b9c0c9a22520314152f811644f04b7 diff --git a/www-servers/varnish/files/varnish-5.2.0-fix-import.patch b/www-servers/varnish/files/varnish-5.2.0-fix-import.patch new file mode 100644 index 000000000000..f83385a3f8e7 --- /dev/null +++ b/www-servers/varnish/files/varnish-5.2.0-fix-import.patch @@ -0,0 +1,66 @@ +From 17c92e43fda114bf5341e51d752e882238b8fe8c Mon Sep 17 00:00:00 2001 +From: Nils Goroll <nils.goroll@uplex.de> +Date: Thu, 5 Oct 2017 13:39:23 +0200 +Subject: [PATCH] hack up vsctool to work with python 2 and 3 + +StringIO does not exist any more in python3, yet requiring 2.7 would +not pave the path forward, so try to be compatible with both. + +Works for me on Python 2.7.9 and Python 3.4 + +I would appreciate if someone more fluent in serpentinous programming +language reviewed and/or rewrote this. +--- + lib/libvcc/vsctool.py | 24 ++++++++++++++++++++---- + 1 file changed, 20 insertions(+), 4 deletions(-) + +diff --git a/lib/libvcc/vsctool.py b/lib/libvcc/vsctool.py +index 854968e3b..829c6e518 100644 +--- a/lib/libvcc/vsctool.py ++++ b/lib/libvcc/vsctool.py +@@ -37,7 +37,10 @@ + import json + import sys + import gzip +-import StringIO ++try: ++ import StringIO ++except ImportError: ++ import io + import collections + import struct + +@@ -54,9 +57,22 @@ + "format": [ "integer", FORMATS], + } + ++# http://python3porting.com/problems.html#bytes-strings-and-unicode ++if sys.version_info < (3,): ++ def b(x): ++ return x ++else: ++ import codecs ++ def b(x): ++ return codecs.latin_1_encode(x)[0] ++ + def gzip_str(s): +- out = StringIO.StringIO() +- gzip.GzipFile(fileobj=out, mode="w").write(s) ++ try: ++ out = StringIO.StringIO() ++ except NameError: ++ out = io.BytesIO() ++ ++ gzip.GzipFile(fileobj=out, mode="w").write(b(s)) + out.seek(4) + out.write(struct.pack("<L", 0x12bfd58)) + return out.getvalue() +@@ -285,7 +301,7 @@ class rst_vsc(directive): + def __init__(self, s): + super(rst_vsc, self).__init__(s) + +- for i,v in PARAMS.iteritems(): ++ for i,v in PARAMS.items(): + if v is not True: + self.do_default(i, v[0], v[1]) + diff --git a/www-servers/varnish/varnish-5.2.1.ebuild b/www-servers/varnish/varnish-5.2.1.ebuild new file mode 100644 index 000000000000..3a01a4558676 --- /dev/null +++ b/www-servers/varnish/varnish-5.2.1.ebuild @@ -0,0 +1,103 @@ +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="6" + +PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} pypy ) + +inherit user autotools systemd python-r1 + +DESCRIPTION="Varnish is a state-of-the-art, high-performance HTTP accelerator" +HOMEPAGE="http://www.varnish-cache.org/" +SRC_URI="http://varnish-cache.org/_downloads/${P}.tgz" + +LICENSE="BSD-2 GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~mips ~ppc ~ppc64 ~x86" +IUSE="jemalloc jit static-libs" + +CDEPEND=" + sys-libs/readline:0= + dev-libs/libpcre[jit?] + jemalloc? ( dev-libs/jemalloc ) + sys-libs/ncurses:0=" + +#varnish compiles stuff at run time +RDEPEND=" + ${PYTHON_DEPS} + ${CDEPEND} + sys-devel/gcc" + +DEPEND=" + ${CDEPEND} + dev-python/docutils + virtual/pkgconfig" + +REQUIRED_USE="${PYTHON_REQUIRED_USE}" + +RESTRICT="test" #315725 + +pkg_setup() { + ebegin "Creating varnish user and group" + enewgroup varnish + enewuser varnish -1 -1 /var/lib/varnish varnish + eend $? +} + +src_prepare() { + # Remove -Werror bug #528354 + sed -i -e 's/-Werror\([^=]\)/\1/g' configure.ac + + # Upstream doesn't put varnish.m4 in the m4/ directory + # We link because the Makefiles look for the file in + # the original location + ln -sf ../varnish.m4 m4/varnish.m4 + + eapply "${FILESDIR}"/${PN}-5.2.0-fix-import.patch + + eapply_user + + eautoreconf +} + +src_configure() { + econf \ + $(use_enable static-libs static) \ + $(use_enable jit pcre-jit ) \ + $(use_with jemalloc) +} + +src_install() { + emake DESTDIR="${D}" install + + python_replicate_script "${D}/usr/share/varnish/vmodtool.py" + + newinitd "${FILESDIR}"/varnishlog.initd varnishlog + newconfd "${FILESDIR}"/varnishlog.confd varnishlog + + newinitd "${FILESDIR}"/varnishncsa.initd varnishncsa + newconfd "${FILESDIR}"/varnishncsa.confd varnishncsa + + newinitd "${FILESDIR}"/varnishd.initd-r4 varnishd + newconfd "${FILESDIR}"/varnishd.confd-r4 varnishd + + insinto /etc/logrotate.d/ + newins "${FILESDIR}/varnishd.logrotate-r2" varnishd + + diropts -m750 + + dodir /var/log/varnish/ + + systemd_dounit "${FILESDIR}/${PN}d.service" + + insinto /etc/varnish/ + doins lib/libvmod_std/vmod.vcc + doins etc/example.vcl + + dodoc README.rst + dodoc doc/changes.rst + + fowners root:varnish /etc/varnish/ + fowners varnish:varnish /var/lib/varnish/ + fperms 0750 /var/lib/varnish/ /etc/varnish/ +} |