nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 113 lines 2.0 kB view raw
1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5 perlPackages, 6 wrapGAppsHook3, 7 imagemagick, 8 gdk-pixbuf, 9 librsvg, 10 hicolor-icon-theme, 11 procps, 12 libwnck, 13 libappindicator-gtk3, 14 xdg-utils, 15}: 16 17let 18 perlModules = with perlPackages; [ 19 Cairo 20 CairoGObject 21 CarpAlways 22 commonsense 23 EncodeLocale 24 FileBaseDir 25 FileCopyRecursive 26 FileWhich 27 Glib 28 GlibObjectIntrospection 29 GooCanvas2 30 GooCanvas2CairoTypes 31 Gtk3 32 Gtk3ImageView 33 HTMLForm 34 HTMLParser 35 HTMLTagset 36 HTTPCookies 37 HTTPDate 38 HTTPMessage 39 ImageExifTool 40 ImageMagick 41 JSON 42 JSONMaybeXS 43 LocaleGettext 44 LWP 45 LWPProtocolHttps 46 Moo 47 NetDBus 48 NumberBytesHuman 49 Pango 50 PathClass 51 ProcProcessTable 52 ProcSimple 53 Readonly 54 SortNaturally 55 SubQuote 56 TryTiny 57 TypesSerialiser 58 URI 59 X11Protocol 60 XMLParser 61 XMLSimple 62 XMLTwig 63 ]; 64in 65stdenv.mkDerivation (finalAttrs: { 66 pname = "shutter"; 67 version = "0.99.6"; 68 69 src = fetchFromGitHub { 70 owner = "shutter-project"; 71 repo = "shutter"; 72 rev = "v${finalAttrs.version}"; 73 sha256 = "sha256-2wRPmTpFfgU8xW9Fyn1+TMowcKm3pukT1ck06IWPiGo="; 74 }; 75 76 nativeBuildInputs = [ wrapGAppsHook3 ]; 77 buildInputs = [ 78 perlPackages.perl 79 procps 80 gdk-pixbuf 81 librsvg 82 libwnck 83 libappindicator-gtk3 84 hicolor-icon-theme 85 ] 86 ++ perlModules; 87 88 makeFlags = [ 89 "prefix=${placeholder "out"}" 90 ]; 91 92 postPatch = '' 93 patchShebangs po2mo.sh 94 ''; 95 96 preFixup = '' 97 # make xdg-open overrideable at runtime 98 gappsWrapperArgs+=( 99 --set PERL5LIB ${perlPackages.makePerlPath perlModules} \ 100 --prefix PATH : ${lib.makeBinPath [ imagemagick ]} 101 --suffix PATH : ${lib.makeBinPath [ xdg-utils ]} 102 ) 103 ''; 104 105 meta = { 106 description = "Screenshot and annotation tool"; 107 mainProgram = "shutter"; 108 homepage = "https://shutter-project.org/"; 109 license = lib.licenses.gpl3Plus; 110 platforms = lib.platforms.all; 111 maintainers = [ lib.maintainers.bjornfor ]; 112 }; 113})