From a2334e604bcd9b43a2f9723d1379cf8d78eeae29 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Llu=C3=ADs=20Batlle=20i=20Rossell?= Date: Sat, 10 Apr 2010 10:47:30 +0000 Subject: [PATCH] Adding slimrat (not the gui, but at least the cli) svn path=/nixpkgs/trunk/; revision=20999 --- pkgs/tools/networking/slimrat/default.nix | 31 +++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 5 ++++ 2 files changed, 36 insertions(+) create mode 100644 pkgs/tools/networking/slimrat/default.nix diff --git a/pkgs/tools/networking/slimrat/default.nix b/pkgs/tools/networking/slimrat/default.nix new file mode 100644 index 000000000000..38b7c27b6fde --- /dev/null +++ b/pkgs/tools/networking/slimrat/default.nix @@ -0,0 +1,31 @@ +{stdenv, fetchurl, perl, WWWMechanize, LWP, makeWrapper}: + +stdenv.mkDerivation { + name = "slimrat-1.0"; + src = fetchurl { + url = http://slimrat.googlecode.com/files/slimrat-1.0.tar.bz2; + sha256 = "139b71d45k4b1y47iq62a9732cnaqqbh8s4knkrgq2hx0jxpsk5a"; + }; + + buildInputs = [ perl WWWMechanize LWP makeWrapper ]; + + patchPhase = '' + sed -e 's,#!.*,#!${perl}/bin/perl,' -i src/{slimrat,slimrat-gui} + ''; + + installPhase = '' + ensureDir $out/share/slimrat $out/bin + cp -R src/* $out/share/slimrat + # slimrat-gui does not work (it needs the Gtk2 perl package) + for i in slimrat; do + makeWrapper $out/share/slimrat/$i $out/bin/$i \ + --prefix PERL5LIB : $PERL5LIB + done + ''; + + meta = { + homepage = http://code.google.com/p/slimrat/; + description = "Linux Rapidshare downloader"; + license = "BSD"; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index b7f73fd9387c..c91cff08edc2 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -1542,6 +1542,11 @@ let inherit stdenv perl; }; + slimrat = import ../tools/networking/slimrat { + inherit fetchurl stdenv perl makeWrapper; + inherit (perlPackages) WWWMechanize LWP; + }; + slsnif = import ../tools/misc/slsnif { inherit fetchurl stdenv; };