php+php 所需扩展库 交叉编译
安装依赖:
libxml2:
1.wget ftp://xmlsoft.org/libxml2/libxml2-2.7.2.tar.gz
2. tar xvf libxml2-2.7.2.tar.gz
3. cd libxml2-2.7.2
4. ./configure CC=aarch64-linux-gnu-gcc –host=aarch64-linux-gnu –prefix=/usr/local/libxml2 -without-python
5. make && make install
报错如下:
1、configure: error: /bin/sh ./config.sub x86_64-unknown-linux-gnu failed
/usr/share/libtool/config/config.sub 与 /usr/share/libtool/config/config.guss 复制到要进行编译的目录
2、/usr/include/python2.7/pyconfig.h:45:35: fatal error: python2.7/pyconfig-64.h: No such file or directory 增加 -without-python 选项
zlib
1.wget http://www.zlib.net/fossils/zlib-1.2.9.tar.gz
2.tar -zxvf zlib-1.2.9.tar.gz
3.export CC=aarch64-linux-gnu-gcc
4./configure –prefix=install-dir
5.make && make install