-
Notifications
You must be signed in to change notification settings - Fork 463
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
Add a version and alias name for Jolt library in CMake #1426
Comments
Hello, I have not seen these constructs before and I can't really find useful information on them either. What does adding a version number do? Is it only a check so that if you do find_package(Jolt 10.0.0) that you would get an error? Or does it do more? W.r.t. ALIAS, I have not tested this but wouldn't:
work equally well? Also I'm not sure if the |
Re: version number, yes from my understanding, in the context of using CMake, it's useful so that Re: ALIAS, yes that works equally well, but using a namespace appears to be a convention. No, it would not cause an error from my understanding. I see this in projects like spdlog and SDL. It's not always the case; I know GLFW does not. |
Ok, I ran some quick tests:
works fine, but I guess there's no problem with having an alias. So I added both suggestions in #1430. |
Could a version be added to the
project
? It would be helpful to be able to specify the version of Jolt infind_package
.Use case would be something like:
find_package(Jolt 5.2.0)
Also, could an ALIAS target be added for Jolt? e.g.
I see that Jolt already exports with a namespace as in
so it would be helpful to add a namespaced target for linking with Jolt when using
add_subdirectory
.Use case would be something like:
Disclaimer: I am not good at CMake, but I see other projects do this. I can writeup a quick PR if it's relevant!
The text was updated successfully, but these errors were encountered: