Skip to content

Update to a newer version of swift-tools-support-core #84

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
May 8, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Package.resolved

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Sources/SwiftDriver/Execution/JobExecutor.swift
Original file line number Diff line number Diff line change
Expand Up @@ -423,6 +423,7 @@ class ExecuteJobRule: LLBuildRule {
context.delegateQueue.async {
let result = ProcessResult(
arguments: [],
environment: env,
exitStatus: .terminated(code: 1),
output: Result.success([]),
stderrOutput: Result.success([])
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ public struct IncrementalCompilation {
.map {$0.option.spelling}
.sorted()
.joined()
return SHA256(hashInput).digestString()
return SHA256().hash(hashInput).hexadecimalRepresentation
}
}

Expand Down
1 change: 1 addition & 0 deletions Tests/SwiftDriverTests/JobExecutorTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ class JobCollectingDelegate: JobExecutorDelegate {
func waitUntilExit() throws -> ProcessResult {
return ProcessResult(
arguments: [],
environment: [:],
exitStatus: .terminated(code: 0),
output: Result.success(ByteString("test").contents),
stderrOutput: Result.success([])
Expand Down
8 changes: 8 additions & 0 deletions Tests/SwiftDriverTests/SwiftDriverTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -830,6 +830,9 @@ final class SwiftDriverTests: XCTestCase {
XCTAssertFalse(cmd.contains(.flag("-shared")))
}

// FIXME: This test will fail when run on macOS, because
// swift-autolink-extract is not present
#if os(Linux)
do {
// linux target
var driver = try Driver(args: commonArgs + ["-emit-library", "-target", "x86_64-unknown-linux"])
Expand Down Expand Up @@ -857,7 +860,11 @@ final class SwiftDriverTests: XCTestCase {
XCTAssertFalse(cmd.contains(.flag("-dylib")))
XCTAssertFalse(cmd.contains(.flag("-static")))
}
#endif

// FIXME: This test will fail when run on macOS, because
// swift-autolink-extract is not present
#if os(Linux)
do {
// static linux linking
var driver = try Driver(args: commonArgs + ["-emit-library", "-static", "-target", "x86_64-unknown-linux"])
Expand Down Expand Up @@ -886,6 +893,7 @@ final class SwiftDriverTests: XCTestCase {
XCTAssertFalse(cmd.contains(.flag("-static")))
XCTAssertFalse(cmd.contains(.flag("-shared")))
}
#endif
}

func testSanitizerArgs() throws {
Expand Down