2013-05-17 21 views
0

PS:My earlier question是不同的,這可能是固定的,現在我遇到了新的問題爲iOS編譯外籍 - 命令/ bin/sh的失敗,退出代碼2

我想給libkml library導入我的iOS項目。我意識到expat庫不能鏈接(?),所以必須重新構建expat源代碼。

我發現了一個SO鏈接,君子提到,他能成功鏈接外籍人士與他的iOS SDK 5.1:How to compile expat with iOS SDK 5.1?

我使用[在GitHub上可用腳本] [2]在上述嘗試同樣的鏈接。

但是,我在腳本的運行階段出現錯誤。我無法充分利用它,但我需要幫助來解決這個問題。

使用的腳本與github鏈接相同。項目中的C++標準庫設置爲「Compiler default」,我認爲它是LLVM C++。下面是config.log的輸出結果,我無法理解我的理解程度。請幫我解決這個問題,並構建庫,以它跨越與我的項目鏈接:

This file contains any messages produced by compilers while 
running configure, to aid debugging if configure makes a mistake. 

It was created by expat configure 2.0.1, which was 
generated by GNU Autoconf 2.59. Invocation command line was 

    $ ./configure --prefix=/Users/raj/Projects/test/bin/iPhoneSimulator5.0-i386.sdk --host=i386-apple-darwin --enable-static 

## --------- ## 
## Platform. ## 
## --------- ## 

hostname = Rajs-MacBook-Pro.local 
uname -m = x86_64 
uname -r = 12.3.0 
uname -s = Darwin 
uname -v = Darwin Kernel Version 12.3.0: Sun Jan 6 22:37:10 PST 2013; root:xnu-2050.22.13~1/RELEASE_X86_64 

/usr/bin/uname -p = i386 
/bin/uname -X  = unknown 

/bin/arch    = unknown 
/usr/bin/arch -k  = unknown 
/usr/convex/getsysinfo = unknown 
hostinfo    = Mach kernel version: 
    Darwin Kernel Version 12.3.0: Sun Jan 6 22:37:10 PST 2013; root:xnu-2050.22.13~1/RELEASE_X86_64 
Kernel configured for up to 8 processors. 
4 processors are physically available. 
8 processors are logically available. 
Processor type: i486 (Intel 80486) 
Processors active: 0 1 2 3 4 5 6 7 
Primary memory available: 4.00 gigabytes 
Default processor set: 124 tasks, 641 threads, 8 processors 
Load average: 1.70, Mach factor: 6.28 
/bin/machine   = unknown 
/usr/bin/oslevel  = unknown 
/bin/universe   = unknown 

PATH: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin 
PATH: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec 
PATH: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin 
PATH: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/local/bin 
PATH: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/usr/bin 
PATH: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/usr/local/bin 
PATH: /Applications/Xcode.app/Contents/Developer/usr/bin 
PATH: /Applications/Xcode.app/Contents/Developer/usr/local/bin 
PATH: /Applications/Xcode.app/Contents/Developer/Tools 
PATH: /usr/bin 
PATH: /bin 
PATH: /usr/sbin 
PATH: /sbin 


## ----------- ## 
## Core tests. ## 
## ----------- ## 

configure:2092: checking build system type 
configure:2110: result: i386-apple-darwin12.3.0 
configure:2118: checking host system type 
configure:2132: result: i386-apple-darwin 
configure:2148: checking for i386-apple-darwin-gcc 
configure:2174: result: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc 
configure:2456: checking for C compiler version 
configure:2459: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc --version </dev/null >&5 
i686-apple-darwin11-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.11.00) 
Copyright (C) 2007 Free Software Foundation, Inc. 
This is free software; see the source for copying conditions. There is NO 
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 

