2020-04-24 23:36:52 +00:00
|
|
|
{ version, sha256 }:
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
{ fetchurl, python3Packages, lib }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
python3Packages.buildPythonApplication rec {
|
|
|
|
pname = "scons";
|
|
|
|
inherit version;
|
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "mirror://sourceforge/scons/${pname}-${version}.tar.gz";
|
|
|
|
inherit sha256;
|
|
|
|
};
|
|
|
|
|
|
|
|
setupHook = ./setup-hook.sh;
|
|
|
|
|
2020-08-20 17:08:02 +00:00
|
|
|
postPatch = lib.optionalString (lib.versionAtLeast version "4.0.0") ''
|
|
|
|
substituteInPlace setup.cfg \
|
|
|
|
--replace "build/dist" "dist"
|
2021-02-05 17:12:51 +00:00
|
|
|
'' + lib.optionalString (lib.versionAtLeast version "4.1.0") ''
|
|
|
|
substituteInPlace setup.cfg \
|
|
|
|
--replace "build/doc/man/" ""
|
2020-08-20 17:08:02 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
# The release tarballs don't contain any tests (runtest.py and test/*):
|
|
|
|
doCheck = lib.versionOlder version "4.0.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
postInstall = lib.optionalString (lib.versionAtLeast version "4.1.0") ''
|
|
|
|
mkdir -p "$out/share/man/man1"
|
|
|
|
mv "$out/"*.1 "$out/share/man/man1/"
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "An improved, cross-platform substitute for Make";
|
|
|
|
longDescription = ''
|
|
|
|
SCons is an Open Source software construction tool. Think of
|
|
|
|
SCons as an improved, cross-platform substitute for the classic
|
|
|
|
Make utility with integrated functionality similar to
|
|
|
|
autoconf/automake and compiler caches such as ccache. In short,
|
|
|
|
SCons is an easier, more reliable and faster way to build
|
|
|
|
software.
|
|
|
|
'';
|
|
|
|
homepage = "https://scons.org/";
|
|
|
|
changelog = "https://raw.githubusercontent.com/SConsProject/scons/rel_${version}/src/CHANGES.txt";
|
|
|
|
license = licenses.mit;
|
|
|
|
platforms = platforms.all;
|
2021-06-01 10:57:12 +00:00
|
|
|
maintainers = [ ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|