You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/install-guides/gcc/cross.md
+35-6Lines changed: 35 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,28 +34,55 @@ Software can be compiled on an `x86` or `Arm` host machine.
34
34
35
35
## How do I download a GCC cross compiler targeting Arm?
36
36
37
-
The Linux package manager will download the required files so there are no special download instructions.
37
+
For the Linux cross-compilers targeting 32-bit and 64-bit Linux applications (`arm-linux-gnueabihf` and `aarch64-linux-gnu`), the Linux package manager downloads the required files.
38
+
39
+
For the bare-metal cross-compiler (`arm-none-eabi`), Arm no longer publishes new releases through Debian or Ubuntu package repositories. To get the latest version, download it directly from the [Arm GNU Toolchain downloads page](https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads).
38
40
39
41
## How do I install a GCC cross compiler on Linux?
40
42
41
43
You can install a GCC cross compiler with Arm as a target architecture using Linux package managers.
42
44
43
45
### Installing on Debian based distributions such as Ubuntu
44
46
45
-
Use the `apt` command to install software packages on any Debian based Linux distribution.
47
+
Use the `apt` command to install the cross-compilers for 32-bit and 64-bit Linux targets.
46
48
47
49
```bash { target="ubuntu:latest" }
48
50
sudo apt update
49
-
sudo apt install gcc-arm-none-eabi -y
50
51
sudo apt install gcc-arm-linux-gnueabihf -y
51
52
sudo apt install gcc-aarch64-linux-gnu -y
52
53
```
53
54
55
+
These packages are maintained by Canonical and the GCC version you receive is tied to your Ubuntu release (for example, GCC 13 on Ubuntu 24.04 LTS, GCC 15 on Ubuntu 25.10). This is normal Ubuntu packaging behaviour and is not the same issue as with `arm-none-eabi`.
56
+
57
+
For the bare-metal cross-compiler (`arm-none-eabi`), Arm no longer publishes new releases to Debian or Ubuntu package repositories. The version available through `apt` is older and may not include support for recent Arm cores or architecture features.
58
+
59
+
To install the latest `arm-none-eabi` toolchain (15.2.Rel1), download the pre-built tarball for your host architecture from the [Arm GNU Toolchain downloads page](https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads). Extract the archive and add the `bin` directory to your `PATH`.
The commands above extract the toolchain into the current directory. Move the folder to a permanent location such as `$HOME` first if you'd like a stable install path.
78
+
79
+
To make the change permanent, add the `export` line to your shell profile such as `~/.bashrc` or `~/.profile`.
80
+
54
81
### Installing on Fedora
55
82
56
-
Fedora uses the `dnf` package manager.
83
+
Fedora uses the `dnf` package manager. The `arm-none-eabi-gcc-cs` package in current Fedora releases (42 and later) tracks the latest GCC release closely.
57
84
58
-
To install the most common development tools use the commands below.
85
+
If you're on RHEL, CentOS, or another EPEL-based distribution, the available version may be older. In that case, download the latest toolchain directly from the [Arm GNU Toolchain downloads page](https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads) and follow the manual extraction steps described in the Ubuntu section above.
59
86
60
87
- If the machine has `sudo` you can use it:
61
88
@@ -79,12 +106,14 @@ To install the most common development tools use the commands below.
79
106
80
107
## How do I install a GCC cross compiler on macOS?
81
108
82
-
You can install a GCC cross compiler with Arm as a target architecture using Homebrew, a package manager for macOS (and Linux).
109
+
You can install a GCC cross compiler with Arm as a target architecture using Homebrew, a package manager for macOS (and Linux). The Homebrew formula tracks the latest GCC release and provides pre-built bottles for Apple Silicon.
83
110
84
111
```console
85
112
brew install arm-none-eabi-gcc
86
113
```
87
114
115
+
Alternatively, Arm provides an official `.pkg` installer for macOS on Apple Silicon. Download the latest version from the [Arm GNU Toolchain downloads page](https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads) and run it to install the toolchain to `/Applications/ArmGNUToolchain/`.
0 commit comments