I created a content only project, which I made a Shipping build for iOS (for TestFlight testing). Then I tried to add C++ code to the project, but then code project file generation failed with the error: “namespace global::” already has a definition for [ProjectName]Target.
The issue was that there was already a [ProjectName]Target.cs file in the Intermediate folder, presumably from the initial Content Only Shipping Build.
Deleting the [ProjectName]Target.cs file in the Intermediate folder, and regenerating project files, fixed the issue. I just wanted to report the error, and request that the error in the Terminal/Output Log suggests checking the Intermediate folder for duplicate files.
Thanks!