vimPlugins.cpsm: fix CMake 4 compatibility

Tracking: https://github.com/NixOS/nixpkgs/issues/445447
This commit is contained in:
Gaetan Lepage
2025-10-12 21:40:20 +00:00
parent d17d4a50bd
commit 62a97e4be9

View File

@@ -898,7 +898,15 @@ assertNoAdditions {
''; '';
}; };
cpsm = super.cpsm.overrideAttrs { cpsm = super.cpsm.overrideAttrs (old: {
# CMake 4 dropped support of versions lower than 3.5, and versions
# lower than 3.10 are deprecated.
postPatch = (old.postPatch or "") + ''
substituteInPlace CMakeLists.txt \
--replace-fail \
"cmake_minimum_required(VERSION 2.8.12)" \
"cmake_minimum_required(VERSION 3.10)"
'';
nativeBuildInputs = [ cmake ]; nativeBuildInputs = [ cmake ];
buildInputs = [ buildInputs = [
python3 python3
@@ -907,11 +915,15 @@ assertNoAdditions {
ncurses ncurses
]; ];
buildPhase = '' buildPhase = ''
runHook preBuild
patchShebangs . patchShebangs .
export PY3=ON export PY3=ON
./install.sh ./install.sh
runHook postBuild
''; '';
}; });
crates-nvim = super.crates-nvim.overrideAttrs { crates-nvim = super.crates-nvim.overrideAttrs {
checkInputs = [ checkInputs = [