2013-06-12 03:24:04 +01:00
|
|
|
{ stdenv, fetchurl, ruby, rake, rubygems, makeWrapper, ncursesw_sup
|
2013-06-20 01:09:15 +01:00
|
|
|
, xapian_ruby, gpgme, libiconvOrEmpty, rmail, mime_types, chronic, trollop
|
|
|
|
, lockfile, gettext, iconv, locale, text, highline }:
|
2013-05-26 09:07:28 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation {
|
2013-06-20 01:09:15 +01:00
|
|
|
name = "sup-896ab66c0263e5ce0fa45857fb08e0fb78fcb6bd";
|
2013-05-26 09:07:28 +01:00
|
|
|
|
|
|
|
meta = {
|
|
|
|
homepage = http://supmua.org;
|
|
|
|
description = "A curses threads-with-tags style email client";
|
|
|
|
maintainers = with stdenv.lib.maintainers; [ lovek323 ];
|
|
|
|
license = stdenv.lib.licenses.gpl2;
|
|
|
|
platforms = stdenv.lib.platforms.unix;
|
|
|
|
};
|
|
|
|
|
|
|
|
dontStrip = true;
|
|
|
|
|
|
|
|
src = fetchurl {
|
2013-06-20 01:09:15 +01:00
|
|
|
url = "https://github.com/sup-heliotrope/sup/archive/896ab66c0263e5ce0fa45857fb08e0fb78fcb6bd.tar.gz";
|
|
|
|
sha256 = "0sknf4ha13m2478fa27qnm43bcn59g6qbd8f2nmv64k2zs7xnwmk";
|
2013-05-26 09:07:28 +01:00
|
|
|
};
|
|
|
|
|
2013-06-12 03:24:04 +01:00
|
|
|
buildInputs =
|
2013-06-20 01:09:15 +01:00
|
|
|
[ ruby rake rubygems makeWrapper gpgme ncursesw_sup xapian_ruby
|
2013-06-13 05:21:20 +01:00
|
|
|
libiconvOrEmpty ];
|
2013-05-26 09:07:28 +01:00
|
|
|
|
|
|
|
buildPhase = "rake gem";
|
|
|
|
|
2013-06-12 03:24:04 +01:00
|
|
|
# TODO: Move gem dependencies out
|
|
|
|
|
2013-05-26 09:07:28 +01:00
|
|
|
installPhase = ''
|
|
|
|
export HOME=$TMP/home; mkdir -pv "$HOME"
|
2013-06-12 03:24:04 +01:00
|
|
|
|
|
|
|
GEM_PATH="$GEM_PATH:$out/${ruby.gemPath}"
|
2013-06-14 09:06:14 +01:00
|
|
|
GEM_PATH="$GEM_PATH:${chronic}/${ruby.gemPath}"
|
|
|
|
GEM_PATH="$GEM_PATH:${gettext}/${ruby.gemPath}"
|
2013-06-15 12:02:57 +01:00
|
|
|
GEM_PATH="$GEM_PATH:${gpgme}/${ruby.gemPath}"
|
2013-06-14 09:06:14 +01:00
|
|
|
GEM_PATH="$GEM_PATH:${iconv}/${ruby.gemPath}"
|
2013-06-15 12:02:57 +01:00
|
|
|
GEM_PATH="$GEM_PATH:${locale}/${ruby.gemPath}"
|
|
|
|
GEM_PATH="$GEM_PATH:${lockfile}/${ruby.gemPath}"
|
|
|
|
GEM_PATH="$GEM_PATH:${mime_types}/${ruby.gemPath}"
|
|
|
|
GEM_PATH="$GEM_PATH:${ncursesw_sup}/${ruby.gemPath}"
|
|
|
|
GEM_PATH="$GEM_PATH:${rmail}/${ruby.gemPath}"
|
|
|
|
GEM_PATH="$GEM_PATH:${text}/${ruby.gemPath}"
|
|
|
|
GEM_PATH="$GEM_PATH:${trollop}/${ruby.gemPath}"
|
2013-06-20 01:09:15 +01:00
|
|
|
GEM_PATH="$GEM_PATH:${xapian_ruby}/${ruby.gemPath}"
|
|
|
|
GEM_PATH="$GEM_PATH:${highline}/${ruby.gemPath}"
|
2013-06-12 03:24:04 +01:00
|
|
|
|
|
|
|
# Don't install some dependencies -- we have already installed
|
2013-06-14 09:06:14 +01:00
|
|
|
# the dependencies but gem doesn't acknowledge this
|
2013-05-26 09:07:28 +01:00
|
|
|
gem install --no-verbose --install-dir "$out/${ruby.gemPath}" \
|
2013-06-12 03:24:04 +01:00
|
|
|
--bindir "$out/bin" --no-rdoc --no-ri pkg/sup-999.gem \
|
|
|
|
--ignore-dependencies
|
2013-05-26 09:07:28 +01:00
|
|
|
|
|
|
|
for prog in $out/bin/*; do
|
|
|
|
wrapProgram "$prog" --prefix GEM_PATH : "$GEM_PATH"
|
|
|
|
done
|
|
|
|
|
|
|
|
for prog in $out/gems/*/bin/*; do
|
|
|
|
[[ -e "$out/bin/$(basename $prog)" ]]
|
|
|
|
done
|
|
|
|
'';
|
|
|
|
}
|
|
|
|
|