PHP oci8无法通过pecl安装:“严重错误:oci8_dtrace_gen.h"; [英] PHP oci8 won't install through pecl: "fatal error: oci8_dtrace_gen.h"

查看:713
本文介绍了PHP oci8无法通过pecl安装:“严重错误:oci8_dtrace_gen.h";的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试将fedora 25 Web服务器-php连接到Oracle数据库.

I am trying to connect my fedora 25 webserver - php to Oracle db.

为此,我需要pecl安装oci8.

To do this I need to pecl install oci8.

但是我收到此错误:

/bin/sh /var/tmp/pear-build-roottqYEC6/oci8-2.1.4/libtool --mode=compile cc  -I. -I/var/tmp/oci8 -DPHP_ATOM_INC -I/var/tmp/pear-build-roottqYEC6/oci8-2.1.4/include -I/var/tmp/pear-build-roottqYEC6/oci8-2.1.4/main -I/var/tmp/oci8 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/include/oracle/12.1/client64  -DHAVE_CONFIG_H  -g -O2   -c /var/tmp/oci8/oci8.c -o oci8.lo
libtool: compile:  cc -I. -I/var/tmp/oci8 -DPHP_ATOM_INC -I/var/tmp/pear-build-roottqYEC6/oci8-2.1.4/include -I/var/tmp/pear-build-roottqYEC6/oci8-2.1.4/main -I/var/tmp/oci8 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/include/oracle/12.1/client64 -DHAVE_CONFIG_H -g -O2 -c /var/tmp/oci8/oci8.c  -fPIC -DPIC -o .libs/oci8.o
In file included from /var/tmp/oci8/oci8.c:49:0:
/var/tmp/oci8/php_oci8_int.h:46:29: fatal error: oci8_dtrace_gen.h: No such file or directory
 #include "oci8_dtrace_gen.h"
                             ^
compilation terminated.
Makefile:196: recipe for target 'oci8.lo' failed
make: *** [oci8.lo] Error 1
ERROR: `make' failed

我不知道该怎么办.我到处都在寻找解决方案,但我只能找到过时的文章.

I do not know what to do. I've searched everywhere for a solution, and I can only find outdated articles.

任何帮助,不胜感激!

推荐答案

似乎您的PHP是在启用DTrace支持的情况下构建的.由于PHP版本&的某些限制,配置文件,PECL OCI8安装也需要提示,也可以使用DTrace进行构建:

It seems that your PHP was built with DTrace support enabled. Due to some limitations with the PHP build & config files, the PECL OCI8 install needs a hint to also build with DTrace:

$ export PHP_DTRACE=yes
$ pecl install oci8

http://php.net/manual/en/oci8中已提及. dtrace.php

这篇关于PHP oci8无法通过pecl安装:“严重错误:oci8_dtrace_gen.h";的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