Skip to content

Commit

Permalink
Add error for no Linux swiftc path (#466)
Browse files Browse the repository at this point in the history
Fixes #16
  • Loading branch information
keith authored Aug 11, 2020
1 parent 616439c commit b255732
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions swift/internal/swift_autoconfiguration.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,9 @@ def _create_linux_toolchain(repository_ctx):
"in your environment before invoking Bazel.")

path_to_swiftc = repository_ctx.which("swiftc")
if not path_to_swiftc:
fail("No 'swiftc' executable found in $PATH")

root = path_to_swiftc.dirname.dirname
feature_values = _compute_feature_values(repository_ctx, path_to_swiftc)
version_file = _write_swift_version(repository_ctx, path_to_swiftc)
Expand Down

0 comments on commit b255732

Please sign in to comment.