From 8bf04f284c664c0974c467670c0bdb1c623799e5 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Sun, 28 Jul 2013 09:01:38 +0200 Subject: redis: sync with rawhide + update to 2.6.14 --- redis-deps-PIC.patch | 23 ++++++++++++++ redis-deps-unbundle-jemalloc.patch | 14 +++++++++ redis.spec | 64 ++++++++++++++++++++++++++++++++------ 3 files changed, 91 insertions(+), 10 deletions(-) create mode 100644 redis-deps-PIC.patch create mode 100644 redis-deps-unbundle-jemalloc.patch diff --git a/redis-deps-PIC.patch b/redis-deps-PIC.patch new file mode 100644 index 0000000..944fa35 --- /dev/null +++ b/redis-deps-PIC.patch @@ -0,0 +1,23 @@ +--- a/deps/Makefile ++++ a/deps/Makefile +@@ -58,7 +58,7 @@ ifeq ($(uname_S),SunOS) + LUA_CFLAGS= -D__C99FEATURES__=1 + endif + +-LUA_CFLAGS+= -O2 -Wall -DLUA_ANSI $(CFLAGS) ++LUA_CFLAGS+= -O2 -Wall -fPIC -DLUA_ANSI $(CFLAGS) + LUA_LDFLAGS+= $(LDFLAGS) + + lua: .make-prerequisites +--- a/deps/linenoise/Makefile ++++ a/deps/linenoise/Makefile +@@ -2,7 +2,7 @@ STD= + WARN= -Wall + OPT= -Os + +-R_CFLAGS= $(STD) $(WARN) $(OPT) $(DEBUG) $(CFLAGS) ++R_CFLAGS= $(STD) $(WARN) $(OPT) $(DEBUG) $(CFLAGS) -fPIC + R_LDFLAGS= $(LDFLAGS) + DEBUG= -g + + diff --git a/redis-deps-unbundle-jemalloc.patch b/redis-deps-unbundle-jemalloc.patch new file mode 100644 index 0000000..c68c1f6 --- /dev/null +++ b/redis-deps-unbundle-jemalloc.patch @@ -0,0 +1,14 @@ +--- a/src/Makefile 2013-04-30 15:15:56.000000000 +0200 ++++ b/src/Makefile 2013-06-19 12:58:12.345612310 +0200 +@@ -71,9 +71,8 @@ ifeq ($(MALLOC),tcmalloc_minimal) + endif + + ifeq ($(MALLOC),jemalloc) +- DEPENDENCY_TARGETS+= jemalloc +- FINAL_CFLAGS+= -DUSE_JEMALLOC -I../deps/jemalloc/include +- FINAL_LIBS+= ../deps/jemalloc/lib/libjemalloc.a -ldl ++ FINAL_CFLAGS+= -DUSE_JEMALLOC -DJEMALLOC_NO_DEMANGLE -I/usr/include/jemalloc ++ FINAL_LIBS+= -ljemalloc -ldl + endif + + REDIS_CC=$(QUIET_CC)$(CC) $(FINAL_CFLAGS) diff --git a/redis.spec b/redis.spec index b3fc3d8..f71abd1 100644 --- a/redis.spec +++ b/redis.spec @@ -1,10 +1,18 @@ # Check for status of man pages # http://code.google.com/p/redis/issues/detail?id=202 -%ifarch %{ix86} x86_64 ppc +%global _hardened_build 1 + +%if 0%{?rhel} == 5 +%ifarch i386 +%global with_perftools 1 +%endif +%else +%ifarch %{ix86} x86_64 ppc %{arm} # available only on selected architectures %global with_perftools 1 %endif +%endif %if 0%{?fedora} >= 15 || 0%{?rhel} >= 7 %global with_systemd 1 @@ -12,8 +20,11 @@ %global with_systemd 0 %endif +# Tests fail in mock, not in local build. +%global with_tests %{?_with_tests:1}%{!?_with_tests:0} + Name: redis -Version: 2.6.13 +Version: 2.6.14 Release: %{?prever:0.}1%{?prever:.%{prever}}%{?dist} Summary: A persistent key-value database @@ -26,14 +37,21 @@ Source2: %{name}.init Source3: %{name}.service # Update configuration for Fedora Patch0: %{name}-2.6.10-conf.patch +Patch1: %{name}-deps-PIC.patch +Patch2: %{name}-deps-unbundle-jemalloc.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) %if !0%{?el5} BuildRequires: tcl >= 8.5 +%endif %if 0%{?with_perftools} +%if 0%{?fedora} >= 15 || 0%{?rhel} >=6 +BuildRequires: gperftools-devel +%else BuildRequires: google-perftools-devel %endif %endif +BuildRequires: jemalloc-devel Requires: logrotate Requires(pre): shadow-utils @@ -60,23 +78,29 @@ different kind of sorting abilities. %prep %setup -q -n %{name}-%{version}%{?prever:-%{prever}} -%patch0 -p1 -b .orig - +%patch0 -p1 +%patch1 -p1 +%patch2 -p1 %build -make %{?_smp_mflags} \ +rm -rvf deps/jemalloc + +export CFLAGS="$RPM_OPT_FLAGS" +make %{?_smp_mflags} V=1 \ DEBUG="" \ - CFLAGS='%{optflags}' \ -%if 0%{?rhel} >= 6 || 0%{?fedora} >= 13 + LDFLAGS="%{?__global_ldflags}" \ + CFLAGS="$RPM_OPT_FLAGS -fPIC" \ + LUA_CFLAGS="-fPIC" \ %if 0%{?with_perftools} USE_TCMALLOC=yes \ -%endif %endif all %check -%if !0%{?el5} -# make test +%if %{with_tests} +make test +%else +: Test disabled, missing '--with tests' option. %endif %install @@ -176,6 +200,26 @@ fi %changelog +* Sun Jul 28 2013 Remi Collet - 2.6.14-1 +- Redis 2.6.14 + upgrade urgency: HIGH because of the following two issues: + Lua scripting + Replication + AOF in slaves problem + AOF + expires possible race condition +- add option to run tests during build (not in mock) + +* Tue Jul 23 2013 Peter Robinson 2.6.13-4 +- ARM has gperftools + +* Wed Jun 19 2013 Fabian Deutsch - 2.6.13-3 +- Modify jemalloc patch for s390 compatibility (Thanks sharkcz) + +* Fri Jun 07 2013 Fabian Deutsch - 2.6.13-2 +- Unbundle jemalloc + +* Fri Jun 07 2013 Fabian Deutsch - 2.6.13-1 +- Add compile PIE flag (rhbz#955459) +- Update to redis 2.6.13 (rhbz#820919) + * Tue Apr 30 2013 Remi Collet - 2.6.13-1 - Redis 2.6.13 upgrade urgency: MODERATE, nothing very critical -- cgit