如何在OSX上为iPhone构建openldap库?
|
我正在尝试为iOS3和4构建openldap-2.4.23库,但是当我尝试运行configure时出现错误:
>./configure --disable-slapd --disable-shared --enable-static --host=arm-apple-darwin
configure: WARNING: If you wanted to set the --build type, don\'t use --host.
If a cross compiler is detected then cross compile mode will be used.
Configuring OpenLDAP 2.4.23-Release ...
checking build system type... i686-apple-darwin10.7.0
checking host system type... arm-apple-darwin
checking target system type... arm-apple-darwin
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... no
checking for mawk... no
checking for nawk... no
checking for awk... awk
checking whether make sets $(MAKE)... yes
checking for arm-apple-darwin-strip... no
checking for strip... strip
checking configure arguments... configure: WARNING: slapd disabled, ignoring --enable- bdb argument
configure: WARNING: slapd disabled, ignoring --enable-hdb argument
configure: WARNING: slapd disabled, ignoring --enable-monitor argument
configure: WARNING: slapd disabled, ignoring --enable-relay argument
configure: WARNING: slapd disabled, ignoring --enable-syncprov argument
done
checking for style of include used by make... GNU
checking for arm-apple-darwin-gcc... /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc
checking for C compiler default output file name...
configure: error: C compiler cannot create executables
See `config.log\' for more details.
我的环境设置如下:
export DEVROOT=\"/Developer/Platforms/iPhoneOS.platform/Developer\"
export SDKROOT=\"/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.3.sdk\"
export CC=\"${DEVROOT}/usr/bin/gcc\"
export LD=\"${DEVROOT}/usr/bin/ld\"
export AR=\"${DEVROOT}/usr/bin/ar\"
export AS=\"${DEVROOT}/usr/bin/as\"
export NM=\"${DEVROOT}/usr/bin/nm\"
export CPPFLAGS=\"-I${SDKROOT}/usr/lib/gcc/arm-apple-darwin10/4.2.1/include -I${SDKROOT}/usr/include\"
export CPP=\"${DEVROOT}/usr/bin/cpp ${CPPFLAGS}\"
export CFLAGS=\"${CPPFLAGS} -arch armv6 -pipe -no-cpp-precomp\"
export LDFLAGS=\"-L${SDKROOT}/usr/lib\"
顺便说一句,在修改CFLAGS和LDFALGS之后,我成功进行了配置,如下所示:
export CFLAGS=\"${CPPFLAGS} -pipe -no-cpp-precomp\"
export LDFLAGS=\"\"
但是,make&make install的结果不是armv体系结构:
> lipo -detailed_info libldap.a
input file libldap.a is not a fat file
Non-fat file: libldap.a is architecture: i386
如何建立armv6架构的openldap库?
任何人,请帮助!
谢谢。
没有找到相关结果
已邀请:
2 个回复
疮痪徘弦漏
呕蹿尉
问题是报告了构建错误(执行
时):
如果我正确理解了SASL的文档,则它不适用于iOS。因此,看来我比@alkain靠近了一步,但仍未找到最终解决方案。