Upgrade librdkafka to v1.3.0

Allow bundled librdkafka on Mac
This commit is contained in:
Andrew Onyshchuk 2020-02-04 16:12:24 -06:00
parent 3c1735d996
commit 9de5dffb5c
4 changed files with 14 additions and 3 deletions

View File

@ -1,5 +1,5 @@
# Freebsd: contrib/cppkafka/include/cppkafka/detail/endianness.h:53:23: error: 'betoh16' was not declared in this scope # Freebsd: contrib/cppkafka/include/cppkafka/detail/endianness.h:53:23: error: 'betoh16' was not declared in this scope
if (NOT ARCH_ARM AND NOT ARCH_32 AND NOT APPLE AND NOT OS_FREEBSD AND OPENSSL_FOUND) if (NOT ARCH_ARM AND NOT ARCH_32 AND NOT OS_FREEBSD AND OPENSSL_FOUND)
option (ENABLE_RDKAFKA "Enable kafka" ${ENABLE_LIBRARIES}) option (ENABLE_RDKAFKA "Enable kafka" ${ENABLE_LIBRARIES})
endif () endif ()
@ -10,7 +10,7 @@ endif ()
if (ENABLE_RDKAFKA) if (ENABLE_RDKAFKA)
if (OS_LINUX AND NOT ARCH_ARM AND USE_LIBGSASL) if (NOT ARCH_ARM AND USE_LIBGSASL)
option (USE_INTERNAL_RDKAFKA_LIBRARY "Set to FALSE to use system librdkafka instead of the bundled" ${NOT_UNBUNDLED}) option (USE_INTERNAL_RDKAFKA_LIBRARY "Set to FALSE to use system librdkafka instead of the bundled" ${NOT_UNBUNDLED})
endif () endif ()

2
contrib/librdkafka vendored

@ -1 +1 @@
Subproject commit 6160ec275a5bb0a4088ede3c5f2afde638bbef65 Subproject commit 4ffe54b4f59ee5ae3767f9f25dc14651a3384d62

View File

@ -23,6 +23,8 @@ set(SRCS
${RDKAFKA_SOURCE_DIR}/rdkafka_lz4.c ${RDKAFKA_SOURCE_DIR}/rdkafka_lz4.c
${RDKAFKA_SOURCE_DIR}/rdkafka_metadata.c ${RDKAFKA_SOURCE_DIR}/rdkafka_metadata.c
${RDKAFKA_SOURCE_DIR}/rdkafka_metadata_cache.c ${RDKAFKA_SOURCE_DIR}/rdkafka_metadata_cache.c
${RDKAFKA_SOURCE_DIR}/rdkafka_mock.c
${RDKAFKA_SOURCE_DIR}/rdkafka_mock_handlers.c
${RDKAFKA_SOURCE_DIR}/rdkafka_msg.c ${RDKAFKA_SOURCE_DIR}/rdkafka_msg.c
${RDKAFKA_SOURCE_DIR}/rdkafka_msgset_reader.c ${RDKAFKA_SOURCE_DIR}/rdkafka_msgset_reader.c
${RDKAFKA_SOURCE_DIR}/rdkafka_msgset_writer.c ${RDKAFKA_SOURCE_DIR}/rdkafka_msgset_writer.c

View File

@ -75,8 +75,17 @@
#define HAVE_STRNDUP 1 #define HAVE_STRNDUP 1
// strerror_r // strerror_r
#define HAVE_STRERROR_R 1 #define HAVE_STRERROR_R 1
#ifdef __APPLE__
#define HAVE_PTHREAD_SETNAME_DARWIN 1
#if (__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ <= 101400)
#define _TTHREAD_EMULATE_TIMESPEC_GET_
#endif
#else
// pthread_setname_gnu // pthread_setname_gnu
#define HAVE_PTHREAD_SETNAME_GNU 1 #define HAVE_PTHREAD_SETNAME_GNU 1
#endif
// python // python
//#define HAVE_PYTHON 1 //#define HAVE_PYTHON 1
// disable C11 threads for compatibility with old libc // disable C11 threads for compatibility with old libc