mirror of
git://git.openembedded.org/meta-openembedded
synced 2026-01-04 16:10:10 +00:00
Need to link with libatomics for 64bit atomics support
Fixes
i686-yoe-linux/i686-yoe-linux-ld: networking.o: in function `createClient':
| /usr/src/debug/redis/4.0.14-r0/redis-4.0.14/src/networking.c:103: undefined reference to `__atomic_fetch_add_8'
Signed-off-by: Khem Raj <raj.khem@gmail.com>
(cherry picked from commit 2b49254d61)
Signed-off-by: Armin Kuster <akuster808@gmail.com>
67 lines
2.3 KiB
BlitzBasic
67 lines
2.3 KiB
BlitzBasic
SUMMARY = "Redis key-value store"
|
|
DESCRIPTION = "Redis is an open source, advanced key-value store."
|
|
HOMEPAGE = "http://redis.io"
|
|
SECTION = "libs"
|
|
LICENSE = "BSD"
|
|
LIC_FILES_CHKSUM = "file://COPYING;md5=3c01b49fed4df1a79843688fa3f7b9d6"
|
|
DEPENDS = "readline lua ncurses"
|
|
|
|
SRC_URI = "http://download.redis.io/releases/${BP}.tar.gz \
|
|
file://hiredis-use-default-CC-if-it-is-set.patch \
|
|
file://lua-update-Makefile-to-use-environment-build-setting.patch \
|
|
file://oe-use-libc-malloc.patch \
|
|
file://Fixed-stack-trace-generation-on-aarch64.patch \
|
|
file://0001-src-Do-not-reset-FINAL_LIBS.patch \
|
|
file://redis.conf \
|
|
file://init-redis-server \
|
|
file://redis.service \
|
|
"
|
|
|
|
SRC_URI_append_mips = " file://remove-atomics.patch"
|
|
SRC_URI_append_arm = " file://remove-atomics.patch"
|
|
SRC_URI_append_powerpc = " file://remove-atomics.patch"
|
|
|
|
SRC_URI[md5sum] = "96ae20ffd68b9daee24b702b754d89f3"
|
|
SRC_URI[sha256sum] = "1e1e18420a86cfb285933123b04a82e1ebda20bfb0a289472745a087587e93a7"
|
|
|
|
inherit autotools-brokensep update-rc.d systemd useradd
|
|
|
|
FINAL_LIBS_x86_toolchain-clang = "-latomic"
|
|
export FINAL_LIBS
|
|
|
|
USERADD_PACKAGES = "${PN}"
|
|
USERADD_PARAM_${PN} = "--system --home-dir /var/lib/redis -g redis --shell /bin/false redis"
|
|
GROUPADD_PARAM_${PN} = "--system redis"
|
|
|
|
REDIS_ON_SYSTEMD = "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}"
|
|
|
|
do_compile_prepend() {
|
|
(cd deps && oe_runmake hiredis lua linenoise)
|
|
}
|
|
|
|
do_install() {
|
|
export PREFIX=${D}/${prefix}
|
|
oe_runmake install
|
|
install -d ${D}/${sysconfdir}/redis
|
|
install -m 0644 ${WORKDIR}/redis.conf ${D}/${sysconfdir}/redis/redis.conf
|
|
install -d ${D}/${sysconfdir}/init.d
|
|
install -m 0755 ${WORKDIR}/init-redis-server ${D}/${sysconfdir}/init.d/redis-server
|
|
install -d ${D}/var/lib/redis/
|
|
chown redis.redis ${D}/var/lib/redis/
|
|
|
|
install -d ${D}${systemd_system_unitdir}
|
|
install -m 0644 ${WORKDIR}/redis.service ${D}${systemd_system_unitdir}
|
|
sed -i 's!/usr/sbin/!${sbindir}/!g' ${D}${systemd_system_unitdir}/redis.service
|
|
|
|
if [ "${REDIS_ON_SYSTEMD}" = true ]; then
|
|
sed -i 's!daemonize yes!# daemonize yes!' ${D}/${sysconfdir}/redis/redis.conf
|
|
fi
|
|
}
|
|
|
|
CONFFILES_${PN} = "${sysconfdir}/redis/redis.conf"
|
|
|
|
INITSCRIPT_NAME = "redis-server"
|
|
INITSCRIPT_PARAMS = "defaults 87"
|
|
|
|
SYSTEMD_SERVICE_${PN} = "redis.service"
|