2017-03-19 21:07:12 +00:00
|
|
|
{ fetchurl, stdenv, ncurses, pkgconfig, libbsd }:
|
2013-07-30 14:53:00 +01:00
|
|
|
stdenv.mkDerivation rec {
|
2017-03-19 21:07:12 +00:00
|
|
|
name = "mg-${version}";
|
|
|
|
version = "20161005";
|
2013-07-30 14:53:00 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
2017-03-19 21:07:12 +00:00
|
|
|
url = "http://homepage.boetes.org/software/mg/${name}.tar.gz";
|
|
|
|
sha256 = "0qaydk2cy765n9clghmi5gdnpwn15y2v0fj6r0jcm0v7d89vbz5p";
|
2013-07-30 14:53:00 +01:00
|
|
|
};
|
|
|
|
|
2016-08-12 05:02:00 +01:00
|
|
|
NIX_CFLAGS_COMPILE = "-Wno-error";
|
2017-03-19 21:07:12 +00:00
|
|
|
|
|
|
|
preConfigure = ''
|
|
|
|
substituteInPlace GNUmakefile \
|
|
|
|
--replace /usr/bin/pkg-config ${pkgconfig}/bin/pkg-config
|
|
|
|
'';
|
2016-08-12 05:02:00 +01:00
|
|
|
|
2013-07-30 14:53:00 +01:00
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin
|
|
|
|
cp mg $out/bin
|
|
|
|
mkdir -p $out/share/man/man1
|
|
|
|
cp mg.1 $out/share/man/man1
|
|
|
|
'';
|
|
|
|
|
2017-03-19 21:07:12 +00:00
|
|
|
nativeBuildInputs = [ pkgconfig ];
|
|
|
|
buildInputs = [ ncurses libbsd ];
|
2013-07-30 14:53:00 +01:00
|
|
|
|
2017-03-19 21:07:12 +00:00
|
|
|
meta = with stdenv.lib; {
|
2013-07-30 14:53:00 +01:00
|
|
|
homepage = http://homepage.boetes.org/software/mg/;
|
2014-08-24 15:21:08 +01:00
|
|
|
description = "Micro GNU/emacs, a portable version of the mg maintained by the OpenBSD team";
|
2017-03-19 21:07:12 +00:00
|
|
|
license = licenses.publicDomain;
|
|
|
|
platforms = platforms.all;
|
2013-07-30 14:53:00 +01:00
|
|
|
};
|
|
|
|
}
|