为ios创建静态c库

为ios创建静态c库,ios,static,Ios,Static,我想为iphone编译一个c库。我完全没有这方面的经验,在谷歌上搜索了一下,发现了她: 我想要构建的项目的原始源代码在我的mac上编译得很好,结果包含以下目录结构 bin include lib share 所以在那之后,我现在想要构建这个东西,这样我就可以在我的iphone上使用它了。对于第一步,我只是从上面的链接复制并粘贴configure命令,然后点击enter。结果是: ./configure --build=arm-apple-darwin --enable-stat

我想为iphone编译一个c库。我完全没有这方面的经验,在谷歌上搜索了一下,发现了她:

我想要构建的项目的原始源代码在我的mac上编译得很好,结果包含以下目录结构

bin     include lib     share
所以在那之后,我现在想要构建这个东西,这样我就可以在我的iphone上使用它了。对于第一步,我只是从上面的链接复制并粘贴configure命令,然后点击enter。结果是:

./configure --build=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
checking build system type... arm-apple-darwin
checking host system type... arm-apple-darwin
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... no
checking for awk... awk
checking whether make sets $(MAKE)... yes
checking host system type... posix
checking for gcc... /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-gcc-4.2.1
checking whether the C compiler works... no
configure: error: in `/path/to/gwenhywfar-4.3.0-src':
configure: error: C compiler cannot create executables

但这有什么问题?这个怎么修理?如果我假设阻止创建二进制可执行文件是解决方案,那么我说的对吗?

您找到解决方案了吗?您找到解决方案了吗?