Skip to content

pypy: fix installPhase#442224

Merged
SuperSandro2000 merged 4 commits intoNixOS:masterfrom
qbisi:pypy
Sep 16, 2025
Merged

pypy: fix installPhase#442224
SuperSandro2000 merged 4 commits intoNixOS:masterfrom
qbisi:pypy

Conversation

@qbisi
Copy link
Contributor

@qbisi qbisi commented Sep 11, 2025

part of #442206 #442540

prerequset for wrapping python executable with --inherit-argv0 in python-env, otherwise issue #301498 will happen.

IMO, pypy{2,3} is very different from pypy{2,3}_prebuilt in tree structure, this pr make it more consistent with prebuilt binary.

tested work on aarch64-darwin.

Things done

  • Built on platform:
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • Tested, as applicable:
  • Ran nixpkgs-review on this PR. See nixpkgs-review usage.
  • Tested basic functionality of all binary files, usually in ./result/bin/.
  • Nixpkgs Release Notes
    • Package update: when the change is major or breaking.
  • NixOS Release Notes
    • Module addition: when adding a new NixOS module.
    • Module update: when the change is significant.
  • Fits CONTRIBUTING.md, pkgs/README.md, maintainers/README.md and other READMEs.

Add a 👍 reaction to pull requests you find important.

@nixpkgs-ci nixpkgs-ci bot added 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 6.topic: python Python is a high-level, general-purpose programming language. labels Sep 11, 2025
@qbisi qbisi marked this pull request as ready for review September 11, 2025 23:32
@qbisi qbisi marked this pull request as draft September 12, 2025 00:11
@qbisi
Copy link
Contributor Author

qbisi commented Sep 12, 2025

nixpkgs-review result

Generated using nixpkgs-review-gha

Command: nixpkgs-review pr 442224
Commit: 57cfcfa34d2a9c7050346268a13c03879c6edbd6 (subsequent changes)
Merge: 6a2e73b51c8c5212a51ccbeea4a43669d3c25179

Logs: https://github.com/qbisi/nixpkgs-review-gha/actions/runs/17663461505


x86_64-linux

✅ 7 packages built:
  • cvs2svn
  • cvs2svn.dist
  • fbpanel
  • pypy (pypy2, pypy27)
  • pypy3 (pypy311)
  • pypy310
  • tests.writers.simple.pypy3NoLibs

aarch64-linux

❌ 1 package failed to build:
  • tests.writers.simple.pypy3NoLibs
✅ 6 packages built:
  • cvs2svn
  • cvs2svn.dist
  • fbpanel
  • pypy (pypy2, pypy27)
  • pypy3 (pypy311)
  • pypy310

x86_64-darwin (sandbox = true)

✅ 6 packages built:
  • cvs2svn
  • cvs2svn.dist
  • pypy (pypy2, pypy27)
  • pypy3 (pypy311)
  • pypy310
  • tests.writers.simple.pypy3NoLibs

aarch64-darwin (sandbox = true)

✅ 6 packages built:
  • cvs2svn
  • cvs2svn.dist
  • pypy (pypy2, pypy27)
  • pypy3 (pypy311)
  • pypy310
  • tests.writers.simple.pypy3NoLibs

@qbisi qbisi marked this pull request as ready for review September 13, 2025 01:18
@qbisi qbisi mentioned this pull request Sep 14, 2025
16 tasks
Copy link
Member

@SuperSandro2000 SuperSandro2000 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I try to build pypy3Packages.bcrypt which currently fails like:

bcrypt>
bcrypt>   --- stderr
bcrypt>   error: Could not find _sysconfigdata*.py in /nix/store/pjn9iin3qyhinadzp0amj4p7ykg8iphb-pypy3.11-7.3.19/lib/pypy3.11
bcrypt> warning: build failed, waiting for other jobs to finish...
bcrypt> error: `cargo rustc --lib --message-format=json-render-diagnostics --manifest-path src/_bcrypt/Cargo.toml --target x86_64-unknown-linux-gnu --release -v --features pyo3/extension-module --crate-type cdylib --` failed with code 101
bcrypt>
bcrypt> ERROR Backend subprocess exited when trying to invoke build_wheel

and if that builds, I am convinced the layout is now better than before.

@qbisi
Copy link
Contributor Author

