File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -1618,6 +1618,18 @@ function Build-CMakeProject {
1618
1618
} else {
1619
1619
@ (" /DEBUG" )
1620
1620
}
1621
+
1622
+ # The linker flags are shared across every language, and `/IGNORE:longsections` is an
1623
+ # `lld-link.exe` argument, not `link.exe`, so this can only be enabled when we use
1624
+ # `lld-link.exe` for linking.
1625
+ # TODO: Investigate supporting fission with PE/COFF, this should avoid this warning.
1626
+ if ($SwiftDebugFormat -eq " dwarf" ) {
1627
+ if ($UseGNUDriver ) {
1628
+ $LinkerFlags += @ (" -Xlinker" , " /IGNORE:longsections" )
1629
+ } elseif (-not $UseMSVCCompilers.Contains (" C" ) -and -not $UseMSVCCompilers.Contains (" CXX" )) {
1630
+ $LinkerFlags += @ (" /IGNORE:longsections" )
1631
+ }
1632
+ }
1621
1633
}
1622
1634
}
1623
1635
You can’t perform that action at this time.
0 commit comments