-
Notifications
You must be signed in to change notification settings - Fork 58
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
Fix: cmake install shouldn't hardcode install path #241
Conversation
@filippobrizzi If this pull request contains a bugfix or a new feature, then please consider using |
@filippobrizzi If this pull request contains a bugfix or a new feature, then please consider using |
1 similar comment
@filippobrizzi If this pull request contains a bugfix or a new feature, then please consider using |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice approach. This should allow to move lib
and include
directories with zenoh-c installed into different place if necessary. I agree with the change.
@filippobrizzi can you tell, is it some standard recommendation to avoid absolute paths in cmake package file? I'd be grateful if you add some link about it
@milyin A reference I found is from the CMake documentation https://cmake.org/cmake/help/v3.17/guide/tutorial/index.html#adding-export-configuration-step-11. I have to admit my solution is halfway elegant as in theory this piece of code
should be automatically generated from CMake when calling I have searched extensively on Google for an elegant solution for imported targets but with no luck. This is the best working solution I could come up with. |
Cmake install shouldn't hardcode install path.