qbisi commented Sep 15, 2025

The build fails, however, there exists _sysconfigdata.py

ls -al /nix/store/qw8wpskm31mmw2i66wig2h3s2fvqqj6g-pypy3.11-7.3.19/lib/pypy3.11/_sysconfigdata.py    
lrwxrwxrwx 3 root root 32 Jan  1  1970 /nix/store/qw8wpskm31mmw2i66wig2h3s2fvqqj6g-pypy3.11-7.3.19/lib/pypy3.11/_sysconfigdata.py -> ../../lib_pypy/_sysconfigdata.py

@SuperSandro2000
Copy link
Member

But before it did not at that location, so I consider this a win.

@SuperSandro2000
Copy link
Member

SuperSandro2000 commented Sep 15, 2025

Debian's PyPy3 has a _sysconfigdata__x86_64-linux-gnu.py next to the normal _sysconfigdata.py but they are not the same size and our Python3 only has a _sysconfigdata__linux_x86_64-linux-gnu.py.

@SuperSandro2000
Copy link
Member

I did this #240301 a long time ago...

@qbisi
Copy link
Contributor Author

qbisi commented Sep 15, 2025

I have tried to build bcrypt from pypy311_prebuilt, also failed

nix build nixpkgs#pythonInterpreters.pypy311_prebuilt.pkgs.bcrypt

error: Could not find _sysconfigdata*.py in /nix/store/fghx2758d4x885vdkr8866759gzdi0h0-pypy3_prebuilt-7.3.19/lib/pypy3.11

So i would consider it a matching bug of upstream bcrypt.

@SuperSandro2000
Copy link
Member

This got added in pypy/pypy@1588a4e upstream but disabled in pypy/pypy@7802d07 due to portable builds which is not applicable to us. I've asked here pypy/pypy#5015 (comment) to reenable it again. I think I am going to patch that into postInstall to fix that.

@qbisi
Copy link
Contributor Author

qbisi commented Sep 15, 2025

We should gen sysconfigdata by ourself, or wait for upstream change?

Debian use their own scripts generating sysconfigdata: https://sources.debian.org/src/pypy3/7.3.20%2Bdfsg-3/debian/scripts/gen-sysconfigdata.sh

@SuperSandro2000
Copy link
Member

We should gen sysconfigdata by ourself, or wait for upstream change?

That will take to long. I am cooking something locally but compiling pypy3 often takes way to long...

@SuperSandro2000
Copy link
Member

SuperSandro2000 commented Sep 15, 2025

I did something quick to test:

with import ./. { }; stdenv.mkDerivation {
  inherit (pypy3) pname version passthru;

  unpackPhase = ''
    mkdir $out
    cp -r ${pypy3}/* $out
    chmod -R +w $out
  '';

  installPhase = ''
    set -x
    # Create platform specific _sysconfigdata__*.py (eg: _sysconfigdata__linux_x86_64-linux-gnu.py)
    # Can be tested by building: pypy3Packages.bcrypt
    # Based on the upstream build code found here:
    # https://github.com/pypy/pypy/blob/release-pypy3.11-v7.3.20/pypy/tool/release/package.py#L176-L189
    # Upstream is not shipping config.guess, just take one from autoconf
    $out/bin/pypy3 -m sysconfig --generate-posix-vars HOST_GNU_TYPE "$(${autoconf}/share/autoconf/build-aux/config.guess)"
    buildir="$(cat pybuilddir.txt)"
    quadruplet=$(ls $buildir | sed -E 's/_sysconfigdata__(.*).py/\1/')
    cp "$buildir/_sysconfigdata__$quadruplet.py" $out/lib_pypy/
    ln -rs "$out/lib_pypy/_sysconfigdata__$quadruplet.py" $out/lib/pypy*/
  '';

  dontFixup = true;
}
diff --git a/pkgs/development/interpreters/python/pypy/default.nix b/pkgs/development/interpreters/python/pypy/default.nix
index 723f34740cd4..c0439aec18ed 100644
--- a/pkgs/development/interpreters/python/pypy/default.nix
+++ b/pkgs/development/interpreters/python/pypy/default.nix
@@ -3,6 +3,7 @@
   stdenv,
   replaceVars,
   fetchurl,
