Skip to content

Conversation

@Hitesh-ed
Copy link
Contributor

@Hitesh-ed Hitesh-ed commented Oct 16, 2025

Issue:
CMake 4.x fails to configure the SentencePiece dependency because its CMakeLists.txt declares cmake_minimum_required(VERSION 3.1), which is no longer compatible (it has to be atleaset 3.5 when using latest Cmake 4.x for build).

Solution:
Adding the following cache variable in CMakePresets.json to enforce modern policies automatically:

"cacheVariables": {
  "CMAKE_POLICY_VERSION_MINIMUM": "3.5"
}

# Pretends old CMake minimums below 3.5 are OK (fixes SentencePiece 3.1 issue automatically)

This ensures all developers can run "cmake --preset windows" without hitting legacy compatibility or deprecation issues.

Adding the following cache variable in the CMakePresets.json to enforce modern policies automatically

This ensures all developers can run cmake --preset windows without hitting legacy compatibility or deprecation issues.
@jan-wassenberg
Copy link
Member

Nice, thanks for adding. We are only able to accept changes to the dev branch, would you please retarget the PR?

@Hitesh-ed Hitesh-ed changed the base branch from main to dev October 16, 2025 14:46
Copy link
Member

@jan-wassenberg jan-wassenberg left a comment

Choose a reason for hiding this comment

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

Thanks for rebasing!

@jan-wassenberg jan-wassenberg added the copybara-import Trigger Copybara for merging pull requests label Oct 22, 2025
@copybara-service copybara-service bot merged commit 64a82ed into google:dev Oct 22, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

copybara-import Trigger Copybara for merging pull requests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants