致命错误:ext/standard/php_smart_str.h:没有那个文件或目录
致命错误:ext/standard/php_smart_str.h:没有那个文件或目录
参考文章:https://blog.csdn.net/jartins/article/details/80371257。
一、发生背景:
安装php-redis扩展时,打开php官网下载扩展,选择了版本redis-2.2.5.tgz。
下载路径是:https://pecl.php.net/get/redis-2.2.5.tgz。
然后使用make编译时,报错:
...
...,致命错误:ext/standard/php_smart_str.h:没有那个文件或目录
...
编译中断。
make: *** [redis.lo] 错误
二、原因:
在网上搜索后,得到的说法是:
因为最新的 phpredis 分了几大分支,针对最新的PHP稳定发行版 php7 有专门为php7的分支,
所以我们从github拉下phpredis 源码。
三、解决:
(1)然后打开github,搜索phpredis。
点击搜索结果的第一个:phpredis/phpredis(https://github.com/phpredis/phpredis)
点击页面中的releases(https://github.com/phpredis/phpredis/releases)
选择最新版本4.3.0(https://github.com/phpredis/phpredis/archive/4.3.0.tar.gz)
(2)下载:
wget https://github.com/phpredis/phpredis/archive/4.3.0.tar.gz
(3)重命名
(个人习惯:下载后文件叫4.3.0.tar.gz,只有版本没有名字,重命名一下,phpredis-4.3.0.tar.gz)
mv 4.3.0.tar.gz phpredis-4.3.0.tar.gz
(4)解压
tar -zxvf phpredis-4.3.0.tar.gz
(5)进入目录
cd phpredis-4.3.0
(6)使用phpize解压
phpize
(7)配置
./configure --with-php-config=/usr/local/php7/bin/php-config
(8)编译
make
(9)安装
make install
安装结果:
Installing shared extensions: /usr/local/php7/lib/php/extensions/no-debug-non-zts-20180731/
表示安装成功!
致命错误:ext/standard/php_smart_str.h:没有那个文件或目录的更多相关文章
- mac centos linux 安装PHP扩展 INTL(国际化) ———— error: 'ext/standard/php_smart_str.h'
PHP简单源码安装扩展 五个步骤: 详细说明下: cd /fujieace/php7.0/ext/intl:#进入INTL扩展目录? 在编译扩展时候需要phpize准备环境,准备程序需要获取这个目录的 ...
- linux使用php动态安装模块mysqli.so(ext/mysqlnd/mysqlnd.h: 没有那个文件或目录)
由于我先安装的php,再安装的mysql! 正常过程: 1.安装mysql 2.安装php configure时带–with-mysql参数 现在我不想重装,因此使用phpize动态安装mysqli, ...
- error: stdio.h: 没有那个文件或目录
在64位系统中,编写一个C语言程序后,使用gcc进行编译时,出现了如下的错误: test.c:1:19: fatal error: stdio.h: 没有那个文件或目录 #include <s ...
- fatal error: openssl/evp.h: 没有那个文件或目录
在陆佳华<嵌入式系统软硬件协同设计实战指南 第2版>一书的第13章节 编译U-boot时会遇到2个错误.原因很简单,就从一开始的错误提示着手: fatal error: openssl/e ...
- busybox编译 fatal error: curses.h: 没有那个文件或目录解决办法
执行make menuconfig时出现如下错误@ubuntu:/home/dev/busybox-1.19.3# make menuconfig HOSTCC scripts/kconfig/lxd ...
- 【caffe编译】 fatal error: hdf5.h: 没有那个文件或目录
src/caffe/layers/hdf5_output_layer.cpp:3:18: fatal error: hdf5.h: 没有那个文件或目录 查找文件 locate hdf5.h 修改Mak ...
- “fatal error: hdf5.h: 没有那个文件或目录”解决方法
問題一: Installing Caffe without CUDA: fatal error: cublas_v2.h No such file: 在Makefile.config中修改,將CPU_ ...
- fastdfs+nginx make时报错fatal error:fdfs_define.h: 没有那个文件或目录
环境: ubuntu 18.04.1 fastdfs-nginx-module_v1.16 root@wang-machine:~/桌面/FastDFS# cd nginx-1.8.1/root@wa ...
- 如何解决编译linux内核(解决声卡问题),遭遇fatal error: linux/limits.h: 没有那个文件或目录
最近帮一位上海的朋友搞一块小板,在ubuntu15.04 vivid上已经加载了对应了.ko驱动包 但关键是系统根本就枚举不到该声卡ALC5640,试了OpenSUSE也是一样的结果,看来是内核漏加载 ...
随机推荐
- 【思维题 欧拉图】loj#10106. 单词游戏
巧妙的模型转化 题目描述 来自 ICPC CERC 1999/2000,有改动. 有 NNN 个盘子,每个盘子上写着一个仅由小写字母组成的英文单词.你需要给这些盘子安排一个合适的顺序,使得相邻两个盘子 ...
- matplotlib绘图(一)
绘制这折现图 导入响应的包 import numpy as npimport pandas as pdfrom pandas import Series,DataFrame%matplotlib in ...
- Python自学笔记_
1. if语句 判断语句. 1 a=2 2 b=3 3 if a>b: 4 print("a>b") 5 else: 6 print("a<b" ...
- Node项目实战-静态资源服务器
打开github,在github上创建新项目: Repository name: anydoor Descripotion: Tiny NodeJS Static Web server 选择:publ ...
- 20.Yii2.0框架多表关联一对多查询之hasMany
目录 新手模式 hasMany关联模式查询 新建mode层Article.php 新建mode层Category.php 新建控制器HomeController.php 新手模式 用上次的查询结果,作 ...
- JAVA基础篇—继承
父类Vehicle package com.car; public class Vehicle { final String brand;// String color;// double speed ...
- Post页面爬取失败__编码问题
python3爬取Post页面时, 报以下错误 "POST data should be bytes or an iterable of bytes. It cannot be of typ ...
- Nginx配置语法和日志
nginx配置 配置文件 重启服务 http请求 nginx日志 一共有两个日志文件 在配置文件中添加这个,就可以在日志文件中看到请求的userAgent 配置语法的检查 nginx重新加载配置 发送 ...
- c#利用反射实现对类中的常量进行取值和对应常量的注释
C#利用反射实现对类中的常量进行取值和对应常量的注释 项目示例:https://gitee.com/dhclly/IceDog.GenerateErrorCode 因为业务需要,项目中有大量的错误码, ...
- DataContext.ExecuteQuery的两种方法调用
ExecuteQuery主要用于DataContext类直接执行SQL语句的查询,在MSDN上有两种执行方法,下面为两种方法的不同调用: 1.ExecuteQuery<TResult>(S ...