about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/interpreters/python/default.nix
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2019-08-31 11:57:05 +0000
committerAlyssa Ross <hi@alyssa.is>2019-09-16 22:04:28 +0000
commita0842e8b20cbe1ed717b72775428d1f8fc047fa4 (patch)
treeb86d0614a477f7e092d626d59b888d085aaca400 /nixpkgs/pkgs/development/interpreters/python/default.nix
parentc36b32d476b520ed0d2a37cd0973f98583d6dc7c (diff)
parent8d1510abfb592339e13ce8f6db6f29c1f8b72924 (diff)
downloadnixlib-a0842e8b20cbe1ed717b72775428d1f8fc047fa4.tar
nixlib-a0842e8b20cbe1ed717b72775428d1f8fc047fa4.tar.gz
nixlib-a0842e8b20cbe1ed717b72775428d1f8fc047fa4.tar.bz2
nixlib-a0842e8b20cbe1ed717b72775428d1f8fc047fa4.tar.lz
nixlib-a0842e8b20cbe1ed717b72775428d1f8fc047fa4.tar.xz
nixlib-a0842e8b20cbe1ed717b72775428d1f8fc047fa4.tar.zst
nixlib-a0842e8b20cbe1ed717b72775428d1f8fc047fa4.zip
Merge commit '8d1510abfb592339e13ce8f6db6f29c1f8b72924'
Diffstat (limited to 'nixpkgs/pkgs/development/interpreters/python/default.nix')
-rw-r--r--nixpkgs/pkgs/development/interpreters/python/default.nix32
1 files changed, 32 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/interpreters/python/default.nix b/nixpkgs/pkgs/development/interpreters/python/default.nix
index c8856ea2aa30..bab7a047b15c 100644
--- a/nixpkgs/pkgs/development/interpreters/python/default.nix
+++ b/nixpkgs/pkgs/development/interpreters/python/default.nix
@@ -111,6 +111,38 @@ in {
     inherit passthruFun;
   };
 
+  # Minimal versions of Python (built without optional dependencies)
+  python3Minimal = (callPackage ./cpython {
+    self = python3Minimal;
+    sourceVersion = {
+      major = "3";
+      minor = "7";
+      patch = "4";
+      suffix = "";
+    };
+    sha256 = "0gxiv5617zd7dnqm5k9r4q2188lk327nf9jznwq9j6b8p0s92ygv";
+    inherit (darwin) CF configd;
+    inherit passthruFun;
+
+    # strip down that python version as much as possible
+    openssl = null;
+    readline = null;
+    ncurses = null;
+    gdbm = null;
+    sqlite = null;
+    stripConfig = true;
+    stripIdlelib = true;
+    stripTests = true;
+    stripTkinter = true;
+    rebuildBytecode = false;
+    stripBytecode = true;
+  }).overrideAttrs(old: {
+    pname = "python3-minimal";
+    meta = old.meta // {
+      maintainers = [];
+    };
+  });
+
   pypy27 = callPackage ./pypy {
     self = pypy27;
     sourceVersion = {