gpt4 book ai didi

iphone - 如何解决 Apple Mach-O 链接器错误?

转载 作者:行者123 更新时间:2023-11-29 11:15:45 25 4
gpt4 key购买 nike

这是日志

CompileC /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/Objects-normal/armv7/iPadNewsbookViewController.o Classes/iPadNewsbookViewController.m normal armv7 objective-c com.apple.compilers.llvm.clang.1_0.compiler
cd /Users/RAGOpoR/Desktop/trunk/src
setenv LANG en_US.US-ASCII
setenv PATH "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x objective-c -arch armv7 -fmessage-length=0 -std=c99 -fobjc-arc -Wno-trigraphs -fpascal-strings -O0 -Wno-missing-field-initializers -Wmissing-prototypes -Wreturn-type -Wno-implicit-atomic-properties -Wformat -Wno-missing-braces -Wparentheses -Wswitch -Wno-unused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wno-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-sign-compare -Wno-shorten-64-to-32 -Wpointer-sign -Wno-newline-eof -Wno-selector -Wno-strict-selector-match -Wno-undeclared-selector -Wno-deprecated-implementations -DDEBUG_MODE=1 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.0.sdk -Wprotocol -Wdeprecated-declarations -g -fvisibility=hidden -Wno-conversion -Wno-sign-conversion -mthumb "-DIBOutlet=__attribute__((iboutlet))" "-DIBOutletCollection(ClassName)=__attribute__((iboutletcollection(ClassName)))" "-DIBAction=void)__attribute__((ibaction)" -miphoneos-version-min=4.0 -iquote "/Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/Hope Demo-generated-files.hmap" "-I/Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/Hope Demo-own-target-headers.hmap" "-I/Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/Hope Demo-all-target-headers.hmap" -iquote "/Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/Hope Demo-project-headers.hmap" -iquote../src -I/Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Products/Debug-iphoneos/include -I/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.0.sdk/usr/include/libxml2 -I/Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/DerivedSources/armv7 -I/Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/DerivedSources -F/Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Products/Debug-iphoneos -F/Users/RAGOpoR/Desktop/trunk/src -include /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/PrecompiledHeaders/iPortals_Prefix-gellvzrskltxesfcgpqcdmiyeqru/iPortals_Prefix.pch -MMD -MT dependencies -MF /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/Objects-normal/armv7/iPadNewsbookViewController.d --serialize-diagnostics /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/Objects-normal/armv7/iPadNewsbookViewController.dia -c /Users/RAGOpoR/Desktop/trunk/src/Classes/iPadNewsbookViewController.m -o /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/Objects-normal/armv7/iPadNewsbookViewController.o

In file included from /Users/RAGOpoR/Desktop/trunk/src/Classes/iPadNewsbookViewController.m:9:
In file included from /Users/RAGOpoR/Desktop/trunk/src/Classes/iPadNewsbookViewController.h:10:
In file included from /Users/RAGOpoR/Desktop/trunk/src/Classes/WebViewerController.h:10:
In file included from /Users/RAGOpoR/Desktop/trunk/src/Classes/AppDelegate_iPhone.h:12:
/Users/RAGOpoR/Desktop/trunk/src/ShareKit/Reachability/Reachability.h:69:58: warning: declaration of 'struct sockaddr_in' will not be visible outside of this function
+ (Reachability*) reachabilityWithAddress: (const struct sockaddr_in*) hostAddress;
^
0 clang 0x000000010cadf6a2 PrintStackTrace(void*) + 34
1 clang 0x000000010cadfb29 SignalHandler(int) + 553
2 libsystem_c.dylib 0x00007fff83d827ea _sigtramp + 26
3 libsystem_c.dylib 0x00007fff6b7b6300 _sigtramp + 18446744073300818736
4 clang 0x000000010c428828 findRetainCycleOwner(clang::Expr*, (anonymous namespace)::RetainCycleOwner&) + 312
5 clang 0x000000010c428b02 clang::Sema::checkRetainCycles(clang::Expr*, clang::Expr*) + 50
6 clang 0x000000010c44d33a clang::Sema::checkPseudoObjectAssignment(clang::Scope*, clang::SourceLocation, clang::BinaryOperatorKind, clang::Expr*, clang::Expr*) + 1242
7 clang 0x000000010bc85e86 clang::Sema::ActOnBinOp(clang::Scope*, clang::SourceLocation, clang::tok::TokenKind, clang::Expr*, clang::Expr*) + 1606
8 clang 0x000000010bc8507a clang::Parser::ParseRHSOfBinaryExpression(clang::ActionResult<clang::Expr*, true>, clang::prec::Level) + 570
9 clang 0x000000010bc7e4cb clang::Parser::ParseAssignmentExpression() + 171
10 clang 0x000000010bc7e401 clang::Parser::ParseExpression() + 17
11 clang 0x000000010bcd3bde clang::Parser::ParseExprStatement(clang::ParsedAttributes&) + 46
12 clang 0x000000010bc7de9c clang::Parser::ParseStatementOrDeclaration(clang::ASTOwningVector<clang::Stmt*, 32u>&, bool) + 1564
13 clang 0x000000010bc7d1b9 clang::Parser::ParseCompoundStatementBody(bool) + 409
14 clang 0x000000010c3fb1f0 clang::Parser::ParseLexedObjCMethodDefs(clang::Parser::LexedMethod&) + 272
15 clang 0x000000010bd1f6fe clang::Parser::ParseObjCAtEndDeclaration(clang::SourceRange) + 158
16 clang 0x000000010bcfd0d2 clang::Parser::ParseObjCAtDirectives() + 386
17 clang 0x000000010bc3e887 clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&, clang::Parser::ParsingDeclSpec*) + 759
18 clang 0x000000010bc3e519 clang::Parser::ParseTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&) + 249
19 clang 0x000000010bc2128b clang::ParseAST(clang::Sema&, bool) + 299
20 clang 0x000000010bc1fd19 clang::CodeGenAction::ExecuteAction() + 857
21 clang 0x000000010bbf20af clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 879
22 clang 0x000000010bbf0d3b clang::ExecuteCompilerInvocation(clang::CompilerInstance*) + 2683
23 clang 0x000000010bbe353e cc1_main(char const**, char const**, char const*, void*) + 5086
24 clang 0x000000010bbbdcd8 main + 648
25 clang 0x000000010bbbda44 start + 52
26 clang 0x0000000000000079 start + 18446744069217724009
Stack dump:
0. Program arguments: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -cc1 -triple thumbv7-apple-ios4.0.0 -S -disable-free -disable-llvm-verifier -main-file-name iPadNewsbookViewController.m -pic-level 1 -mdisable-fp-elim -relaxed-aliasing -target-abi apcs-gnu -target-cpu cortex-a8 -mfloat-abi soft -target-feature +soft-float-abi -target-linker-version 131.3 -g -coverage-file /var/folders/2s/0vbgmlf914d3x7m4xjqwdfh80000gp/T/iPadNewsbookViewController-qXtlG9.s -resource-dir /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/clang/4.0 -dependency-file /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/Objects-normal/armv7/iPadNewsbookViewController.d -MT dependencies -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.0.sdk -iquote /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/Hope Demo-generated-files.hmap -iquote /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/Hope Demo-project-headers.hmap -iquote ../src -include-pch /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/PrecompiledHeaders/iPortals_Prefix-gellvzrskltxesfcgpqcdmiyeqru/iPortals_Prefix.pch.pth -D DEBUG_MODE=1 -D IBOutlet=__attribute__((iboutlet)) -D IBOutletCollection(ClassName)=__attribute__((iboutletcollection(ClassName))) -D IBAction=void)__attribute__((ibaction) -I /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/Hope Demo-own-target-headers.hmap -I /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/Hope Demo-all-target-headers.hmap -I /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Products/Debug-iphoneos/include -I /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.0.sdk/usr/include/libxml2 -I /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/DerivedSources/armv7 -I /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/DerivedSources -F/Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Products/Debug-iphoneos -F/Users/RAGOpoR/Desktop/trunk/src -fmodule-cache-path /var/folders/2s/0vbgmlf914d3x7m4xjqwdfh80000gp/T/clang-module-cache -O0 -Wno-trigraphs -Wno-missing-field-initializers -Wmissing-prototypes -Wreturn-type -Wno-implicit-atomic-properties -Wformat -Wno-missing-braces -Wparentheses -Wswitch -Wno-unused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wno-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-sign-compare -Wno-shorten-64-to-32 -Wpointer-sign -Wno-newline-eof -Wno-selector -Wno-strict-selector-match -Wno-undeclared-selector -Wno-deprecated-implementations -Wprotocol -Wdeprecated-declarations -Wno-conversion -Wno-sign-conversion -std=c99 -fno-dwarf2-cfi-asm -fno-dwarf-directory-asm -ferror-limit 19 -fmessage-length 0 -fvisibility hidden -fblocks -fobjc-default-synthesize-properties -fobjc-arc -fobjc-exceptions -fexceptions -fsjlj-exceptions -fpascal-strings -fdiagnostics-show-option -serialize-diagnostic-file /Users/RAGOpoR/Library/Developer/Xcode/DerivedData/iPortals-hfedckfrrkbpaeeekwhpwwkrxkgz/Build/Intermediates/iPortals.build/Debug-iphoneos/iPortals.build/Objects-normal/armv7/iPadNewsbookViewController.dia -o /var/folders/2s/0vbgmlf914d3x7m4xjqwdfh80000gp/T/iPadNewsbookViewController-qXtlG9.s -x objective-c /Users/RAGOpoR/Desktop/trunk/src/Classes/iPadNewsbookViewController.m
1. /Users/RAGOpoR/Desktop/trunk/src/Classes/iPadNewsbookViewController.m:77:60: current parser token ';'
2. /Users/RAGOpoR/Desktop/trunk/src/Classes/iPadNewsbookViewController.m:57:20: in compound statement ('{}')
clang: error: unable to execute command: Segmentation fault: 11
clang: error: clang frontend command failed due to signal 2 (use -v to see invocation)
clang: note: diagnostic msg: Please submit a bug report to http://developer.apple.com/bugreporter/ and include command line arguments and all diagnostic information.
clang: note: diagnostic msg: Preprocessed source(s) and associated run script(s) are located at:
clang: note: diagnostic msg: /var/folders/2s/0vbgmlf914d3x7m4xjqwdfh80000gp/T/iPadNewsbookViewController-Q4pbhm.mi
clang: note: diagnostic msg: /var/folders/2s/0vbgmlf914d3x7m4xjqwdfh80000gp/T/iPadNewsbookViewController-Q4pbhm.sh
Command /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang failed with exit code 254

最佳答案

如果这种情况一直发生在您代码中大致相同的位置,那么您似乎在编译器中发现了一个内部错误,我认为最好的方法是首先将其作为错误报告提交给苹果(该 URL 在您粘贴的输出中列出)。

然后,如果您想继续,请尝试对要编译的代码进行更改,例如注释掉前半部分,然后重试,然后注释掉后半部分,然后重试。这应该指向导致内部编译器错误的代码。

有时重新排序一些代码会为您解决问题。所以至少你可以继续发展。

关于iphone - 如何解决 Apple Mach-O 链接器错误?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9513661/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com