From f6ccb637d24ea93b67fff582a186273604971e71 Mon Sep 17 00:00:00 2001 From: Richard Howell Date: Mon, 27 Jan 2025 07:59:12 -0800 Subject: [PATCH] disallow swift driver for interface compilation Summary: The swift-driver does not have the same behaviour as the legacy driver when presented with a single swiftinterface source. For now disallow the swift driver when compiling swiftinterface files. Reviewed By: drodriguez Differential Revision: D68650149 fbshipit-source-id: 48fea9d5205041f2d37a2e84ae740434729f1365 --- apple/swift/swift_compilation.bzl | 3 +++ 1 file changed, 3 insertions(+) diff --git a/apple/swift/swift_compilation.bzl b/apple/swift/swift_compilation.bzl index 41b15c7fc..42fdab6fd 100644 --- a/apple/swift/swift_compilation.bzl +++ b/apple/swift/swift_compilation.bzl @@ -500,6 +500,9 @@ def _compile_swiftmodule( "-Xfrontend", "-compile-module-from-interface", output_swiftinterface, + # The new driver will fail with "error: no input files" + # so use the legacy driver until we add functionality for this. + "-disallow-use-new-driver", "-o", output_swiftmodule.as_output(), ])