Skip to content
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 3.12 really necessary? #47

Closed
grepwood opened this issue Mar 22, 2019 · 3 comments
Closed

CMake 3.12 really necessary? #47

grepwood opened this issue Mar 22, 2019 · 3 comments
Labels
enhancement New feature or request

Comments

@grepwood
Copy link

I wanted to compile this project on Gentoo Linux and got a message saying my stable CMake is too old :)

CMake Error at CMakeLists.txt:1 (cmake_minimum_required):
  CMake 3.12 or higher is required.  You are running version 3.9.6

Further investigation shows CMake versions across various distributions considered stable.

System  Version   CMake
Gentoo  2.2       3.9.6
Ubuntu  18.04.2   3.10.2
Debian  9.8.0     3.7.2
FreeBSD 12.0      3.13.4

Fedora and Arch were not taken into account due to them being cutting-edge distros that are expected to have latest packages.
CentOS was not taken into account because it's antiquated and a new release is coming soon.

Bottom line - is such a version of CMake really necessary?
After reducing the minimum version to 3.7, I only got this error:

CMake Error at CMakeLists.txt:196 (target_link_libraries):
  Object library target "devilution" may not link to anything.


-- Configuring incomplete, errors occurred!

When in fact, that's not really correct. The offending line says

target_link_libraries(devilution PUBLIC Threads::Threads)

Any ideas?

@AJenbo
Copy link
Member

AJenbo commented Mar 22, 2019

The requirement comes from the Windows build. We build the releases on Debian-backports (CMake 3.13). Prior to adding Windows support the CMake requirement was 3.7.

We are currently looking in to ways of bringing down the requirement to something like 3.10, or maybe even 3.7. Thanks for the version overview.

@grepwood
Copy link
Author

grepwood commented Mar 22, 2019

@AJenbo What specifically about the Windows build warranted this change? I can crosscompile OpenJK for Windows just fine with CMake 3.9.

@AJenbo
Copy link
Member

AJenbo commented Mar 22, 2019

The requirment has now been lowered to 3.7 for most platforms, technically it works all the way back to and including 3.3. But using older versions then 3.7 for continuous testing seems more of a hassle then it's worth, and it's preferable that we can detect if there is a change in requirements.

For Windows-builds the limit is 3.10 since older versions fail during the pthread lookup.

#50

@AJenbo AJenbo closed this as completed Mar 22, 2019
@AJenbo AJenbo added the enhancement New feature or request label Mar 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants