Code Coverage GCov not working with XCode 4.2 and iOS SDK 5

后端 未结 2 507
半阙折子戏
半阙折子戏 2021-01-22 04:07

I\'ve been trying to get GCov working with Xcode 4.2Build 4D199 on Lion with iOS SDK 5.0 to no avail. Has anyone had any luck with this? I\'m using Google Tools For Mac for my u

2条回答
  •  -上瘾入骨i
    2021-01-22 04:17

    GCov is no longer supported in XCode 4.2. You'll note that if you go their "man page" for it, XCode 4.2 is not an option in the drop down list. Furthermore, if you look at the compile, it's using "c++", which is linked to llvm-g++-4.2. They now exclusively use the Clang/LLVM tool chain (which in turn often makes use of the gcc tool chain) instead of giving you the option of directly using the gcc tool chain. A consequence of this is that doing code coverage in XCode4 with gcov is no longer directly available. This also can affect compiles using CMake that bypass XCode 4. That first link gives you instructions on how to change your project to use profile_rt instead of gcov.

提交回复
热议问题