简体   繁体   中英

program “g++” and “gcc” not found in path

I am using eclipse luna. I have installed CDT into it. For accessing GNU tool chain I have installed latest version of MinGW and given the path of MinGW\\bin in environment variables. But when I have built a test project(written in C), I am getting the following errors:

Program "g++" not found in path
Program "gcc" not found in path

Info: I am using Windows 8 32 bit OS

Hi I just had a similar problem and i tried many of the solutions offered by the members and nothing worked. after a long time i managed to find the main issue it is the ANTI VIRUS! it blocks the gcc.exe and g++.exe Mke sure you disable every anti virus or make an exception.

(WINDOWS 7 64BIT Eclipse kepler)

I had similar problem and I solved it by:

Installing g++ The GNU C++ compiler using Ubuntu Software Center

Changing in: Window -> Preferences -> C/C++ -> Build -> Settings -> Discovery -> CDT GCC Build in Complier Settings [Shared]

from: ${COMMAND} -E -P -v -dD "${INPUTS}"

to: /usr/bin/${COMMAND} -E -P -v -dD "${INPUTS}"

I am using ubuntu but try the same in windows.

Be sure that you have installed g++ and then add whole path before $ as (path)${COMMAND} -E -P -v -dD "${INPUTS}"

I hope it helps.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM