diff --git a/pkgs/by-name/us/usbtop/package.nix b/pkgs/by-name/us/usbtop/package.nix index 8b4bad511fa5..d169964184d1 100644 --- a/pkgs/by-name/us/usbtop/package.nix +++ b/pkgs/by-name/us/usbtop/package.nix @@ -18,6 +18,16 @@ stdenv.mkDerivation rec { sha256 = "0qbad0aq6j4jrh90l6a0akk71wdzhyzmy6q8wl138axyj2bp9kss"; }; + postPatch = + # fix compatibility with CMake (https://cmake.org/cmake/help/v4.0/command/cmake_minimum_required.html) + # TODO: drop when https://github.com/aguinet/usbtop/pull/45 is merged + '' + substituteInPlace CMakeLists.txt \ + --replace-fail \ + 'cmake_minimum_required(VERSION 2.8)' \ + 'cmake_minimum_required(VERSION 2.8...4.0)' + ''; + nativeBuildInputs = [ cmake ]; buildInputs = [ libpcap