33 stdenv.mkDerivation (finalAttrs: {
42 src = fetchFromGitHub {
43 owner = "rpm-software-management";
45 rev = finalAttrs.version;
46 hash = "sha256-R9woS84vZkF7yatbJr7KNhaUsLZcGaiS+XnYXG3i1jA=";
59 ++ (with python3Packages; [
84 # workaround for https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105329
85 NIX_CFLAGS_COMPILE = "-Wno-restrict -Wno-maybe-uninitialized";
92 "-DWITH_PLUGIN_RHSM=OFF" # Red Hat Subscription Manager plugin
93 # the cmake package does not handle absolute CMAKE_INSTALL_INCLUDEDIR correctly
94 # (setting it to an absolute path causes include files to go to $out/$out/include,
95 # because the absolute path is interpreted with root at $out).
96 "-DCMAKE_INSTALL_INCLUDEDIR=include"
97 "-DCMAKE_INSTALL_LIBDIR=lib"
105 substituteInPlace CMakeLists.txt \
106 --replace-fail "/usr/lib/systemd/system" "$out/lib/systemd/system"
107 substituteInPlace dnf5daemon-server/dbus/CMakeLists.txt \
108 --replace-fail "/usr" "$out"
109 substituteInPlace dnf5daemon-server/polkit/CMakeLists.txt \
110 --replace-fail "/usr" "$out"
111 substituteInPlace dnf5/CMakeLists.txt \
112 --replace-fail "/etc/bash_completion.d" "$out/etc/bash_completion.d"
118 tests.version = testers.testVersion { package = finalAttrs.finalPackage; };
119 updateScript = nix-update-script { };
123 description = "Next-generation RPM package management system";
124 homepage = "https://github.com/rpm-software-management/dnf5";
125 changelog = "https://github.com/rpm-software-management/dnf5/releases/tag/${finalAttrs.version}";
126 license = licenses.gpl2Plus;
127 maintainers = with lib.maintainers; [
131 mainProgram = "dnf5";
132 platforms = platforms.linux ++ platforms.darwin;