Reputation: 34833
If I download a project from https://android.googlesource.com to what Android API version will it be compatable ?
I have cloned a project.
Then created a project in Eclipse
in that name with its res
, src
and manifest.xml
, but still its shows error with some variables declaration missing , some functions arguments changed/not correct etc.
Any idea?
I'm using sdk_r08
, and android 2.3
project working well.
Does the project from https://android.googlesource.com need any dependent files? If so what do I need to get those files?
Is there any extra arguments that I can set in git clone
to get the project in a specific version?
Upvotes: 2
Views: 2256
Reputation: 1603
Actually you cannot load only a single project into eclipse since the whole OS tree is mutually dependent, you have to checkout the whole source code, make a compile and then copy the .classpath in the root folder of the build and create a java project using this classpath. and ONLY then will you be able to load a project. however note that the AOSP compiles only on 64bit Ubuntu 10.04 (version and distro is mostly because of library versions and dependencies, I've seen people do it on fedora and suse) the compile is horrific however you ARE compiling an OS from scratch so ... it takes about 5 hours on a dualcore pentium u 3gigs of ram.. and about 20 mins on i7 with running
make -j16
after importing everything in eclipse you can work with individual applications like, Launcher, Contacts, Calendar, Phone.. etc.. however to actually install anything on a real device (without flashing the whole rom) you have to refactor/rename the project package declaration since most of them are com.android.* which means the device will not override the default app installed
in short, after setting up the workstation:
(don use -b gingerbread
since it is the bleeding edge branch, numbered versions are production branches so bugs are minimal)
repo init -u https://android.googlesource.com/platform/manifest -b android-2.3.4_r1
repo sync
. build/envsetup.sh
lunch 1
make -j8
most of the flags I am using are explained in the tutors below...
More info on the subject:
Workstation setup : http://source.android.com/source/initializing.html
Downloading source ; http://source.android.com/source/downloading.html
Building : http://source.android.com/source/building.html
and most important.. howtos...
http://www.youtube.com/watch?v=1_H4AlQaNa0
http://www.youtube.com/watch?v=rFqELLB1Kk8
Upvotes: 1
Reputation: 47672
You need to use the repo
tool , then you can use the -b
parameter to checkout a specific branch, see repo documentation for examples.
Upvotes: 1