From 0dc894cfa38535770b3b6db5da32787b47629756 Mon Sep 17 00:00:00 2001 From: Dinand Vanvelzen Date: Sat, 23 Mar 2024 16:15:31 -0500 Subject: [PATCH] WIP: commit to switch librdkafka from version 1.1.0 to version 2.3.0 --- dependencies/librdkafka/CMakeLists.txt | 3 ++- dependencies/librdkafka/config.h | 27 ++++++++++++++++++++++++++ 2 files changed, 29 insertions(+), 1 deletion(-) create mode 100644 dependencies/librdkafka/config.h diff --git a/dependencies/librdkafka/CMakeLists.txt b/dependencies/librdkafka/CMakeLists.txt index 3cc982238..2b8bf9181 100644 --- a/dependencies/librdkafka/CMakeLists.txt +++ b/dependencies/librdkafka/CMakeLists.txt @@ -12,6 +12,7 @@ # Configuration for module: RdKafka set( HEADER_FILES + config.h src/cJSON.h src/crc32c.h src/lz4.h @@ -244,7 +245,7 @@ if ( LINUX64 ) set_property( TARGET ${MODULE_NAME} APPEND_STRING PROPERTY COMPILE_DEFINITIONS "WITH_LIBDL" ) endif( LINUX64 ) -include_directories( src src-cpp ) +include_directories( ../librdkafka src src-cpp ) if ( LINUX32 ) include_directories( ../zlib ) diff --git a/dependencies/librdkafka/config.h b/dependencies/librdkafka/config.h new file mode 100644 index 000000000..1b90dae07 --- /dev/null +++ b/dependencies/librdkafka/config.h @@ -0,0 +1,27 @@ +#ifndef LIBRDKAFKA_CONFIG_H +#define LIBRDKAFKA_CONFIG_H + +/* this file is for Linux builds, not Windows which has its own config file */ +#if ( !defined _WIN32 ) + +#define WITH_SSL 0 +#define WITH_ZLIB 1 +#define WITH_SNAPPY 0 +#define WITH_ZSTD 0 +/* zstd is linked dynamically on Windows, but the dynamic library provides + * the experimental/advanced API, just as the static builds on *nix */ +#define WITH_ZSTD_STATIC 0 +#define WITH_SASL_SCRAM 0 +#define WITH_SASL_OAUTHBEARER 0 +#define ENABLE_DEVEL 0 +#define WITH_PLUGINS 1 +#define WITH_HDRHISTOGRAM 1 + +#define SOLIB_EXT ".so" + +/* Notice: Keep up to date */ +#define BUILT_WITH "SSL ZLIB SNAPPY SASL_SCRAM PLUGINS HDRHISTOGRAM" + +#endif + +#endif /* LIBRDKAFKA_CONFIG_H ? */