mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-11 15:27:20 +03:00
colordiff: build from source, cleanup, take maintainership
This commit is contained in:
parent
39125d0a08
commit
ca45892b9f
@ -1,26 +1,36 @@
|
||||
{ lib, stdenv, fetchurl, perl /*, xmlto */}:
|
||||
{ lib, stdenv, fetchFromGitHub, docbook_xml_dtd_412, docbook_xsl, perl, w3m, xmlto }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "colordiff-1.0.19";
|
||||
pname = "colordiff";
|
||||
version = "1.0.19";
|
||||
|
||||
src = fetchurl {
|
||||
urls = [
|
||||
"https://www.colordiff.org/${name}.tar.gz"
|
||||
"http://www.colordiff.org/archive/${name}.tar.gz"
|
||||
];
|
||||
sha256 = "069vzzgs7b44bmfh3ks2psrdb26s1w19gp9w4xxbgi7nhx6w3s26";
|
||||
src = fetchFromGitHub {
|
||||
owner = "daveewart";
|
||||
repo = "colordiff";
|
||||
rev = "v${version}";
|
||||
sha256 = "1v7s1yn0qvn08iwm5js8mxn442392qyr7s9ij506byfd497ag7qk";
|
||||
};
|
||||
|
||||
buildInputs = [ perl /* xmlto */ ];
|
||||
nativeBuildInputs = [ docbook_xml_dtd_412 docbook_xsl perl w3m xmlto ];
|
||||
|
||||
dontBuild = 1; # do not build doc yet.
|
||||
buildInputs = [ perl ];
|
||||
|
||||
installPhase = ''make INSTALL_DIR=/bin MAN_DIR=/share/man/man1 DESTDIR="$out" install'';
|
||||
postPatch = ''
|
||||
substituteInPlace Makefile \
|
||||
--replace 'TMPDIR=colordiff-''${VERSION}' ""
|
||||
'';
|
||||
|
||||
installFlags = [
|
||||
"INSTALL_DIR=/bin"
|
||||
"MAN_DIR=/share/man/man1"
|
||||
"DESTDIR=${placeholder "out"}"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Wrapper for 'diff' that produces the same output but with pretty 'syntax' highlighting";
|
||||
homepage = "https://www.colordiff.org/";
|
||||
license = licenses.gpl3;
|
||||
platforms = platforms.linux ++ platforms.darwin;
|
||||
license = licenses.gpl2Plus;
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ SuperSandro2000 ];
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user