Bash - command not found

I created a make file with a name Makefileon my ec2 Linux server.

all: a b

a: daemon.cpp dictionary_exclude.cpp
        g++ -o a daemon.cpp dictionary_exclude.cpp -lpthread -std=c++0x -L.

b: user_main.cpp client.cpp
        g++ -o b user_main.cpp client.cpp

I could run each of them independently of each other.

But when I do

make
make -f Makefile

He says make: -bash: make: command not found

Any idea? I see that manually for make is available through man make

+4
source share
3 answers

To install make on your system, run the following command

sudo yum install build-essential
+10
source

On CentOS or Red Hat, try the following:

# yum groupinstall "Development Tools"

(Do not enter #which is intended to represent the command line shell.)

+3
source
+1

Source: https://habr.com/ru/post/1526330/


All Articles