pypy: don't try to fetch vendored dependencies for cffi bindings

Specifically, this affects _ssl and lzma.

This should be useful on Hydra/macOS where sandboxing is disabled.
This commit is contained in:
Dmitry Kalinkin 2021-07-16 02:02:58 -04:00
parent b43959a817
commit d557708761
No known key found for this signature in database
GPG key ID: 5157B3EC8B2CA333
2 changed files with 14 additions and 0 deletions

View file

@ -73,6 +73,8 @@ in with passthru; stdenv.mkDerivation rec {
LD_LIBRARY_PATH = makeLibraryPath (filter (x : x.outPath != stdenv.cc.libc.outPath or "") buildInputs);
patches = [
./dont_fetch_vendored_deps.patch
(substituteAll {
src = ./tk_tcl_paths.patch;
inherit tk tcl;

View file

@ -0,0 +1,12 @@
diff -ur a/lib_pypy/pypy_tools/build_cffi_imports.py b/lib_pypy/pypy_tools/build_cffi_imports.py
--- a/lib_pypy/pypy_tools/build_cffi_imports.py 2021-04-12 01:11:48.000000000 -0400
+++ b/lib_pypy/pypy_tools/build_cffi_imports.py 2021-07-16 06:37:03.000000000 -0400
@@ -225,6 +225,8 @@
print('*', ' '.join(args), file=sys.stderr)
if embed_dependencies and key in cffi_dependencies:
+ print("Nixpkgs: skipping fetching/building dependency", key)
+ elif False:
status, stdout, stderr = _build_dependency(key)
if status != 0:
failures.append((key, module))