New upstream release

Rebased patches for 5.1.1
Removed patches merged upstream
Pulled support for rhel5 and clones
Updated pkg-varnish checkout to 92373fe
This commit is contained in:
Ingvar Hagelund 2017-03-20 22:48:21 +01:00
parent 02e9bf3c11
commit 435f47b061
5 changed files with 137 additions and 38 deletions

1
.gitignore vendored
View File

@ -22,3 +22,4 @@ varnish-2.1.3.tar.gz
/pkg-varnish-cache-4e27994.tar.gz
/varnish-5.0.0.tar.gz
/pkg-varnish-cache-502fcc0.tar.gz
/varnish-5.1.1.tar.gz

View File

@ -1,2 +1 @@
6c76ff181d21be595a18ae969a692ae7 varnish-5.0.0.tar.gz
5b12768ac45aa55b74370c71235a323c pkg-varnish-cache-502fcc0.tar.gz
SHA512 (varnish-5.1.1.tar.gz) = d5acb1fa9d55f5bb77bea85a6db637769126b701c010cffd511e8ac9fd67853e7f0d3bf86ba1ff067031e14a320b3bc9a84c66cd4a5a6b66d30226f5184f5f05

View File

@ -0,0 +1,41 @@
--- doc/sphinx/Makefile.in.orig 2017-03-16 16:01:18.440999286 +0100
+++ doc/sphinx/Makefile.in 2017-03-16 16:02:38.557728852 +0100
@@ -626,28 +626,38 @@
# XXX add varnishstat here when it's been _opt2rst'ed
include/varnishncsa_options.rst: $(top_builddir)/bin/varnishncsa/varnishncsa
+ LD_LIBRARY_PATH=$(top_builddir)/lib/libvarnishapi/.libs \
$(top_builddir)/bin/varnishncsa/varnishncsa --options > $@
include/varnishncsa_synopsis.rst: $(top_builddir)/bin/varnishncsa/varnishncsa
+ LD_LIBRARY_PATH=$(top_builddir)/lib/libvarnishapi/.libs \
$(top_builddir)/bin/varnishncsa/varnishncsa --synopsis > $@
include/varnishlog_options.rst: $(top_builddir)/bin/varnishlog/varnishlog
+ LD_LIBRARY_PATH=$(top_builddir)/lib/libvarnishapi/.libs \
$(top_builddir)/bin/varnishlog/varnishlog --options > $@
include/varnishlog_synopsis.rst: $(top_builddir)/bin/varnishlog/varnishlog
+ LD_LIBRARY_PATH=$(top_builddir)/lib/libvarnishapi/.libs \
$(top_builddir)/bin/varnishlog/varnishlog --synopsis > $@
include/varnishtop_options.rst: $(top_builddir)/bin/varnishtop/varnishtop
+ LD_LIBRARY_PATH=$(top_builddir)/lib/libvarnishapi/.libs \
$(top_builddir)/bin/varnishtop/varnishtop --options > $@
include/varnishtop_synopsis.rst: $(top_builddir)/bin/varnishtop/varnishtop
+ LD_LIBRARY_PATH=$(top_builddir)/lib/libvarnishapi/.libs \
$(top_builddir)/bin/varnishtop/varnishtop --synopsis > $@
include/varnishhist_options.rst: $(top_builddir)/bin/varnishhist/varnishhist
+ LD_LIBRARY_PATH=$(top_builddir)/lib/libvarnishapi/.libs \
$(top_builddir)/bin/varnishhist/varnishhist --options > $@
include/varnishhist_synopsis.rst: $(top_builddir)/bin/varnishhist/varnishhist
+ LD_LIBRARY_PATH=$(top_builddir)/lib/libvarnishapi/.libs \
$(top_builddir)/bin/varnishhist/varnishhist --synopsis > $@
include/varnishstat_options.rst: $(top_builddir)/bin/varnishstat/varnishstat
+ LD_LIBRARY_PATH=$(top_builddir)/lib/libvarnishapi/.libs \
$(top_builddir)/bin/varnishstat/varnishstat --options > $@
include/varnishstat_synopsis.rst: $(top_builddir)/bin/varnishstat/varnishstat
+ LD_LIBRARY_PATH=$(top_builddir)/lib/libvarnishapi/.libs \
$(top_builddir)/bin/varnishstat/varnishstat --synopsis > $@
include/vsl-tags.rst: $(top_builddir)/lib/libvarnishapi/vsl2rst

View File

