From fb4775ada16e32f4862103ae05bf3f92bf5e99f9 Mon Sep 17 00:00:00 2001 From: David Tardon Date: Tue, 27 Jan 2015 19:00:23 +0100 Subject: [PATCH] install all headers --- 0001-Fix-Makefile-install-problems.patch | 43 ++++++++++++++++++++++++ hiredis.spec | 9 ++++- 2 files changed, 51 insertions(+), 1 deletion(-) create mode 100644 0001-Fix-Makefile-install-problems.patch diff --git a/0001-Fix-Makefile-install-problems.patch b/0001-Fix-Makefile-install-problems.patch new file mode 100644 index 0000000..4798581 --- /dev/null +++ b/0001-Fix-Makefile-install-problems.patch @@ -0,0 +1,43 @@ +From 4355ab3c8fa7ad98b8a21267f84ebbaf47e2d2f8 Mon Sep 17 00:00:00 2001 +From: Sebastian Wiedenroth +Date: Fri, 23 Jan 2015 19:01:19 +0100 +Subject: [PATCH] Fix Makefile install problems + +Adds DESTDIR support +Fixes INSTALL_PKGCONF_PATH +Properly copies {read,shs}.h now during make install + +Closes #297 +--- + Makefile | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +diff --git a/Makefile b/Makefile +index d683aec..c2cee1a 100644 +--- a/Makefile ++++ b/Makefile +@@ -18,9 +18,9 @@ PREFIX?=/usr/local + INCLUDE_PATH?=include/hiredis + LIBRARY_PATH?=lib + PKGCONF_PATH?=pkgconfig +-INSTALL_INCLUDE_PATH= $(PREFIX)/$(INCLUDE_PATH) +-INSTALL_LIBRARY_PATH= $(PREFIX)/$(LIBRARY_PATH) +-INSTALL_PKGCONF_PATH= $(LIBRARY_PATH)/$(PKGCONF_PATH) ++INSTALL_INCLUDE_PATH= $(DESTDIR)$(PREFIX)/$(INCLUDE_PATH) ++INSTALL_LIBRARY_PATH= $(DESTDIR)$(PREFIX)/$(LIBRARY_PATH) ++INSTALL_PKGCONF_PATH= $(INSTALL_LIBRARY_PATH)/$(PKGCONF_PATH) + + # redis-server configuration used for testing + REDIS_PORT=56379 +@@ -162,7 +162,7 @@ $(PKGCONFNAME): $(PKGCONF_SRCNAME) + + install: $(DYLIBNAME) $(STLIBNAME) + mkdir -p $(INSTALL_INCLUDE_PATH) $(INSTALL_LIBRARY_PATH) +- $(INSTALL) hiredis.h async.h adapters $(INSTALL_INCLUDE_PATH) ++ $(INSTALL) hiredis.h async.h read.h sds.h adapters $(INSTALL_INCLUDE_PATH) + $(INSTALL) $(DYLIBNAME) $(INSTALL_LIBRARY_PATH)/$(DYLIB_MINOR_NAME) + cd $(INSTALL_LIBRARY_PATH) && ln -sf $(DYLIB_MINOR_NAME) $(DYLIB_MAJOR_NAME) + cd $(INSTALL_LIBRARY_PATH) && ln -sf $(DYLIB_MAJOR_NAME) $(DYLIBNAME) +-- +2.1.0 + diff --git a/hiredis.spec b/hiredis.spec index 38f466a..8071a62 100644 --- a/hiredis.spec +++ b/hiredis.spec @@ -1,11 +1,13 @@ Name: hiredis Version: 0.12.0 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Minimalistic C client library for Redis License: BSD URL: https://github.com/redis/hiredis Source0: https://github.com/redis/hiredis/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz +Patch0: 0001-Fix-Makefile-install-problems.patch + %description Hiredis is a minimalistic C client library for the Redis database. @@ -20,6 +22,8 @@ developing applications that use %{name}. %prep %setup -q +%patch0 -p1 + %build make %{?_smp_mflags} OPTIMIZATION="%{optflags}" LDFLAGS="%{?__global_ldflags}" @@ -67,6 +71,9 @@ make test || true %{_libdir}/pkgconfig/hiredis.pc %changelog +* Tue Jan 27 2015 David Tardon - 0.12.0-2 +- install all headers + * Fri Jan 23 2015 Christopher Meng - 0.12.0-1 - Update to 0.12.0