mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-23 00:43:28 +00:00
03dc71ceac
<ChangeLog> # UPGRADE URGENCY: LOW for Redis, LOW for Sentinel. However this release adds new features so users may want to upgrade in order to exploit the new functionalities. * [FIX] Sometimes the absolute config file path was obtained in a wrong way. This happened when there was a "dir" directive inside the config file and at the same time the configuration file was given as a relative path to redis-server or redis-sentinel executables. * [FIX] redis-cli: Automatically enter --slave mode when SYNC or PSYNC are called during an interactive session. * [FIX] Sentinel "IDONTKNOW" error removed as it does not made sense with the new Sentinel design. This error was actually a fix for a design error in the first implementation of Sentinel. * [FIX] Sentinel: added a missing exit() call to abort after config file checks at startup. This error was introduced with an improvement in a previous 2.8 release. * [FIX] BITCOUNT: fixed unaligned access causing issues in sparc and other archs not capable of dealing with unaligned accesses. This also makes the code faster in archs where unaligned accesses are allowed. * [FIX] Sentinel: better nodes fail over start time desynchronization to avoid split-brain during the voting process needed to get authorization to fail over. This means the system is less likely to need to retry and will fail over faster. No changes in behavior / correctness. * [FIX] Force INFO used_memory_peak to match peak memory. This generated some confusion among users even if it was not an actual bug. * [NEW] Sentinel unit tests and framework. More tests needed and units must be improved in order to have less false positives, but it is a start and features a debugging console that is useful to fix tests or to inspect bugs causing tests failures. * [NEW] New Sentinel events: +/-monitor and +set used to monitor when an instance to monitor is added or removed, or when a configuration is modified via SENTINEL SET. * [NEW] Redis-cli updated to use SCAN instead of random sampling via RANDOMKEY in order to implement --bigkeys feature. Moreover the implementation now supports pipelining and reports more information at the end of the scan. Much faster, much better. A special thank you to Michael Grunder for this improvement. * [NEW] redis-cli now supports a new --intrinsic-latency mode that is able to meter the latency of a system due to kernel / hypervisor. How to use it is explained at http://redis.io/topics/latency. * [NEW] New command BITPOS: find first bit set or clear in a bitmap. * [NEW] CONFIG REWRITE calls are now logged. </ChangeLog>
101 lines
2.4 KiB
Makefile
101 lines
2.4 KiB
Makefile
# Created by: Sergey Skvortsov <skv@protey.ru>
|
|
# $FreeBSD$
|
|
|
|
PORTNAME= redis
|
|
DISTVERSION= 2.8.7
|
|
CATEGORIES= databases
|
|
MASTER_SITES= http://download.redis.io/releases/
|
|
|
|
MAINTAINER= osa@FreeBSD.org
|
|
COMMENT= A persistent key-value database with built-in net interface
|
|
|
|
LICENSE= BSD
|
|
|
|
LIB_DEPENDS= libexecinfo.so:${PORTSDIR}/devel/libexecinfo
|
|
|
|
OPTIONS_DEFINE= TESTS
|
|
OPTIONS_RADIO= EXTLUA
|
|
OPTIONS_RADIO_EXTLUA= LUA LUAJIT
|
|
LUA_DESC= Use lang/lua instead of builtin lua
|
|
LUAJIT_DESC= Use lang/luajit instead of builtin lua
|
|
TESTS_DESC= Install lang/tcl for redis unit tests
|
|
|
|
NO_STAGE= yes
|
|
|
|
.include <bsd.port.options.mk>
|
|
|
|
.if ${PORT_OPTIONS:MLUA}
|
|
USE_LUA?= 5.1
|
|
EXTRA_PATCHES+= ${PATCHDIR}/extra-patch-src-Makefile.lua
|
|
CFLAGS+= -fPIC
|
|
LDFLAGS+= -Wl,-E
|
|
.endif
|
|
|
|
.if ${PORT_OPTIONS:MLUAJIT}
|
|
LIB_DEPENDS+= libluajit-5.1.so:${PORTSDIR}/lang/luajit
|
|
EXTRA_PATCHES+= ${PATCHDIR}/extra-patch-src-Makefile.luajit
|
|
CFLAGS+= -fPIC
|
|
LDFLAGS+= -Wl,-E
|
|
.endif
|
|
|
|
.if ${PORT_OPTIONS:MTESTS}
|
|
USES+= tcl:build
|
|
.endif
|
|
|
|
CFLAGS+= -I${LOCALBASE}/include
|
|
LDFLAGS+= -L${LOCALBASE}/lib ${PTHREAD_LIBS} -lm -lexecinfo
|
|
|
|
CONFLICTS?= redis-devel-2.*
|
|
|
|
USES+= gmake
|
|
MAKE_ENV= "V=yo"
|
|
USE_RC_SUBR= redis
|
|
BIN_FILES= redis-benchmark redis-check-aof redis-check-dump \
|
|
redis-cli redis-sentinel redis-server
|
|
|
|
PKGMESSAGE= ${WRKDIR}/pkg-message
|
|
|
|
USERS= redis
|
|
GROUPS= redis
|
|
|
|
REDIS_DBDIR?= /var/db/redis
|
|
REDIS_RUNDIR?= /var/run/redis
|
|
REDIS_LOGDIR?= /var/log/redis
|
|
|
|
SUB_FILES= pkg-message
|
|
SUB_LIST+= PORTNAME=${PORTNAME} \
|
|
REDIS_USER=${USERS} \
|
|
REDIS_DBDIR=${REDIS_DBDIR} \
|
|
REDIS_LOGDIR=${REDIS_LOGDIR} \
|
|
REDIS_RUNDIR=${REDIS_RUNDIR}
|
|
|
|
PLIST_SUB+= REDIS_USER=${USERS} \
|
|
REDIS_GROUP=${GROUPS} \
|
|
REDIS_LOGDIR=${REDIS_LOGDIR} \
|
|
REDIS_DBDIR=${REDIS_DBDIR} \
|
|
REDIS_RUNDIR=${REDIS_RUNDIR}
|
|
|
|
.if ${PORT_OPTIONS:MLUAJIT} || ${PORT_OPTIONS:MLUA}
|
|
post-patch:
|
|
@cd ${WRKSRC}/deps/lua/src && ${CP} lua_* strbuf.* ${WRKSRC}/src/
|
|
.endif
|
|
|
|
post-build:
|
|
${SED} ${SUB_LIST:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} \
|
|
${WRKSRC}/redis.conf > ${WRKDIR}/redis.conf
|
|
|
|
do-install:
|
|
${INSTALL_PROGRAM} ${BIN_FILES:C!^!${WRKSRC}/src/!} ${PREFIX}/bin/
|
|
${INSTALL_DATA} ${WRKDIR}/redis.conf ${PREFIX}/etc/redis.conf.sample
|
|
${INSTALL_DATA} ${WRKSRC}/sentinel.conf ${PREFIX}/etc/sentinel.conf.sample
|
|
|
|
post-install:
|
|
.for d in ${REDIS_LOGDIR} ${REDIS_RUNDIR} ${REDIS_DBDIR}
|
|
[ -d ${d} ] || ${MKDIR} ${d} && ${CHOWN} ${USERS}:${GROUPS} ${d}
|
|
.endfor
|
|
|
|
regression-test: build
|
|
@cd ${WRKSRC} && ${TCLSH} tests/test_helper.tcl
|
|
|
|
.include <bsd.port.mk>
|