@ -0,0 +1,62 @@
--- configure.orig 2017-03-18 02:53:31.235204299 +0100
+++ configure 2017-03-18 02:54:54.229053852 +0100
@@ -13545,13 +13545,13 @@
if test -n "$PYTHON"; then
# If the user set $PYTHON, use it and don't search something else.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $PYTHON version is >= 2.7" >&5
-$as_echo_n "checking whether $PYTHON version is >= 2.7... " >&6; }
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $PYTHON version is >= 2.4" >&5
+$as_echo_n "checking whether $PYTHON version is >= 2.4... " >&6; }
prog="import sys
# split strings by '.' and convert to numeric. Append some zeros
# because we need at least 4 digits for the hex conversion.
# map returns an iterator in Python 3.0 and a list in 2.x
-minver = list(map(int, '2.7'.split('.'))) + [0, 0, 0]
+minver = list(map(int, '2.4'.split('.'))) + [0, 0, 0]
minverhex = 0
# xrange is not present in Python 3.0 and range returns an iterator
for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
@@ -13572,8 +13572,8 @@
else
# Otherwise, try each interpreter until we find one that satisfies
# VERSION.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a Python interpreter with version >= 2.7" >&5
-$as_echo_n "checking for a Python interpreter with version >= 2.7... " >&6; }
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a Python interpreter with version >= 2.4" >&5
+$as_echo_n "checking for a Python interpreter with version >= 2.4... " >&6; }
if ${am_cv_pathless_PYTHON+:} false; then :
$as_echo_n "(cached) " >&6
else
@@ -13584,7 +13584,7 @@
# split strings by '.' and convert to numeric. Append some zeros
# because we need at least 4 digits for the hex conversion.
# map returns an iterator in Python 3.0 and a list in 2.x
-minver = list(map(int, '2.7'.split('.'))) + [0, 0, 0]
+minver = list(map(int, '2.4'.split('.'))) + [0, 0, 0]
minverhex = 0
# xrange is not present in Python 3.0 and range returns an iterator
for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
@@ -13651,7 +13651,7 @@
if test "$PYTHON" = :; then
- as_fn_error $? "Python >= 2.7 is required." "$LINENO" 5
+ as_fn_error $? "Python >= 2.4 is required." "$LINENO" 5
else
@@ -13698,11 +13698,11 @@
can_use_sysconfig = 0
else:
can_use_sysconfig = 1
-# Can't use sysconfig in CPython 2.7, since it's broken in virtualenvs:
+# Can't use sysconfig in CPython 2.4, since it's broken in virtualenvs:
# <https://github.com/pypa/virtualenv/issues/118>
try:
from platform import python_implementation
- if python_implementation() == 'CPython' and sys.version[:3] == '2.7':
+ if python_implementation() == 'CPython' and sys.version[:3] == '2.4':
can_use_sysconfig = 0
except ImportError:
pass"

View File

