Search code examples
objective-cxcode10swift4.2

Xcode 10 warning "unexpected C compiler invocation with specified output"


I have a project with both Swift and Objective-C code.

After upgrading to Xcode 10 and Swift 4.2, I get the following warning for two of my objective-C .m files:

:-1: unexpected C compiler invocation with specified output: '/Users/[username]/Library/Developer/Xcode/DerivedData/[filepath]' (for input: '/Users/[username]/Documents/Projects/[filepath]') (in target [targetName])

How can I debug this?


Solution

  • Figured out the issue: I have some of my source files accidentally listed under "Copy Bundle Resources" in Build Phases. Fixed by removing those files from "Copy Bundle Resources".