about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/compilers/swift/compiler/patches/swift-darwin-link-cxxabi.patch
blob: dad9b3285dc12f481da3de21cdf9023726a345c0 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
This patches the stdlib backdeploy static lib to have its users link c++abi.
Without this, later steps that try to link this fail looking for global
new/delete operators (__Znwm/__ZdlPv).

--- a/stdlib/toolchain/Compatibility56/Overrides.cpp
+++ b/stdlib/toolchain/Compatibility56/Overrides.cpp
@@ -23,6 +23,7 @@
 using namespace swift;
 
 __asm__ (".linker_option \"-lc++\"");
+__asm__ (".linker_option \"-lc++abi\"");
 
 #define OVERRIDE(name, ret, attrs, ccAttrs, namespace, typedArgs, namedArgs) \
   Override_ ## name name;