2022-12-17 10:02:37 +00:00
|
|
|
{ lib
|
|
|
|
, pkgs
|
|
|
|
, pkgsBuildHost
|
2022-04-15 01:41:22 +00:00
|
|
|
, ...
|
2021-01-05 17:05:55 +00:00
|
|
|
}:
|
|
|
|
|
2021-09-26 12:46:18 +00:00
|
|
|
let
|
2022-12-17 10:02:37 +00:00
|
|
|
python27' = (pkgsBuildHost.python27.overrideAttrs (old:
|
|
|
|
{
|
|
|
|
# Overriding `meta.knownVulnerabilities` here, see #201859 for why it exists
|
|
|
|
# In resholve case this should not be a security issue,
|
|
|
|
# since it will only be used during build, not runtime
|
|
|
|
meta = (old.meta or { }) // { knownVulnerabilities = [ ]; };
|
|
|
|
}
|
|
|
|
)).override {
|
|
|
|
self = python27';
|
|
|
|
pkgsBuildHost = pkgsBuildHost // { python27 = python27'; };
|
|
|
|
# strip down that python version as much as possible
|
|
|
|
bzip2 = null;
|
|
|
|
readline = null;
|
|
|
|
ncurses = null;
|
|
|
|
gdbm = null;
|
|
|
|
sqlite = null;
|
|
|
|
rebuildBytecode = false;
|
|
|
|
stripBytecode = true;
|
|
|
|
strip2to3 = true;
|
|
|
|
stripConfig = true;
|
|
|
|
stripIdlelib = true;
|
|
|
|
stripTests = true;
|
|
|
|
stripLibs = [
|
|
|
|
# directories
|
|
|
|
"bsddb*"
|
|
|
|
"curses"
|
|
|
|
"compiler"
|
|
|
|
"ensurepip"
|
|
|
|
"hotshot"
|
|
|
|
"lib-tk"
|
|
|
|
"sqlite3"
|
|
|
|
# files
|
|
|
|
"aifc*"
|
|
|
|
"antigravity*"
|
|
|
|
"async*"
|
|
|
|
"*audio*"
|
|
|
|
"BaseHTTPServer*"
|
|
|
|
"Bastion*"
|
|
|
|
"binhex*"
|
|
|
|
"bdb*"
|
|
|
|
"CGIHTTPServer*"
|
|
|
|
"cgitb*"
|
|
|
|
"chunk*"
|
|
|
|
"colorsys*"
|
|
|
|
"dbhash*"
|
|
|
|
"dircache*"
|
|
|
|
"*dbm*"
|
|
|
|
"ftplib*"
|
|
|
|
"*hdr*"
|
|
|
|
"imaplib*"
|
|
|
|
"imputil*"
|
|
|
|
"MimeWriter*"
|
|
|
|
"mailbox*"
|
|
|
|
"mhlib*"
|
|
|
|
"mimify*"
|
|
|
|
"multifile*"
|
|
|
|
"netrc*"
|
|
|
|
"nntplib*"
|
|
|
|
"os2emxpath*"
|
|
|
|
"pyclbr*"
|
|
|
|
"pydoc*"
|
|
|
|
"SimpleHTTPServer*"
|
|
|
|
"sgmllib*"
|
|
|
|
"smtp*"
|
|
|
|
"ssl*"
|
|
|
|
"sun*"
|
|
|
|
"tabnanny*"
|
|
|
|
"telnetlib*"
|
|
|
|
"this*"
|
|
|
|
"wave*"
|
|
|
|
"webbrowser*"
|
|
|
|
"whichdb*"
|
|
|
|
"wsgiref*"
|
|
|
|
"xdrlib*"
|
|
|
|
"*XMLRPC*"
|
|
|
|
];
|
|
|
|
enableOptimizations = false;
|
|
|
|
};
|
|
|
|
callPackage = lib.callPackageWith (pkgs // { python27 = python27'; });
|
2021-09-26 12:46:18 +00:00
|
|
|
source = callPackage ./source.nix { };
|
|
|
|
deps = callPackage ./deps.nix { };
|
|
|
|
in
|
2021-01-05 17:05:55 +00:00
|
|
|
rec {
|
2022-04-15 01:41:22 +00:00
|
|
|
# resholve itself
|
2021-09-26 12:46:18 +00:00
|
|
|
resholve = callPackage ./resholve.nix {
|
2021-09-28 08:13:01 +00:00
|
|
|
inherit (source) rSrc version;
|
2021-09-26 12:46:18 +00:00
|
|
|
inherit (deps.oil) oildev;
|
2022-12-17 10:02:37 +00:00
|
|
|
inherit (deps) configargparse;
|
2022-04-15 01:41:22 +00:00
|
|
|
inherit resholve-utils;
|
2021-09-26 12:46:18 +00:00
|
|
|
};
|
2022-04-15 01:41:22 +00:00
|
|
|
# funcs to validate and phrase invocations of resholve
|
|
|
|
# and use those invocations to build packages
|
2021-09-28 08:13:01 +00:00
|
|
|
resholve-utils = callPackage ./resholve-utils.nix {
|
2021-09-26 12:46:18 +00:00
|
|
|
inherit resholve;
|
|
|
|
};
|
2021-01-05 17:05:55 +00:00
|
|
|
}
|