-
Notifications
You must be signed in to change notification settings - Fork 620
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
New CMake setup fails on cmake 3.12 #457
Comments
Maybe this would be a viable option without outright requiring 3.13:
|
As an afterthought: maybe supporting the stock cmake of the most recent Ubuntu LTS (18.04) which would be 3.10, would be worth the hassle. No idea what features would be missing compared to 3.12, though. |
This policy converts relative paths to absolute in target_sources - @kdt3rd, I'm curious where this comes up? https://cmake.org/cmake/help/git-stage/policy/CMP0076.html |
oh, I wanted to use cmake 3.12 because of the improved FindPython logic to handle both python 2 and 3 at the same time. Additionally, I use object libraries such that when you have the make both shared and static libraries turned on, it doesn't have to re-compile everything twice. In 3.12, these object libraries can be used in the target link calls, and it injects the .o into the resulting library, and carries the compile flags, etc. along with it, so I don't have to replicate that. Both pretty nice features, and while I could do the object libraries a different way, as we head to VFX Platform 2020, with it's python 3 requirement, I don't want to make that any more complex than it is already with the boost python stuff, I'd rather spend the time switching to pybind11 :) Back to the policy, I was originally using target_sources, as that is recommended in a bunch of the 'More Modern CMake' stuff, however, when I added the macros I've added to centralize the library creation, the need for them has largely gone away, so I believe we can just remove that policy entirely. I need to touch all the cmake files today, will remove that policy set. |
So there seems to be plenty of good reason to require 3.12. I'm personally all in on making progress and getting rid of cruft. Thanks for the background info. |
…of cmake, no longer needed
…of cmake, no longer needed Signed-off-by: Kimball Thurston <kdt3rd@gmail.com>
…of cmake, no longer needed Signed-off-by: Kimball Thurston <kdt3rd@gmail.com>
cmake_minimum_required(VERSION 3.12)
but this policy is only introduced in 3.13. Unfortunately 3.12 is the best I get on a stock Ubuntu 18.10.If I comment out the policy line, it configures and compiles just fine.
The text was updated successfully, but these errors were encountered: