How to get RC30 source code from git? - G1 Android Development

Hi,
In the android git repository, there are three branches/tags. The default one is master. cupcake is the most famous. The last one is release-1.0 but which is not the RC30 release (it can't be compiled at all).
I doesn't know git well, so I must miss some tags for RC30. Is there anyone can tell me how to get the RC30 source code? Big thanks!
Sunner

Try:
repo init -u git://android.git.kernel.org/platform/manifest.git -b release-1.0

jashsu said:
Try:
repo init -u git://android.git.kernel.org/platform/manifest.git -b release-1.0
Click to expand...
Click to collapse
I've tried this command before. There were some error like "nowhere" when "repo sync". And I've mentioned in the first post that the release-1.0 can't be compiled at all. So many .c files in it miss including some header files.

Can't compile? Hmm... Well I am not working with the release-1.0 branch anymore so I can't be of much help there.
As for the source code used to produce G1 Android builds RC19-RC30, those were never made public. All Android platform development prior to cupcake was divided between openly available and private internal branches. The reasons for this are manifold and infinitely debatable in merit. One reason you can not build a true RC30 from the public repo is that they can not legally distribute proprietary modules from there.

Related

AOSP guide?

Can some one please point me to a complete guide that takes you through all the steps of making a final update.zip from the AOSP code? I ran the make command at the end of the AOSP website guide, but i have no idea where to go from here. Anyone wanna lend a hand?
http://wiki.cyanogenmod.com/index.php/Compile_for_dream
http://forum.xda-developers.com/forumdisplay.php?f=613
Use search next time.
I started from scratch and did not source cyanogen's repositories. what build target should i specify? Every target from the lunch menu seems to be eclair. So what do i do to select donut?
You do
source build/envsetup.sh
lunch
Click to expand...
Click to collapse
Then select dream-open (eng or userdebug).
Don't forget when you do repo init to set the branch to donut:
repo init git://android.git.kernel.org/platform/manifest.git -b donut
Click to expand...
Click to collapse
kingkurry said:
I started from scratch and did not source cyanogen's repositories. what build target should i specify? Every target from the lunch menu seems to be eclair. So what do i do to select donut?
Click to expand...
Click to collapse
you should probably download the donut branch and not the eclair branch
Eclair is very broken for build. Currently, Master is a snapshot of 2.1r1, so you'd best build master (donut stock is very broken too).
Unfortunately, at this time, there's no way to switch branches once you've synced a repository.
Unless there's a better way to do it that I don't know about, I keep different branches downloaded on different directories. It's redundant because the whole information for all branches/commits is downloaded to .repo anyway, so I don't see why branch switching is not possible. Anyway, if you want donut, create another directory, cd to it, and repo init -u git://android.git.kernel.org/platform/manifest.git -b donut (I suggest donut-plus-aosp instead, builds a bit better than donut).
Thanks for all of the help guys . Its been a long time since i started, but im going to start building and try and learn this stuff.
Also, will the make otazip command only work when sourcing cyanogen, or will it work on AOSP?

Want dream/sapphire proprietary files

In all tutorials I found this lines:
cd ~/android/system/device/htc/dream_sapphire/
./extract-files.sh
But i haven't ANY files in this directory(including this scipt). Can you upload for me all folder? I think about /android/system/device/htc/dream-sapphire/.
Thanks!
The command "extract_files.sh" will extract those files from your phone, but you need to have the phone connected via USB with your PC.
Before trying, you should check whether your adb connection with your phone is working.
Sent from my Gingerbread on Dream using XDA
ADB working for me, If I navigate to platform-tools:
[email protected]:~/sdk/platform-tools$ ./adb devices
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
List of devices attached
But if I am In dream_sapphire folder, terminal show only that extract-files.sh not found:
bash: ./extract-files.sh: No such file or directory
From which sources do you want to build? For ezGingerbread for example the "extract-files.sh" is located in "~android/device/htc/sapphire".
Btw. adb devices should give you a list of connected devices. If that is empty (as you posted) something is not working correctly.
CyanogenMod sources. List of devices is not empty, my phone is present here but I found no need to paste this line.
Sorry, but I'm green in this. I want to learn some about building android. I follow this:
http://wiki.cyanogenmod.com/wiki/HTC_Dream_&_Magic:_Compile_CyanogenMod_(Linux)
But i type
repo init -u git://github.com/CyanogenMod/android.git ics
instead of
repo init -u git://github.com/CyanogenMod/android.git -b froyo-stable
dream/sapphire is not supported by CM7/CM9 and that's the reason you do not have the directory/files you are expecting. If you only want to get the proprietary files, you can also switch to an older release (e.g. CM6) for that project, but nevertheless you need to change several other things, too, before you will get a build. If you are not familiar with building from sources, I suggest you to start with something easier, i.e. CM6 or ezGingerbread.
Or you could run repo init from anddisa's or my git repos. I don't know his from memory but for mine you would run
Code:
repo init -u https://github.com/tvall43/android.git -b ics-ds
AndDiSa's might be a little better right now but I hope to eventually get mine running something close to stable if possible.
The latest version of cm with the dream/sapphire stuff is cm7 (even though they dropped support). Anything past that you'll have to port yourself (like AndDiSa and I) or wait for someone to.
Also, I'm half asleep. I could have (and likely did) post errors that I didn't notice. Google is your friend.
tvall said:
Or you could run repo init from anddisa's or my git repos. I don't know his from memory but for mine you would run
Code:
repo init -u https://github.com/tvall43/android.git -b ics-ds
AndDiSa's might be a little better right now but I hope to eventually get mine running something close to stable if possible.
The latest version of cm with the dream/sapphire stuff is cm7 (even though they dropped support). Anything past that you'll have to port yourself (like AndDiSa and I) or wait for someone to.
Also, I'm half asleep. I could have (and likely did) post errors that I didn't notice. Google is your friend.
Click to expand...
Click to collapse
OK, I just downloaded your repo. But...
Command:
lunch cyanogen_dream_sapphire-eng
Returns:
[email protected]:~/android/system$ . build/envsetup.sh
including device/htc/dream_sapphire/vendorsetup.sh
including vendor/cm/vendorsetup.sh
[email protected]:~/android/system$ lunch cyanogen_dream_sapphire
Invalid lunch combo: cyanogen_dream_sapphire
[email protected]:~/android/system$ lunch cyanogen_dream_sapphire-eng
vendor/htc/dream_sapphire/dream_sapphire-vendor-blobs.mk:46: *** missing separator. Stop.
Device dream_sapphire not found. Attempting to retrieve device repository from CyanogenMod Github (http://github.com/CyanogenMod).
Found repository: android_device_htc_dream_sapphire
Adding dependency: CyanogenMod/android_device_htc_dream_sapphire -> device/htc/dream_sapphire
Traceback (most recent call last):
File "build/tools/roomservice.py", line 170, in <module>
add_to_manifest([{'repository':repo_name,'target_path':repo_path}])
File "build/tools/roomservice.py", line 121, in add_to_manifest
f = open('.repo/local_manifest.xml', 'w')
IOError: [Errno 2] No such file or directory: '.repo/local_manifest.xml'
vendor/htc/dream_sapphire/dream_sapphire-vendor-blobs.mk:46: *** missing separator. Stop.
** Don't have a product spec for: 'cyanogen_dream_sapphire'
** Do you have the right repo manifest?
And next, command:
[email protected]:~/android/system$ mka bacon
Returns:
make: *** No rule to make target `bacon'. Stop.
How to fix this?
Anybody can't help me?
blaster44 said:
Anybody can't help me?
Click to expand...
Click to collapse
Only CM uses the "make bacon" command. Unless they use the CM repo tool in their repo, it will be unavailable. Same goes for AOSP.
Sent from my HTC PH39100 using Tapatalk 2

Cherry-Picking From Github

how do i cherry pick a single commit from a github source? like get a certain commit from aokps settings app and get it into cm10.1
i tried this and seemed to break my build
cd ~/android/system/frameworks/base
git fetch https://github.com/AOKP/packages_apps_Settings.git && cherry-pick 8b7e06fe63939730067b539ca7343fcd8e68ad01 FETCH_HEAD
is that the right way to do it? and how do i know if it cherry picked correctly? sorry im still getting the hang of thins with github
azoller1 said:
how do i cherry pick a single commit from a github source? like get a certain commit from aokps settings app and get it into cm10.1
i tried this and seemed to break my build
cd ~/android/system/frameworks/base
git fetch https://github.com/AOKP/packages_apps_Settings.git && cherry-pick 8b7e06fe63939730067b539ca7343fcd8e68ad01 FETCH_HEAD
is that the right way to do it? and how do i know if it cherry picked correctly? sorry im still getting the hang of thins with github
Click to expand...
Click to collapse
I'd go to their gerrit. Anything and find what you want.
http://gerrit.sudoservers.com/#/q/status:open,n,z
Click on it, note the Project listed. cd to that in your tree. then in the download section you see a cherry-pick tab. click that and select the command there. That is the command you use. If it comes in without needing to merge anything you are good.
thanks, and how would i know if merging is needed?
azoller1 said:
thanks, and how would i know if merging is needed?
Click to expand...
Click to collapse
it'll tell you. Not sure if you use UI or command line but in command line i installed vimdiff, then set it as git mergetool with,
git config --global merge.tool vimdiff
if using UI I'd use meld.
so it'll report something needs to be merged then just
git mergetool and it'll open up. manually fix the merge
then
git status
This will show you the .orig files. delete them
Then:
git add -A
git commit -a
Control+X(nano) or :wq (vim)
And you're done.
git remote add -f repo.git then git cherry pick commit id
so basically just get the branch i want a cherry pick from, then picks it from the branch when i enter the commit, and i need to cd in the right directory before doing
git remote add -f repo.git?
see if it help!http://forum.xda-developers.com/showthread.php?p=23527685#post23527685
yeah i saw that guide, but still confused using github, gerrit is pretty easy
I always use this thingy as reference for cherry-picking:
http://stackoverflow.com/questions/...ctively-pull-merge-changes-from-anothers-fork
sorry forgot about this i will give a better example. if you want tp cherry pick a framwork base commit be in the framework folder then
git remote add paranoid(name is irrlefvent) -f [email protected]aranoidAndroid/android_frameworks_base.git
wait for it to download
then git cherry pick the commit id: git cherry pick f9cedfe79cc1d545b920f93539a0843d02819fe6
FYI, if you are looking at a specific commit on github, you can get it in patch format by adding .patch to the URL.
For example:
https://github.com/CyanogenMod/andr...mmit/e8ba824b16a3575d9a4c5d85dce6d3800970d093
becomes
https://github.com/CyanogenMod/andr...8ba824b16a3575d9a4c5d85dce6d3800970d093.patch
If you download that .patch file, it can be applied using:
Code:
git am <patchfile>.patch
FYI, on your own machine, if you want to export such a patch for distribution, use
Code:
git format-patch
For example:
Code:
git format-patch HEAD~3
Would output the last 3 patches you committed in "git am" committable form.
FYI, this is why any developer who tells you that releasing source code for test kernels is not feasible is full of BS. It's understandable that you don't want to push test commits to a public repo, but it's perfectly feasible to meet the requirements of the GPL by providing formatted patches.
As an example: http://forum.xda-developers.com/showpost.php?p=22925793&postcount=339
Entropy512 said:
FYI, if you are looking at a specific commit on github, you can get it in patch format by adding .patch to the URL.
For example:
https://github.com/CyanogenMod/andr...mmit/e8ba824b16a3575d9a4c5d85dce6d3800970d093
becomes
https://github.com/CyanogenMod/andr...8ba824b16a3575d9a4c5d85dce6d3800970d093.patch
If you download that .patch file, it can be applied using:
Code:
git am <patchfile>.patch
FYI, on your own machine, if you want to export such a patch for distribution, use
Code:
git format-patch
For example:
Code:
git format-patch HEAD~3
Would output the last 3 patches you committed in "git am" committable form.
FYI, this is why any developer who tells you that releasing source code for test kernels is not feasible is full of BS. It's understandable that you don't want to push test commits to a public repo, but it's perfectly feasible to meet the requirements of the GPL by providing formatted patches.
As an example: http://forum.xda-developers.com/showpost.php?p=22925793&postcount=339
Click to expand...
Click to collapse
If using this method to patch, which folder in my source do I download the patch to? Also when adding commits to my source do I need to add every single commit individually or can I just choose the commit from the major header? For example there are many commits within the Frameworks folder (Frameworks/Base..etc) do I need to go into the Frameworks folder and add each element individually or can I just add the commit from the Frameworks folder? One more thing, how to I apply a patch that I have downloaded as xxx.patch? Sorry if this is hard to understand I'm new at this and still learning the jargon.
Thanks!
The truth is already out there: http://wiki.cyanogenmod.org/w/After_You_Build
http://wiki.cyanogenmod.org/w/Doc:_...building_a_patch_submission_already_on_Gerrit
Sent from my Nexus 7 using xda premium
i want this commit: https://github.com/CyanogenMod/andr...mmit/d1f1fb4064bfcef528a12a4c5176df7b44ffd48c
you need two things, the url to the main project and the commit id, both you just copy out of your browser
the branch i always use is called "jellybean"
my remote to my git is called "github"
that might differ from your configuration-
cd aosp
cd packages/app/Settings
git checkout jellybean
git remote add cyan https://github.com/CyanogenMod/android_packages_apps_Settings
git fetch cyan
git cherry-pick d1f1fb4064bfcef528a12a4c5176df7b44ffd48c
done.
in case it conflicts, you run:
grep -r "<< HEAD" .
and fix all the files it spits out. search for "<< HEAD" in these files and you should see what to do.
when you're done fixing your files you can test if it builds, if it does you go:
git add --all
git commit --all
in the end you push it up to your git
git push github jellybean
Entropy512 said:
FYI, if you are looking at a specific commit on github, you can get it in patch format by adding .patch to the URL.
For example:
https://github.com/CyanogenMod/andr...mmit/e8ba824b16a3575d9a4c5d85dce6d3800970d093
becomes
https://github.com/CyanogenMod/andr...8ba824b16a3575d9a4c5d85dce6d3800970d093.patch
If you download that .patch file, it can be applied using:
Code:
git am <patchfile>.patch
FYI, on your own machine, if you want to export such a patch for distribution, use
Code:
git format-patch
For example:
Code:
git format-patch HEAD~3
Would output the last 3 patches you committed in "git am" committable form.
FYI, this is why any developer who tells you that releasing source code for test kernels is not feasible is full of BS. It's understandable that you don't want to push test commits to a public repo, but it's perfectly feasible to meet the requirements of the GPL by providing formatted patches.
As an example: http://forum.xda-developers.com/showpost.php?p=22925793&postcount=339
Click to expand...
Click to collapse
i think this is the easiest way to pick a commit from someone and add it into your own source, but instead i used this command line in my root source
patch -p1 < ./patch
seems to fail a lot when adding the patch but its really easy to fix it
Entropy512 said:
FYI, if you are looking at a specific commit on github, you can get it in patch format by adding .patch to the URL.
For example:
https://github.com/CyanogenMod/andr...mmit/e8ba824b16a3575d9a4c5d85dce6d3800970d093
becomes
https://github.com/CyanogenMod/andr...8ba824b16a3575d9a4c5d85dce6d3800970d093.patch
If you download that .patch file, it can be applied using:
Code:
git am <patchfile>.patch
FYI, on your own machine, if you want to export such a patch for distribution, use
Code:
git format-patch
For example:
Code:
git format-patch HEAD~3
Would output the last 3 patches you committed in "git am" committable form.
FYI, this is why any developer who tells you that releasing source code for test kernels is not feasible is full of BS. It's understandable that you don't want to push test commits to a public repo, but it's perfectly feasible to meet the requirements of the GPL by providing formatted patches.
As an example: http://forum.xda-developers.com/showpost.php?p=22925793&postcount=339
Click to expand...
Click to collapse
FYI, you use a lot of `FYI` in your post lol.
Sent from my Nexus 7 using Tapatalk 4

[Script] repo-mm: gerrit-mirror.sh - Gerrit project mirroring script [06/30/2013]

Hello xda,
I had a little time on my hands the other night, and wanted to figure out a way that I could work on any of the project repositories needed to build say, aokp, cyanogenmod, aosp, etc... without having to connect to the internet.
Mirroring is not new. Simple enough to:
Code:
mkdir cm-mirror
cd cm-mirror
repo init -u git://github.com/CyanogenMod/android.git -b cm-10.1 --mirror
repo sync -j[dl-jobs]
then create a working directory:
Code:
cd ..
mkdir cm-work
cd cm-work
repo init -u file:///Volumes/Android/cm-mirror/CyanogenMod/android.git --reference /Volumes/Android/cm-mirror/ -b cm-10.1
repo sync # no jobs needed. super fast.
But at this point you only have what you need for cm-10.1. What if you also have work you are doing for 10.1.0? Or an old update to make for cm-7.2.0?
I originally started looking for a solution to sync every branch in the manifest one at a time, but while talking with cdesai he showed me a really clean way of getting the repositories directly from gerrit.
Anyways, here is the resulting script. Let me know your thoughts.
I've moved the script to a git repository here: https://github.com/bhundven/repo-mm
in case anyone wants to contribute.
I've also written a post on my blog about using the new gerrit-mirror.sh on gh.
ChangeLog
Changes:
[06/30/13]: Announce some updates to gerrit-mirror.sh, and blog post.
[06/24/13]: Moved gist to github project.
GitHub for repo-mm.

Building a rom...

i' m following a guide to try builiding my first rom and i don't understand a step
"6. After the repo sync finally finishes, all you need to do is add your device, kernel, vendor specific files for the device you are building for."
Where can i find these things? Is there a command i should give in the terminal?
I've searched a little but not found anything...any hint would be accepted!
tylpica wives
phoenixita said:
i' m following a guide to try builiding my first rom and i don't understand a step
"6. After the repo sync finally finishes, all you need to do is add your device, kernel, vendor specific files for the device you are building for."
Where can i find these things? Is there a command i should give in the terminal?
I've searched a little but not found anything...any hint would be accepted!
Click to expand...
Click to collapse
What rom are you building? If CM10.1 or CM10.2 just follow the instructions on
wiki.cyanogenmod.org - w - Build_for_ville
(sorry, cannot post the link since I don't have enough posts Just replace - with /)
I guess your point 6 refers to items 2.7-2.9 where prebuilt apps, device-specific code (e.g. kernel etc.) and other
proprietary drivers are copied to your source code.
To init for CM10.1, use
repo init -u git://github.com/CyanogenMod/android.git -b cm-10.1
for CM10.2 use
repo init -u git://github.com/CyanogenMod/android.git -b cm-10.2
Hope this helps. good luck
drkxyz said:
What rom are you building? If CM10.1 or CM10.2 just follow the instructions on
wiki.cyanogenmod.org - w - Build_for_ville
(sorry, cannot post the link since I don't have enough posts Just replace - with /)
I guess your point 6 refers to items 2.7-2.9 where prebuilt apps, device-specific code (e.g. kernel etc.) and other
proprietary drivers are copied to your source code.
To init for CM10.1, use
repo init -u git://github.com/CyanogenMod/android.git -b cm-10.1
for CM10.2 use
repo init -u git://github.com/CyanogenMod/android.git -b cm-10.2
Hope this helps. good luck
Click to expand...
Click to collapse
I'm trying to build another rom not CM but i'm trying following the 2.7-2.9 steps from your link
What
Building from source or MOD ROM?
xdluisssxd said:
Building from source or MOD ROM?
Click to expand...
Click to collapse
i think i'm building it from source lol

Categories

Resources