+  autoconf,
   zlibSupport ? true,
   zlib,
   bzip2,
@@ -22,7 +23,13 @@
   db,
   xz,
   python-setup-hook,
-  optimizationLevel ? "jit",
+  optimizationLevel ? "1",
+  # extra args to pass to rpython when running pypy/goal/targetpypystandalone.py
+  # Using --no-compile does not work as pypy-c is then missing
+  # --no-backendopt does not work because lib_pypy is then missing
+  # To speed things up use:
+  rpythonArgs ? [ "--no-annotate" "--no-rtype" ],
+  # rpythonArgs ? [ ],
   boehmgc,
   # For the Python package set
   hash,
@@ -150,7 +157,7 @@
     # 3. ld -t (where it attaches the values in $LD_LIBRARY_PATH as -L arguments)
     # The first is disabled in Nix (and wouldn't work in the build sandbox or on NixOS anyway), and
     # the third was only introduced in Python 3.6 (see bugs.python.org/issue9998), so is not
-    # available when buliding PyPy (which is built using Python/PyPy 2.7).
+    # available when building PyPy (which is built using Python/PyPy 2.7).
     # The second requires SONAME to be set for the dynamic library for the second part not to fail.
     # As libsqlite3 stopped shipping with SONAME after the switch to autosetup (>= 3.50 in Nixpkgs;
     # see https://www.sqlite.org/src/forumpost/5a3b44f510df8ded). This makes the Python CFFI module
@@ -177,7 +184,10 @@
     ${pythonForPypy.interpreter} rpython/bin/rpython \
       --make-jobs="$NIX_BUILD_CORES" \
       -O${optimizationLevel} \
-      --batch pypy/goal/targetpypystandalone.py
+      --batch \
+      ${lib.concatStringsSep " " rpythonArgs} \
+      pypy/goal/targetpypystandalone.py \
+      ${lib.optionalString ((toString optimizationLevel) == "1") "--withoutmod-cpyext"}

     runHook postBuild
   '';
@@ -202,6 +212,17 @@
       if isPy38OrNewer then sitePackages else "lib/${libPrefix}/${sitePackages}"
     }/sitecustomize.py

+    # Create platform specific _sysconfigdata__*.py (eg: _sysconfigdata__linux_x86_64-linux-gnu.py)
+    # Can be tested by building: pypy3Packages.bcrypt
+    # Based on the upstream build code found here:
+    # https://github.com/pypy/pypy/blob/release-pypy3.11-v7.3.20/pypy/tool/release/package.py#L176-L189
+    # Upstream is not shipping config.guess, just take one from autoconf
+    $out/bin/pypy3 -m sysconfig --generate-posix-vars HOST_GNU_TYPE "$(${autoconf}/share/autoconf/build-aux/config.guess)"
+    buildir="$(cat pybuilddir.txt)"
+    quadruplet=$(ls $buildir | sed -E 's/_sysconfigdata__(.*).py/\1/')
+    cp "$buildir/_sysconfigdata__$quadruplet.py" $out/lib_pypy/
+    ln -rs "$out/lib_pypy/_sysconfigdata__$quadruplet.py" $out/lib/pypy*/
+
     runHook postInstall
   '';

Still need testing. When this works, I am going to commit it and push it onto this PR.

@qbisi
Copy link
Contributor Author

qbisi commented Sep 15, 2025

can we just

