lol
1{ stdenv, fetchFromGitHub, lib
2, intltool, glib, pkgconfig, polkit, python, sqlite, systemd
3, gobjectIntrospection, vala_0_23, gtk_doc, autoreconfHook, autoconf-archive
4, nix, boost
5, enableCommandNotFound ? false
6, enableBashCompletion ? false, bashCompletion ? null }:
7
8stdenv.mkDerivation rec {
9 name = "packagekit-${version}";
10 version = "1.1.3";
11
12 src = fetchFromGitHub {
13 owner = "hughsie";
14 repo = "PackageKit";
15 rev = "PACKAGEKIT_${lib.replaceStrings ["."] ["_"] version}";
16 sha256 = "150mpar7bhlvwfpwsr6zrjn3yggvklzr6nlhk0shaxnrfkfxvvb6";
17 };
18
19 buildInputs = [ glib polkit systemd python gobjectIntrospection vala_0_23 ]
20 ++ lib.optional enableBashCompletion bashCompletion;
21 propagatedBuildInputs = [ sqlite nix boost ];
22 nativeBuildInputs = [ intltool pkgconfig autoreconfHook autoconf-archive gtk_doc ];
23
24 preAutoreconf = ''
25 gtkdocize
26 intltoolize
27 '';
28
29 configureFlags = [
30 "--enable-systemd"
31 "--enable-nix"
32 "--disable-dummy"
33 "--disable-cron"
34 "--disable-introspection"
35 "--disable-offline-update"
36 "--localstatedir=/var"
37 "--sysconfdir=/etc"
38 "--with-dbus-sys=$(out)/etc/dbus-1/system.d"
39 "--with-systemdsystemunitdir=$(out)/lib/systemd/system/"
40 ]
41 ++ lib.optional (!enableBashCompletion) "--disable-bash-completion"
42 ++ lib.optional (!enableCommandNotFound) "--disable-command-not-found";
43
44 enableParallelBuilding = true;
45
46 installFlags = [
47 "sysconfdir=\${out}/etc"
48 "localstatedir=\${TMPDIR}"
49 ];
50
51 meta = with lib; {
52 description = "System to facilitate installing and updating packages";
53 longDescription = ''
54 PackageKit is a system designed to make installing and updating software
55 on your computer easier. The primary design goal is to unify all the
56 software graphical tools used in different distributions, and use some of
57 the latest technology like PolicyKit. The actual nuts-and-bolts distro
58 tool (dnf, apt, etc) is used by PackageKit using compiled and scripted
59 helpers. PackageKit isn't meant to replace these tools, instead providing
60 a common set of abstractions that can be used by standard GUI and text
61 mode package managers.
62 '';
63 homepage = http://www.packagekit.org/;
64 license = licenses.gpl2Plus;
65 platforms = platforms.linux;
66 maintainers = with maintainers; [ nckx matthewbauer ];
67 };
68}