| 4 Jul 2025 |
lzcunt | i am overriding python3Minimal to add zlib back, then overriding meson to use my python3Minimal | 17:33:12 |
lzcunt | the first part works but the second part doesn't seem to work (it seems to use regular python3Minimal instead) | 17:33:38 |
lzcunt | i don't really understand splicing, is this something to do with that and what can I do about it? | 17:33:51 |
lzcunt | meson does use python3.pkgs which I've heard is bad for cross but switching it to python3Packages doesn't help | 17:34:19 |
lzcunt | the previous solution was this abomination:
(buildPackages.meson.override { python3 = (buildPackages.__splicedPackages.python3Minimal); })
| 17:35:20 |
lzcunt | this is basically what I'm trying to do after rebasing to add zlib back in, but what I explained happens
(buildPackages.meson.override { python3 = (buildPackages.__splicedPackages.python3Minimal.override { zlib = buildPackages.zlib; allowedReferenceNames = []; }); })
| 17:36:19 |
Artturin | overriding doesn't preserve splicing so the __splicedPackages there does nothing | 18:13:27 |
Artturin | What commis? | 18:16:39 |
Artturin | * What commits? | 18:16:43 |
Artturin | * overriding doesn't preserve splicing so the __splicedPackages there does nothing (in the "previous solution" it did something) | 18:18:48 |
Artturin | * overriding doesn't preserve splicing so the __splicedPackages there does nothing (in the "previous solution" it did something because you didn't .override) | 18:22:48 |
Artturin | * What commits? You can find them in git reflog | 18:32:40 |
lzcunt | the commits that removed zlib from python3Minimal | 18:38:23 |
lzcunt | is there a way to splice the overridden package? | 18:38:40 |
Artturin | https://github.com/NixOS/nixpkgs/pull/267792 | 18:40:58 |
Artturin | Maybe the self and pythonAttr are causing your issue https://github.com/NixOS/nixpkgs/blob/ce72a12fd00a945c0b7717b3ea2ce51d5c42a20c/pkgs/development/interpreters/python/default.nix#L105-L107 | 18:42:38 |
Artturin | You should really do an overlay to overwrite | 18:42:50 |
Artturin | * You should really do an overlay to override | 18:42:56 |
Artturin | python3MinimalWithZlib = python3.override { self = __splicedPackages.python3MinimalWithZlib; pythonAttr = "python3MinimalWithZlib"; ... } | 18:43:41 |
Artturin | meson.override { python3 = python3MinimalWithZlib; } | 18:43:59 |
Artturin | * ...meson.override { python3 = python3MinimalWithZlib; } | 18:44:02 |
lzcunt | Redacted or Malformed Event | 18:44:16 |
lzcunt | wrong reply | 18:44:27 |
lzcunt | well I intend for this to be merged to nixpkgs | 18:44:40 |
Artturin | There's some python3.override's in nixpkgs but they're doing packageOverrides, not overriding python.
python = python3.override {
self = python;
packageOverrides = self: super: { sqlalchemy = super.sqlalchemy_1_4; };
};
| 18:46:59 |
emily | you should really just try to get full Python building | 18:47:11 |
emily | Darwin bootstrap does it | 18:47:16 |
Artturin | * There's some python3.override's in nixpkgs but they're doing packageOverrides, not overriding python. (I don't think they cause a python rebuild though)
python = python3.override {
self = python;
packageOverrides = self: super: { sqlalchemy = super.sqlalchemy_1_4; };
};
| 18:47:44 |
lzcunt | openssl, libffi, and probably others have infinite recursions because they all do cc.isGNU which depends on the libc which depends on meson which is rough | 18:48:09 |
lzcunt | but i'll look into darwin bootstrap | 18:48:16 |