-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
CMake FetchContent support #1119
Comments
Hi, I'm honestly not sure what the right way to get this to work is. It looks like using Here's a blog post saying as much. I suppose you would need to somehow forward the custom include directory to redisplusplus, but I'm not familiar enough with CMake to tell you how 😅 Edit: Looks like you can tell |
@ivan-ushakov I tried this out and got hiredis and redis++ to build using following gist. I found two issues during this:
The tests in redis++ uses Would the setup from the gist work for you? |
Sorry! The gist above might not work after all.. |
Updated the gist to make it work, but requires CMake 3.24. |
With this two hacks:
It works, but maybe in future this could be solved without hacks. |
Thank you for the gist. A note for people searching: redis-plus-plus's 1.3.8 release breaks this workaround by introducing a feature test using It seems that the |
Worked for me out of the box (the same way I
Then later you can use
Cmake v 3.22.1 |
Is it possible to make FetchContent support? If I use this declaration:
I get header files inside
_deps/hiredis-src
, notinclude/hiredis/
and this leads to build error for Redis++ library.The text was updated successfully, but these errors were encountered: