cppkafka icon indicating copy to clipboard operation
cppkafka copied to clipboard

Upgrade find librdkafka.cmake

Open sknop opened this issue 5 years ago • 1 comments

Hi,

I had problems compiling your C++ wrapper because it could not find librdkafka. I found this new cmake extension that allowed me to find and compile the library: https://gist.github.com/matthew-d-jones/550ee6fa2f89610f88991513fa5d6cfc

(after adjusting the find:

-find_package(RdKafka REQUIRED ${FIND_PACKAGE_QUIET}) +find_package(LibRDKafka REQUIRED ${FIND_PACKAGE_QUIET})

)

Might be worth a look?

sknop avatar Mar 27 '19 09:03 sknop

The current FindRdKafka.cmake should work fine. It searches here to find all possible variations of the file such as librdkafka.so, librdkafka.a, rdkafka.a etc... Note that your rdkafka library should be installed in the default place otherwise you should issue: cmake -DRDKAFKA_ROOT_DIR=/some/other/dir ...

accelerated avatar Apr 26 '19 20:04 accelerated