@ -6,28 +6,26 @@
# Package scripts are now external
# https://github.com/varnishcache/pkg-varnish-cache
%define commit1 502fcc0b19794b98458111b99f77cdc03227dcfc
%define commit1 92373fee0017d6087977e31eb88f9af227b6d9d5
%global shortcommit1 %(c=%{commit1}; echo ${c:0:7})
Summary: High-performance HTTP accelerator
Name: varnish
Version: 5.0.0
Release: 1%{?v_rc}%{?dist}.1
Version: 5.1.1
Release: 1%{?v_rc}%{?dist}
License: BSD
Group: System Environment/Daemons
URL: http://www.varnish-cache.org/
Source0: http://repo.varnish-cache.org/source/%{name}-%{version}%{?vd_rc}.tar.gz
Source1: https://github.com/varnishcache/pkg-varnish-cache/archive/%{commit1}.tar.gz#/pkg-varnish-cache-%{shortcommit1}.tar.gz
Patch1: varnish-5.0.0.fix_ld_library_path_in_doc_build.patch
Patch2: varnish-5.0.0.fix_Werror_el6.patch
Patch3: varnish-5.0.0.fix_python24.el5.patch
Patch1: varnish-5.1.1.fix_ld_library_path_in_doc_build.patch
Patch4: varnish-4.0.3_fix_varnish4_selinux.el6.patch
Patch6: varnish-4.1.0.fix_find-provides.patch
Patch7: varnish-5.0.0.fix_test_suite_on_secondary_arches.patch
Patch9: varnish-5.1.1.fix_python_version.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%if 0%{?rhel} > 5
%if 0%{?rhel} >= 6
BuildRequires: python-sphinx
%endif
BuildRequires: python-docutils
@ -39,6 +37,7 @@ BuildRequires: libedit-devel
BuildRequires: jemalloc-devel
BuildRequires: gcc
BuildRequires: make
BuildRequires: graphviz
%if 0%{?rhel} == 6
BuildRequires: selinux-policy
@ -77,7 +76,7 @@ Requires: gcc
%description
This is Varnish Cache, a high-performance HTTP accelerator.
Varnish Cache stores web pages in memory so web servers don't have to
Varnish Cache stores web pages in memory so web servers dont have to
create the same web page over and over again. Varnish Cache serves
pages much faster than any application server; giving the website a
significant speed up.
@ -102,7 +101,6 @@ Requires: varnish-libs = %{version}-%{release}
Requires: python
Provides: varnish-libs-devel
Obsoletes: varnish-libs-devel
Conflicts: varnish-libs-devel
%description devel
Development files for %{name}-libs
@ -130,17 +128,11 @@ tar xzf %SOURCE1
ln -s pkg-varnish-cache-%{commit1}/redhat redhat
ln -s pkg-varnish-cache-%{commit1}/debian debian
%patch1 -p0
%if 0%{?rhel} <= 6 && 0%{?fedora} <= 12
%patch2 -p0
%endif
%if 0%{?rhel} <= 5 && 0%{?fedora} <= 12
%patch3 -p0
%endif
%if 0%{?rhel} == 6
%patch4 -p0
%patch9 -p0
%endif
%patch6 -p0
%patch7 -p1
%build
%if 0%{?rhel} == 6
@ -148,22 +140,18 @@ export CFLAGS="%{optflags} -fPIC"
export LDFLAGS=" -pie"
%endif
%ifarch i386 i686
# https://gcc.gnu.org/wiki/FAQ#PR323%ifarch i386 i686
%if 0%{?fedora} > 21
export CFLAGS="%{optflags} -ffloat-store -fexcess-precision=standard"
%endif
%if 0%{?rhel} >= 5
%if 0%{?rhel} >= 6
export CFLAGS="%{optflags} -fPIC -ffloat-store"
%endif
%endif
# Man pages are prebuilt. No need to regenerate them.
export RST2MAN=/bin/true
%configure --disable-static \
%if 0%{?rhel} <= 5 && 0%{?fedora} <= 12
--with-rst2man=/bin/true \
%endif
--localstatedir=/var/lib \
--docdir=%{?_pkgdocdir}%{!?_pkgdocdir:%{_docdir}/%{name}-%{version}}
@ -178,16 +166,13 @@ pushd lib/libvarnishapi/.libs
ln -s libvarnishapi.so libvarnishapi.so.1
popd
make %{?_smp_mflags} V=1
%if 0%{?fedora}%{?rhel} != 0 && 0%{?rhel} <= 4 && 0%{?fedora} <= 8
# Old style daemon function
sed -i 's,--pidfile \$pidfile,,g;
s,status -p \$pidfile,status,g;
s,killproc -p \$pidfile,killproc,g' \
redhat/varnish.initrc redhat/varnishncsa.initrc
# Upstream github issue #2265
%if 0%{?rhel} == 6
sed -i 's/-Werror$//g;' bin/varnishd/Makefile
%endif
make %{?_smp_mflags} V=1
# One varnish user is enough
sed -i 's,User=varnishlog,User=varnish,g;' redhat/varnishncsa.service
@ -206,7 +191,7 @@ sed -i "s,\${RPM_BUILD_ROOT}/../../BUILD/varnish\*,%{buildroot}%{_includedir}/%{
%ifarch ppc ppc64
rm bin/varnishtest/tests/u00000.vtc
%endif
make -j4 check LD_LIBRARY_PATH="%{buildroot}%{_libdir}:%{buildroot}%{_libdir}/%{name}" TESTS_PARALLELISM=4 VERBOSE=1
make %{?_smp_mflags} check LD_LIBRARY_PATH="%{buildroot}%{_libdir}:%{buildroot}%{_libdir}/%{name}" VERBOSE=1
%install
rm -rf %{buildroot}
@ -309,10 +294,10 @@ rm -rf %{buildroot}
%defattr(-,root,root,-)
%doc LICENSE
%doc doc/sphinx
%if 0%{?rhel} > 5 || 0%{?fedora} > 12
%doc doc/html
%doc doc/changes*.html
%endif
#if 0%{?rhel} >= 6 || 0%{?fedora} > 12
#doc doc/html
#doc doc/changes*.html
#endif
%if 0%{?rhel} == 6
%files selinux
@ -404,6 +389,17 @@ fi
%endif
%changelog
* Thu Mar 16 2017 Ingvar Hagelund <ingvar@redpill-linpro.com> 5.1.1-1
- New upstream release
- Rebased patches for 5.1.1
- Removed patches merged upstream
- Pulled support for rhel5 and clones
- Updated pkg-varnish checkout to 92373fe
* Mon Feb 13 2017 Ingvar Hagelund <ingvar@redpill-linpro.com> 5.0.0-2
- Updated snapshot of pgk-varnish
- Added a patch for varnish_reload_vcl, fixes stricter vcl names
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 5.0.0-1.1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild