Skip to content

Commit

Permalink
[Core] Upgrade redis to 7.2.2 and spdlog to 1.12.0 (ray-project#40852)
Browse files Browse the repository at this point in the history
Upgrade redis and spdlog so that ray can be compiled on mac 13.5.2+.

Signed-off-by: Jiajun Yao <[email protected]>
  • Loading branch information
jjyao authored Nov 1, 2023
1 parent 0d0678c commit f811e3e
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 32 deletions.
8 changes: 4 additions & 4 deletions bazel/ray_deps_setup.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -107,8 +107,8 @@ def ray_deps_setup():
name = "com_github_antirez_redis",
build_file = "@com_github_ray_project_ray//bazel:BUILD.redis",
patch_args = ["-p1"],
url = "https://github.com/redis/redis/archive/refs/tags/7.0.8.tar.gz",
sha256 = "0e439cbc19f6db5a4c63d355519ab73bf6ac2ecd47df806c14b19564b3d0c593",
url = "https://github.com/redis/redis/archive/refs/tags/7.2.3.tar.gz",
sha256 = "afd656dbc18a886f9a1cc08a550bf5eb89de0d431e713eba3ae243391fb008a6",
patches = [
"@com_github_ray_project_ray//thirdparty/patches:redis-quiet.patch",
],
Expand All @@ -128,8 +128,8 @@ def ray_deps_setup():
auto_http_archive(
name = "com_github_spdlog",
build_file = "@com_github_ray_project_ray//bazel:BUILD.spdlog",
urls = ["https://github.com/gabime/spdlog/archive/v1.7.0.zip"],
sha256 = "c8f1e1103e0b148eb8832275d8e68036f2fdd3975a1199af0e844908c56f6ea5",
urls = ["https://github.com/gabime/spdlog/archive/v1.12.0.zip"],
sha256 = "6174bf8885287422a6c6a0312eb8a30e8d22bcfcee7c48a6d02d1835d7769232",
)

auto_http_archive(
Expand Down
63 changes: 35 additions & 28 deletions thirdparty/patches/redis-quiet.patch
Original file line number Diff line number Diff line change
@@ -1,84 +1,91 @@
diff --git a/deps/Makefile b/deps/Makefile
index 8592e17..0c13eea 100644
index 3bf0363d5..ea5d12cd4 100644
--- a/deps/Makefile
+++ b/deps/Makefile
@@ -49,19 +49,19 @@ ifeq ($(BUILD_TLS),yes)
@@ -51,25 +51,25 @@ ifneq (,$(filter $(BUILD_TLS),yes module))
endif

hiredis: .make-prerequisites
- @printf '%b %b\n' $(MAKECOLOR)MAKE$(ENDCOLOR) $(BINCOLOR)$@$(ENDCOLOR)
+ #@printf '%b %b\n' $(MAKECOLOR)MAKE$(ENDCOLOR) $(BINCOLOR)$@$(ENDCOLOR)
cd hiredis && $(MAKE) static $(HIREDIS_MAKE_FLAGS)

.PHONY: hiredis

linenoise: .make-prerequisites
- @printf '%b %b\n' $(MAKECOLOR)MAKE$(ENDCOLOR) $(BINCOLOR)$@$(ENDCOLOR)
+ #@printf '%b %b\n' $(MAKECOLOR)MAKE$(ENDCOLOR) $(BINCOLOR)$@$(ENDCOLOR)
cd linenoise && $(MAKE)

.PHONY: linenoise

hdr_histogram: .make-prerequisites
- @printf '%b %b\n' $(MAKECOLOR)MAKE$(ENDCOLOR) $(BINCOLOR)$@$(ENDCOLOR)
+ #@printf '%b %b\n' $(MAKECOLOR)MAKE$(ENDCOLOR) $(BINCOLOR)$@$(ENDCOLOR)
cd hdr_histogram && $(MAKE)

.PHONY: hdr_histogram
@@ -85,7 +85,7 @@ AR=ar

fpconv: .make-prerequisites
- @printf '%b %b\n' $(MAKECOLOR)MAKE$(ENDCOLOR) $(BINCOLOR)$@$(ENDCOLOR)
+ #@printf '%b %b\n' $(MAKECOLOR)MAKE$(ENDCOLOR) $(BINCOLOR)$@$(ENDCOLOR)
cd fpconv && $(MAKE)

.PHONY: fpconv
@@ -98,7 +98,7 @@ AR=ar
ARFLAGS=rc

lua: .make-prerequisites
- @printf '%b %b\n' $(MAKECOLOR)MAKE$(ENDCOLOR) $(BINCOLOR)$@$(ENDCOLOR)
+ #@printf '%b %b\n' $(MAKECOLOR)MAKE$(ENDCOLOR) $(BINCOLOR)$@$(ENDCOLOR)
cd lua/src && $(MAKE) all CFLAGS="$(LUA_CFLAGS)" MYLDFLAGS="$(LUA_LDFLAGS)" AR="$(AR) $(ARFLAGS)"

.PHONY: lua
@@ -98,7 +98,7 @@ JEMALLOC_CONFIGURE_OPTS += --host=$(DEB_HOST_GNU_TYPE)
@@ -111,7 +111,7 @@ JEMALLOC_CONFIGURE_OPTS += --host=$(DEB_HOST_GNU_TYPE)
endif

jemalloc: .make-prerequisites
- @printf '%b %b\n' $(MAKECOLOR)MAKE$(ENDCOLOR) $(BINCOLOR)$@$(ENDCOLOR)
+ #@printf '%b %b\n' $(MAKECOLOR)MAKE$(ENDCOLOR) $(BINCOLOR)$@$(ENDCOLOR)
cd jemalloc && ./configure --with-version=5.2.1-0-g0 --with-lg-quantum=3 --with-jemalloc-prefix=je_ CFLAGS="$(JEMALLOC_CFLAGS)" LDFLAGS="$(JEMALLOC_LDFLAGS)" $(JEMALLOC_CONFIGURE_OPTS)
cd jemalloc && $(MAKE) CFLAGS="$(JEMALLOC_CFLAGS)" LDFLAGS="$(JEMALLOC_LDFLAGS)" lib/libjemalloc.a
cd jemalloc && ./configure --disable-cxx --with-version=5.3.0-0-g0 --with-lg-quantum=3 --disable-cache-oblivious --with-jemalloc-prefix=je_ CFLAGS="$(JEMALLOC_CFLAGS)" LDFLAGS="$(JEMALLOC_LDFLAGS)" $(JEMALLOC_CONFIGURE_OPTS)
cd jemalloc && $(MAKE) lib/libjemalloc.a

diff --git a/deps/jemalloc/Makefile.in b/deps/jemalloc/Makefile.in
index 7128b00..da8e429 100644
index 1193cd859..140995eb5 100644
--- a/deps/jemalloc/Makefile.in
+++ b/deps/jemalloc/Makefile.in
@@ -406,7 +406,7 @@ $(objroot)include/jemalloc/internal/private_namespace_jet.gen.h: $(C_JET_SYMS)
@@ -496,7 +496,7 @@ $(objroot)include/jemalloc/internal/private_namespace_jet.gen.h: $(C_JET_SYMS)
$(SHELL) $(srcroot)include/jemalloc/internal/private_namespace.sh $^ > $@

%.h: %.gen.h
- @if ! `cmp -s $< $@` ; then echo "cp $< $<"; cp $< $@ ; fi
- @if ! `cmp -s $< $@` ; then echo "cp $< $@"; cp $< $@ ; fi
+ @if ! `cmp -s $< $@` ; then cp $< $@ ; fi

$(CPP_OBJS) $(CPP_PIC_OBJS) $(TESTS_CPP_OBJS): %.$(O):
@mkdir -p $(@D)
diff --git a/src/Makefile b/src/Makefile
index e4f7d90..704d4b4 100644
index ecbd2753d..737a14777 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -115,7 +115,7 @@ endif
@@ -116,7 +116,7 @@ endif
# Override default settings if possible
-include .make-settings

-FINAL_CFLAGS=$(STD) $(WARN) $(OPT) $(DEBUG) $(CFLAGS) $(REDIS_CFLAGS)
+FINAL_CFLAGS=$(STD) $(WARN) $(OPT) $(DEBUG) $(CFLAGS) $(REDIS_CFLAGS) $(CPPFLAGS)
FINAL_LDFLAGS=$(LDFLAGS) $(REDIS_LDFLAGS) $(DEBUG)
FINAL_LIBS=-lm
DEBUG=-g -ggdb
@@ -326,9 +326,9 @@ REDIS_CHECK_AOF_NAME=redis-check-aof$(PROG_SUFFIX)
@@ -355,9 +355,9 @@ REDIS_CHECK_AOF_NAME=redis-check-aof$(PROG_SUFFIX)
ALL_SOURCES=$(sort $(patsubst %.o,%.c,$(REDIS_SERVER_OBJ) $(REDIS_CLI_OBJ) $(REDIS_BENCHMARK_OBJ)))
all: $(REDIS_SERVER_NAME) $(REDIS_SENTINEL_NAME) $(REDIS_CLI_NAME) $(REDIS_BENCHMARK_NAME) $(REDIS_CHECK_RDB_NAME) $(REDIS_CHECK_AOF_NAME)

all: $(REDIS_SERVER_NAME) $(REDIS_SENTINEL_NAME) $(REDIS_CLI_NAME) $(REDIS_BENCHMARK_NAME) $(REDIS_CHECK_RDB_NAME) $(REDIS_CHECK_AOF_NAME) $(TLS_MODULE)
- @echo ""
- @echo "Hint: It's a good idea to run 'make test' ;)"
- @echo ""
+ #@echo ""
+ #@echo "Hint: It's a good idea to run 'make test' ;)"
+ #@echo ""

Makefile.dep:
-$(REDIS_CC) -MM $(ALL_SOURCES) > Makefile.dep 2> /dev/null || true

0 comments on commit f811e3e

Please sign in to comment.