首页 > 解决方案 > g++ --version 失败,但显示 g++ 已经安装

问题描述

root@node4:/storage/LHY/Pytorch-Correlation-extension-master# g++ --version

Command 'g++' not found, but can be installed with:

但安装也失败:

root@node4:/storage/LHY/Pytorch-Correlation-extension-master# apt install g++
Reading package lists... Done
Building dependency tree       
Reading state information... Done
g++ is already the newest version (4:7.4.0-1ubuntu2.3).
The following packages were automatically installed and are no longer required:
  fonts-crosextra-caladea fonts-crosextra-carlito fonts-dejavu fonts-linuxlibertine fonts-sil-gentium fonts-sil-gentium-basic gstreamer1.0-gtk3
  lib32gcc1 libapache-pom-java libbsh-java libcommons-logging-java libcommons-parent-java libel-api-java libhsqldb1.8.0-java libjsp-api-java libllvm7
  libservlet-api-java libservlet3.1-java libwebsocket-api-java
Use 'apt autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 486 not upgraded.
root@node4:/storage/LHY/Pytorch-Correlation-extension-master# 

标签: c++

解决方案


推荐阅读