小编Dan*_*Dan的帖子

为iPhone编译C lib

我正在尝试编译ZeroMQ C绑定以便能够在iPhone上使用它,这是我的配置选项:

./configure --host=arm-apple-darwin --enable-static=yes --enable-shared=no CC=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-gcc-4.2.1 CFLAGS="-pipe -std=c99 -Wno-trigraphs -fpascal-strings -O0 -Wreturn-type -Wunused-variable -fmessage-length=0 -fvisibility=hidden -miphoneos-version-min=3.1.2 -gdwarf-2 -mthumb -I/Library/iPhone/include -isysroot /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.0.sdk -mdynamic-no-pic" CPP=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/cpp AR=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ar AS=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/as LIBTOOL=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/libtool STRIP=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/strip RANLIB=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ranlib

它实际上配置和编译很好,但是当我将它添加到Xcode Frameworks部分时,我收到警告:ld: warning: in /path/to/app/libzmq.a, file was built for unsupported file format which is not the architecture being linked (armv7)并且发现很多符号错误.

如果我将当前活动架构从armv6更改为armv7,警告消息会将其更改为armv6.我究竟做错了什么 ?

谢谢,丹

iphone xcode compilation configure zeromq

4
推荐指数
1
解决办法
7165
查看次数

标签 统计

compilation ×1

configure ×1

iphone ×1

xcode ×1

zeromq ×1