开发者

Running otest results in found old-ABI metadata in image

I am trying to run unit test from terminal but it is failing each time. The following message is what I get when I try to run otest in terminal.

objc[42339]: GC: forcing GC OFF because OBJC_DISABLE_GC is set
objc[42339]: found old-ABI metadata in image /Developer/Tools/otest !
Segmentation fault

I need the output of the unit test for Hudson integration and I have the iOS deployment target set to 4.2. Here is what I am attempting to run.

export SDKROOT=/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.2.sdk
export BUILD_DIR=~/Documents/XCode/MyApp/build
export BUILD_PRODUCTS_DIR=~/Documents/XCode/MyApp/build/Debug-iphonesimulator

export DYLD_ROOT_PATH=$SDKROOT
export DYLD_FRAMEWORK_PATH=$BUILD_P开发者_开发问答RODUCTS_DIR:$SDKROOT
export IPHONE_SIMULATOR_ROOT=$SDKROOT
export CFFIXED_USER_HOME="~/Library/Application Support/iPhone Simulator/User/"
export OBJC_DISABLE_GC=YES
export DYLD_LIBRARY_PATH=$BUILD_PRODUCTS_DIR:$SDKROOT
export DYLD_NEW_LOCAL_SHARED_REGIONS=YES
export DYLD_NO_FIX_PREBINDING=YES

arch -i386 /Developer/Tools/otest MyApp.octest


bbum is correct I was using the wrong otest. Described here I needed to run the following

$ find /Developer -name otest
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator3.2.sdk/Developer/usr/bin/otest
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/Developer/usr/bin/otest
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/Developer/usr/bin/otest
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.2.sdk/Developer/usr/bin/otest
/Developer/Tools/otest

Obviously by the output I chose the correct otest for my application and it worked perfectly.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