cp build/*/_sysconfigdata*.py $out/lib_pypy

as the comment pypy/pypy#5015 (comment) suggested?

@SuperSandro2000
Copy link
Member

SuperSandro2000 commented Sep 15, 2025

I've successfull built pypy3Packages.bcrypt. I needed to rebase and also fixed some other erorrs.

@qbisi are you happy with the other changes? If so, I would merge this

@qbisi
Copy link
Contributor Author

qbisi commented Sep 15, 2025

I have reviewed the commit that generate sysconfigdata, LGTM. I am not familiar with other two commits. In all looks good to me, you can merge this once nixpkgs-review happy.

@qbisi
Copy link
Contributor Author

qbisi commented Sep 16, 2025

nixpkgs-review result

Generated using nixpkgs-review-gha

Command: nixpkgs-review pr 442224
Commit: 2a7c18f88858fa5bc4674a445b1a174066bdd89c (subsequent changes)
Merge: b273007267e0cc7b47a9401df5972b7e97ff945f

Logs: https://github.com/qbisi/nixpkgs-review-gha/actions/runs/17749976130


x86_64-linux

✅ 7 packages built:
  • cvs2svn
  • cvs2svn.dist
  • fbpanel
  • pypy (pypy2, pypy27)
  • pypy3 (pypy311)
  • pypy310
  • tests.writers.simple.pypy3NoLibs

aarch64-linux

❌ 1 package failed to build:
  • tests.writers.simple.pypy3NoLibs
✅ 6 packages built:
  • cvs2svn
  • cvs2svn.dist
  • fbpanel
  • pypy (pypy2, pypy27)
  • pypy3 (pypy311)
  • pypy310

x86_64-darwin (sandbox = true)

❌ 3 packages failed to build:
  • pypy3 (pypy311)
  • pypy310
  • tests.writers.simple.pypy3NoLibs
✅ 3 packages built:
  • cvs2svn
  • cvs2svn.dist
  • pypy (pypy2, pypy27)

Error logs: `x86_64-darwin`
pypy3
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/__pycache__:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/ctypes_config_cache:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/cffi-1.18.0.dev0.dist-info:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/_tkinter:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/_tkinter/__pycache__:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/hpy-0.9.1.dev61+g79fb330d.dist-info:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/_hashlib:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/_hashlib/__pycache__:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/_ssl:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/_ssl/__pycache__:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/_ctypes:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/_ctypes/__pycache__:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/_blake2:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/_blake2/impl:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/_blake2/__pycache__:
/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/lib_pypy/pypy_tools:
dyld[36693]: Library not loaded: @rpath/libpypy3.11-c.dylib
  Referenced from: <3E1FB7FF-2A0B-30C5-BDBE-D78E720DDB70> /nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/bin/pypy3.11
  Reason: tried: '/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/bin/libpypy3.11-c.dylib' (no such file), '/nix/store/qc126qbp5rhy1ibq330jvdgw385vxnmh-pypy3.11-7.3.19/bin/libpypy3.11-c.dylib' (no such file), '/usr/local/lib/libpypy3.11-c.dylib' (no such file), '/usr/lib/libpypy3.11-c.dylib' (no such file, not in dyld cache)
/nix/store/bih3vjig4if6jy5i92m4wzqkqvrixnxq-stdenv-darwin/setup: line 1786: 36693 Abort trap: 6              $out/bin/pypy3 -m sysconfig --generate-posix-vars HOST_GNU_TYPE "$(/nix/store/8r12hvxnxdxizzm0h96sbjmywrg5yqcf-autoconf-2.72/share/autoconf/build-aux/config.guess)"
pypy310
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/__pycache__:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/ctypes_config_cache:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/cffi-1.18.0.dev0.dist-info:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/_tkinter:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/_tkinter/__pycache__:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/_hashlib:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/_hashlib/__pycache__:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/_ssl:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/_ssl/__pycache__:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/_ctypes:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/_ctypes/__pycache__:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/_blake2:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/_blake2/impl:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/_blake2/__pycache__:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/hpy-0.9.0.dist-info:
/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/lib_pypy/pypy_tools:
dyld[36629]: Library not loaded: @rpath/libpypy3.10-c.dylib
  Referenced from: <B1AB05E5-99BE-384E-8E05-09ECB9EC0DD5> /nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/bin/pypy3.10
  Reason: tried: '/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/bin/libpypy3.10-c.dylib' (no such file), '/nix/store/iz3fm8giiv2kgvi6pbi56whqnclsf9gi-pypy3.10-7.3.19/bin/libpypy3.10-c.dylib' (no such file), '/usr/local/lib/libpypy3.10-c.dylib' (no such file), '/usr/lib/libpypy3.10-c.dylib' (no such file, not in dyld cache)
/nix/store/bih3vjig4if6jy5i92m4wzqkqvrixnxq-stdenv-darwin/setup: line 1786: 36629 Abort trap: 6              $out/bin/pypy3 -m sysconfig --generate-posix-vars HOST_GNU_TYPE "$(/nix/store/8r12hvxnxdxizzm0h96sbjmywrg5yqcf-autoconf-2.72/share/autoconf/build-aux/config.guess)"

aarch64-darwin (sandbox = true)

❌ 3 packages failed to build:
  • pypy3 (pypy311)
  • pypy310
  • tests.writers.simple.pypy3NoLibs
✅ 3 packages built:
  • cvs2svn
  • cvs2svn.dist
  • pypy (pypy2, pypy27)

Error logs: `aarch64-darwin`
pypy3
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/__pycache__:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/ctypes_config_cache:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/cffi-1.18.0.dev0.dist-info:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/_tkinter:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/_tkinter/__pycache__:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/hpy-0.9.1.dev61+g79fb330d.dist-info:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/_hashlib:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/_hashlib/__pycache__:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/_ssl:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/_ssl/__pycache__:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/_ctypes:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/_ctypes/__pycache__:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/_blake2:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/_blake2/impl:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/_blake2/__pycache__:
/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/lib_pypy/pypy_tools:
dyld[40720]: Library not loaded: @rpath/libpypy3.11-c.dylib
  Referenced from: <16AA02B1-2A84-3755-A0AE-D5154127BD01> /nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/bin/pypy3.11
  Reason: tried: '/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/bin/libpypy3.11-c.dylib' (no such file), '/nix/store/1ikf04vndbkyqn390abvppps20lgzgp5-pypy3.11-7.3.19/bin/libpypy3.11-c.dylib' (no such file), '/usr/local/lib/libpypy3.11-c.dylib' (no such file), '/usr/lib/libpypy3.11-c.dylib' (no such file, not in dyld cache)
/nix/store/pgrkqlci4gld1kp0qdhjzp1zazxblj2b-stdenv-darwin/setup: line 1786: 40720 Abort trap: 6              $out/bin/pypy3 -m sysconfig --generate-posix-vars HOST_GNU_TYPE "$(/nix/store/njq245nshh1hl008ac7binv7h0cq700l-autoconf-2.72/share/autoconf/build-aux/config.guess)"
pypy310
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/__pycache__:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/ctypes_config_cache:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/cffi-1.18.0.dev0.dist-info:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/_tkinter:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/_tkinter/__pycache__:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/_hashlib:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/_hashlib/__pycache__:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/_ssl:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/_ssl/__pycache__:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/_ctypes:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/_ctypes/__pycache__:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/_blake2:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/_blake2/impl:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/_blake2/__pycache__:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/hpy-0.9.0.dist-info:
/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/lib_pypy/pypy_tools:
dyld[39155]: Library not loaded: @rpath/libpypy3.10-c.dylib
  Referenced from: <5745516C-841A-3F13-A973-01A308E4DB28> /nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/bin/pypy3.10
  Reason: tried: '/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/bin/libpypy3.10-c.dylib' (no such file), '/nix/store/aaphi9cgy8j67s33g4lnkwb8xhcj1pay-pypy3.10-7.3.19/bin/libpypy3.10-c.dylib' (no such file), '/usr/local/lib/libpypy3.10-c.dylib' (no such file), '/usr/lib/libpypy3.10-c.dylib' (no such file, not in dyld cache)
/nix/store/pgrkqlci4gld1kp0qdhjzp1zazxblj2b-stdenv-darwin/setup: line 1786: 39155 Abort trap: 6              $out/bin/pypy3 -m sysconfig --generate-posix-vars HOST_GNU_TYPE "$(/nix/store/njq245nshh1hl008ac7binv7h0cq700l-autoconf-2.72/share/autoconf/build-aux/config.guess)"

@qbisi
Copy link
Contributor Author

qbisi commented Sep 16, 2025

Looks like we generate sysconfigdata before we fixup the rpath of libpypy3.11-c.dylib.
Moved to preFixup.

@nixpkgs-ci nixpkgs-ci bot added the 12.approvals: 1 This PR was reviewed and approved by one person. label Sep 16, 2025
@SuperSandro2000 SuperSandro2000 added this pull request to the merge queue Sep 16, 2025
Merged via the queue into NixOS:master with commit 461e7da Sep 16, 2025
29 of 32 checks passed
@SuperSandro2000 SuperSandro2000 mentioned this pull request Sep 17, 2025
12 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.topic: python Python is a high-level, general-purpose programming language. 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. 12.approvals: 1 This PR was reviewed and approved by one person.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants