Skip to content

llvm_{10..13}: backport gcc-13 fixes#234957

Merged
trofi merged 1 commit intoNixOS:stagingfrom
trofi:llvm-gcc-13-fix
Jun 20, 2023
Merged

llvm_{10..13}: backport gcc-13 fixes#234957
trofi merged 1 commit intoNixOS:stagingfrom
trofi:llvm-gcc-13-fix

Conversation

@trofi
Copy link
Contributor

@trofi trofi commented May 30, 2023

Without the change llvm build fails on gcc-13 fails as:

[  0%] Building CXX object lib/Support/CMakeFiles/LLVMSupport.dir/Signals.cpp.o
In file included from llvm/lib/Support/Signals.cpp:14:
llvm/include/llvm/Support/Signals.h:119:8: error: variable or field 'CleanupOnSignal' declared void
  119 |   void CleanupOnSignal(uintptr_t Context);
      |        ^~~~~~~~~~~~~~~
Description of changes
Things done
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 23.05 Release Notes (or backporting 22.11 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Without the change `llvm` build fails on `gcc-13` fails as:

    [  0%] Building CXX object lib/Support/CMakeFiles/LLVMSupport.dir/Signals.cpp.o
    In file included from llvm/lib/Support/Signals.cpp:14:
    llvm/include/llvm/Support/Signals.h:119:8: error: variable or field 'CleanupOnSignal' declared void
      119 |   void CleanupOnSignal(uintptr_t Context);
          |        ^~~~~~~~~~~~~~~
@trofi trofi mentioned this pull request May 30, 2023
12 tasks
@ofborg ofborg bot added the 10.rebuild-darwin-stdenv This PR causes stdenv to rebuild on Darwin and must target a staging branch. label May 30, 2023
@ofborg ofborg bot added 10.rebuild-darwin: 501+ This PR causes many rebuilds on Darwin and should normally target the staging branches. 10.rebuild-darwin: 5001+ This PR causes many rebuilds on Darwin and must target the staging branches. 10.rebuild-linux: 501+ This PR causes many rebuilds on Linux and should normally target the staging branches. 10.rebuild-linux: 5001+ This PR causes many rebuilds on Linux and must target the staging branches. labels May 30, 2023
@rrbutani
Copy link
Contributor

Have yet to run a build but this looks good to me; both patches were backported to LLVM 14 in upstream (1, 2) and the Base64.h patch indeed isn't applicable prior to LLVM 11.


@Trofli have you tried building llvm_{5..9} with gcc-13? It seems like the Signals.h patch would be applicable for those.

@trofi
Copy link
Contributor Author

trofi commented May 30, 2023

Have yet to run a build but this looks good to me; both patches were backported to LLVM 14 in upstream (1, 2) and the Base64.h patch indeed isn't applicable prior to LLVM 11.

@Trofli have you tried building llvm_{5..9} with gcc-13? It seems like the Signals.h patch would be applicable for those.

Yeah, I built all of 5..13. Don't know why older version don't fail. Could it be those are pinned to older gcc versions already?

@rrbutani
Copy link
Contributor

Yeah, I built all of 5..13. Don't know why older version don't fail.

Ah, my bad; void CleanupOnSignal(uintptr_t Context); was added to Signals.h in LLVM 10: llvm/llvm-project@a1f1699

@rrbutani
Copy link
Contributor

rrbutani commented Jun 9, 2023

I haven't yet tested on Darwin (I should have a chance to this weekend) but otherwise this looks good.

@trofi trofi merged commit cc5c495 into NixOS:staging Jun 20, 2023
@trofi trofi deleted the llvm-gcc-13-fix branch June 20, 2023 07:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

10.rebuild-darwin: 501+ This PR causes many rebuilds on Darwin and should normally target the staging branches. 10.rebuild-darwin: 5001+ This PR causes many rebuilds on Darwin and must target the staging branches. 10.rebuild-darwin-stdenv This PR causes stdenv to rebuild on Darwin and must target a staging branch. 10.rebuild-linux: 501+ This PR causes many rebuilds on Linux and should normally target the staging branches. 10.rebuild-linux: 5001+ This PR causes many rebuilds on Linux and must target the staging branches.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants