Skip to content

Conversation

@ClausKlein
Copy link
Contributor

@ClausKlein ClausKlein commented Jul 5, 2025

Note: I have tested it with ubuntu-25.04 and llvm-20, works fine!

# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception

cmake_minimum_required(VERSION 3.28)
cmake_minimum_required(VERSION 3.28...4.1)
Copy link
Member

@JeffGarland JeffGarland Jul 5, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

edit: suggestion-removed...

cmake_minimum_required(VERSION 3.28)

I believe on the advice of @nickelpro we are explicitly not putting in ranges

Copy link
Contributor Author

@ClausKlein ClausKlein Jul 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if on ci is only cmake v3.28, I need this to test import std;

Copy link
Member

@nickelpro nickelpro Jul 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm in favor of version ranges.

There was confusion over what a cmake_minimum_required(VERSION MIN...MAX) meant among some beman maintainers, ie, that it forbid the project from building with a version >MAX, which led to some discussion of avoiding ranges.

This is not the behavior of a range. Instead it offers to CMake a range of behaviors it may emulate. cmake_minimum_required(VERSION 3.28) requires that CMake offer bug-for-bug compatibility with CMake 3.28. cmake_minimum_required(VERSION 3.28...4.1) allows CMake to choose any version in this range to target.

If a maintainer is comfortable with offering a range, we should allow them to do so.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for the clarification -- that's actually good news :)

"binaryDir": "${sourceDir}/build/${presetName}",
"cacheVariables": {
"CMAKE_CXX_STANDARD": "20"
"CMAKE_CXX_STANDARD": "23"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what's the reason for this one? I think we should leave it at 20

Copy link
Contributor Author

@ClausKlein ClausKlein Jul 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

to test import std;

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

right, but given the limited compiler support and the hoop jumping required on the cmake side I don't see us putting import std on main yet -- that seems like it needs to wait until we have an official cmake that support import std?

@JeffGarland
Copy link
Member

other than the questions, looks good

@JeffGarland JeffGarland merged commit f2aa9b9 into bemanproject:main Jul 7, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants