1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-23 04:23:08 +00:00
freebsd-ports/databases/redis4/files/patch-deps-hiredis-Makefile
Sergey A. Osokin 89e0b04783 Repocopy the databases/redis to the databases/redis4 to update
the databases/redis port to the latest stable version, 5.0.6.

PR:		241526
Reviewed by:	portmgr (adamw)
Approved by:	portmgr (adamw)
Differential Revision:	https://reviews.freebsd.org/D22336
2019-11-21 19:27:39 +00:00

42 lines
1.4 KiB
Plaintext

--- deps/hiredis/Makefile.orig 2017-05-01 19:46:31.733229000 -0400
+++ deps/hiredis/Makefile 2017-05-01 19:48:37.150358000 -0400
@@ -15,7 +15,7 @@
HIREDIS_SONAME=$(shell grep HIREDIS_SONAME hiredis.h | awk '{print $$3}')
# Installation related variables and target
-PREFIX?=/usr/local
+PREFIX?=${PREFIX}
INCLUDE_PATH?=include/hiredis
LIBRARY_PATH?=lib
PKGCONF_PATH?=pkgconfig
@@ -38,10 +38,10 @@
# Fallback to gcc when $CC is not in $PATH.
CC:=$(shell sh -c 'type $(CC) >/dev/null 2>/dev/null && echo $(CC) || echo gcc')
CXX:=$(shell sh -c 'type $(CXX) >/dev/null 2>/dev/null && echo $(CXX) || echo g++')
-OPTIMIZATION?=-O3
+#OPTIMIZATION?=-O3
WARNINGS=-Wall -W -Wstrict-prototypes -Wwrite-strings
-DEBUG_FLAGS?= -g -ggdb
-REAL_CFLAGS=$(OPTIMIZATION) -fPIC $(CFLAGS) $(WARNINGS) $(DEBUG_FLAGS) $(ARCH)
+#DEBUG_FLAGS?= -g -ggdb
+REAL_CFLAGS=$(OPTIMIZATION) -fPIC $(CFLAGS) $(WARNINGS) $(DEBUG_FLAGS)
REAL_LDFLAGS=$(LDFLAGS) $(ARCH)
DYLIBSUFFIX=so
@@ -60,6 +60,15 @@
DYLIB_MAKE_CMD=$(CC) -G -o $(DYLIBNAME) -h $(DYLIB_MINOR_NAME) $(LDFLAGS)
INSTALL= cp -r
endif
+ifeq ($(uname_S),FreeBSD)
+ CFLAGS?=$(CFLAGS)
+ CCLINK?=-pthread
+ LDFLAGS?=-L. -Wl,-rpath,.
+ DYLIBNAME?=libhiredis.so
+ DYLIB_MAKE_CMD?=$(CC) -o ${DYLIBNAME} ${OBJ}
+ STLIBNAME?=libhiredis.a
+ STLIB_MAKE_CMD?=ar rcs ${STLIBNAME} ${OBJ}
+endif
ifeq ($(uname_S),Darwin)
DYLIBSUFFIX=dylib
DYLIB_MINOR_NAME=$(LIBNAME).$(HIREDIS_SONAME).$(DYLIBSUFFIX)