Has anybody ever faced this issue:
PBXCp error ..... is longer than filepath buffer size (1025)
Yes, I got the same problem.
Inside Build Phases-> "Copy Bundle Resources" section, a folder was nested with the project folder again (it means duplicating files).
So xcode is trying to recursively build the product, so it can add the product itself recursively as a resource for itself.
Remove that product( duplicate folder ) itself from "Copy Bundle Resources" section. This method solved the problem for me.