Commit Graph

1291 Commits

Author SHA1 Message Date
Raito Bezarius
6d6210ee9b llvmPackages_git.libcxxabi: fix build on Linux and Darwin
The previous fix in db0c2564 broke *-linux.
2023-08-26 12:18:45 +02:00
Raito Bezarius
e5e3e6e4d6 llvmPackages_16.libcxxabi: fix build on Linux and Darwin
The previous fix in adc89508 broke *-linux.
2023-08-26 12:18:45 +02:00
Raito Bezarius
56bb8b73a6 llvmPackages_15.libcxxabi: fix build on Linux and Darwin
The previous fix in 314584b2 broke *-linux.
2023-08-26 12:18:45 +02:00
Randy Eckenrode
db0c256417
llvmPackages_git.libcxxabi: fix build on Darwin 2023-08-24 18:28:34 -04:00
Randy Eckenrode
adc8950856
llvmPackages_16.libcxxabi: fix build on Darwin 2023-08-24 18:28:25 -04:00
Randy Eckenrode
314584b222
llvmPackages_15.libcxxabi: fix build on Darwin 2023-08-24 18:28:16 -04:00
Peter Waller
044e8c4e44 llvmPackages_git: Port stdenv fix for cxx-headers
Signed-off-by: Peter Waller <p@pwaller.net>
2023-08-22 17:34:16 +01:00
Peter Waller
6ba1b5b0b3 llvmPackages_15, llvmPackages_16: Make the pkgsLLVM.stdenv work
What changed:

