Program 'gcc' not found in PATH

Discussions concerning TrueSTUDIO for STM32 9.0.0 and later versions.

Moderators: Markus Girdland, Mattias Norlander

jblauser
Posts: 1
Joined: Sun Jan 28, 2018 7:48 pm

Program 'gcc' not found in PATH

Postby jblauser » Sun Jan 28, 2018 7:54 pm

Just installed v9.0.0 and followed the quick start guide to try a new project.
When trying to build there is 1 error - Program 'gcc' not found in PATH
1. Where in the tool can I find where the path is defined?
2. Why would the gcc not be included in the automatic installation?
3. If gcc is present, just not installed, what is the default location so I can find it?
4. If there is no gcc default location on my local machine, where can I find gcc to download it?
5. After gcc has been located, what are the steps to make sure it is properly installed and shows up in the PATH?

kalle
Posts: 3
Joined: Mon Jan 29, 2018 2:41 pm

Re: Program 'gcc' not found in PATH

Postby kalle » Tue Jan 30, 2018 6:10 pm

1) search for 'arm-atollic-eabi-gcc' in your install directory. I find it under ARMTools/bin
2) is for me. Something wrong with your installation, perhaps?
5) TrueSTUDIO picked up its own gcc by default for me.

nishiyama
Posts: 4
Joined: Mon Feb 13, 2017 4:53 am

Re: Program 'gcc' not found in PATH

Postby nishiyama » Mon Apr 23, 2018 2:49 am

Me too.
Some of old projects had this issue.
How to refresh these error ?
In fact all of build was done in correctly.
But finally it shows this error as failure. :(

nishiyama
Posts: 4
Joined: Mon Feb 13, 2017 4:53 am

[SOLVED]: Program 'gcc' not found in PATH

Postby nishiyama » Mon Apr 23, 2018 3:42 am

Hello folks
I could fix this issue as added following path into system environment PATH.
D:\Program Files (x86)\Atollic\TrueSTUDIO for STM32 9.0.0\PCTools\bin

regards

tma
Posts: 5
Joined: Mon Feb 20, 2017 5:32 pm

Re: Program 'gcc' not found in PATH

Postby tma » Sun Sep 30, 2018 5:48 am

Greetings,

I ran into this same problem with a new Windows 10 install of TrueStudio 9.0.1. It is apparent that the IDE installation package does not add the path to to the environment for the "gcc" tools as possibly it should. As stated in a previous reply here manually adding the path to the System PATH environment fixes the issue. However I wonder why the IDE should have need to use the environment to find the "gcc" tools when the path is well known during the TrueStudio installation?

Note that TrueStudio must be closed and re-started to acquire the new environment path. It is apparent TrueStudio only loads the path environment during start up which can be confusing when trying to fix a problem when TrueStudio is already running.

tma

Mattias Norlander
Posts: 273
Joined: Fri Apr 29, 2016 10:01 am

Re: Program 'gcc' not found in PATH

Postby Mattias Norlander » Fri Oct 05, 2018 3:52 pm

TrueSTUDIO sets its own environmental variables when running, so no need for the Windows Path variable (in theory apparently only).
Verify that you have the gcc installed in the ARMTools\bin folder. Sometimes we have seen anti-virus tools eating the compiler :roll:
If you re-install TS try disabling anti-virus. Do you have admin permissions on the computer?

tma
Posts: 5
Joined: Mon Feb 20, 2017 5:32 pm

Re: Program 'gcc' not found in PATH

Postby tma » Sat Oct 06, 2018 5:57 am

Greetings Mattias,

Thank you for your informed response!

I was not running TrueStudio as administrator as I didn't know that was a requirement which I have now specified for the TS executable. I decided to disable the path variable I had previously added and then, after re-booting, I gave TS a test run and found it re-builds the application OK when ran as administrator. As you mentioned my virus monitor immediately detected the system change attempt and prevented it from happening. Once I provided specific authorization and did a second re-boot it seems to start OK and I was able to re-build the project.

I gather administrator privileges are needed for the changing the operating system environment each time TS initializes. It might be better from a security viewpoint to be able to run TS as a user. If it is just the one GCC path that is required manually installing a single path statement is not that difficult to do as long as the need is known. Since the installation package is given admin privileges possibly it could be designed to install the variable permanently on the system at the onset so that admin privileges to run TS would not be required. I don't recall encountering a need for admin privileges for other IDE's that I have used however I have encountered the need for manually adding path statements in the past.

Thanks again!

TMA

tma
Posts: 5
Joined: Mon Feb 20, 2017 5:32 pm

Re: Program 'gcc' not found in PATH

Postby tma » Sat Oct 06, 2018 6:26 pm

Greetings,

Further to my last I find now that after removing the previously manually installed gcc path environment statement I can still re-build OK when running TS WITHOUT admin privileges. It appears that it may only be necessary to run TS once with admin privileges to establish the gcc path.

I hope this info is of some value for those that may be interested trying to resolve this issue.

TMA

Mattias Norlander
Posts: 273
Joined: Fri Apr 29, 2016 10:01 am

Re: Program 'gcc' not found in PATH

Postby Mattias Norlander » Mon Oct 08, 2018 9:17 am

Thanks tma,

I am sure it is if people care to google ;)
Interesting feedback. It is difficult to narrow down these types of issues since different companies have differently looking PC environments and we simply cannot test it all.


Return to “TrueSTUDIO for STM32 discussions”

Who is online

Users browsing this forum: No registered users and 1 guest