File tree Expand file tree Collapse file tree
pkgs/applications/audio/lmms Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -70,7 +70,21 @@ mkDerivation rec {
7070 } )
7171 ] ;
7272
73- cmakeFlags = [ "-DWANT_QT5=ON" ] ;
73+ prePatch = ''
74+ # Update CMake minimum required version and policies
75+ substituteInPlace CMakeLists.txt --replace 'CMAKE_MINIMUM_REQUIRED(VERSION 2.8.7)' 'CMAKE_MINIMUM_REQUIRED(VERSION 3.5)'
76+ substituteInPlace CMakeLists.txt --replace 'CMAKE_POLICY(SET CMP0026 OLD)' 'CMAKE_POLICY(SET CMP0026 NEW)'
77+ substituteInPlace CMakeLists.txt --replace 'CMAKE_POLICY(SET CMP0050 OLD)' 'CMAKE_POLICY(SET CMP0050 NEW)'
78+ substituteInPlace CMakeLists.txt --replace 'GET_TARGET_PROPERTY(BIN2RES bin2res LOCATION)' 'SET(BIN2RES $<TARGET_FILE:bin2res>)'
79+ '' ;
80+
81+ cmakeFlags = [
82+ "-DWANT_QT5=ON"
83+ ]
84+ ++ lib . optionals ( lib . versionOlder version "11.4" ) [
85+ # Fix the build with CMake 4.
86+ "-DCMAKE_POLICY_VERSION_MINIMUM=3.5"
87+ ] ;
7488
7589 meta = with lib ; {
7690 description = "DAW similar to FL Studio (music production software)" ;
You can’t perform that action at this time.
0 commit comments