Error 1 ERROR: `make#39; failed when installing sqlsrv(错误 1 错误:安装 sqlsrv 时“make失败)
问题描述
我正在尝试使用 this 页面中的命令安装 sqlsrv.但是,运行时
I'm trying to install sqlsrv by using the commands from this page. However, when running
pecl install sqlsrv-4.2.0preview
我收到错误:Error 1 ERROR: 'make' failed
.
我试过了:
apt-get update
apt-get install build-essential
apt-get install libpcre3-dev
apt-get install make
所有这些都安装在最新版本上.
All of these are installed on the latest version.
我正在使用 php:7.0-apache 映像运行一个容器.运行 apachectl -V
会返回 Apache/2.4.10 (Debian)
.
I'm running a container using the php:7.0-apache image. Running apachectl -V
returns Apache/2.4.10 (Debian)
.
这是我运行的命令的完整日志输出:https://pastebin.com/MYDY3xwU
Here is the full log output from the command I ran: https://pastebin.com/MYDY3xwU
推荐答案
我遇到了这个确切的错误.
I had this exact error.
/tmp/pear/temp/sqlsrv/shared/xplat.h:30:17: fatal error: sql.h: No such file or directory
#include <sql.h>
显然它要查找的头文件仅在包 unixODBC-devel 中.
Apparently the header file its looking for is only in the package unixODBC-devel.
我安装了该软件包并能够成功完成构建.yum install unixODBC-devel
.
I installed that package and was able to successfully complete the build. yum install unixODBC-devel
.
也许,这里有更好的解释.stackoverflow 问题 #15447386
Possibly, a better explanation is here. stackoverflow Question # 15447386
这篇关于错误 1 错误:安装 sqlsrv 时“make"失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:错误 1 错误:安装 sqlsrv 时“make"失败


- Mod使用GET变量将子域重写为PHP 2021-01-01
- Oracle 即时客户端 DYLD_LIBRARY_PATH 错误 2022-01-01
- SoapClient 设置自定义 HTTP Header 2021-01-01
- 正确分离 PHP 中的逻辑/样式 2021-01-01
- 没有作曲家的 PSR4 自动加载 2022-01-01
- PHP Count 布尔数组中真值的数量 2021-01-01
- Laravel 仓库 2022-01-01
- 如何定位 php.ini 文件 (xampp) 2022-01-01
- 从 PHP 中的输入表单获取日期 2022-01-01
- 带有通配符的 Laravel 验证器 2021-01-01