Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, stdenv 3, fetchFromGitHub 4, perlPackages 5, wrapGAppsHook 6, imagemagick 7, gdk-pixbuf 8, librsvg 9, hicolor-icon-theme 10, procps 11, libwnck 12, libappindicator-gtk3 13, xdg-utils 14}: 15 16let 17 perlModules = with perlPackages; [ 18 # Not sure if these are needed 19 # Gnome2 Gnome2Canvas Gnome2VFS Gtk2AppIndicator Gtk2Unique 20 ImageMagick 21 Cairo 22 FileBaseDir 23 FileWhich 24 FileCopyRecursive 25 XMLSimple 26 XMLTwig 27 XMLParser 28 SortNaturally 29 LocaleGettext 30 ProcProcessTable 31 X11Protocol 32 ProcSimple 33 ImageExifTool 34 JSON 35 JSONMaybeXS 36 NetOAuth 37 PathClass 38 LWP 39 LWPProtocolHttps 40 NetDBus 41 TryTiny 42 WWWMechanize 43 HTTPMessage 44 HTTPDate 45 HTMLForm 46 HTMLParser 47 HTMLTagset 48 HTTPCookies 49 EncodeLocale 50 URI 51 CarpAlways 52 GlibObjectIntrospection 53 NumberBytesHuman 54 CairoGObject 55 Readonly 56 Gtk3ImageView 57 Gtk3 58 Glib 59 Pango 60 GooCanvas2 61 GooCanvas2CairoTypes 62 commonsense 63 TypesSerialiser 64 ]; 65in 66stdenv.mkDerivation rec { 67 pname = "shutter"; 68 version = "0.99.2"; 69 70 src = fetchFromGitHub { 71 owner = "shutter-project"; 72 repo = "shutter"; 73 rev = "v${version}"; 74 sha256 = "sha256-o95skSr6rszh0wsHQTpu1GjqCDmde7aygIP+i4XQW9A="; 75 }; 76 77 nativeBuildInputs = [ wrapGAppsHook ]; 78 buildInputs = [ 79 perlPackages.perl 80 procps 81 gdk-pixbuf 82 librsvg 83 libwnck 84 libappindicator-gtk3 85 hicolor-icon-theme 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 = with lib; { 106 description = "Screenshot and annotation tool"; 107 homepage = "https://shutter-project.org/"; 108 license = licenses.gpl3Plus; 109 platforms = platforms.all; 110 maintainers = [ maintainers.bjornfor ]; 111 }; 112}