Skip to content

Commit d2f4f58

Browse files
realiesJamesH65
authored andcommitted
Update building.md (raspberrypi#655)
* Update building.md * Updating the cross-compilation guide Making the cross-compilation tools installation steps slightly more obvious * copy edits
1 parent ede280c commit d2f4f58

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

linux/kernel/building.md

+12-3
Original file line numberDiff line numberDiff line change
@@ -60,13 +60,22 @@ You can either do this using VirtualBox (or VMWare) on Windows, or install it di
6060

6161
### Install toolchain
6262

63-
Use the following command to install the toolchain:
63+
Use the following command to download the toolchain to the home folder:
6464

6565
```bash
66-
git clone https://github.com/raspberrypi/tools
66+
git clone https://github.com/raspberrypi/tools ~/
6767
```
6868

69-
You can then copy the `/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian` directory to a common location, and add `/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian/bin` to your $PATH in the `.bashrc` in your home directory. For 64-bit host systems, use `/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin`. While this step isn't strictly necessary, it does make it easier for later command lines!
69+
Updating the $PATH environment variable makes the system aware of file locations needed for cross-compilation. On a 32-bit host system you can update and reload it using:
70+
```bash
71+
echo PATH=\$PATH:~/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian/bin >> ~/.bashrc
72+
source ~/.bashrc
73+
```
74+
If you are on a 64-bit host system, you should use:
75+
```bash
76+
echo PATH=\$PATH:~/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin >> ~/.bashrc
77+
source ~/.bashrc
78+
```
7079

7180
### Get sources
7281

0 commit comments

Comments
 (0)