Skip to content

Commit 1bc3e29

Browse files
authored
Enable swift.use_response_files by default on Linux (#1013)
All versions of Swift we support can use this
1 parent 8c6a03f commit 1bc3e29

File tree

2 files changed

+1
-15
lines changed

2 files changed

+1
-15
lines changed

swift/internal/swift_autoconfiguration.bzl

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -117,20 +117,6 @@ print("Hello")
117117
source_file,
118118
)
119119

120-
def _check_use_response_files(repository_ctx, swiftc_path, temp_dir):
121-
"""Returns True if `swiftc` supports the use of response files."""
122-
param_file = _scratch_file(
123-
repository_ctx,
124-
temp_dir,
125-
"check-response-files.params",
126-
"-version",
127-
)
128-
return _swift_succeeds(
129-
repository_ctx,
130-
swiftc_path,
131-
"@{}".format(param_file),
132-
)
133-
134120
def _check_supports_lld_gc_workaround(repository_ctx, swiftc_path, temp_dir):
135121
"""Returns True if lld is being used and it supports nostart-stop-gc"""
136122
source_file = _scratch_file(
@@ -226,7 +212,6 @@ _FEATURE_CHECKS = {
226212
SWIFT_FEATURE_LLD_GC_WORKAROUND: _check_supports_lld_gc_workaround,
227213
SWIFT_FEATURE_SUPPORTS_BARE_SLASH_REGEX: _check_enable_bare_slash_regex,
228214
SWIFT_FEATURE_SUPPORTS_PRIVATE_DEPS: _check_supports_private_deps,
229-
SWIFT_FEATURE_USE_RESPONSE_FILES: _check_use_response_files,
230215
}
231216

232217
def _normalized_linux_cpu(cpu):

swift/internal/swift_toolchain.bzl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -293,6 +293,7 @@ def _swift_toolchain_impl(ctx):
293293
SWIFT_FEATURE_NO_GENERATED_MODULE_MAP,
294294
SWIFT_FEATURE_OPT_USES_WMO,
295295
SWIFT_FEATURE_USE_GLOBAL_MODULE_CACHE,
296+
SWIFT_FEATURE_USE_RESPONSE_FILES,
296297
])
297298

298299
requested_features.extend(ctx.features)

0 commit comments

Comments
 (0)