This error indicates you need to take some drastic action. Be aware this is somewhat advanced and will remove any boards you have installed via Boards Manager:
In the Arduino IDE, click the link on the line following File > Preferences > More preferences can be edited directly in the file. This will open the Arduino15 (or similar name depending on OS) folder.
Delete all files and folders under the Arduino15 folder except for preferences.txt. Please be very careful when deleting things from your computer. When in doubt, back up!
Restart the Arduino IDE
Verify that you can now use your board before reinstalling any packages via Boards Manager.
Hi pert, i follow the steps that you have given to me but the Arduino IDE still occur the error same as that i posted even i have connect the arduino board to pc.
This sort of error could be caused by your antivirus software. Try TEMPORARILY disabling your antivirus for a single compilation to see if the problem goes away, then turn the antivirus back on. If the problem doesn't occur with the antivirus off you will need to adjust the settings of your antivirus to whitelist the appropriate file, folder, or process so it doesn't interfere with compilation.
A search shows that several times after we've suggested doing that there was no further response on the Forum thread, which could be seen as a sign of success.
No. First, the GCC compiler is only used to compile the sketch. It can't be used to upload. AVRDUDE is used to upload and AVRDUDE has nothing to do with GCC. Second, I am in no way suggesting that you don't use the Arduino IDE.
Pert, for the step that delete all the files in the Arduino15 file except the preferences right?? is it correct ?? Like this... i send the photo that i try to use the solution that you gave last few days ago.
One more thing is the for the last two steps, restart the Adruino IDE ( this step i already go through it) and for the verification of board , is it just connect the arduino to pc and without go to Tools > Boards Manager.
Right?? so the Arduino IDE of PC will able to verify the Arduino Uno (made in China) by itself and to make it successfully t verify and upload to Arduino Board ?
Jackson3089:
Pert, for the step that delete all the files in the Arduino15 file except the preferences right?? is it correct ?? Like this... i send the photo that i try to use the solution that you gave last few days ago.
You can try that, but from the output you posted after I provided those instructions I can see that the toolchain bundled with the Arduino IDE installation is in use, rather than a toolchain installed under the Arduino15 folder, so it probably won't help.
Jackson3089:
One more thing is the for the last two steps, restart the Adruino IDE ( this step i already go through it) and for the verification of board , is it just connect the arduino to pc and without go to Tools > Boards Manager.
Right?? so the Arduino IDE of PC will able to verify the Arduino Uno (made in China) by itself and to make it successfully t verify and upload to Arduino Board ?
No. By "verify", I just meant to compile a sketch (Sketch > Verify/Compile). You don't need to have an Arduino board plugged into your computer to do that.
Please try temporarily disabling your antivirus software for a single compilation as I suggested in my last reply.
You'll find the environment variables listed in Windows Control Panel > System and Security > System > Advanced system settings > Advanced > Environment variables.... You can delete them there.
Pert, i have a little bit confuse on this statement ( i send u a pic in png form named untitled ) because i read through that carefully but haven't come a solution.
Secondly, i also try the other method that you suggested to me but it don't show the Arduino15 file in the Users variables for User and i also try browse file doesn't find the Arduino15 ( i send u a pic in png form named untitled2 )
In Windows Control Panel > System and Security > System > Advanced system settings > Advanced > Environment variables..., do you see "GCC EXEC PREFIX" listed under "System Variables"? Your screenshot doesn't show the entire list of system variables.
Hi pert, sorry for the late replied. I found the " GCC EXEC PREFIX " In Windows Control Panel > System and Security > System > Advanced system settings > Advanced > Environment variables. Thanks...
So i should delete this variable and open the Arduino IDE to compile /verify the sample code again to check whether the error still appear right ???
I have send the GCC.PNG in image for your as reference.
You're welcome. I'm glad to hear it's working now. I was a bit unclear about how to do this fix because it came from someone else with somewhat vague instructions and I had never investigated it very thoroughly. Now that I've gone through this process, I'll be able to provide more clear instructions to the next person who encounters this error.