Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Ok, I just installed MinGW on my PC and to used g++ command on cmd and it says,

'perl' is not recognized as an internal or external command, 
 operable program or batch file.

I just checked PATH and it is as I should expect, there is g++ directory and perl is not anywhere in the list. Same happens when I use gcc. But everything is alright when i use python. Now this problem is driving me insane and compels me to think that my PC is a sick Idiot who likes to suffer from strange diseases which have never been documented.

Yes, I can just cd into g++ directory and do what I need but thats too much of hard work every time. Any solutions?

Just to mention I used to program in perl(don't know what I was thinking) but I my PC has gone several changes, partitioning removal, program uninstallation since.

share|improve this question
So, if you invoke g++ (no matter how) through the PATH environment, you get this error? I'm a bit confused by the wording of your question. – Oliver Salzburg May 4 '12 at 13:45
Yes, in the command prompt, In Notepad++ console, In netbeans compilation they say the same. – Shubham May 4 '12 at 13:51
up vote 2 down vote accepted

Perhaps the first "g++" found in your PATH is a script that contains a "perl" command or which starts with a shebang line that specifies "perl" without giving a full and correct path to a perl executable.

share|improve this answer
Have you faced that problem before? If not, thats kind of Shelock Holmes reasoning. :) – Shubham May 4 '12 at 14:52
"Elementary my dear @Shubham." – RedGrittyBrick May 4 '12 at 15:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .