Arm-none-eabi-gcc command not found in w10

I am trying to upgrade the firmware version of my photon but I am having some issues installing all the stuff required.

I work on w10. I did all the steps in this guide: https://github.com/spark/firmware/blob/develop/docs/dependencies.md#1-download-and-install-dependencies

But as soon as I try to compile modules, I guet this error:

$ mingw32-make clean all PLATFORM=photon -s program-dfu
/usr/bin/sh: arm-none-eabi-gcc: command not found
../build/arm-tools.mk:43: *** "ARM gcc version 4.8.4 or later required, but found ".  Stop.

I tried to include arm-none-eabi-gcc in my enviromental variables and also the bin folder ( There is 2 bin folder, one in C:\Program Files (x86)\gnu_arm_tool\5.4 2016q2 and another one inside the version folder. I tried with both. But I always get that message.

Is there anything I need to do to include it? I tried to execute --version command in cmd.exe and git-bash and in both I get the same response.

Is this proccess easier on linux? I could try to install a virtual machine or a real one in my laptop.

If this is only to update the system firmware, and not to compile locally, there are easier ways to do so. Just select a higher version in the web IDE and flash that OTA.
Alternatively install the CLI and issue particle update while in DFU mode.

Unless it’s an Electron, then the best way to go is via CLI, but you can also do it with dfu-util alone.

1 Like

This process is easier in Linux, but I also had to solve the problem that you are having. The /usr/bin/sh: arm-none-eabi-gcc: command not found error happens when you do not have the 32-bit C libraries installed.

If you want to use Linux, I have made a tool called po-util that automatically installs all of the dependencies for you and makes it easier to build firmware. It also makes DFU uploading much faster, compiling system firmware simpler, and lets you use any branch (version) of the Particle Firmware.

Or serial, or the updater… :wink: (it was also mentioned to be a Photon)

1 Like

@nrobinson2000 Which libraries did you need to install to make this work? I have the MinGW Installation Manager open in front of me, and can’t figure out what the “32-bit C libraries” you mention are:

Where are they located???

I’m pretty sure I have them installed allready???

If so, then I’m not sure why I am getting the arm-none-eabi-gcc command not found error. Here is a printout of my environment variables. As you can see I have included the correct .bin folders in the PATH variable… so not sure why I am still getting this error:

Boompy@TOMS_TOWER /c/PARTICLE_LOCAL/firmware/modules
$ printenv
USERDOMAIN_ROAMINGPROFILE=TOMS_TOWER
HOMEPATH=\
APPDATA=C:\Users\Boompy\AppData\Roaming
PROGRAMW6432=C:\Program Files
ONEDRIVE=C:\Users\Boompy\OneDrive
TERM=cygwin
PROCESSOR_IDENTIFIER=Intel64 Family 6 Model 42 Stepping 7, GenuineIntel
WINDIR=C:\WINDOWS
VXIPNPPATH64=C:\Program Files\IVI Foundation\VISA\
COMMONPROGRAMW6432=C:\Program Files\Common Files
PUBLIC=C:\Users\Public
OLDPWD=/c/Program Files
PROGRAMDATA=C:\ProgramData
USERDOMAIN=TOMS_TOWER
COMMONPROGRAMFILES(X86)=C:\Program Files (x86)\Common Files
OS=Windows_NT
ALLUSERSPROFILE=C:\ProgramData
TEMP=/tmp
COMMONPROGRAMFILES=C:\Program Files (x86)\Common Files
ACTEL_FOR_ALTIUM_OVERRIDE=
VXIPNPPATH=C:\Program Files (x86)\IVI Foundation\VISA\
USERNAME=Boompy
PROCESSOR_LEVEL=6
PATH=.:/usr/local/bin:/mingw/bin:/bin:/c/ProgramData/Oracle/Java/javapath:/c/Program Files (x86)/NVIDIA Corporation/PhysX/Common:/c/WINDOWS/system32:/c/WINDOWS:/c/WINDOWS/System32/Wbem:/c/WINDOWS/System32/WindowsPowerShell/v1.0/:/c/Program Files (x86)/AMD/ATI.ACE/Core-Static:/c/Program Files/IVI Foundation/VISA/Win64/Bin/:/c/Program Files (x86)/IVI Foundation/VISA/WinNT/Bin/:/c/Program Files (x86)/IVI Foundation/VISA/WinNT/Bin:/c/Program Files (x86)/Skype/Phone/:/c/Program Files/nodejs/:/c/Program Files/PuTTY/:/c/Program Files/SourceGear/Common/DiffMerge/:/c/Program Files/Git/cmd:/c/dfu-util-0.8-binaries/win32-mingw32:/c/Particle/Tools/DFU-util:/c/Users/Boompy/AppData/Local/Microsoft/WindowsApps:/c/Users/Boompy/AppData/Roaming/npm:/c/Users/Boompy/AppData/Local/particledev/bin:/c/Program Files/Docker Toolbox:/c/Program Files (x86)/GnuWin32/bin:/mingw/bin:/c/Program Files (x86)/GNU Tools ARM Embedded/6 2017-q1-update/arm-none-eabi/bin:C:/ProgramFiles (x86)/GNU Tools ARM Embedded/6 2017-q1-update/arm-none-eabi/bin:C:/Program Files (x86)/GNU Tools ARM Embedded/6 2017-q1-update/bin
PSMODULEPATH=C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules\
DOCKER_TOOLBOX_INSTALL_PATH=C:\Program Files\Docker Toolbox
MSYSCON=sh.exe
PWD=/c/PARTICLE_LOCAL/firmware/modules
SYSTEMDRIVE=C:
PROCESSOR_ARCHITEW6432=AMD64
USERPROFILE=C:\Users\Boompy
PS1=\[\033]0;$MSYSTEM:\w\007
\033[32m\]\u@\h \[\033[33m\w\033[0m\]
$
LOGONSERVER=\\TOMS_TOWER
PROCESSOR_ARCHITECTURE=x86
LOCALAPPDATA=C:\Users\Boompy\AppData\Local
!C:=C:\MinGW\msys\1.0
HOME=/home/Boompy
SHLVL=1
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC
HOMEDRIVE=C:
WD=C:\MinGW\msys\1.0\\bin\
VBOX_MSI_INSTALL_PATH=C:\Program Files\Oracle\VirtualBox\
PROMPT=$P$G
MSYSTEM=MINGW32
COMSPEC=C:\WINDOWS\SysWOW64\cmd.exe
LOGNAME=Boompy
TMP=/tmp
SYSTEMROOT=C:\WINDOWS
PROCESSOR_REVISION=2a07
ALTERA_FOR_ALTIUM_OVERRIDE=
MAKE_MODE=unix
PROGRAMFILES=C:\Program Files (x86)
NUMBER_OF_PROCESSORS=8
PROGRAMFILES(X86)=C:\Program Files (x86)
ASL.LOG=Destination=file
SESSIONNAME=Console
HISTFILE=/home/Boompy/.bash_history
COMPUTERNAME=TOMS_TOWER
_=/bin/printenv

@jaza_tom
I had to install the libc6-i386 package on Ubuntu. No idea what is required for MinGW.

Hey I just read the “official guide” (as opposed to the github guide) and notice this discrepancy:

Github:

The build requires version 4.9.3 20150529 or newer of ARM GCC and will print an error message if the version is older than this.

Official Guide:

Currently, the 4.9-2015-q3-update is recommended. The 5.3.1 version can be used now and will be used for cloud compiles starting with system firmware 0.7.0. The 5.4.x and 6.x versions are not recommended at this time.

I was following the GitHub instructions and therefore installed arm-gcc v6.0. Once I saw the “Official Guide” recommended 4.9-2015-q3 I uninstalled 6.0 and installed the 4.9q3 version.

Things are now working as expected:

Boompy@TOMS_TOWER ~
$ export PATH="$PATH:C:/Program Files (x86)/GNU Tools ARM Embedded/4.9 2015q3/bin"

Boompy@TOMS_TOWER ~
$ cd C:/PARTICLE_LOCAL/firmware/modules

Boompy@TOMS_TOWER /c/PARTICLE_LOCAL/firmware/modules
$ make clean all PLATFORM=photon -s program-dfu
  /c/PARTICLE_LOCAL/firmware/modules/photon/system-part1/makefile /c/PARTICLE_LOCAL/firmware/modules/photon/system-part2/makefile /c/PARTICLE_LOCAL/firmware/modules/photon/user-part/makefile
   text    data     bss     dec     hex filename
 252280     144     148  252572   3da9c ../../../build/target/system-part1/platform-6-m/system-part1.elf
dfu-suffix (dfu-util) 0.8

Copyright 2011-2012 Stefan Schmidt, 2013-2014 Tormod Volden
This program is Free Software and has ABSOLUTELY NO WARRANTY
Please report bugs to dfu-util@lists.gnumonks.org

Suffix successfully added to file
Serial device PARTICLE_SERIAL_DEV : not available
Flashing using dfu:
dfu-util 0.8

Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2014 Tormod Volden and Stefan Schmidt
This program is Free Software and has ABSOLUTELY NO WARRANTY
Please report bugs to dfu-util@lists.gnumonks.org

No DFU capable USB device available
make[1]: *** [program-dfu] Error 74
make: *** [/c/PARTICLE_LOCAL/firmware/modules/photon/system-part1/makefile] Error 2

Nice