获取llvm-gcc-4.2失败,退出错误

时间:2011-08-02 18:50:24

标签: ios xcode gcc compiler-errors

我不知道如何调试这个,而且我一直在撞墙几个小时。这是我得到的错误:

Ld /Users/MyAccount/Library/Developer/Xcode/DerivedData/TAC-goimuvevceqxowccylmmpcflbtvz/Build/Products/Debug-iphonesimulator/TAC.app/TAC normal i386
    cd "/Users/MyAccount/Desktop/Programming Stuff/iOS Programming/XCode 4/TAC"
    setenv MACOSX_DEPLOYMENT_TARGET 10.6
    setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
    /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-gcc-4.2 -arch i386 -isysroot /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk -L/Users/MyAccount/Library/Developer/Xcode/DerivedData/TAC-goimuvevceqxowccylmmpcflbtvz/Build/Products/Debug-iphonesimulator -L/Developer/Platforms/iPhoneOS.platform/DeviceSupport/3.0/Symbols/usr/lib "-L/Developer/Platforms/iPhoneOS.platform/DeviceSupport/4.3.3 (8J2)/Symbols/usr/lib" -F/Users/MyAccount/Library/Developer/Xcode/DerivedData/TAC-goimuvevceqxowccylmmpcflbtvz/Build/Products/Debug-iphonesimulator "-F/Users/MyAccount/Desktop/Programming Stuff/iOS Programming/XCode 4/TAC" -filelist /Users/MyAccount/Library/Developer/Xcode/DerivedData/TAC-goimuvevceqxowccylmmpcflbtvz/Build/Intermediates/TAC.build/Debug-iphonesimulator/TAC.build/Objects-normal/i386/TAC.LinkFileList -mmacosx-version-min=10.6 -Xlinker -objc_abi_version -Xlinker 2 -D__IPHONE_OS_VERSION_MIN_REQUIRED=40300 -framework UIKit -framework Foundation -framework CoreGraphics -framework Security -framework CoreMotion -framework SystemConfiguration -framework CFNetwork -framework MobileCoreServices -lxml2.2 -lz.1.2.5 -o /Users/MasonSilber/Library/Developer/Xcode/DerivedData/TAC-goimuvevceqxowccylmmpcflbtvz/Build/Products/Debug-iphonesimulator/TAC.app/TAC

ld: warning: ignoring file /Developer/Platforms/iPhoneOS.platform/DeviceSupport/3.0/Symbols/usr/lib/libxml2.2.dylib, missing required architecture i386 in file
ld: warning: ignoring file /Developer/Platforms/iPhoneOS.platform/DeviceSupport/3.0/Symbols/usr/lib/libSystem.dylib, missing required architecture i386 in file
ld: in /Developer/Platforms/iPhoneOS.platform/DeviceSupport/3.0/Symbols/usr/lib/libobjc.A.dylib, missing required architecture i386 in file for architecture i386
Command /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-gcc-4.2 failed with exit code 1

非常感谢任何帮助。我通常会花更多时间自己解决问题,但我真的不知道从哪里开始。

3 个答案:

答案 0 :(得分:2)

如果您要针对Simulator进行构建,那么您明确需要将i386添加为有效的体系结构。同时检查平台下你有“iphonesimulator”。只需单击您的项目文件,它将在右侧编辑器中显示Build设置。你会在那里找到这些设置。希望它有所帮助。

答案 1 :(得分:1)

据说相关图书馆中缺少32位英特尔架构。

我会问为什么你坚持使用GCC 4.2当LLVM 2.0现在是默认编译器并且gcc开发已经关闭(在Apple)

切换到LLVM 2.1并查看问题是否仍然存在。

你真的需要在Apple Dev论坛上询问这个错误,如果你使用GCC作为iOS 5并且XCode 4.2是NDA很重要

答案 2 :(得分:0)

您忘记添加任何library.try来添加您错过的目录。解决此问题。