2019-04-16 10:42:20 +00:00
|
|
|
{ stdenv, fetchurl, fetchpatch, ed }:
|
2004-11-28 17:28:55 +00:00
|
|
|
|
2011-10-12 20:43:44 +00:00
|
|
|
stdenv.mkDerivation rec {
|
2015-01-27 12:35:08 +00:00
|
|
|
name = "rcs-5.9.4";
|
2010-02-16 14:19:07 +00:00
|
|
|
|
2004-11-28 17:28:55 +00:00
|
|
|
src = fetchurl {
|
2014-01-27 14:48:30 +00:00
|
|
|
url = "mirror://gnu/rcs/${name}.tar.xz";
|
2015-01-27 12:35:08 +00:00
|
|
|
sha256 = "1zsx7bb0rgvvvisiy4zlixf56ay8wbd9qqqcp1a1g0m1gl6mlg86";
|
2004-11-28 17:28:55 +00:00
|
|
|
};
|
2010-02-12 14:27:26 +00:00
|
|
|
|
2014-01-27 14:48:30 +00:00
|
|
|
buildInputs = [ ed ];
|
|
|
|
|
2019-04-16 10:42:20 +00:00
|
|
|
patches = stdenv.lib.optionals stdenv.isDarwin [
|
|
|
|
# This failure appears unrelated to the subject of the test. This
|
|
|
|
# test seems to rely on a bash bug where `test $x -nt $y` ignores
|
|
|
|
# subsecond values in timetamps. This bug has been fixed in Bash
|
|
|
|
# 5, and seemingly doesn't affect Darwin.
|
|
|
|
./disable-t810.patch
|
|
|
|
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://raw.githubusercontent.com/macports/macports-ports/b76d1e48dac/editors/nano/files/secure_snprintf.patch";
|
|
|
|
extraPrefix = "";
|
|
|
|
sha256 = "1wy9pjw3vvp8fv8a7pmkqmiapgacfx54qj9fvsc5gwry0vv7vnc3";
|
|
|
|
})
|
|
|
|
|
|
|
|
# Expected to appear in the next release
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://raw.githubusercontent.com/Homebrew/formula-patches/3fff7c990b8df4174045834b9c1210e7736ff5a4/rcs/noreturn.patch";
|
|
|
|
sha256 = "10zniqrd6xagf3q03i1vksl0vd9nla3qcj0840n3m8z6jd4aypcx";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2011-10-12 20:43:44 +00:00
|
|
|
doCheck = true;
|
2010-11-05 14:46:13 +00:00
|
|
|
|
2019-04-16 10:42:20 +00:00
|
|
|
checkFlags = [ "VERBOSE=1" ];
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
# If neither LOGNAME or USER are set, rcs will default to
|
|
|
|
# getlogin(), which is unreliable on macOS. It will often return
|
|
|
|
# things like `_spotlight`, or `_mbsetupuser`. macOS sets both
|
|
|
|
# environment variables in user sessions, so this is unlikely to
|
|
|
|
# affect regular usage.
|
|
|
|
|
|
|
|
export LOGNAME=$(id -un)
|
|
|
|
|
|
|
|
print_logs_and_fail() {
|
|
|
|
grep -nH -e . -r tests/*.d/{out,err}
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
|
|
|
|
make $checkFlags check || print_logs_and_fail
|
|
|
|
'';
|
|
|
|
|
2019-10-30 01:29:30 +00:00
|
|
|
NIX_CFLAGS_COMPILE = "-std=c99";
|
2015-08-20 12:09:55 +00:00
|
|
|
|
2019-04-16 10:42:20 +00:00
|
|
|
hardeningDisable = stdenv.lib.optional stdenv.cc.isClang "format";
|
|
|
|
|
2010-02-12 14:27:26 +00:00
|
|
|
meta = {
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://www.gnu.org/software/rcs/";
|
2014-08-24 14:21:08 +00:00
|
|
|
description = "Revision control system";
|
2011-10-12 20:43:44 +00:00
|
|
|
longDescription =
|
|
|
|
'' The GNU Revision Control System (RCS) manages multiple revisions of
|
|
|
|
files. RCS automates the storing, retrieval, logging,
|
|
|
|
identification, and merging of revisions. RCS is useful for text
|
|
|
|
that is revised frequently, including source code, programs,
|
|
|
|
documentation, graphics, papers, and form letters.
|
|
|
|
'';
|
|
|
|
|
2014-06-19 04:19:00 +00:00
|
|
|
license = stdenv.lib.licenses.gpl3Plus;
|
2016-05-16 20:30:20 +00:00
|
|
|
maintainers = with stdenv.lib.maintainers; [ eelco ];
|
2019-04-16 10:42:20 +00:00
|
|
|
platforms = stdenv.lib.platforms.unix;
|
2010-02-12 14:27:26 +00:00
|
|
|
};
|
2004-11-28 17:28:55 +00:00
|
|
|
}
|