0

I have an app that uses a Swift framework that contains an intentdefinition file. I use CocoaPods to manage/distribute my frameworks, so, in order for Siri to successfully find the app and extension so that she can respond, I needed to add a "Build Phases"/"Copy Bundle Resources" step that copies the intentdefinition file from the framework into the app's main bundle.

Please see this question and answer for more background about this question.

The app and extension are working properly, now, but at compile time I get warnings for each intent:

"The Swift file '.../DerivedSources/IntentDefinitionGenerated/*Intents/*Intent.swift' cannot be processed by a Copy Bundle Resources build phase"

While this statement is true, it is not relevant in this case, since the framework will process the files.

How can I suppress this warning?

Paul King
  • 1,881
  • 20
  • 23
  • You may want to check out https://stackoverflow.com/questions/53760452/xcode-generated-coredata-files-cannot-be-processed-by-copy-bundle-resources-buil/54046043#54046043. It is similar to yours, although it specifically deals with a coreData file issue rather than an intent file issue. I am not sure if your problem relates or not. – EndersJeesh Jan 04 '19 at 21:07
  • If the Intent file is not copied into the bundle then the Intent functionality does not work (see the link referenced in the question). By adding the "Build Phases"/"Copy Bundle Resources" step, everything works, but I then continuously see the warnings with each compile... – Paul King Jan 04 '19 at 21:14

1 Answers1

0

Check if the files mentioned in the warning are there in Build Phases > Copy Bundle Resources Simply remove from there and warning will be gone. enter image description here

Abhirajsinh Thakore
  • 1,806
  • 2
  • 13
  • 23