nixpkgs/pkgs/applications/networking/feedreaders/newsbeuter/default.nix

44 lines
1.2 KiB
Nix
Raw Normal View History

2014-03-13 18:15:28 +01:00
{ stdenv, fetchurl, sqlite, curl, pkgconfig, libxml2, stfl, json-c-0-11, ncurses
2013-07-04 04:06:39 +02:00
, gettext, libiconvOrEmpty, makeWrapper, perl }:
2013-06-02 08:27:00 +02:00
stdenv.mkDerivation rec {
2014-03-13 18:15:28 +01:00
name = "newsbeuter-2.8";
2013-06-02 08:27:00 +02:00
src = fetchurl {
url = "http://www.newsbeuter.org/downloads/${name}.tar.gz";
2014-03-13 18:15:28 +01:00
sha256 = "013qi8yghpms2qq1b3xbrlmfgpj0ybgk0qhj245ni4kpxila0wn8";
2013-06-02 08:27:00 +02:00
};
buildInputs
# use gettext instead of libintlOrEmpty so we have access to the msgfmt
# command
2014-03-13 18:15:28 +01:00
= [ pkgconfig sqlite curl libxml2 stfl json-c-0-11 ncurses gettext perl ]
2013-06-02 08:27:00 +02:00
++ libiconvOrEmpty
++ stdenv.lib.optional stdenv.isDarwin makeWrapper;
preBuild = ''
2014-03-13 18:15:28 +01:00
sed -i -e 110,114d config.sh
2013-07-04 04:06:39 +02:00
sed -i "1 s%^.*$%#!${perl}/bin/perl%" txt2h.pl
2013-06-02 08:27:00 +02:00
export LDFLAGS=-lncursesw
'';
installPhase = ''
DESTDIR=$out prefix=\"\" make install
''
+ stdenv.lib.optionalString stdenv.isDarwin ''
for prog in $out/bin/*; do
wrapProgram "$prog" --prefix DYLD_LIBRARY_PATH : "${stfl}/lib"
done
'';
meta = {
homepage = http://www.newsbeuter.org;
description = "An open-source RSS/Atom feed reader for text terminals";
maintainers = with stdenv.lib.maintainers; [ lovek323 ];
license = stdenv.lib.licenses.mit;
platforms = stdenv.lib.platforms.unix;
};
}