I managed to get my C++ project running in Xcode using cmake -G Xcode. Now I would like to debug it, because of the nice gdb fronted it provides.
However I need to change the working directory where gdb is executed otherwise it wont work. (It needs to read some data from files relative to the path of the working directory) What I can do is after gdb has stopped typing cd working_dir and then run it manually typing r. This works, but Xcode will complain constantly and is also not an elegant solution.
So somewhere in the build settings I should be able to set the working directory..but where?!
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…