Skip to content

Commit 72337ef

Browse files
authored
build: adjust application of flags for LLVM issue (#67455)
The flags were meant to be applied to the C++ code not the Swift code. Adjust the configuration to apply the flags properly.
1 parent 64ba7ff commit 72337ef

File tree

1 file changed

+4
-10
lines changed

1 file changed

+4
-10
lines changed

tools/swift-inspect/Package.swift

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -22,17 +22,11 @@ let package = Package(
2222
.target(name: "SwiftInspectClient", condition: .when(platforms: [.windows])),
2323
.target(name: "SwiftInspectClientInterface", condition: .when(platforms: [.windows])),
2424
],
25-
swiftSettings: [
26-
.unsafeFlags([
27-
"-parse-as-library",
28-
"-Xcc",
29-
"-Xclang",
30-
"-Xcc",
31-
"-fno-split-cold-code", // Workaround https://github.com/llvm/llvm-project/issues/40056
32-
]),
33-
]),
25+
swiftSettings: [.unsafeFlags(["-parse-as-library"])]),
3426
.target(
35-
name: "SwiftInspectClient"),
27+
name: "SwiftInspectClient",
28+
// Workaround https://github.com/llvm/llvm-project/issues/40056
29+
cxxSettings: [.unsafeFlags(["-Xclang", "-fno-split-cold-code"])]),
3630
.systemLibrary(
3731
name: "SwiftInspectClientInterface"),
3832
.testTarget(

0 commit comments

Comments
 (0)