-
Notifications
You must be signed in to change notification settings - Fork 219
Fix RdKafka_LIBRARY_DIR-NOTFOUND #219
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
This gives me the impression that there's something wrong with the |
|
I don't think exporting this is wrong as it helps not have to add the rdkafka binary directory to the |
This is not right. I created a new project, did |
|
I see...was RdKafka installed as a module-only (from DPKG or autotools) or did you also have the RdKafka cmake config present (i.e. build and installed via cmake)? This could affect the way the lib was discovered. In any case if you prefer to have that line removed from the target, it's ok too, it's just that I haven't tested extensively without it. |
|
I installed it via |
|
BTW I got this working as well by adding the same directories as HINTS instead of adding them to the prefix in the main CMakeLists.txt. So if you want to just change the FindRdKafka script it's also possible but other |
|
I ran this by removing those lines in the |
|
I assume that besides removing the line in the exported target we have to remove find_path and change find_library to: so that if you ever install RDKafka in another location it will still work. |
|
Looks good to me. @kerenor23 can you double check to make sure this works on your environment? |
|
sorry, we got a bit of a timezone difference here, will test it tomorrow. |
|
Test in current environment
Test with librdkafka in different location
Many thanks! A Very interesting repo. |
|
Perfect, thanks for testing this! Regarding the next release, I'm not sure. I currently don't really have the time to work on this library anymore so there's no changes scheduled on my side. @accelerated has made most of the recent contributions (thanks again!) to this repo. I had started working on the kafka admin API but got side tracked and never finished it. Maybe one of these days! |
Add additional default search directories for
find_xxxcmake functions. By defaultCMAKE_PREFIX_PATHandCMAKE_INCLUDE_PATHare empty.NOTE: The bug reported in 218 has 2 easy workarounds:
-DRDKAFKA_ROOT=/usr/lib/<arch>-DRDKAFKA_ROOT=/usr/localFixes #218