I got this warning while compiling my app for uploading to Apple App Store:
Application failed codesign verification. The signature was invalid, or it was not signed with an Apple submission certificate. (-19011)
After spending plenty of time searching for the solution, still no luck.
I finally found out that it was because I had set the codesign provision to be automatically select. After I set the codesign provision manually everything is fine.
Hope this will help those who encounter the same problem.