2011-12-09 91 views
5

我在哪里可以买到Android 4.0(冰淇淋三明治)内核源代码?Android 4.0内核源代码?

虽然这可能是一个愚蠢的问题,有些人问过,我似乎无法找到一个合适的答案随时随地因为:

  • 谷歌决定是非常有用的和重定向到android.kernel.org其中包括除了内核之外的Android 的每个单独部分。 我不明白这背后的逻辑。

  • git clone https://android.googlesource.com/kernel/common.git做奇怪的事情,并创建一个巨大的(600 MB +).git文件夹,而无需创建源代码树。我不给狗屎回购两个狗屎,我只需要源树

  • GitHub上的所有内核分支都非常过时。

回答

5

观看Android源代码托管在Github

9

Jean-Baptiste Queru在他的2011年11月30日post中解释了为什么内核源在克隆后不可见。 This post描述了为ICS的各种硬件口味而存在的内核源分支。

而在一般情况下,这里是如何做具体的分支可见:

git clone https://android.googlesource.com/kernel/common.git # clone the repo 
git branch -a # lists branches, both local and remote 
git checkout -b android-3.0 remotes/origin/android-3.0 # create local branch 
# android-3.0 that tracks the named remote branch