That’s the most frustrating thing about Xcode, especially the section on auto-signing the output once it’s built, because there doesn’t seem to be a way to handle it via CMake (and not an issue with CMake, but with XCode). Any time the project is re-created, that section has to be set manually again.
Which section? There is another post that describes how to edit the CMake so some things do not need to be set in Xcode again and again…. I am not testing on device at present, but as soon as I build with cmake I can run in Xcode without changing anything in Xcode
It simply means that you re-run the same cmake command you initially used to generate the build files.
It’s best to delete the build folder prior to moving or copying the project source to different path, and just re-create the build files with cmake.
If for some strange reason you don’t want to delete the build files, then the least you may be able to do is delete the [build folder]\CMakeCache.txt file, and then re-run the same cmake command you initially used to generate the project.
I don’t remember running a cmake command I just used this command when I created my project
“cocos new MyGame -p com.MyCompany.MyGame -l cpp -d ~/MyCompany” and then built it everytime from android studio or xcode
Also does the CMakeCache.txt file get regenerated ?
Android Studio automatically runs cmake for you within the IDE, and generates the relevant build files.
Xcode does not generate the build files for you, so I’m not sure how you managed to build the project without a valid Xcode project file that was generated by cmake.
That file is generated by cmake, and is located in the build folder.