Skip to content

Update CMake to 4.0#627

Merged
NvTimLiu merged 1 commit into
NVIDIA:mainfrom
NvTimLiu:cmake-4-for-cudf-udf
May 20, 2026
Merged

Update CMake to 4.0#627
NvTimLiu merged 1 commit into
NVIDIA:mainfrom
NvTimLiu:cmake-4-for-cudf-udf

Conversation

@NvTimLiu

Copy link
Copy Markdown
Collaborator

To fix build cuDF cmake version error

[INFO]      [exec] CMake Error at /home/jenkins/agent/workspace/jenkins-examples-udf-examples-native-597/examples/UDF-Examples/RAPIDS-accelerated-UDFs/target/cpp-build/_deps/cudf-src/cpp/CMakeLists.txt:8 (cmake_minimum_required):
[INFO]      [exec]   CMake 4.0 or higher is required.  You are running version 3.30.4

Refer to NVIDIA/cudf-spark-jni#4557

This commit updates CMakeLists.txt to use CMake 4.0+, and updates the Dockerfile used in the build.

This is in line with the changes in cuDF, in rapidsai/cudf#22492.

This commit updates CMakeLists.txt to use CMake 4.0+, and updates the Dockerfile used in the build.

This is in line with the changes in cuDF, in rapidsai/cudf#22492.

Signed-off-by: Tim Liu <timl@nvidia.com>
@NvTimLiu NvTimLiu self-assigned this May 20, 2026
@NvTimLiu NvTimLiu added the bug Something isn't working label May 20, 2026
@greptile-apps

greptile-apps Bot commented May 20, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR fixes a build failure caused by the upstream cuDF project now requiring CMake 4.0 or higher, updating both the Dockerfile and the project's own cmake_minimum_required declaration to satisfy that constraint.

  • Dockerfile: The installed CMake binary is bumped from 3.30.4 to 4.0.3; the download URL is generated dynamically from CMAKE_VERSION, so no other lines need to change.
  • CMakeLists.txt: cmake_minimum_required is raised from VERSION 3.30.4 to VERSION 4.0, matching the minimum enforced by the fetched cuDF CMakeLists.txt.

Confidence Score: 5/5

Safe to merge; both changes are mechanical version bumps that directly unblock the broken build.

The two changes are a single-line version bump in the Dockerfile and a matching cmake_minimum_required update in CMakeLists.txt. Both track the upstream cuDF change and carry no functional risk. The only note is a stale inline comment, which is a cosmetic issue.

No files require special attention; both changed files are straightforward build-configuration updates.

Important Files Changed

Filename Overview
examples/UDF-Examples/RAPIDS-accelerated-UDFs/Dockerfile Bumps the installed CMake binary from 3.30.4 to 4.0.3 to satisfy the updated cuDF requirement; a stale version comment still references 3.22.3.
examples/UDF-Examples/RAPIDS-accelerated-UDFs/src/main/cpp/CMakeLists.txt Raises cmake_minimum_required from 3.30.4 to 4.0, matching the minimum version now enforced by the upstream cuDF CMakeLists.txt.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[Docker build] -->|downloads| B["CMake 4.0.3 binary\n(was 3.30.4)"]
    B --> C[Container image with CMake 4.0.3]
    C --> D[Maven UDF native build]
    D --> E["CMakeLists.txt\ncmake_minimum_required(VERSION 4.0)"]
    E --> F{Fetch cuDF via CPM}
    F -->|cuDF CMakeLists.txt requires CMake 4.0| G[✓ Version satisfied — build proceeds]
    F -->|old CMake 3.30.4| H[✗ CMake Error: 4.0 or higher required]
Loading

Reviews (1): Last reviewed commit: "Update CMake to 4.0" | Re-trigger Greptile

Comment thread examples/UDF-Examples/RAPIDS-accelerated-UDFs/Dockerfile

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Updates the RAPIDS-accelerated UDF native build configuration to meet cuDF’s new requirement for CMake 4.0+, unblocking builds that currently fail due to running CMake 3.30.4.

Changes:

  • Bump cmake_minimum_required to CMake 4.0 in the native UDF CMake project.
  • Update the UDF build Dockerfile to install CMake 4.0.3.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
examples/UDF-Examples/RAPIDS-accelerated-UDFs/src/main/cpp/CMakeLists.txt Raises the minimum required CMake version to 4.0 to align with cuDF requirements.
examples/UDF-Examples/RAPIDS-accelerated-UDFs/Dockerfile Updates the pinned CMake version used in the build container to 4.0.3.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread examples/UDF-Examples/RAPIDS-accelerated-UDFs/Dockerfile

@res-life res-life left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM

@res-life

Copy link
Copy Markdown
Collaborator

Thanks Tim to fix this.

@NvTimLiu NvTimLiu merged commit c382e9a into NVIDIA:main May 20, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants