Search code examples
androidandroid-sourceandroid-build

How to build an Android version?


I upgraded my phone and would now like to begin breaking my old one.

I went and pulled the Android Source and and synced it. All was swell. Next up was to run:

envsetup.sh

I think this went ok; nothing was displayed so I assume no errors occurred. Now I'm stuck on `lunch'. What do I have to do here? The docs say to

Choose which target to build with lunch. The exact configuration can be passed as an argument, e.g.

by running

lunch full-eng

I did this, but it tells me full-eng doesn't exist. So I tried just lunch and get

No such file: /home/andrew/.lunchrc.

What do I have to do to get this to build? Did I fail to download the appropriate resources?


Solution

  • First a control question, when you said you ran envsetup.sh, you really meant source build/envsetup.sh right? If not, that is likely the cause of your problems.

    If that doesn't solve your problem, that is probably because another lunch (in your case it looks like http://code.sat.qc.ca/trac/lunch) is invoked. Try uninstalling the other lunch or at least remove it from your PATH to ensure that it is lunch from Android that is run.