Ubuntu: $PATH in the .bashrc



Question:

How I can do this:

INSTALL TOOLCHAIN

... add /tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian/bin to your $PATH in the .bashrc in your home directory.

I managed to find the .bashrc file and open it.

gcc-linaro-arm-linux-gnueabihf-raspbian/bin is a file on my PC

I am running Ubuntu 14.04 on vmware


Solution:1

Open the /home/$USER/.bashrc file with any editor of your choice, then add the following that line in this manner:

export PATH="/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian/bin:$PATH"  

Then either:

  1. Source the file with: source ~/.bashrc, OR
  2. Restart the system but step one is better

Check if it's there with this command:

echo $PATH | grep -i /tools/arm-bcm2708/  

If it's there you will see it in the output, if not your syntax may be off.


Solution:2

One way for adding the path to the file is:

You should edit ~/.bashrc file, e.g. using:

vi ~/.bashrc  

And add the following line to the end of the file

export PATH=$PATH:/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian/bin  

The above line will add the specific path to the end of the lists of paths in PATH variable


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »