-
-
Notifications
You must be signed in to change notification settings - Fork 14.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
rPackages: Disable stackprotector on aarch64-darwin #165765
Conversation
Some derivations, like `rPackages.KernSmooth`, fail to build on `aarch64-darwin` because `stackprotector` is enabled. This is similar to the fix required to get R itself working on `aarch64-darwin`: NixOS#158992.
aarch64-darwin
x86_64-linuxconnorbaker@ConnorPC:~/Packages/nixpkgs_R$ nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
$ git -c fetch.prune=false fetch --no-tags --force https://github.com/NixOS/nixpkgs master:refs/nixpkgs-review/0
remote: Enumerating objects: 105, done.
remote: Counting objects: 100% (84/84), done.
remote: Compressing objects: 100% (46/46), done.
remote: Total 105 (delta 48), reused 54 (delta 38), pack-reused 21
Receiving objects: 100% (105/105), 550.12 KiB | 9.02 MiB/s, done.
Resolving deltas: 100% (49/49), completed with 26 local objects.
From https://github.com/NixOS/nixpkgs
974af506015..d96a67d1567 master -> refs/nixpkgs-review/0
$ git worktree add /home/connorbaker/.cache/nixpkgs-review/rev-78a439e5143ddf9e1cb0e485ea05e74f61635b40/nixpkgs d96a67d15672df117e1ba56aa98c74176d747f66
Preparing worktree (detached HEAD d96a67d1567)
Updating files: 100% (30018/30018), done.
HEAD is now at d96a67d1567 Merge pull request #161545 from Infinisil/synaesthesia
$ nix-env --option system x86_64-linux -f /home/connorbaker/.cache/nixpkgs-review/rev-78a439e5143ddf9e1cb0e485ea05e74f61635b40/nixpkgs -qaP --xml --out-path --show-trace
$ git merge --no-commit --no-ff 78a439e5143ddf9e1cb0e485ea05e74f61635b40
Automatic merge went well; stopped before committing as requested
$ nix-env --option system x86_64-linux -f /home/connorbaker/.cache/nixpkgs-review/rev-78a439e5143ddf9e1cb0e485ea05e74f61635b40/nixpkgs -qaP --xml --out-path --show-trace --meta
9 packages updated:
python3.10-CNVkit python3.10-rpy2 python3.9-CNVkit python3.9-rpy2 R RStudio RStudio sage sage
$ nix --experimental-features nix-command build --no-link --keep-going --option build-use-sandbox relaxed -f /home/connorbaker/.cache/nixpkgs-review/rev-78a439e5143ddf9e1cb0e485ea05e74f61635b40/build.nix
error: builder for '/nix/store/r1r59s843hiyp2ib4kn6nrcm771npygc-RStudio-1.4.1717.drv' failed with exit code 2;
last 10 log lines:
> [ 99%] Building CXX object src/cpp/session/CMakeFiles/rsession.dir/modules/SessionFindTests.cpp.o
> [100%] Building CXX object src/cpp/session/CMakeFiles/rsession.dir/modules/SessionDiagnosticsTests.cpp.o
> [100%] Building CXX object src/cpp/session/CMakeFiles/rsession.dir/SessionConsoleProcessTests.cpp.o
> [100%] Building CXX object src/cpp/session/CMakeFiles/rsession.dir/SessionConsoleProcessSocketTests.cpp.o
> [100%] Building CXX object src/cpp/session/CMakeFiles/rsession.dir/SessionConsoleProcessPersistTests.cpp.o
> [100%] Building CXX object src/cpp/session/CMakeFiles/rsession.dir/SessionConsoleProcessInfoTests.cpp.o
> [100%] Building CXX object src/cpp/session/CMakeFiles/rsession.dir/http/SessionPosixHttpConnectionListener.cpp.o
> [100%] Linking CXX executable rsession
> [100%] Built target rsession
> make: *** [Makefile:156: all] Error 2
For full logs, run 'nix log /nix/store/r1r59s843hiyp2ib4kn6nrcm771npygc-RStudio-1.4.1717.drv'.
error: builder for '/nix/store/n6kfphpraglwcq6vk95ivzlq8lyi7cms-python3.10-CNVkit-0.9.7.drv' failed with exit code 1;
last 10 log lines:
> File "/nix/store/d0f7xzsj7034ixbnzyy1rdyvgmhvzf1j-python3.10-CNVkit-0.9.7/lib/python3.10/site-packages/skgenome/tabio/__init__.py", line 74, in read
> dframe = reader(infile, **kwargs)
> File "/nix/store/d0f7xzsj7034ixbnzyy1rdyvgmhvzf1j-python3.10-CNVkit-0.9.7/lib/python3.10/site-packages/skgenome/tabio/vcfio.py", line 30, in read_vcf
> raise ValueError("Must give a VCF filename, not open file handle: %s"
> ValueError: Must give a VCF filename, not open file handle: file `b'formats/nosample.vcf'` does not have valid header (mode=`b'r'`) - is it VCF/BCF format?
>
> ----------------------------------------------------------------------
> Ran 10 tests in 9.889s
>
> FAILED (errors=1)
For full logs, run 'nix log /nix/store/n6kfphpraglwcq6vk95ivzlq8lyi7cms-python3.10-CNVkit-0.9.7.drv'.
error: builder for '/nix/store/rzdf325d1q461flfhx7khs23aq054j79-python3.9-CNVkit-0.9.7.drv' failed with exit code 1;
last 10 log lines:
> File "/nix/store/k400cawnyw99n7sjqlr27jrfrnf2vx8s-python3.9-CNVkit-0.9.7/lib/python3.9/site-packages/skgenome/tabio/__init__.py", line 74, in read
> dframe = reader(infile, **kwargs)
> File "/nix/store/k400cawnyw99n7sjqlr27jrfrnf2vx8s-python3.9-CNVkit-0.9.7/lib/python3.9/site-packages/skgenome/tabio/vcfio.py", line 30, in read_vcf
> raise ValueError("Must give a VCF filename, not open file handle: %s"
> ValueError: Must give a VCF filename, not open file handle: file `b'formats/nosample.vcf'` does not have valid header (mode=`b'r'`) - is it VCF/BCF format?
>
> ----------------------------------------------------------------------
> Ran 10 tests in 2.886s
>
> FAILED (errors=1)
For full logs, run 'nix log /nix/store/rzdf325d1q461flfhx7khs23aq054j79-python3.9-CNVkit-0.9.7.drv'.
error: 1 dependencies of derivation '/nix/store/1v0q4y2kykdjspq6fginq9ifjzp6jncd-RStudio-1.4.1717-wrapper.drv' failed to build
error: 3 dependencies of derivation '/nix/store/gj0vgcw20nz41a37sniaqmjzcqysrrwx-review-shell.drv' failed to build
3 packages failed to build:
python310Packages.cnvkit python39Packages.cnvkit rstudioWrapper
6 packages built:
python310Packages.rpy2 python39Packages.rpy2 rWrapper rstudioServerWrapper sage sageWithDoc
$ nix-shell /home/connorbaker/.cache/nixpkgs-review/rev-78a439e5143ddf9e1cb0e485ea05e74f61635b40/shell.nix
[nix-shell:~/.cache/nixpkgs-review/rev-78a439e5143ddf9e1cb0e485ea05e74f61635b40]$ |
I don't have an M1 so hard to test this, strikes me as perhaps something that should be fixed in stdenv rather than here if M1s just don't work with the stack protector? Also bit surprised nloptr requires additional requirements, the builds for aarch64-linux and x86_64-linux are fine without. |
Result of 3 packages built:
|
Some derivations, like
rPackages.KernSmooth
, fail to build onaarch64-darwin
becausestackprotector
is enabled.This is similar to the fix required to get R itself working on
aarch64-darwin
: #158992.I've not yet tested on other platforms. I plan on doing so shortly!
Things done
sandbox = true
set innix.conf
? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)nixos/doc/manual/md-to-db.sh
to update generated release notes