I was following a tutorial online so I can install a USB DisplayLink monitor, and it told me to type:

sudo apt-get install git-core gcc-4.6-arm-linux-gnueabi

I tried that, and it says it "cannot locate the package". Please help

  • I would have made this a comment but I don't have the privileges. Could you explain why you think this is a kernel error? You didn't supply the error message. Are you sure it contains no useful information for anyone reading your question?
    – joan
    Commented Apr 13, 2014 at 8:26
  • It said that it could not locate the package. By the way, you now have 56 reputation so you can now comment. Commented Apr 13, 2014 at 17:25
  • 1
    Have you run sudo apt-get update lately? Commented Apr 13, 2014 at 18:13
  • 1
    @RPiAwesomeness actually, that was the first thing I did. Commented Apr 13, 2014 at 18:25
  • 1
    @goldilocks Well, it did say raspberry pi in the title. Here is a link: mitchtech.net/raspberry-pi-kernel-compile Commented Apr 13, 2014 at 18:35

1 Answer 1


As RPi Awesomeness points out, run apt-get update and then apt-get upgrade before you do anything.

apt-get is part of the Debian package management system used on, e.g., raspbian.

Unless you are certain of what you want to install, it is usually a good idea to see exactly what is available first. apt-cache search will provide a list matching a string, for example;

> apt-cache search git-core
devscripts - scripts to make the life of a Debian Package maintainer easier
git - fast, scalable, distributed revision control system
git-core - fast, scalable, distributed revision control system (obsolete)

It's not always obvious why the search returns the things it does, but in any case, here we have confirmation that git-core exists and is available, although there is the note that it is obsolete. We could broaden the seach by using just git, but this returns more than 500 results. However, if we filter via grep (see man grep), we can apply a regular expression so that only packages with "git" at the beginning of their name are returned:

apt-cache search git | grep "^git"

This limits us to a more manageable 30-40 hits, the first of which is:

git - fast, scalable, distributed revision control system

That's the package you actually want. For "gcc-4.6-arm-linux-gnueabi", we could try apt-cache search gcc | grep gnueabi -- but that returns nothing. The same regexp trick might work (just plan search gcc will return way too much again):

apt-cache search gcc | grep "^gcc"

A single screenful, which is easy to glance over. But there is no mention of "gnueabi".

"arm-linux-gnueabi" is actually a tuple used to identify the target of a compiler. In this case, the target is the same as the base system, so we can assume that the normal compiler will work in this case (it would have been good if you had included a link to the instructions you are following). We just need to make sure we get at least version 4.6; the list returned from the last search (which I omitted here) contains reference to 4.4 through 4.7. As it so happens, the current default on raspbian is 4.6, so just plain:

apt-get install gcc

Will do it. Check to make sure afterward with gcc --version. You should see something like:

gcc (Debian 4.6.3-14+rpi1) 4.6.3
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
  • any suggestions now that I gave the link? Commented Apr 13, 2014 at 19:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.