nixpkgs/pkgs/desktops/mate/caja-extensions/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

74 lines
1.8 KiB
Nix
Raw Normal View History

2022-07-12 14:56:56 +03:00
{ lib
, stdenv
, fetchurl
, pkg-config
, gettext
, gtk3
, gupnp
, mate
, imagemagick
, wrapGAppsHook
, mateUpdateScript
, glib
, substituteAll
}:
2017-08-18 06:16:18 +03:00
stdenv.mkDerivation rec {
pname = "caja-extensions";
2022-09-09 23:15:55 +03:00
version = "1.26.1";
2017-08-18 06:16:18 +03:00
src = fetchurl {
2021-01-15 16:21:58 +03:00
url = "https://pub.mate-desktop.org/releases/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
2022-09-09 23:15:55 +03:00
sha256 = "WJwZ4/oQJC1iOaXMuVhVmENqVuvpTS6ypQtZUMzh1SA=";
2017-08-18 06:16:18 +03:00
};
nativeBuildInputs = [
2021-01-17 05:21:50 +03:00
pkg-config
gettext
wrapGAppsHook
2017-08-18 06:16:18 +03:00
];
buildInputs = [
gtk3
gupnp
mate.caja
mate.mate-desktop
2017-08-18 06:16:18 +03:00
imagemagick
];
patches = [
(substituteAll {
src = ./hardcode-gsettings.patch;
caja_gsetttings_path = glib.getSchemaPath mate.caja;
desktop_gsetttings_path = glib.getSchemaPath mate.mate-desktop;
})
];
2017-08-18 06:16:18 +03:00
postPatch = ''
substituteInPlace open-terminal/caja-open-terminal.c --subst-var-by \
GSETTINGS_PATH ${glib.makeSchemaPath "$out" "${pname}-${version}"}
substituteInPlace sendto/caja-sendto-command.c --subst-var-by \
GSETTINGS_PATH ${glib.makeSchemaPath "$out" "${pname}-${version}"}
substituteInPlace wallpaper/caja-wallpaper-extension.c --subst-var-by \
GSETTINGS_PATH ${glib.makeSchemaPath "$out" "${pname}-${version}"}
2017-08-18 06:16:18 +03:00
for f in image-converter/caja-image-{resizer,rotator}.c; do
substituteInPlace $f --replace "/usr/bin/convert" "${imagemagick}/bin/convert"
done
'';
2017-08-18 06:16:18 +03:00
configureFlags = [ "--with-cajadir=$$out/lib/caja/extensions-2.0" ];
2020-02-15 00:52:51 +03:00
enableParallelBuilding = true;
passthru.updateScript = mateUpdateScript { inherit pname; };
2021-04-02 22:58:16 +03:00
meta = with lib; {
2017-08-18 06:16:18 +03:00
description = "Set of extensions for Caja file manager";
2020-02-12 20:51:18 +03:00
homepage = "https://mate-desktop.org";
2021-04-22 16:23:43 +03:00
license = licenses.gpl2Plus;
2017-08-18 06:16:18 +03:00
platforms = platforms.unix;
maintainers = teams.mate.members;
2017-08-18 06:16:18 +03:00
};
}