Merge pull request #171301 from RamKromberg/fix/rc
commit
aefcb8f476
@ -1,42 +1,44 @@ |
|||||||
{ lib, stdenv, fetchurl, autoreconfHook |
{ lib, stdenv, fetchFromGitHub, autoreconfHook, byacc |
||||||
, ncurses #acinclude.m4 wants headers for tgetent(). |
, ncurses, readline |
||||||
, historySupport ? false |
, historySupport ? false, readlineSupport ? true }: |
||||||
, readline ? null |
|
||||||
}: |
|
||||||
|
|
||||||
stdenv.mkDerivation rec { |
stdenv.mkDerivation rec { |
||||||
pname = "rc"; |
pname = "rc"; |
||||||
version = "1.7.4"; |
version = "unstable-2021-08-03"; |
||||||
|
|
||||||
src = fetchurl { |
src = fetchFromGitHub { |
||||||
url = "http://static.tobold.org/rc/rc-${version}.tar.gz"; |
owner = "rakitzis"; |
||||||
sha256 = "1n5zz6d6z4z6s3fwa0pscqqawy561k4xfnmi91i626hcvls67ljy"; |
repo = "rc"; |
||||||
|
rev = "8ca9ab1305c3e30cd064290081d6e5a1fa841d26"; |
||||||
|
sha256 = "0744ars6y9zzsjr9xazms91qy6bi7msg2gg87526waziahfh4s4z"; |
||||||
}; |
}; |
||||||
|
|
||||||
nativeBuildInputs = [ autoreconfHook ]; |
nativeBuildInputs = [ autoreconfHook ]; |
||||||
buildInputs = [ ncurses ] |
|
||||||
++ lib.optionals (readline != null) [ readline ]; |
# acinclude.m4 wants headers for tgetent(). |
||||||
|
buildInputs = [ byacc ncurses ] |
||||||
|
++ lib.optionals readlineSupport [ readline ]; |
||||||
|
|
||||||
configureFlags = [ |
configureFlags = [ |
||||||
"--enable-def-interp=${stdenv.shell}" #183 |
"--enable-def-interp=${stdenv.shell}" #183 |
||||||
] ++ lib.optionals historySupport [ "--with-history" ] |
] ++ lib.optionals historySupport [ "--with-history" ] |
||||||
++ lib.optionals (readline != null) [ "--with-edit=readline" ]; |
++ lib.optionals readlineSupport [ "--with-edit=readline" ]; |
||||||
|
|
||||||
prePatch = '' |
#reproducible-build |
||||||
|
postPatch = '' |
||||||
substituteInPlace configure.ac \ |
substituteInPlace configure.ac \ |
||||||
--replace "date -I" "echo 2015-05-13" #reproducible-build |
--replace "$(git describe || echo '(git description unavailable)')" "${builtins.substring 0 7 src.rev}" |
||||||
''; |
''; |
||||||
|
|
||||||
passthru = { |
passthru.shellPath = "/bin/rc"; |
||||||
shellPath = "/bin/rc"; |
|
||||||
}; |
|
||||||
|
|
||||||
meta = with lib; { |
meta = with lib; { |
||||||
description = "The Plan 9 shell"; |
description = "The Plan 9 shell"; |
||||||
longDescription = "Byron Rakitzis' UNIX reimplementation of Tom Duff's Plan 9 shell."; |
longDescription = "Byron Rakitzis' UNIX reimplementation of Tom Duff's Plan 9 shell"; |
||||||
homepage = "http://tobold.org/article/rc"; |
homepage = "https://web.archive.org/web/20180820053030/tobold.org/article/rc"; |
||||||
license = with licenses; zlib; |
license = with licenses; zlib; |
||||||
maintainers = with maintainers; [ ramkromberg ]; |
maintainers = with maintainers; [ ramkromberg ]; |
||||||
|
mainProgram = "rc"; |
||||||
platforms = with platforms; all; |
platforms = with platforms; all; |
||||||
}; |
}; |
||||||
} |
} |
||||||
|
Loading…
Reference in new issue