私はこの非常に簡単なコードを持っていますが、どういうわけかこれで Apple Mach-O エラーが発生します。誰が何が悪いのか手がかりを教えてもらえますか?
AvhorViewController.h:
#import <UIKit/UIKit.h>
@interface AvhorViewController : UIViewController
@property (strong, nonatomic) IBOutlet UIWebView *WebViewAvhor;
@end
AvhorViewController.m
#import "AvhorViewController.h"
@interface AvhorViewController ()
@end
@implementation AvhorViewController
- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
if (self) {
}
return self;
}
- (void)viewDidLoad
{
[super viewDidLoad];
NSString *path = [[NSBundle mainBundle] pathForResource:@"one" ofType:@"htm" inDirectory:@"Avhor"];
NSURL *url = [NSURL fileURLWithPath:path];
NSURLRequest *requestObj = [NSURLRequest requestWithURL:url];
[_WebViewAvhor loadRequest:requestObj];
}
- (void)didReceiveMemoryWarning
{
[super didReceiveMemoryWarning];
}
@end
以下のフレームワークを追加しました。
AddressBookUI.framework
MapKit.framework
CoreLocation.framework
UIKit.framework
Foundation.framework
CoreGraphics.framework
エラーの内容:
Ld /Users/Centurion/Library/Developer/Xcode/DerivedData/Avhor-clfeavlkecrxomdmbtwixetebjsa/Build/Products/Debug-iphonesimulator/Avhor.app/Avhor 通常の i386 cd /Users/Centurion/Documents/Xcode/Avhor setenv IPHONEOS_DEPLOYMENT_TARGET 6.1 setenv PATH " /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.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 -arch i386 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/ SDK/iPhoneSimulator6.1.sdk -L/Users/Centurion/Library/Developer/Xcode/DerivedData/Avhor-clfeavlkecrxomdmbtwixetebjsa/Build/Products/Debug-iphonesimulator -F/Users/Centurion/Library/Developer/Xcode/DerivedData/Avhor-clfeavlkecrxomdmbtwixetebjsa/Build/Products/ Debug-iphonesimulator -filelist /Users/Centurion/Library/Developer/Xcode/DerivedData/Avhor-clfeavlkecrxomdmbtwixetebjsa/Build/Intermediates/Avhor.build/Debug-iphonesimulator/Avhor.build/Objects-normal/i386/Avhor.LinkFileList -Xlinker - objc_abi_version -Xlinker 2 -fobjc-arc -fobjc-link-runtime -Xlinker -no_implicit_dylibs -mios-simulator-version-min=6.1 -framework AddressBookUI -framework MapKit -framework CoreLocation -framework UIKit -framework Foundation -framework CoreGraphics -o /Users/Centurion/Library/Developer/Xcode/DerivedData/Avhor-clfeavlkecrxomdmbtwixetebjsa/Build/Products/Debug-iphonesimulator/Avhor.app/アフォー
ld: 出力ファイルを書き込み用に開くことができません: /Users/Centurion/Library/Developer/Xcode/DerivedData/Avhor-clfeavlkecrxomdmbtwixetebjsa/Build/Products/Debug-iphonesimulator/Avhor.app/Avhor、アーキテクチャ i386 クランの errno=21:エラー: リンカー コマンドが終了コード 1 で失敗しました (呼び出しを確認するには -v を使用してください)