问题
I added to my project bridging-header file so I can use opencv in swift. I decided that I don't need opencv so I deleted the bridging header file , after I did it I couldn't run my project because of this error:
:0: error: error opening input file '/Users/user1/Desktop/project_name/project_name/project_name-Bridging-Header.h' (No such file or directory)
this error appeared in the Compile Swift source files > Precompile bridging header section. I tried cleaning my derived data and I tried deleting the path in the Swift Compiler - General > Objective c bridging header.
回答1:
You have to delete bridging header path from the Buide setting>Swift Compiler - General > Objective c bridging header
Please search your header file name in your project and if you find anything. then delete
回答2:
Just go to product and clink "Clean Build Folder" option. That will fix the problem.
来源:https://stackoverflow.com/questions/50080712/swift-bridging-header-compiler-error