Sign up ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

When I'm trying to compile a C++ program with gcc, it gives me following error:

gcc: error trying to exec 'cc1plus': execvp: No such file or directory
error: command 'gcc' failed with exit status 1
share|improve this question

1 Answer 1

You're missing g++ package on your machine. Install it via:

sudo apt-get install g++


share|improve this answer
Just for a clarification: Default Ubuntu installation comes with gcc, but not with g++. – Andrejs Cainikovs May 21 '12 at 10:45

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.