源码安装PHP的坑
来源:互联网 发布:安吉汽车物流知乎 编辑:程序博客网 时间:2024/06/02 03:35
昨天想尝试为PHP写一点小扩展,结果硬是写不上去。就自己从官网下了一个版本进行源码编译安装,中间遇见好多坑,总结记录下来。
1.error: xml2-config not found. Please check your libxml2 installation
sudo apt-get install libxml2-dev
2.configure: error: Cannot find OpenSSL’s evp.h or hmac.h
sudo apt-get install libssl-dev
3.configure: error: Please reinstall the BZip2 distribution
sudo apt-get install libbz2-dev
4.configure: error: mcrypt.h not found. Please reinstall libmcrypt.
sudo apt-get install libmcrypt-dev
5.configure: error: Please reinstall readline - I cannot find readline.
sudo apt-get install libreadline6-dev
6.Sorry, I cannot run apxs
安装apache服务后,是不会带Apxs,需要安装 apache2-dev。其命令是: sudo apt-get install apache2-dev
安装完后查看安装的路径: whereis apxs2
如果在安装Mod_pythond的make过程出现这样到错误:fatal error: Python.h: No such file or directory,可以安装python2.7-dev(装的是V2.7)解决,命令为:
sudo apt-get install python2.7-dev
Apxs的默认位置:usr/bin/apxs,但在ubuntu11版本中已经是usr/bin/apxs2。
但是,由于路径不一样,还需要加一个软链接: ln -s /usr/bin/apxs /usr/local/bin/apxs
以上就是我昨天安装PHP遇见的坑,然后PHP安装扩展可以参考Rango的博客:
- PHP安装C函数扩展
- PHP实现类扩展
- 用C/C++扩展你的PHP
0 0
- 源码安装PHP的坑
- php+gd库的源码安装
- PHP源码编译安装的简单整理
- linux php+gd库的源码安装
- apache+php的安装配置(源码)
- PHP的ZMQ扩展zeromq源码安装
- mysql和php的源码编译安装
- PHP的源码安装与配置
- apache php源码安装
- CentOS源码安装PHP
- CentOS 源码安装PHP
- PHP源码安装
- PHP源码安装
- centos源码安装PHP
- php源码编译安装
- php源码安装
- PHP源码安装
- linux 源码安装php
- 欢迎使用CSDN-markdown编辑器
- ofbiz 商业级别界面
- 总结,回顾,展望
- UVA
- myeclipse性能调优技巧
- 源码安装PHP的坑
- Shell传入参数的处理
- ofbiz 高性能最佳实践
- 树莓派Python直接操控摄像头
- CLR via C#笔记
- C++中类的组合和继承关系
- 修改spark源码并编译部署
- SpringMVC之文件上传/下载
- Android问题—读取其他应用的SharedPreferences