TCMPortMapperを追加しようとしています(http://code.google.com/p/tcmportmapper/)
ビルドフェーズでフレームワークをリンクし、サンプルコードを実行しようとしました。
#import <Foundation/Foundation.h>
#import <TCMPortMapper/TCMPortMapper.h>
int main (int argc, const char * argv[])
{
NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
TCMPortMapper *pm = [TCMPortMapper sharedInstance];
[pm addPortMapping:
[TCMPortMapping portMappingWithLocalPort:13478
desiredExternalPort:4321
transportProtocol:TCMPortMappingTransportProtocolTCP
userInfo:nil]];
[pm start];
[pool drain];
return 0;
}
しかし、私はエラーを受け取ります:
ld: warning: ignoring file /Applications/TCMPortMapper.framework/TCMPortMapper, missing required
architecture x86_64 in file
Undefined symbols for architecture x86_64:
"_OBJC_CLASS_$_TCMPortMapper", referenced from:
objc-class-ref in main.o
"_OBJC_CLASS_$_TCMPortMapping", referenced from:
objc-class-ref in main.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
私ではなく、フレームワークと関係があると思います。しかし、私はグーグルに多くの時間を費やし、32ビットモードと64ビットモードのものである可能性があることを除いて、あまり現れませんでした。
私はこれに3日間立ち往生しているので、どんな助けでも大歓迎です。
ありがとう、ウィル