hiredis: Add recipe
PATCH 1/1 hiredis: Add recipe
Hiredis is a C client library for Redis database.
Signed-off-by Marian Pritsak <[email protected]>
--- .../0001-Makefile-remove-hardcoding-of-CC.patch | 32 ++++++++++++++++++++++ meta-oe/recipes-extended/hiredis/hiredis_0.13.1.bb | 24 ++++++++++++++++ 2 files changed, 56 insertions(+) create mode 100644 meta-oe/recipes-extended/hiredis/files/0001-Makefile-remove-hardcoding-of-CC.patch create mode 100644 meta-oe/recipes-extended/hiredis/hiredis_0.13.1.bb
meta-oe/recipes-extended/hiredis/files/0001-Makefile-remove-hardcoding-of-CC.patch new file +32 -0
@@ -0,0 +1,32 @@ +From d13b918a3ff8b0ebfd1e7b18b198b4b45841d720 Mon Sep 17 00:00:00 2001 +From: Andrea Galbusera <[email protected]> +Date: Fri, 31 Jul 2015 16:42:08 +0200 +Subject: [PATCH] Makefile: remove hardcoding of CC + +* upgrade previous patch to avoid wiping CFLAGS. This fixes build on arm +platforms which previously caused and issue due to -fPIC being lost + +Signed-off-by: Andrea Galbusera <[email protected]> +--- + Makefile | 5 ----- + 1 file changed, 5 deletions(-) + +diff --git a/Makefile b/Makefile +index 8b0f0c2..66a4317 100644 +--- a/Makefile ++++ b/Makefile +@@ -34,11 +34,6 @@ define REDIS_TEST_CONFIG + endef + export REDIS_TEST_CONFIG + +-# Fallback to gcc when $CC is not in $PATH. +-CC:=$(shell sh -c 'type $(CC) >/dev/null 2>/dev/null && echo $(CC) || echo gcc') +-OPTIMIZATION?=-O3 +-WARNINGS=-Wall -W -Wstrict-prototypes -Wwrite-strings +-DEBUG?= -g -ggdb + REAL_CFLAGS=$(OPTIMIZATION) -fPIC $(CFLAGS) $(WARNINGS) $(DEBUG) $(ARCH) + REAL_LDFLAGS=$(LDFLAGS) $(ARCH) + +-- +1.9.1 +
meta-oe/recipes-extended/hiredis/hiredis_0.13.1.bb new file +24 -0
@@ -0,0 +1,24 @@ +DESCRIPTION = "Minimalistic C client library for Redis" +HOMEPAGE = "http://github.com/redis/hiredis" +LICENSE = "BSD-3-Clause" +SECTION = "libs" +DEPENDS = "redis" + +LIC_FILES_CHKSUM = "file://COPYING;md5=d84d659a35c666d23233e54503aaea51" +SRC_URI = "git://github.com/redis/hiredis;protocol=git;rev=f58dd249d6ed47a7e835463c3b04722972281dbb \ + file://0001-Makefile-remove-hardcoding-of-CC.patch" + +S = "${WORKDIR}/git" + +inherit autotools + +do_compile() { + cd ${S} + oe_runmake +} + +do_install() { + cd ${S} + oe_runmake PREFIX=${D}/usr INSTALL='cp -r' install + cp hiredis.pc ${D}/${libdir}/pkgconfig/ +}
Signature · 1 line
2.7.4
Quoted 62 lines · Marian Pritsak
Hiredis is a C client library for Redis database.
Signed-off-by Marian Pritsak <[email protected]>--- .../0001-Makefile-remove-hardcoding-of-CC.patch | 32 ++++++++++++++++++++++ meta-oe/recipes-extended/hiredis/hiredis_0.13.1.bb | 24 ++++++++++++++++ 2 files changed, 56 insertions(+) create mode 100644 meta-oe/recipes-extended/hiredis/files/0001-Makefile-remove-hardcoding-of-CC.patch create mode 100644 meta-oe/recipes-extended/hiredis/hiredis_0.13.1.bbmeta-oe/recipes-extended/hiredis/files/0001-Makefile-remove-hardcoding-of-CC.patch new file +32
-0@@ -0,0 +1,32 @@ +From d13b918a3ff8b0ebfd1e7b18b198b4b45841d720 Mon Sep 17 00:00:00 2001 +From: Andrea Galbusera <[email protected]> +Date: Fri, 31 Jul 2015 16:42:08 +0200 +Subject: [PATCH] Makefile: remove hardcoding of CC + +* upgrade previous patch to avoid wiping CFLAGS. This fixes build on arm +platforms which previously caused and issue due to -fPIC being lost + +Signed-off-by: Andrea Galbusera <[email protected]> +--- + Makefile | 5 ----- + 1 file changed, 5 deletions(-) + +diff --git a/Makefile b/Makefile +index 8b0f0c2..66a4317 100644 +--- a/Makefile ++++ b/Makefile +@@ -34,11 +34,6 @@ define REDIS_TEST_CONFIG + endef + export REDIS_TEST_CONFIG + +-# Fallback to gcc when $CC is not in $PATH. +-CC:=$(shell sh -c 'type $(CC) >/dev/null 2>/dev/null && echo $(CC) || echo gcc') +-OPTIMIZATION?=-O3 +-WARNINGS=-Wall -W -Wstrict-prototypes -Wwrite-strings +-DEBUG?= -g -ggdb + REAL_CFLAGS=$(OPTIMIZATION) -fPIC $(CFLAGS) $(WARNINGS) $(DEBUG) $(ARCH) + REAL_LDFLAGS=$(LDFLAGS) $(ARCH) + +-- +1.9.1 +meta-oe/recipes-extended/hiredis/hiredis_0.13.1.bb new file +8
-0@@ -0,0 +1,24 @@ +DESCRIPTION = "Minimalistic C client library for Redis" +HOMEPAGE = "http://github.com/redis/hiredis" +LICENSE = "BSD-3-Clause" +SECTION = "libs" +DEPENDS = "redis" + +LIC_FILES_CHKSUM = "file://COPYING;md5=d84d659a35c666d23233e54503aaea51" +SRC_URI = "git://github.com/redis/hiredis;protocol=git;rev=f58dd249d6ed47a7e835463c3b04722972281dbb \
meta-oe/recipes-extended/hiredis/hiredis_0.13.1.bb line 18
Quoted 10 lines
meta-oe/recipes-extended/hiredis/hiredis_0.13.1.bb new file +10
-0+ file://0001-Makefile-remove-hardcoding-of-CC.patch" + +S = "${WORKDIR}/git" + +inherit autotools + +do_compile() { + cd ${S} + oe_runmake +}
I think you can inherit autotools-brokensep instead of autotools and completely get rid ofdo_compile override
meta-oe/recipes-extended/hiredis/hiredis_0.13.1.bb line 24
Quoted 6 lines
meta-oe/recipes-extended/hiredis/hiredis_0.13.1.bb new file +6
-0+ +do_install() { + cd ${S} + oe_runmake PREFIX=${D}/usr INSTALL='cp -r' install + cp hiredis.pc ${D}/${libdir}/pkgconfig/ +}
you dont need to cd into ${S} then. Can you explain why INSTALL needs to be overridden ?
Quoted 8 lines
--
2.7.4--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel