c++ - 配置:错误:C++ 预处理器 "/lib/cpp"完整性检查失败

这个错误让我抓狂。我尝试了很多解决方案都没有成功。 这是我的问题,当我启动 ./configure 来编译 libtool 时,出现此错误:

....

checking for g++... g++
checking whether we are using the GNU C++ compiler... no
checking whether g++ accepts -g... no
checking dependency style of g++... gcc3
checking how to run the C++ preprocessor... /lib/cpp
configure: error: in `/home/thierry/libtool-master/libtool-master':
configure: error: C++ preprocessor "/lib/cpp" fails sanity check
See `config.log' for more details

我无法向您显示 config.log,因为它的大小,并且其中包含一些二进制字符。

我有如上所示的所有编译器 c++、g++、gcc:

thierry@LFR038391:~/DeepSpeech$ dpkg -l | grep c++
ii  libsigc++-2.0-0v5:amd64               2.10.0-2                           amd64        type-safe Signal Framework for C++ - runtime
ii  libstdc++-6-dev:amd64                 6.5.0-2ubuntu1~18.04               amd64        GNU Standard C++ Library v3 (development files)
ii  libstdc++-7-dev:amd64                 7.4.0-1ubuntu1~18.04.1             amd64        GNU Standard C++ Library v3 (development files)
ii  libstdc++6:amd64                      8.3.0-6ubuntu1~18.04.1             amd64        GNU Standard C++ Library v3
thierry@LFR038391:~/DeepSpeech$ pwd
/home/thierry/DeepSpeech
thierry@LFR038391:~/DeepSpeech$ dpkg -l | grep gcc
ii  gcc                                   4:7.4.0-1ubuntu2.3                 amd64        GNU C compiler
ii  gcc-6                                 6.5.0-2ubuntu1~18.04               amd64        GNU C compiler
ii  gcc-6-base:amd64                      6.5.0-2ubuntu1~18.04               amd64        GCC, the GNU Compiler Collection (base package)
ii  gcc-7                                 7.4.0-1ubuntu1~18.04.1             amd64        GNU C compiler
ii  gcc-7-base:amd64                      7.4.0-1ubuntu1~18.04.1             amd64        GCC, the GNU Compiler Collection (base package)
ii  gcc-8-base:amd64                      8.3.0-6ubuntu1~18.04.1             amd64        GCC, the GNU Compiler Collection (base package)
ii  libgcc-6-dev:amd64                    6.5.0-2ubuntu1~18.04               amd64        GCC support library (development files)
ii  libgcc-7-dev:amd64                    7.4.0-1ubuntu1~18.04.1             amd64        GCC support library (development files)
ii  libgcc1:amd64                         1:8.3.0-6ubuntu1~18.04.1           amd64        GCC support library
thierry@LFR038391:~/DeepSpeech$ dpkg -l | grep g++
ii  g++                                   4:7.4.0-1ubuntu2.3                 amd64        GNU C++ compiler
ii  g++-6                                 6.5.0-2ubuntu1~18.04               amd64        GNU C++ compiler
ii  g++-7                                 7.4.0-1ubuntu1~18.04.1             amd64        GNU C++ compiler

我现在不知道如何解决这个问题。

最佳答案

我昨天遇到了同样的问题,我所做的是在我的虚拟机中安装所有这些 RPM,然后它开始运行良好。

大多数这些 rpm 是相互依赖的。

安装包

cpp-4.8.5-44.el7.x86_64.rpm
glibc-2.17-317.el7.x86_64.rpm
glibc-devel-2.17-317.el7.x86_64.rpm
kernel-headers-3.10.0-1160.15.2.el7.x86_64.rpm
mpfr-3.1.1-4.el7.x86_64.rpm
gcc-4.8.5-44.el7.x86_64.rpm
glibc-common-2.17-317.el7.x86_64.rpm
glibc-headers-2.17-317.el7.x86_64.rpm
libmpc-1.0.1-3.el7.x86_64.rpm
nss-softokn-freebl-3.44.0-8.el7_7.i686.rpm

关于c++ - 配置:错误:C++ 预处理器 "/lib/cpp"完整性检查失败,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/58062300/

相关文章:

html - 有没有一种方法可以确保在 print 语句中使用 kable 表时 unicode 符

php - 如何在 PHP 中使用 Google 我的业务 API 发布问题的新答案

r - 如何更新 R shiny 中 for 循环内的无功输出

azure-sql-database - 目前无法检索该地区的定价配置数据。请重试

keras - 卷积自动编码器keras的高损失

amazon-web-services - 调用端点 url 时找不到 AWS API Gatewa

reactjs - 在 Kafka 上 react GUI

batch-file - Windows CMD 行 'sftp' 使用密码进行身份验证

python - 未绑定(bind)的 super 对象,super(self, self)

laravel-5 - Phpspreadsheet 四舍五入帐号并从开始删除 0