configure:2462: $? = 0 
configure:2464: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc -v </dev/null >&5 
Using built-in specs. 
Target: i686-apple-darwin11 
Configured with: /private/var/tmp/llvmgcc42/llvmgcc42-2336.11~182/src/configure --disable-checking --enable-werror --prefix=/Applications/Xcode.app/Contents/Developer/usr/llvm-gcc-4.2 --mandir=/share/man --enable-languages=c,objc,c++,obj-c++ --program-prefix=llvm- --program-transform-name=/^[cg][^.-]*$/s/$/-4.2/ --with-slibdir=/usr/lib --build=i686-apple-darwin11 --enable-llvm=/private/var/tmp/llvmgcc42/llvmgcc42-2336.11~182/dst-llvmCore/Developer/usr/local --program-prefix=i686-apple-darwin11- --host=x86_64-apple-darwin11 --target=i686-apple-darwin11 --with-gxx-include-dir=/usr/include/c++/4.2.1 
Thread model: posix 
gcc version 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.11.00) 
configure:2467: $? = 0 
configure:2469: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc -V </dev/null >&5 
llvm-gcc-4.2: argument to `-V' is missing 
configure:2472: $? = 1 
configure:2495: checking for C compiler default output file name 
configure:2498: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc -arch i386 -pipe -no-cpp-precomp -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk -I/Users/raj/Projects/test/include -arch i386 -pipe -no-cpp-precomp -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk -L/Users/raj/Projects/test/lib conftest.c >&5 
configure:2501: $? = 0 
configure:2547: result: a.out 
configure:2552: checking whether the C compiler works 
configure:2558: ./a.out 
configure:2561: $? = 0 
configure:2578: result: yes 
configure:2585: checking whether we are cross compiling 
configure:2587: result: no 
configure:2590: checking for suffix of executables 
configure:2592: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc -o conftest -arch i386 -pipe -no-cpp-precomp -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk -I/Users/raj/Projects/test/include -arch i386 -pipe -no-cpp-precomp -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk -L/Users/raj/Projects/test/lib conftest.c >&5 
configure:2595: $? = 0 
configure:2620: result: 
configure:2626: checking for suffix of object files 
configure:2647: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc -c -arch i386 -pipe -no-cpp-precomp -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk -I/Users/raj/Projects/test/include conftest.c >&5 
configure:2650: $? = 0 
configure:2672: result: o 
configure:2676: checking whether we are using the GNU C compiler 
configure:2700: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc -c -arch i386 -pipe -no-cpp-precomp -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk -I/Users/raj/Projects/test/include conftest.c >&5 
configure:2706: $? = 0 
configure:2710: test -z 
      || test ! -s conftest.err 
configure:2713: $? = 0 
configure:2716: test -s conftest.o 
configure:2719: $? = 0 
configure:2732: result: yes 
configure:2738: checking whether /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc accepts -g 
configure:2759: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc -c -g conftest.c >&5 
configure:2765: $? = 0 
configure:2769: test -z 
      || test ! -s conftest.err 
configure:2772: $? = 0 
configure:2775: test -s conftest.o 
configure:2778: $? = 0 
configure:2789: result: yes 
configure:2806: checking for /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc option to accept ANSI C 
configure:2876: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc -c -arch i386 -pipe -no-cpp-precomp -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk -I/Users/raj/Projects/test/include conftest.c >&5 
conftest.c:10:19: error: stdio.h: No such file or directory 
conftest.c:11:23: error: sys/types.h: No such file or directory 
conftest.c:12:22: error: sys/stat.h: No such file or directory 
conftest.c:15: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token 
conftest.c:44: error: expected declaration specifiers or '...' before 'FILE' 
configure:2882: $? = 1 
configure: failed program was: 
| /* confdefs.h. */ 
| 
| #define PACKAGE_NAME "expat" 
| #define PACKAGE_TARNAME "expat" 
| #define PACKAGE_VERSION "2.0.1" 
| #define PACKAGE_STRING "expat 2.0.1" 
| #define PACKAGE_BUGREPORT "[email protected]" 
| /* end confdefs.h. */ 
| #include <stdarg.h> 
| #include <stdio.h> 
| #include <sys/types.h> 
| #include <sys/stat.h> 
| /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ 
| struct buf { int x; }; 
| FILE * (*rcsopen) (struct buf *, struct stat *, int); 
| static char *e (p, i) 
|  char **p; 
|  int i; 
| { 
| return p[i]; 
| } 
| static char *f (char * (*g) (char **, int), char **p, ...) 
| { 
| char *s; 
| va_list v; 
| va_start (v,p); 
| s = g (p, va_arg (v,int)); 
| va_end (v); 
| return s; 
| } 

. 
. 
. 
. 
. 


configure: exit 0 

除了上述的config.log文件,我能找到一個構建日誌了。集結外籍-2.0.1.log文件的

詳情:

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. 
checking build system type... i386-apple-darwin12.3.0 
checking host system type... i386-apple-darwin 
checking for i386-apple-darwin-gcc... /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc 
checking for C compiler default output file name... a.out 
checking whether the C compiler works... yes 
checking whether we are cross compiling... no 
checking for suffix of executables... 
checking for suffix of object files... o 
checking whether we are using the GNU C compiler... yes 
checking whether /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc accepts -g... yes 
checking for /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc option to accept ANSI C... none needed 
checking for a sed that does not truncate output... /usr/bin/sed 
checking for egrep... grep -E 
checking for ld used by /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc... /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ld 
checking if the linker (/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ld) is GNU ld... no 
checking for /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ld option to reload object files... -r 
checking for BSD-compatible nm... /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/nm 
checking whether ln -s works... yes 
checking how to recognise dependent libraries... pass_all 
checking how to run the C preprocessor... /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc -E 
checking for ANSI C header files... no 
checking for sys/types.h... no 
checking for sys/stat.h... no 
checking for stdlib.h... no 
checking for string.h... no 
checking for memory.h... no 
checking for strings.h... no 
checking for inttypes.h... no 
checking for stdint.h... no 
checking for unistd.h... no 
checking dlfcn.h usability... no 
checking dlfcn.h presence... yes 
configure: WARNING: dlfcn.h: present but cannot be compiled 
configure: WARNING: dlfcn.h:  check for missing prerequisite headers? 
configure: WARNING: dlfcn.h: see the Autoconf documentation 
configure: WARNING: dlfcn.h:  section "Present But Cannot Be Compiled" 
configure: WARNING: dlfcn.h: proceeding with the preprocessor's result 
configure: WARNING: dlfcn.h: in the future, the compiler will take precedence 
configure: WARNING:  ## -------------------------------------- ## 
configure: WARNING:  ## Report this to [email protected] ## 
configure: WARNING:  ## -------------------------------------- ## 
checking for dlfcn.h... yes 
checking for i386-apple-darwin-g++... /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/g++ 
checking whether we are using the GNU C++ compiler... yes 
checking whether /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/g++ accepts -g... yes 
checking how to run the C++ preprocessor... /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-cpp-4.2 
checking for i386-apple-darwin-g77... no 
checking for i386-apple-darwin-f77... no 
checking for i386-apple-darwin-xlf... no 
checking for i386-apple-darwin-frt... no 
checking for i386-apple-darwin-pgf77... no 
checking for i386-apple-darwin-fort77... no 
checking for i386-apple-darwin-fl32... no 
checking for i386-apple-darwin-af77... no 
checking for i386-apple-darwin-f90... no 
checking for i386-apple-darwin-xlf90... no 
checking for i386-apple-darwin-pgf90... no 
checking for i386-apple-darwin-epcf90... no 
checking for i386-apple-darwin-f95... no 
checking for i386-apple-darwin-fort... no 
checking for i386-apple-darwin-xlf95... no 
checking for i386-apple-darwin-ifc... no 
checking for i386-apple-darwin-efc... no 
checking for i386-apple-darwin-pgf95... no 
checking for i386-apple-darwin-lf95... no 
checking for i386-apple-darwin-gfortran... no 
checking for g77... no 
checking for f77... no 
checking for xlf... no 
checking for frt... no 
checking for pgf77... no 
checking for fort77... no 
checking for fl32... no 
checking for af77... no 
checking for f90... no 
checking for xlf90... no 
checking for pgf90... no 
checking for epcf90... no 
checking for f95... no 
checking for fort... no 
checking for xlf95... no 
checking for ifc... no 
checking for efc... no 
checking for pgf95... no 
checking for lf95... no 
checking for gfortran... no 
checking whether we are using the GNU Fortran 77 compiler... no 
checking whether accepts -g... no 
checking the maximum length of command line arguments... 196608 
checking command to parse /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/nm output from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc object... ok 
checking for objdir... .libs 
checking for i386-apple-darwin-ar... no 
checking for ar... ar 
checking for i386-apple-darwin-ranlib... /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ranlib 
checking for i386-apple-darwin-strip... no 
checking for strip... strip 
checking if /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc supports -fno-rtti -fno-exceptions... no 
checking for /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc option to produce PIC... -fno-common 
checking if /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc PIC flag -fno-common works... yes 
checking if /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc static flag -static works... no 
checking if /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc supports -c -o file.o... yes 
checking whether the /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc linker (/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ld) supports shared libraries... yes 
checking dynamic linker characteristics... darwin dyld 
checking how to hardcode library paths into programs... immediate 
checking whether stripping libraries is possible... yes 
checking if libtool supports shared libraries... yes 
checking whether to build shared libraries... yes 
checking whether to build static libraries... yes 
configure: creating libtool 
appending configuration tag "CXX" to libtool 
checking for ld used by /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/g++... /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ld 
checking if the linker (/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ld) is GNU ld... no 
checking whether the /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/g++ linker (/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ld) supports shared libraries... yes 
checking for /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/g++ option to produce PIC... -fno-common 
checking if /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/g++ PIC flag -fno-common works... yes 
checking if /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/g++ static flag -static works... no 
checking if /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/g++ supports -c -o file.o... yes 
checking whether the /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/g++ linker (/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ld) supports shared libraries... yes 
checking dynamic linker characteristics... darwin dyld 
checking how to hardcode library paths into programs... immediate 
appending configuration tag "F77" to libtool 
checking for i386-apple-darwin-gcc... (cached) /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc 
checking whether we are using the GNU C compiler... (cached) yes 
checking whether /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc accepts -g... (cached) yes 
checking for /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc option to accept ANSI C... (cached) none needed 
checking for a BSD-compatible install... /usr/bin/install -c 
checking whether /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc accepts -fexceptions... yes 
checking for ANSI C header files... (cached) no 
checking whether byte ordering is bigendian... no 
checking for an ANSI C-conforming const... yes 
checking for size_t... no 
checking for memmove... no 
checking for bcopy... no 
checking fcntl.h usability... no 
checking fcntl.h presence... yes 
configure: WARNING: fcntl.h: present but cannot be compiled 
configure: WARNING: fcntl.h:  check for missing prerequisite headers? 
configure: WARNING: fcntl.h: see the Autoconf documentation 
configure: WARNING: fcntl.h:  section "Present But Cannot Be Compiled" 
configure: WARNING: fcntl.h: proceeding with the preprocessor's result 
configure: WARNING: fcntl.h: in the future, the compiler will take precedence 
configure: WARNING:  ## -------------------------------------- ## 
configure: WARNING:  ## Report this to [email protected] ## 
configure: WARNING:  ## -------------------------------------- ## 
checking for fcntl.h... yes 
checking for unistd.h... (cached) no 
checking for off_t... no 
checking for stdlib.h... (cached) no 
checking for unistd.h... (cached) no 
checking for getpagesize... no 
checking for working mmap... no 
checking for an ANSI C99-conforming __func__... yes 
configure: creating ./config.status 
config.status: creating Makefile 
config.status: creating expat_config.h 
config.status: expat_config.h is unchanged 
/bin/sh ./libtool --silent --mode=compile /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc -I./lib -I. -arch i386 -pipe -no-cpp-precomp -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk -I/Users/raj/Projects/test/include -Wall -Wmissing-prototypes -Wstrict-prototypes -fexceptions -DHAVE_EXPAT_CONFIG_H -o lib/xmlparse.lo -c lib/xmlparse.c 
lib/xmlparse.c:6:65: error: string.h: No such file or directory 
lib/xmlparse.c:7:20: error: assert.h: No such file or directory 
In file included from lib/xmlparse.c:24: 
lib/expat.h:17:20: error: stdlib.h: No such file or directory 
lib/xmlparse.c:81:2: error: #error memmove does not exist on this platform, nor is a substitute available 
lib/xmlparse.c: In function 'parserCreate': 
lib/xmlparse.c:719: warning: implicit declaration of function 'malloc' 
lib/xmlparse.c:719: warning: incompatible implicit declaration of built-in function 'malloc' 
lib/xmlparse.c:722: warning: assignment from incompatible pointer type 
lib/xmlparse.c:723: error: 'realloc' undeclared (first use in this function) 
lib/xmlparse.c:723: error: (Each undeclared identifier is reported only once 
lib/xmlparse.c:723: error: for each function it appears in.) 
lib/xmlparse.c:724: error: 'free' undeclared (first use in this function) 
lib/xmlparse.c: In function 'parserInit': 
lib/xmlparse.c:848: warning: implicit declaration of function 'memset' 
lib/xmlparse.c:848: warning: incompatible implicit declaration of built-in function 'memset' 
lib/xmlparse.c: In function 'XML_Parse': 
lib/xmlparse.c:1543: warning: implicit declaration of function 'memcpy' 
lib/xmlparse.c:1543: warning: incompatible implicit declaration of built-in function 'memcpy' 
lib/xmlparse.c: In function 'XML_GetBuffer': 
lib/xmlparse.c:1627: warning: implicit declaration of function 'memmove' 
lib/xmlparse.c:1627: warning: incompatible implicit declaration of built-in function 'memmove' 
lib/xmlparse.c:1656: warning: incompatible implicit declaration of built-in function 'memcpy' 
lib/xmlparse.c: In function 'XML_GetParsingStatus': 
lib/xmlparse.c:1750: warning: implicit declaration of function 'assert' 
lib/xmlparse.c: In function 'storeRawNames': 
lib/xmlparse.c:2009: warning: incompatible implicit declaration of built-in function 'memcpy' 
lib/xmlparse.c: In function 'doContent': 
lib/xmlparse.c:2424: warning: implicit declaration of function 'memcmp' 
lib/xmlparse.c: In function 'storeAtts': 
lib/xmlparse.c:2922: warning: incompatible implicit declaration of built-in function 'memcpy' 
lib/xmlparse.c:2931: warning: incompatible implicit declaration of built-in function 'memcpy' 
lib/xmlparse.c: In function 'addBinding': 
lib/xmlparse.c:3039: warning: incompatible implicit declaration of built-in function 'memcpy' 
lib/xmlparse.c: In function 'lookup': 
lib/xmlparse.c:5871: warning: incompatible implicit declaration of built-in function 'memset' 
lib/xmlparse.c:5898: warning: incompatible implicit declaration of built-in function 'memset' 
lib/xmlparse.c:5927: warning: incompatible implicit declaration of built-in function 'memset' 
lib/xmlparse.c: In function 'poolGrow': 
lib/xmlparse.c:6112: warning: incompatible implicit declaration of built-in function 'memcpy' 
lib/xmlparse.c:6148: warning: incompatible implicit declaration of built-in function 'memcpy' 
make: *** [lib/xmlparse.lo] Error 1 
+0

這個錯誤發生在我身上的原因之一: http://stackoverflow.com/a/8273239/260665 –

回答

1

兩個建議:

1)建立OSX庫,即運行./configure和make。如果可行,構建一個Xcode庫項目,添加所有的庫源文件,以及創建的congig.h等,讓這個項目編譯,然後將該項目添加到您的應用程序。我已經做到了這一點,而且它通常是最簡單的(最終)解決方案。 2)如果你不能得到這個工作提供一個100到250的賞金,而其他人會這樣做。這是在這裏積累分數的明顯優勢 - 當您真正需要時,您可以將它們用於某些事情!

+0

感謝您的寶貴建議,但我試圖用iOS來源鏈接它,這意味着應該在ARM中構建expat源代碼。如果我在Mac中編譯它,我能否將它與我的iOS項目鏈接起來? –

+1

我明白了。當你爲Mac配置時,你會得到或多或少相同的config.h文件。你可以手動調整,如果有什麼奇怪的。我已經完成了兩個我支持的開源項目,xlslib和libxls。它真的很難強制汽車...得到你想要的東西 - 它看起來每個項目都是不同的,你可以在它上面燒幾個小時。如果您可以爲Mac構建這個版本,我敢打賭,您可以在30分鐘內完成Xcode項目的編譯,然後構建現在或未來的任何架構。 –

相關問題