Linux make: g++: Command not found
Linux使用make命令时遇到“make: g++: Command not found”,这个主要是没有安装gcc-c++.x86_64,如下所示
[root@localhost nethogs]# make
g++ -g -Wall -Wextra -c packet.cpp
make: g++: Command not found
make: *** [packet.o] Error 127
root@localhost nethogs]# yum search "gcc-c++"
Loaded plugins: product-id, security, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
==================================== N/S Matched: gcc-c++ ====================================
gcc-c++.x86_64 : C++ support for GCC
Name and summary matches only, use "search all" for everything.
[root@localhost nethogs]# yum list "gcc-c++"
Loaded plugins: product-id, security, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
media | 4.1 kB 00:00 ...
Available Packages
gcc-c++.x86_64 4.4.7-11.el6 media
[root@localhost nethogs]# yum install "gcc-c++.x86_64"
Loaded plugins: product-id, security, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package gcc-c++.x86_64 0:4.4.7-11.el6 will be installed
--> Processing Dependency: gcc = 4.4.7-11.el6 for package: gcc-c++-4.4.7-11.el6.x86_64
--> Processing Dependency: libstdc++-devel = 4.4.7-11.el6 for package: gcc-c++-4.4.7-11.el6.x86_64
--> Processing Dependency: libmpfr.so.1()(64bit) for package: gcc-c++-4.4.7-11.el6.x86_64
--> Running transaction check
---> Package gcc.x86_64 0:4.4.7-11.el6 will be installed
--> Processing Dependency: cpp = 4.4.7-11.el6 for package: gcc-4.4.7-11.el6.x86_64
--> Processing Dependency: cloog-ppl >= 0.15 for package: gcc-4.4.7-11.el6.x86_64
---> Package libstdc++-devel.x86_64 0:4.4.7-11.el6 will be installed
---> Package mpfr.x86_64 0:2.4.1-6.el6 will be installed
--> Running transaction check
---> Package cloog-ppl.x86_64 0:0.15.7-1.2.el6 will be installed
--> Processing Dependency: libppl.so.7()(64bit) for package: cloog-ppl-0.15.7-1.2.el6.x86_64
--> Processing Dependency: libppl_c.so.2()(64bit) for package: cloog-ppl-0.15.7-1.2.el6.x86_64
---> Package cpp.x86_64 0:4.4.7-11.el6 will be installed
--> Running transaction check
---> Package ppl.x86_64 0:0.10.2-11.el6 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
==============================================================================================
Package Arch Version Repository Size
==============================================================================================
Installing:
gcc-c++ x86_64 4.4.7-11.el6 media 4.7 M
Installing for dependencies:
cloog-ppl x86_64 0.15.7-1.2.el6 media 93 k
cpp x86_64 4.4.7-11.el6 media 3.7 M
gcc x86_64 4.4.7-11.el6 media 10 M
libstdc++-devel x86_64 4.4.7-11.el6 media 1.6 M
mpfr x86_64 2.4.1-6.el6 media 156 k
ppl x86_64 0.10.2-11.el6 media 1.3 M
Transaction Summary
==============================================================================================
Install 7 Package(s)
Total download size: 22 M
Installed size: 53 M
Is this ok [y/N]: y
Downloading Packages:
----------------------------------------------------------------------------------------------
Total 163 MB/s | 22 MB 00:00
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : mpfr-2.4.1-6.el6.x86_64 1/7
Installing : cpp-4.4.7-11.el6.x86_64 2/7
Installing : ppl-0.10.2-11.el6.x86_64 3/7
Installing : cloog-ppl-0.15.7-1.2.el6.x86_64 4/7
Installing : gcc-4.4.7-11.el6.x86_64 5/7
Installing : libstdc++-devel-4.4.7-11.el6.x86_64 6/7
Installing : gcc-c++-4.4.7-11.el6.x86_64 7/7
Verifying : gcc-4.4.7-11.el6.x86_64 1/7
Verifying : gcc-c++-4.4.7-11.el6.x86_64 2/7
Verifying : mpfr-2.4.1-6.el6.x86_64 3/7
Verifying : libstdc++-devel-4.4.7-11.el6.x86_64 4/7
Verifying : cpp-4.4.7-11.el6.x86_64 5/7
Verifying : ppl-0.10.2-11.el6.x86_64 6/7
Verifying : cloog-ppl-0.15.7-1.2.el6.x86_64 7/7
Installed:
gcc-c++.x86_64 0:4.4.7-11.el6
Dependency Installed:
cloog-ppl.x86_64 0:0.15.7-1.2.el6 cpp.x86_64 0:4.4.7-11.el6 gcc.x86_64 0:4.4.7-11.el6
libstdc++-devel.x86_64 0:4.4.7-11.el6 mpfr.x86_64 0:2.4.1-6.el6 ppl.x86_64 0:0.10.2-11.el6
Complete!
Linux make: g++: Command not found的更多相关文章
- 解决g++:command not found(centos7.0)
问题背景,因为装了虚拟机,系统为centos7.0,由于是纯净版,没有gcc,使用命令yum install gcc安装了gcc,但是没安装g++,导致g++:command not found问题. ...
- 【亲测】<g++/gcc>CentOS下g++: command not found问题的解决(c++环境安装)
CentOS下g++: command not found问题的解决 2017年02月27日 18:09:06 阅读数:5174 标签: centosgcc 更多 个人分类: 问题分析 版权声明: ...
- Linux & terminal color & command line color
Linux & terminal color & command line color how to change Linux terminal color https://askub ...
- [转]Linux下g++编译与使用静态库(.a)和动态库(.os) (+修正与解释)
在windows环境下,我们通常在IDE如VS的工程中开发C++项目,对于生成和使用静态库(*.lib)与动态库(*.dll)可能都已经比较熟悉,但是,在linux环境下,则是另一套模式,对应的静态库 ...
- linux shell basic command
Learning basic Linux commands Command Description $ ls This command is used to check the contents of ...
- Linux环境g++编译TinyXML动态库
除了CMarkup,tinyxml也是C/C++下解析XML很好的工具.在linux下用g++编译tinyxml的步骤如下(tinyxml版本2.6.2): 进入tinyxml解压目录,用文本编辑器打 ...
- Linux sort -g 的困惑
sort命令是帮我们依据不同的数据类型进行排序,排序的效率很高,因此也是很常用的命令. sort参考及说明:https://www.gnu.org/software/coreutils/manual/ ...
- [问题解决]linux sudo xxx:command not found
题外话 软件的安装在linux下主要分为两种.一种是通过包管理器例如ubuntu的apt-get xxx,另一种是自己手动安装.通过包管理器安装的,基本开箱即用,无需配置,但是存在一个问题,有时候无法 ...
- Linux renew ip command
$ sudo dhclient -r //release ip 释放IP$ sudo dhclient //获取IP Now obtain fresh IP:$ sudo dhcli ...
随机推荐
- hibernate笔记--cascade级联以及inverse属性
cascade : 不管是单向多对一还是一对多,或者是双向的一对多关系,在一的一端映射文件中有一个set标签,在多的一端有many-to-one标签,拿前几篇笔记里讲的Grade和Student举例, ...
- Tomcat服务器本地的搭建,以及在 IDEA软件下的配置,以及项目的测试运行(基于supermvc框架下的web)
一.声明 使用了基于springmvc的supermvc的web框架.实习公司的框架. 二.tomact的下载与安装 1选择适合自己电脑配置的jdk和jre版本(截图来自tomcat的官方网站http ...
- 常见的几个meta标签元素
1.指定字符集: <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/& ...
- Hibernate —— Session
一.概述 Session 是 Hibernate 向应用程序提供操纵数据的主要接口,它提供了基本的保存.更新.删除和加载 Java 对象的方法. 二.Session 缓存 1.简介 (1)Sessio ...
- Objective-C 对象(内容根据iOS编程编写)
开发iOS程序需要使用 Objective-C 语言和Cocoa Touch框架.Objective-C 源于 C 语言,是 C 语言的扩展. Cocoa Touch框架是一个Objective-C类 ...
- RESTful API测试工具
Postman Postman是一个Chrome APP,可以直接通过Chrome商店安装(需F墙,推荐修改hosts的方法,简便快捷有效) 其截图如下,非常漂亮 Aoizza Web APP,点击访 ...
- c# 生成SHA1加密字符串
从网上找到的一种加密代码: var enstr ="abcdefg"; var strRes = Encoding.Default.GetBytes(enstr); HashAlg ...
- Git GUI下载远程源代码简单使用介绍
学习编程,适当的时候弄些开源项目的源代码来学习实践,对技术是很有帮助的.如果学习.NET.C#的话,codeplex上面有许多不错的源代码,推荐一个ASP.ENT的:HoverTree http:// ...
- 设计模式(三)工厂方法模式(Factory Pattern)
一.引言 在简单工厂模式中讲到简单工厂模式的缺点,有一点是——简单工厂模式系统难以扩展,一旦添加新产品就不得不修改简单工厂方法,这样就会造成简单工厂的实现逻辑过于复杂,然而本专题介绍的工厂方法模式可以 ...
- 未能解析此远程名称: 'api.ucpaas.com'
未能解析此远程名称: 'api.ucpaas.com' 这个问题的原因不是云之讯,而是(我用的是阿里云)云服务器的DNS解析的问题 或者是云服务器后台的安全组规则的问题, 应该把内网入方向和内网出 ...