-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Use Hunter for pulling in dependencies #2488
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
d9dd509 to
7de92ca
Compare
7de92ca to
b36cd33
Compare
b36cd33 to
d00f4f4
Compare
|
@kimkulling Any thoughts on this? |
|
For me it looks fine as a prototype test, which could get enabled on master. I also played around with Conan, but there aren't any working results out there until now. Let me do the code review and then I will merge it, if no one else has any concerns. |
|
Few notes from myself. Personally, I don’t update my assimp version as much as I should. Namely because when I do, I have to (re)build it so many times for so many different systems. iOS, Android, Windows store (arm,x86,x64), mac, windows desktop, etc. So, I’m on board with a new dependency manager as long as it doesn’t impede my ability to use CMake to build assimp again for the above systems. Just my two cents. |
|
Merged, let's see! |
Assimp has a lot of dependencies, copied into the repo at
contrib/. The Hunter package manager (https://github.com/ruslo/hunter) helps manage such a dependency tree, as well as potential integration into other projects.As mentioned in #1946, there is a fork of Assimp in Hunter but it is quite dated: https://github.com/hunter-packages/assimp.
This PR adds support for the Hunter package manager in Assimp, using it to resolve and pull in dependencies only when the
HUNTER_ENABLEDCMake argument is set. By default,HUNTER_ENABLEDis set toOFFand the current CMake behavior is preserved.This PR does a few things besides adding the requisite Hunter-related CMake files if
HUNTER_ENABLED=ON:-std=cxx11and-fPIC) as they will be set externallyASSIMP_USE_HUNTERand rewrite include paths for dependencies if setWhat's missing:
Open3DGC - I haven't added this to Hunter and disabled it in Assimp for Hunter builds. For glTF 2.0, perhaps Draco is more widely supported and I have added that to Hunter so it would be pretty easy to add to Assimp.
Testing of tools/samples/tests - I focused on incorporating the library build for use in the package manager.
As a sanity check, I was able to build the library after completely removing the
contrib/directory.