1{ 2 stdenv, 3 fetchurl, 4 lib, 5 file, 6 pkg-config, 7 autoconf, 8 glib, 9 dbus-glib, 10 json-glib, 11 gtk2, 12 libindicator-gtk2, 13 libdbusmenu-gtk2, 14 libappindicator-gtk2, 15}: 16 17stdenv.mkDerivation rec { 18 pname = "indicator-application-gtk2"; 19 version = "12.10.0.1"; 20 21 src = fetchurl { 22 url = "${meta.homepage}/indicator-application-gtk2/i-a-${version}/+download/indicator-application-${version}.tar.gz"; 23 sha256 = "1xqsb6c1pwawabw854f7aybjrgyhc2r1316i9lyjspci51zk5m7v"; 24 }; 25 26 nativeBuildInputs = [ 27 pkg-config 28 autoconf 29 dbus-glib # dbus-binding-tool 30 ]; 31 32 buildInputs = [ 33 glib 34 dbus-glib 35 json-glib 36 gtk2 37 libindicator-gtk2 38 libdbusmenu-gtk2 39 libappindicator-gtk2 40 ]; 41 42 postPatch = '' 43 substituteInPlace configure.ac \ 44 --replace 'DBUSSERVICEDIR=`$PKG_CONFIG --variable=session_bus_services_dir dbus-1`' \ 45 "DBUSSERVICEDIR=$out/share/dbus-1/services" 46 autoconf 47 for f in {configure,ltmain.sh,m4/libtool.m4}; do 48 substituteInPlace $f \ 49 --replace /usr/bin/file ${file}/bin/file 50 done 51 substituteInPlace src/Makefile.in \ 52 --replace 'applicationlibdir = $(INDICATORDIR)' "applicationlibdir = $out/lib" 53 ''; 54 55 configureFlags = [ 56 "CFLAGS=-Wno-error" 57 "--sysconfdir=/etc" 58 "--localstatedir=/var" 59 ]; 60 61 installFlags = [ 62 "sysconfdir=\${out}/etc" 63 "localstatedir=\${TMPDIR}" 64 ]; 65 66 meta = with lib; { 67 description = "Indicator to take menus from applications and place them in the panel (GTK 2 library for Xfce/LXDE)"; 68 homepage = "https://launchpad.net/indicators-gtk2"; 69 license = licenses.gpl3; 70 platforms = platforms.linux; 71 maintainers = [ maintainers.msteen ]; 72 }; 73}