* Fixed crtbeginS.o and crtendS.o missing
  (they may or may not be called crt{begin_end},{,_shared}.

* Fixed implicit function declaration causing build errors for various
  builds by supplying -Wno-implicit-function-declaration.

* Fixed __cxxabi_config.h missing, by adding -I${cxxabi}/include/c++/v1
  in the wrapper.

* Fixed libcxx failing to build due to missing libunwind symbols by
  including libunwind as a buildInput, and setting
  -DLIBCXX_ADDITIONAL_LIBRARIES=unwind for stdenv.hostPlatform.useLLVM == true.

* libcxxabi wants to find libunwind at libunwind_shared.so, so symlink
  it there in libunwind.

* llvmPackages_16.libcxxabi: Pass -nostdlib via CMAKE_*_LINKER_FLAGS

  Without this flag, the link of libcxxabi.so tries to pull in libgcc and
  friends, from the clang compiler driver.

* Drop unneeded musl hack patch from libcxx.

* Pass -Wno-error=implicit-function-declaration only to compiler-rt

  See LLVM forum discussion:

  https://discourse.llvm.org/t/configure-script-breakage-with-the-new-werror-implicit-function-declaration/65213

  In summary, LLVM 16 made implicit function declaration an error. This
  happens a lot in configure scripts which can break things.

* llvmPackages_16: !isDarwin: Supply -DLIBCXX_ABI_USE_LLVM_UNWINDER=On

  Otherwise it fails with various undefined references to _Unwind_*
  functions: (full list: _Unwind_DeleteException _Unwind_GetIP
  _Unwind_GetLanguageSpecificData _Unwind_GetRegionStart
  _Unwind_RaiseException _Unwind_Resume _Unwind_SetGR _Unwind_SetIP).

* 16.libcxxabi: Only pass -nostdlib for useLLVM and Darwin builds

What was tested:

* x86_64-linux, aarch64-linux, the stdenv builds.
  * Additionally I was able to get nix to build, with an overlay to fix
    a couple of minor issues in downstream packages (overlay supplied in
    PR #246577.

* aarch64-darwin fails spuriously in a single LLVM test
  strip-preserve-atime.test checking atime timestamps.

* The same for pkgsLLVM with llvmPackages = llvmPackages_15.

Signed-off-by: Peter Waller <p@pwaller.net>
2023-08-22 17:33:24 +01:00
Theodore Ni
174e4f41b4
Merge pull request #247066 from reckenrode/compiler-rt-static
llvmPackages_16.compiler-rt: fix static build on Darwin
2023-08-21 19:36:50 -07:00
Randy Eckenrode
761aa9bf9f
llvmPackages_16.compiler-rt: fix static build on Darwin
This fixes two issues on Darwin to allow pkgsStatic to work with LLVM 16

* It fixes an infinite recursion where Darwin was using a regular stdenv
  to build compiler-rt instead of one without compiler-rt; and
* It disables sanitizers that won’t build statically and makes sure the
  build can find the cross-lipo.
2023-08-21 21:51:35 -04:00
github-actions[bot]
0542af4e29
Merge master into staging-next 2023-08-04 00:02:04 +00:00
Jan Malakhovski
5852f26bdc treewide: noop: refer to src.name or similar in sourceRoot where appropriate, part 1: trivial cases 2023-08-03 16:32:03 +00:00
7c6f434c
1e8f4ab411
Merge pull request #191801 from ShamrockLee/clang-python-scan-view
clang-unwrapped: mv {$out,$python}/share/scan-view/*.py
2023-07-18 14:18:49 +00:00
github-actions[bot]
eda8cc3756
Merge master into staging-next 2023-06-24 00:02:43 +00:00
Artturi
d9a2741d79
Merge pull request #238597 from avnik/avnik/clang-fix-crosscompilation 2023-06-23 21:59:29 +03:00
Alexander V. Nikolaev
cef1efea15
clang: fix crosscompilation for 16.x 2023-06-23 13:38:12 +03:00
Ryan Lahfa
b81d4f064e
Merge pull request #235624 from willcohen/emscripten-wasm2c 2023-06-22 17:49:31 +02:00
github-actions[bot]
8b9041779d
Merge staging-next into staging 2023-06-20 18:01:51 +00:00
Artturi
289d9cf8a7
Merge pull request #230387 from Artturin/llvmsplit1 2023-06-20 16:43:41 +03:00
Sergei Trofimovich
cc5c495706
Merge pull request #234957 from trofi/llvm-gcc-13-fix
llvm_{10..13}: backport gcc-13 fixes
2023-06-20 08:02:00 +01:00
Will Cohen
251c55700d llvmPackages_16: 16.0.1 -> 16.0.6 2023-06-18 19:35:45 -04:00
Randy Eckenrode
85a7771af6 llvmPackages_16.compiler-rt: fix missing builtins
Based on c96a05a293 but for LLVM 16.
2023-06-02 08:35:43 +00:00
Sergei Trofimovich
899eccf612 llvm_{10..13}: backport gcc-13 fixes
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);
          |        ^~~~~~~~~~~~~~~
2023-05-30 09:00:54 +01:00
Kira Bruneau
f44f437676
Merge pull request #232279 from kira-bruneau/llvmPackages_rocm
llvmPackages_rocm.llvm: build on big-parallel
2023-05-16 16:43:23 -04:00
Kira Bruneau
0aee301acb llvmPackages_rocm.llvm: build on big-parallel
All other LLVM packages run on big-parallel, so we should be
consistent when building the ROCm fork.
2023-05-16 14:12:02 -04:00
github-actions[bot]
b5b52a946a
Merge staging-next into staging 2023-05-09 18:02:32 +00:00
Artturin
d53d5a8b38 llvmPackages.lldb: deduplicate >10 2023-05-09 19:59:45 +03:00
Adam Joseph
62794bf2bb wrapClangMulti: link include/c++ into gcc_multi_sysroot
The phoney gcc that we construct for multilib was missing the
`$out/include/c++` directory which `cc-wrapper` needs to pass as an
`-isystem` to `clang`.

Closes #221891
2023-05-09 00:16:24 -07:00
Adam Joseph
c02c5f0860 wrapClangMulti: set gcc_multi_sysroot.langCC
The phoney gcc that we construct for multilib was missing the
`langCC` attribute, which `cc-wrapper` needs in order to decide
whether or not to add gcc's `libstdc++` headers as an `-isystem` for
`clang`.
2023-05-09 00:16:24 -07:00
Adam Joseph
0e9ef0a07d cc-wrapper: when merging gcc32 and gcc64, merge libgcc as well
Our gcc_multi and glibc_multi expressions merge together a
32-bit-targeted and 64-bit-targeted gcc.  However they do not thread
through the passthru.libgcc from these merged gccs.

This commit corrects that.

It also extends passthru.libgcc to allow a *list* rather than just a
single outpath.

Resolves part of #221891 (at least getting it back to the error
message it gave before).
2023-05-09 00:16:24 -07:00
github-actions[bot]
54295bf976
Merge staging-next into staging 2023-05-08 18:02:09 +00:00
fetsorn
91e7191660 llvm: fix typos
"verion" -> "version"
2023-05-08 21:05:07 +04:00
github-actions[bot]
cfd87655c8
Merge staging-next into staging 2023-05-05 18:01:52 +00:00
github-actions[bot]
c0860aa88a
Merge master into staging-next 2023-05-05 18:01:12 +00:00
Domen Kožar
6cf7bb9998
Merge pull request #225197 from stephank/feat/swift58
swift: 5.7.3 -> 5.8
2023-05-05 13:58:07 +01:00
github-actions[bot]
519b94e7dd
Merge staging-next into staging 2023-05-04 12:02:09 +00:00
github-actions[bot]
bf19e21376
Merge master into staging-next 2023-05-04 12:01:18 +00:00
Weijia Wang
dbea9194da
Merge pull request #229833 from wegank/llvm-darwin-hotfix
llvmPackages_16.llvm: fix postPatch on darwin
2023-05-04 13:03:42 +03:00
Weijia Wang
fd155c2a94 llvmPackages_16.llvm: avoid calling roundevenf on darwin 2023-05-04 12:59:57 +03:00
Weijia Wang
3c7fba2b0f llvmPackages_16.llvm: fix postPatch on darwin 2023-05-04 12:59:53 +03:00
misuzu
d4c2564bb6 llvmPackages_16.llvm: fix build on armv7l-linux 2023-05-04 08:55:00 +03:00
github-actions[bot]
ffc1ef23bc
Merge staging-next into staging 2023-05-04 00:03:03 +00:00
github-actions[bot]
9546b65417
Merge master into staging-next 2023-05-04 00:02:30 +00:00
Michael Weiss
b8960cd250
Merge pull request #223282 from RaitoBezarius/llvmPackages_16
llvmPackages_16: init
2023-05-03 23:56:51 +02:00
Alyssa Ross
ad10899abf llvm_5: backport patch for musl 1.2.4 2023-05-03 09:37:13 +00:00
Alyssa Ross
12d4b4ad2f llvm_6: backport patch for musl 1.2.4 2023-05-03 09:37:13 +00:00
Alyssa Ross
f6b5061108 llvm_7: backport patch for musl 1.2.4 2023-05-03 09:37:13 +00:00
Alyssa Ross
d93bd8e23d llvm_8: backport patch for musl 1.2.4 2023-05-03 09:37:13 +00:00
Alyssa Ross
768007c210 llvm_9: backport patch for musl 1.2.4 2023-05-03 09:37:13 +00:00
Alyssa Ross
fe65411847 llvm_10: backport patch for musl 1.2.4 2023-05-03 09:37:13 +00:00