nixpkgs/pkgs/applications/version-management/cvs/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

56 lines
1.4 KiB
Nix
Raw Permalink Normal View History

{ lib, stdenv, fetchurl, fetchpatch, nano }:
stdenv.mkDerivation rec {
pname = "cvs";
version = "1.12.13";
src = fetchurl {
url = "mirror://savannah/cvs/source/feature/${version}/cvs-${version}.tar.bz2";
sha256 = "0pjir8cwn0087mxszzbsi1gyfc6373vif96cw4q3m1x6p49kd1bq";
};
patches = [
./getcwd-chroot.patch
./CVE-2012-0804.patch
./CVE-2017-12836.patch
2018-04-12 05:13:25 +00:00
(fetchpatch {
url = "https://raw.githubusercontent.com/Homebrew/formula-patches/24118ec737c7/cvs/vasnprintf-high-sierra-fix.diff";
sha256 = "1ql6aaia7xkfq3vqhlw5bd2z2ywka82zk01njs1b2szn699liymg";
})
];
2016-11-22 12:53:33 +00:00
hardeningDisable = [ "fortify" "format" ];
2016-02-07 19:23:40 +00:00
preConfigure = ''
# Apply the Debian patches.
for p in "debian/patches/"*; do
echo "applying \`$p' ..."
patch --verbose -p1 < "$p"
done
'';
2021-02-12 14:42:53 +00:00
configureFlags = [
"--with-editor=${nano}/bin/nano"
# Required for cross-compilation.
"cvs_cv_func_printf_ptr=yes"
];
makeFlags = [
"AR=${stdenv.cc.targetPrefix}ar"
];
env = lib.optionalAttrs (stdenv.isDarwin && stdenv.cc.isClang) {
2023-11-04 17:12:10 +00:00
NIX_CFLAGS_COMPILE = "-Wno-implicit-function-declaration";
};
doCheck = false; # fails 1 of 1 tests
meta = with lib; {
homepage = "http://cvs.nongnu.org";
description = "Concurrent Versions System - a source control system";
2021-02-12 14:42:53 +00:00
license = licenses.gpl2Plus; # library is GPLv2, main is GPLv1
2018-08-16 19:44:29 +00:00
platforms = platforms.all;
};
}