← Back to issue list

kde-neon: invalid CMAKE_PREFIX_PATH

View original Github issue

Metadata

Project
snapcraft
Number
#5302
Type
issue
State
closed
Author
furgo16
Labels
Status: Triaged Type: Bug
Created
Updated
Closed

Current evaluation

Fixed KDE Neon CMAKE_PREFIX_PATH handling in merged PR #5310 (commit 9cb3f5155), released in Snapcraft 8.8; the maintainer marked #5302 completed.

Resolution: closed resolved

Reason: PR #5310 corrected the Linux path separator and removed an invalid CMake root path. It was merged as commit 9cb3f5155, and a maintainer confirmed the fix before closing the report.

Evaluated by: mr-cal-bot

No scores available.

Issue body

### Bug Description PR https://github.com/canonical/snapcraft/pull/5092 added `core24` support for `kde-neon{,-6}`-based snaps. It also added `CMAKE_PREFIX_PATH` as an environment variable to the build environment. However, it separated the multiple paths in the variable with semicolon (`;`), whereas [CMake expects a colon (`:`) as a separator on Linux](https://cmake.org/cmake/help/latest/envvar/CMAKE_PREFIX_PATH.html). https://github.com/canonical/snapcraft/blob/cdf598656caa546db8c5a06815d4edee4fbeb684/snapcraft/extensions/kde_neon.py#L309-L320 However, there is a potential source of confusion here. CMake has: 1. [`CMAKE_PREFIX_PATH` as an environment variable](https://cmake.org/cmake/help/latest/envvar/CMAKE_PREFIX_PATH.html). Paths separated by colon (`:`). With the current code, `prepend_to_env()` will add the wrong separator. 2. [`CMAKE_PREFIX_PATH` as a CMake variable](https://cmake.org/cmake/help/latest/variable/CMAKE_PREFIX_PATH.html#variable:CMAKE_PREFIX_PATH) Paths separated by semicolon (`;`) With the current code, `prepend_to_env()` is not the right function, as it's not and environment variable. The question is, which one of the two are we trying to add? ### To Reproduce Running the following command on any `kde-neon` snap shows that `CMAKE_PREFIX_PATH` is semicolon-separated, instead of colon-separated ``` snapcraft expand-extensions ``` ### Environment Ubuntu 24.04 LTS in destructive mode or LXD. ### snapcraft.yaml ```yaml N/A ``` ### Relevant log output ```shell N/A ``` ### Additional context _No response_

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha — closed resolved Fixed KDE Neon CMAKE_PREFIX_PATH handling in merged PR #5310 (commit 9cb3f5155), released in Snapcraft 8.8; the maintainer marked #5302 completed.
stealth/space-bunny-alpha — closed resolved Merged PR #5310 (commit 9cb3f5155), targeting Snapcraft 8.8, fixed KDE Neon's CMAKE_PREFIX_PATH handling and removed an invalid CMake root path.
qwen/qwen3.6-35b-a3b — — CMAKE_PREFIX_PATH incorrectly used semicolons instead of colons in kde-neon builds. The bug was fixed and merged in PR #5310, correcting the separator to match CMake's Linux requirements. Issue closed as completed.
qwen/qwen3.6-35b-a3b — — Fixed in PR #5310. The kde-neon extension incorrectly used semicolons instead of colons to separate paths in the CMAKE_PREFIX_PATH environment variable. The maintainer confirmed the resolution and closed the issue.
qwen3.6-35b-a3b-mtp-q6 — — Fixed by merging pull request #5310, which corrected the CMAKE_PREFIX_PATH path delimiter from semicolon to colon for kde-neon snaps. The bug is resolved and the issue is closed.

Update history

No update history recorded yet.

Related work

  • Likely Fixed By: canonical/snapcraft#5310 (confidence 100%)

    Merged resolving PR, committed as 9cb3f5155 and released in Snapcraft 8.8.

Related issues

Issue Project State Summary Similarity
#5585 fix: kde-neon: Append usr to cmake prefix path #5272 snapcraft merged Merged as e2daf4cbe: PR #5585 updates KDE Neon CMAKE_PREFIX_PATH entries to use SDK usr subdirectories, fixing #5272; released in Snapcraft 8.10.1.
84%
#5310 fix: Fix cmake prefix path and remove invalid cmake root path. snapcraft merged Merged as 9cb3f5155, fixing KDE Neon CMake prefix handling and removing an invalid CMake root path in Snapcraft 8.8; fixes #5302.
81%
#6366 fix(kde-neon-6): don't modify LD_LIBRARY_PATH snapcraft merged Merged PR #6366 reapplies #6016 onto main: KDE Neon 6 no longer sets LD_LIBRARY_PATH/QT_PLUGIN_PATH in snapcraft.yaml (moved to the launcher) and lxqt-support is updated, fixing #6327 (SNAPCRAFT-1365).
74%
#1244 repo: enable KDE Neon. snapcraft merged Merged in canonical/snapcraft#1244 via commit 0b70903dc, adding the neon distribution ID so Snapcraft recognizes KDE Neon.
72%
#6016 fix(kde): don't modify LD_LIBRARY_PATH snapcraft merged Merged in PR #6016 (commit 3fc9abd0b), removing Snapcraft-added LD_LIBRARY_PATH and QT_LIBRARY_PATH from KDE Neon 6 in favor of launcher configuration.
72%
#6002 Fix kde-neon-6 LD_LIBRARY_PATH snapcraft closed Superseded by merged PR canonical/snapcraft#6016 (commit 3fc9abd0b), which corrected KDE Neon 6 environment handling by relying on launcher configuration.
71%
#5272 CMAKE_PREFIX_PATH is not set with gnome extenstion snapcraft closed GNOME/KDE extension CMAKE_PREFIX_PATH handling was corrected by merged PR #5589 (d30f563a7), adding stage and SDK usr prefixes; released in Snapcraft 8.10.1.
70%