nixpkgs/pkgs/desktops/gnome-3/apps/gnome-boxes/default.nix
Profpatsch 4a7f99d55d treewide: with stdenv.lib; in meta -> with lib;
Part of: https://github.com/NixOS/nixpkgs/issues/108938

meta = with stdenv.lib;

is a widely used pattern. We want to slowly remove
the `stdenv.lib` indirection and encourage people
to use `lib` directly. Thus let’s start with the meta
field.

This used a rewriting script to mostly automatically
replace all occurances of this pattern, and add the
`lib` argument to the package header if it doesn’t
exist yet.

The script in its current form is available at
https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
2021-01-11 10:38:22 +01:00

146 lines
2.3 KiB
Nix

{ lib, stdenv
, fetchurl
, meson
, ninja
, wrapGAppsHook
, pkgconfig
, gettext
, itstool
, libvirt-glib
, glib
, gobject-introspection
, libxml2
, gtk3
, gtksourceview4
, gtk-vnc
, freerdp
, libvirt
, spice-gtk
, python3
, appstream-glib
, spice-protocol
, libhandy_0
, libsoup
, libosinfo
, systemd
, tracker
, tracker-miners
, vala
, libcap
, yajl
, gmp
, gdbm
, cyrus_sasl
, gnome3
, librsvg
, desktop-file-utils
, mtools
, cdrkit
, libcdio
, libusb1
, libarchive
, acl
, libgudev
, libsecret
, libcap_ng
, numactl
, libapparmor
, json-glib
, webkitgtk
, vte
, glib-networking
}:
stdenv.mkDerivation rec {
pname = "gnome-boxes";
version = "3.38.2";
src = fetchurl {
url = "mirror://gnome/sources/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
sha256 = "1zjvng0izbws3506998l3dwsxjbm7wnhqipb8nmqzvi096czvajl";
};
doCheck = true;
nativeBuildInputs = [
appstream-glib # for appstream-util
desktop-file-utils
gettext
gobject-introspection
itstool
meson
ninja
pkgconfig
python3
vala
wrapGAppsHook
];
# Required for USB redirection PolicyKit rules file
propagatedUserEnvPkgs = [
spice-gtk
];
buildInputs = [
acl
cyrus_sasl
freerdp
gdbm
glib
glib-networking
gmp
gnome3.adwaita-icon-theme
gtk-vnc
gtk3
gtksourceview4
json-glib
libapparmor
libarchive
libcap
libcap_ng
libgudev
libhandy_0
libosinfo
librsvg
libsecret
libsoup
libusb1
libvirt
libvirt-glib
libxml2
numactl
spice-gtk
spice-protocol
systemd
tracker
tracker-miners
vte
webkitgtk
yajl
];
preFixup = ''
gappsWrapperArgs+=(--prefix PATH : "${stdenv.lib.makeBinPath [ mtools cdrkit libcdio ]}")
'';
postPatch = ''
chmod +x build-aux/post_install.py # patchShebangs requires executable file
patchShebangs build-aux/post_install.py
'';
passthru = {
updateScript = gnome3.updateScript {
packageName = pname;
attrPath = "gnome3.${pname}";
};
};
meta = with lib; {
description = "Simple GNOME 3 application to access remote or virtual systems";
homepage = "https://wiki.gnome.org/Apps/Boxes";
license = licenses.gpl3;
platforms = platforms.linux;
maintainers = teams.gnome.members;
};
}