forked from ray-project/ray
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Split hiredis from Redis and use it directly (ray-project#9176)
* Split hiredis from Redis and use it directly Co-authored-by: Mehrdad <[email protected]>
- Loading branch information
Showing
8 changed files
with
78 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
COPTS = [] + select({ | ||
"@bazel_tools//src/conditions:windows": [ | ||
"-D_CRT_DECLARE_NONSTDC_NAMES=0", # don't define off_t, to avoid conflicts | ||
], | ||
"//conditions:default": [ | ||
], | ||
}) | ||
|
||
# This library is for internal hiredis use, because hiredis assumes a | ||
# different include prefix for itself than external libraries do. | ||
cc_library( | ||
name = "_hiredis", | ||
hdrs = [ | ||
"dict.c", | ||
], | ||
copts = COPTS, | ||
) | ||
|
||
cc_library( | ||
name = "hiredis", | ||
srcs = glob( | ||
[ | ||
"*.c", | ||
"*.h", | ||
], | ||
exclude = | ||
[ | ||
"test.c", | ||
], | ||
), | ||
hdrs = glob([ | ||
"*.h", | ||
"adapters/*.h", | ||
]), | ||
copts = COPTS + select({ | ||
"@bazel_tools//src/conditions:windows": [ | ||
"-D" + "WIN32_REPLACE_FD_APIS", | ||
"/FI" + "win32fd.h", | ||
], | ||
"//conditions:default": [ | ||
], | ||
}), | ||
include_prefix = "hiredis", | ||
deps = [ | ||
":_hiredis", | ||
"@//:platform_shims", | ||
], | ||
visibility = ["//visibility:public"], | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters