at 18.09-beta 87 lines 2.5 kB view raw
1{ stdenv, fetchurl, pkgconfig, wrapGAppsHook, gtk2, gnome2, gnome3, 2 libstartup_notification, libgtop, perl, perlXMLParser, 3 autoreconfHook, intltool, docbook_xsl, xauth 4}: 5 6stdenv.mkDerivation rec { 7 version = "2.0.12"; 8 pname = "libgksu"; 9 name = "${pname}-${version}"; 10 11 src = fetchurl { 12 url = "http://people.debian.org/~kov/gksu/${name}.tar.gz"; 13 sha256 = "1brz9j3nf7l2gd3a5grbp0s3nksmlrp6rxmgp5s6gjvxcb1wzy92"; 14 }; 15 16 nativeBuildInputs = [ 17 pkgconfig autoreconfHook intltool docbook_xsl wrapGAppsHook 18 ]; 19 20 buildInputs = [ 21 gtk2 gnome2.GConf libstartup_notification 22 gnome3.libgnome-keyring libgtop gnome2.libglade perl perlXMLParser 23 ]; 24 25 enableParallelBuilding = true; 26 27 hardeningDisable = [ "format" ]; 28 29 patches = [ 30 # Patches from the gentoo ebuild 31 32 # Fix compilation on bsdc 33 ./libgksu-2.0.0-fbsd.patch 34 35 # Fix wrong usage of LDFLAGS, gentoo bug #226837 36 ./libgksu-2.0.7-libs.patch 37 38 # Use po/LINGUAS 39 ./libgksu-2.0.7-polinguas.patch 40 41 # Don't forkpty; gentoo bug #298289 42 ./libgksu-2.0.12-revert-forkpty.patch 43 44 # Make this gmake-3.82 compliant, gentoo bug #333961 45 ./libgksu-2.0.12-fix-make-3.82.patch 46 47 # Do not build test programs that are never executed; also fixes gentoo bug #367397 (underlinking issues). 48 ./libgksu-2.0.12-notests.patch 49 50 # Fix automake-1.11.2 compatibility, gentoo bug #397411 51 ./libgksu-2.0.12-automake-1.11.2.patch 52 ]; 53 54 postPatch = '' 55 # gentoo bug #467026 56 sed -i -e 's:AM_CONFIG_HEADER:AC_CONFIG_HEADERS:' configure.ac 57 58 # Fix some binary paths 59 sed -i -e 's|/usr/bin/xauth|${xauth}/bin/xauth|g' libgksu/gksu-run-helper.c libgksu/libgksu.c 60 sed -i -e 's|/usr/bin/sudo|/run/wrappers/bin/sudo|g' libgksu/libgksu.c 61 sed -i -e 's|/bin/su\([^d]\)|/run/wrappers/bin/su\1|g' libgksu/libgksu.c 62 63 touch NEWS README 64 ''; 65 66 preConfigure = '' 67 intltoolize --force --copy --automake 68 ''; 69 70 configureFlags = [ 71 "--disable-gtk-doc" 72 ]; 73 74 meta = { 75 description = "A library for integration of su into applications"; 76 longDescription = '' 77 This library comes from the gksu program. It provides a simple API 78 to use su and sudo in programs that need to execute tasks as other 79 user. It provides X authentication facilities for running 80 programs in an X session. 81 ''; 82 homepage = http://www.nongnu.org/gksu/; 83 license = stdenv.lib.licenses.lgpl2; 84 maintainers = [ stdenv.lib.maintainers.romildo ]; 85 platforms = stdenv.lib.platforms.linux; 86 }; 87}