So I've been doing some cross-platform mobile applications using cocos2d-x. Basically it uses common c++ code, that can easily be compiled to the popular mobile platforms with some small wrapper code that stays constant while working on the common c++ code. Everything works great, but I have a problem keeping all my project files up to date. For example, to compile to windows I have a .csproj file that holds all the c++ code to compile, for iOS I have a .xcodeproj that holds the files, and for android I have a make file that points to the files to compile. This means any time I add a new file to my project, or do anything to alter the file structure I have 3 files I must update in order to continue to build for all platforms, if I add any other platforms the problem continues to get worse.
I am wondering, is this a problem that has been solved? I'm sure I'm not the first to have problems like this, keeping up multiple project / make files to update for the different platforms to compile. I was thinking of writing my own wrapper that can easily update these files without having to open an IDE / notepad to manually update any time I add a file. But before I do I thought I'd ask the question if there was a well accepted way to handle this problem, perhaps something that already exists that deals with this exact problem.
I was curious about whether to ask this here or stackoverflow, as I'm curious both at the cocos2d-x specific case, but also the general case whenever multiple projects must be updated whenever new code is added. I chose to post it here, but am interested to the answer to both questions (specifically if cocos2d-x has something already widely used to solve the problem, and solving the problem in the general case).