我正在尝试使用以下实现为macos构建c++静态kafka库:https://github.com/edenhill/librdkafka
我想包括加密,所以我试图在openssl链接。我的构建脚本如下所示:
git clone https://github.com/edenhill/librdkafka.git
cd librdkafka
git checkout b581d0d9df282847f76e8b9e87337161959d39c9
./configure --prefix=$ARTIFACT_DIR \
--CPPFLAGS="-I/usr/local/opt/openssl/include" \
--LDFLAGS="-L/usr/local/opt/openssl/lib" \
--enable-static
make
make install
我将得到的工件上传到一个bucket中,然后在其中引用我使用bazel管理的项目(https://bazel.build). 在我的主要部分,我有一些基本的代码,我用它来测试Kafka是建立正确的,它不断崩溃。下面是我的主要想法:
# include <librdkafka/rdkafkacpp.h>
int main() {
RdKafka::Conf *conf = RdKafka::Conf::create(RdKafka::Conf::CONF_GLOBAL);
RdKafka::Conf *tconf = RdKafka::Conf::create(RdKafka::Conf::CONF_TOPIC);
}
尝试运行此程序时,出现以下链接器错误:
Undefined symbols for architecture x86_64:
"_sasl_client_init", referenced from:
_rd_kafka_sasl_cyrus_global_init in librdkafka.a(rdkafka_sasl_cyrus.o)
"_sasl_client_new", referenced from:
_rd_kafka_sasl_cyrus_client_new in librdkafka.a(rdkafka_sasl_cyrus.o)
(maybe you meant: _rd_kafka_sasl_client_new)
"_sasl_client_start", referenced from:
_rd_kafka_sasl_cyrus_client_new in librdkafka.a(rdkafka_sasl_cyrus.o)
"_sasl_client_step", referenced from:
_rd_kafka_sasl_cyrus_recv in librdkafka.a(rdkafka_sasl_cyrus.o)
"_sasl_dispose", referenced from:
_rd_kafka_sasl_cyrus_close in librdkafka.a(rdkafka_sasl_cyrus.o)
"_sasl_errdetail", referenced from:
_rd_kafka_sasl_cyrus_client_new in librdkafka.a(rdkafka_sasl_cyrus.o)
_rd_kafka_sasl_cyrus_recv in librdkafka.a(rdkafka_sasl_cyrus.o)
"_sasl_errstring", referenced from:
_rd_kafka_sasl_cyrus_global_init in librdkafka.a(rdkafka_sasl_cyrus.o)
_rd_kafka_sasl_cyrus_client_new in librdkafka.a(rdkafka_sasl_cyrus.o)
"_sasl_getprop", referenced from:
_rd_kafka_sasl_cyrus_recv in librdkafka.a(rdkafka_sasl_cyrus.o)
"_sasl_listmech", referenced from:
_rd_kafka_sasl_cyrus_client_new in librdkafka.a(rdkafka_sasl_cyrus.o)
ld: symbol(s) not found for architecture x86_64
如果我正确地阅读了这个错误,那么看起来openssl没有链接到静态库中。
提前谢谢。
update:命令行的输出,显示编译过程中发生的事情。
using cache file config.cache
checking for OS or distribution... ok (osx)
checking for C compiler from CC env... failed
checking for gcc (by command)... ok (cached)
checking for C++ compiler from CXX env... failed
checking for C++ compiler (g++)... ok (cached)
checking executable ld... ok (cached)
checking executable nm... ok (cached)
checking executable objdump... ok (cached)
checking executable strip... ok (cached)
checking for debug symbols compiler flag (-g...)... ok (cached)
checking for pkgconfig (by command)... failed
checking for install (by command)... failed
checking for PIC (by compile)... ok (cached)
checking for GNU-compatible linker options... failed
checking for OSX linker options... ok (cached)
checking for GNU linker-script ld flag... failed
checking for Solaris linker-script ld flag... failed (ignore)
checking for __atomic_32 (by compile)... ok (cached)
checking for __atomic_64 (by compile)... ok (cached)
checking for socket (by compile)... ok (cached)
parsing version '0x000b03ff'... ok (0.11.3)
checking for libpthread (by compile)... ok (cached)
checking for zlib (by compile)... ok (cached)
checking for libcrypto (by compile)... ok (cached)
checking for liblz4 (by compile)... failed (disable)
checking for libssl (by compile)... ok (cached)
checking for libsasl2 (by compile)... ok (cached)
checking for crc32chw (by compile)... ok (cached)
checking for regex (by compile)... ok (cached)
checking for librt (by compile)... failed
checking for strndup (by compile)... ok (cached)
checking for strerror_r (by compile)... ok (cached)
checking for libdl (by compile)... ok (cached)
checking for nm (by env NM)... ok (cached)
Generated Makefile.config
Generated config.h
Configuration summary:
prefix /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3
ARCH x86_64
CPU generic
GEN_PKG_CONFIG y
ENABLE_DEVEL n
ENABLE_VALGRIND n
ENABLE_REFCNT_DEBUG n
ENABLE_SHAREDPTR_DEBUG n
ENABLE_LZ4_EXT y
ENABLE_SSL y
ENABLE_SASL y
CPPFLAGS -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align
LDFLAGS -L/usr/local/opt/openssl/lib
MKL_APP_NAME librdkafka
MKL_APP_DESC_ONELINE The Apache Kafka C/C++ library
MKL_DISTRO osx
SOLIB_EXT .dylib
CC gcc
CXX g++
LD ld
NM nm
OBJDUMP objdump
STRIP strip
PKG_CONFIG pkg-config
INSTALL install
HAS_LDFLAGS_STATIC n
LIB_LDFLAGS -shared -dynamiclib -Wl,-install_name,$(DESTDIR)$(libdir)/$(LIBFILENAME)
RDKAFKA_VERSION_STR 0.11.3
MKL_APP_VERSION 0.11.3
LIBS -lpthread -lz -lcrypto -lssl -lsasl2 -ldl
CXXFLAGS -Wno-non-virtual-dtor
SYMDUMPER $(NM) -g
exec_prefix /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3
bindir /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/bin
sbindir /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/sbin
libexecdir /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/libexec
datadir /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/share
sysconfdir /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/etc
sharedstatedir /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/com
localstatedir /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/var
libdir /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/lib
includedir /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/include
infodir /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/info
mandir /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/man
Generated config.cache
Now type 'make' to build
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka.c -o rdkafka.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_broker.c -o rdkafka_broker.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_msg.c -o rdkafka_msg.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_topic.c -o rdkafka_topic.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_conf.c -o rdkafka_conf.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_timer.c -o rdkafka_timer.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_offset.c -o rdkafka_offset.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_transport.c -o rdkafka_transport.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_buf.c -o rdkafka_buf.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_queue.c -o rdkafka_queue.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_op.c -o rdkafka_op.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_request.c -o rdkafka_request.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_cgrp.c -o rdkafka_cgrp.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_pattern.c -o rdkafka_pattern.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_partition.c -o rdkafka_partition.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_subscription.c -o rdkafka_subscription.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_assignor.c -o rdkafka_assignor.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_range_assignor.c -o rdkafka_range_assignor.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_roundrobin_assignor.c -o rdkafka_roundrobin_assignor.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_feature.c -o rdkafka_feature.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdcrc32.c -o rdcrc32.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c crc32c.c -o crc32c.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdaddr.c -o rdaddr.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdrand.c -o rdrand.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdlist.c -o rdlist.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c tinycthread.c -o tinycthread.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdlog.c -o rdlog.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdstring.c -o rdstring.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_event.c -o rdkafka_event.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_metadata.c -o rdkafka_metadata.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdregex.c -o rdregex.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdports.c -o rdports.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_metadata_cache.c -o rdkafka_metadata_cache.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdavl.c -o rdavl.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_sasl.c -o rdkafka_sasl.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_sasl_plain.c -o rdkafka_sasl_plain.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_interceptor.c -o rdkafka_interceptor.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_msgset_writer.c -o rdkafka_msgset_writer.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_msgset_reader.c -o rdkafka_msgset_reader.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdvarint.c -o rdvarint.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdbuf.c -o rdbuf.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdunittest.c -o rdunittest.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_sasl_cyrus.c -o rdkafka_sasl_cyrus.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_sasl_scram.c -o rdkafka_sasl_scram.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c snappy.c -o snappy.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdgz.c -o rdgz.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_lz4.c -o rdkafka_lz4.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rddl.c -o rddl.o
gcc -MD -MP -I/usr/local/opt/openssl/include -gstrict-dwarf -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -DLIBRDKAFKA_GIT_VERSION="\"v0.11.3\"" -c rdkafka_plugin.c -o rdkafka_plugin.o
Creating shared library librdkafka.1.dylib
gcc -L/usr/local/opt/openssl/lib -shared -dynamiclib -Wl,-install_name,/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/lib/librdkafka.1.dylib rdkafka.o rdkafka_broker.o rdkafka_msg.o rdkafka_topic.o rdkafka_conf.o rdkafka_timer.o rdkafka_offset.o rdkafka_transport.o rdkafka_buf.o rdkafka_queue.o rdkafka_op.o rdkafka_request.o rdkafka_cgrp.o rdkafka_pattern.o rdkafka_partition.o rdkafka_subscription.o rdkafka_assignor.o rdkafka_range_assignor.o rdkafka_roundrobin_assignor.o rdkafka_feature.o rdcrc32.o crc32c.o rdaddr.o rdrand.o rdlist.o tinycthread.o rdlog.o rdstring.o rdkafka_event.o rdkafka_metadata.o rdregex.o rdports.o rdkafka_metadata_cache.o rdavl.o rdkafka_sasl.o rdkafka_sasl_plain.o rdkafka_interceptor.o rdkafka_msgset_writer.o rdkafka_msgset_reader.o rdvarint.o rdbuf.o rdunittest.o rdkafka_sasl_cyrus.o rdkafka_sasl_scram.o snappy.o rdgz.o rdkafka_lz4.o xxhash.o lz4.o lz4frame.o lz4hc.o rddl.o rdkafka_plugin.o -o librdkafka.1.dylib -lpthread -lz -lcrypto -lssl -lsasl2 -ldl
Creating static library librdkafka.a
ar rcs librdkafka.a rdkafka.o rdkafka_broker.o rdkafka_msg.o rdkafka_topic.o rdkafka_conf.o rdkafka_timer.o rdkafka_offset.o rdkafka_transport.o rdkafka_buf.o rdkafka_queue.o rdkafka_op.o rdkafka_request.o rdkafka_cgrp.o rdkafka_pattern.o rdkafka_partition.o rdkafka_subscription.o rdkafka_assignor.o rdkafka_range_assignor.o rdkafka_roundrobin_assignor.o rdkafka_feature.o rdcrc32.o crc32c.o rdaddr.o rdrand.o rdlist.o tinycthread.o rdlog.o rdstring.o rdkafka_event.o rdkafka_metadata.o rdregex.o rdports.o rdkafka_metadata_cache.o rdavl.o rdkafka_sasl.o rdkafka_sasl_plain.o rdkafka_interceptor.o rdkafka_msgset_writer.o rdkafka_msgset_reader.o rdvarint.o rdbuf.o rdunittest.o rdkafka_sasl_cyrus.o rdkafka_sasl_scram.o snappy.o rdgz.o rdkafka_lz4.o xxhash.o lz4.o lz4frame.o lz4hc.o rddl.o rdkafka_plugin.o
Generating pkg-config file rdkafka.pc
Checking librdkafka integrity
librdkafka.1.dylib OK
librdkafka.a OK
Symbol visibility OK
Generating pkg-config file rdkafka++.pc
Checking librdkafka++ integrity
librdkafka++.1.dylib OK
librdkafka++.a OK
/Applications/Xcode.app/Contents/Developer/usr/bin/make -C examples
gcc -I/usr/local/opt/openssl/include -g -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -I../src rdkafka_example.c -o rdkafka_example -L/usr/local/opt/openssl/lib \
../src/librdkafka.a -lpthread -lz -lcrypto -lssl -lsasl2 -ldl
# rdkafka_example is ready
#
# Run producer (write messages on stdin)
./rdkafka_example -P -t <topic> -p <partition>
# or consumer
./rdkafka_example -C -t <topic> -p <partition>
#
# More usage options:
./rdkafka_example -h
gcc -I/usr/local/opt/openssl/include -g -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -I../src rdkafka_performance.c -o rdkafka_performance -L/usr/local/opt/openssl/lib \
../src/librdkafka.a -lpthread -lz -lcrypto -lssl -lsasl2 -ldl
# rdkafka_performance is ready
#
# Run producer
./rdkafka_performance -P -t <topic> -p <partition> -s <msgsize>
# or consumer
./rdkafka_performance -C -t <topic> -p <partition>
#
# More usage options:
./rdkafka_performance -h
g++ -I/usr/local/opt/openssl/include -g -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -Wno-non-virtual-dtor -I../src-cpp rdkafka_example.cpp -o rdkafka_example_cpp -L/usr/local/opt/openssl/lib \
../src-cpp/librdkafka++.a ../src/librdkafka.a -lpthread -lz -lcrypto -lssl -lsasl2 -ldl -lstdc++
gcc -I/usr/local/opt/openssl/include -g -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -I../src rdkafka_consumer_example.c -o rdkafka_consumer_example -L/usr/local/opt/openssl/lib \
../src/librdkafka.a -lpthread -lz -lcrypto -lssl -lsasl2 -ldl
# rdkafka_consumer_example is ready
#
./rdkafka_consumer_example <topic[:part]> <topic2[:part]> ..
#
# More usage options:
./rdkafka_consumer_example -h
g++ -I/usr/local/opt/openssl/include -g -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -Wno-non-virtual-dtor -I../src-cpp rdkafka_consumer_example.cpp -o rdkafka_consumer_example_cpp -L/usr/local/opt/openssl/lib \
../src-cpp/librdkafka++.a ../src/librdkafka.a -lpthread -lz -lcrypto -lssl -lsasl2 -ldl -lstdc++
g++ -I/usr/local/opt/openssl/include -g -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -Wno-non-virtual-dtor -I../src-cpp kafkatest_verifiable_client.cpp -o kafkatest_verifiable_client -L/usr/local/opt/openssl/lib \
../src-cpp/librdkafka++.a ../src/librdkafka.a -lpthread -lz -lcrypto -lssl -lsasl2 -ldl -lstdc++
gcc -I/usr/local/opt/openssl/include -g -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -Wcast-align -I../src rdkafka_simple_producer.c -o rdkafka_simple_producer -L/usr/local/opt/openssl/lib \
../src/librdkafka.a -lpthread -lz -lcrypto -lssl -lsasl2 -ldl
Updating
Checking integrity
CONFIGURATION.md OK
examples/rdkafka_example OK
examples/rdkafka_performance OK
examples/rdkafka_example_cpp OK
Checking librdkafka integrity
librdkafka.1.dylib OK
librdkafka.a OK
Symbol visibility OK
Checking librdkafka++ integrity
librdkafka++.1.dylib OK
librdkafka++.a OK
Install librdkafka to /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3
install -d $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/include/librdkafka ; \
install -d $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/lib ; \
install rdkafka.h $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/include/librdkafka ; \
install librdkafka.a $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/lib ; \
install librdkafka.1.dylib $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/lib ; \
[ -f "rdkafka.pc" ] && ( \
install -d $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/lib/pkgconfig ; \
install -m 0644 rdkafka.pc $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/lib/pkgconfig \
) ; \
(cd $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/lib && ln -sf librdkafka.1.dylib librdkafka.dylib)
Install librdkafka++ to /Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3
install -d $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/include/librdkafka ; \
install -d $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/lib ; \
install rdkafkacpp.h $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/include/librdkafka ; \
install librdkafka++.a $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/lib ; \
install librdkafka++.1.dylib $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/lib ; \
[ -f "rdkafka++.pc" ] && ( \
install -d $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/lib/pkgconfig ; \
install -m 0644 rdkafka++.pc $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/lib/pkgconfig \
) ; \
(cd $DESTDIR/Users/przemeklach/dev/artifact_staging/librdkafka-0.11.3/lib && ln -sf librdkafka++.1.dylib librdkafka++.dylib)
暂无答案!
目前还没有任何答案,快来回答吧!