arm php 交叉编译_ARM交叉编译PHP

  • Post author:
  • Post category:php


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



版权声明:本文为weixin_34751996原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。