问题
When converting to use the new build system on Xcode 10, I get the following error in my output for several of my extension targets.
<unknown>:0: error: if any output files are specified, they all must be
Command CompileSwift failed with a nonzero exit code
I have looked for a solution online, but the only reference I can find to this error is in the Swift compiler source code itself.
- https://www.google.com/search?q=error_if_any_output_files_are_specified_they_all_must_be
Does anyone know how this error is actually triggered, or what I can do to fix it?
回答1:
Ok, I had the same problem with one of our projects. Building or Archiving are always stopped with the error <unknown>:0: error: if any output files are specified, they all must be
.
The solution for us was to set Compilation Mode
to Incremental
instead of Whole Module
.
This means, you have to ignore the Validate Project Settings
warning:
来源:https://stackoverflow.com/questions/52390963/swift-build-error-if-any-output-files-are-specified-they-all-must-be