yashsingh1/xdaforums huggingface dataset:
[Samsung Galaxy Nexus] djmatt604:
If you built as a userdebug build, you should see the su binary under /system/bin...this pretty much means the rom would have root capabilities, the Superuser/SU apks don't dictate whether or not you are rooted by themselves...they just act as a front-end for you so that if an app or service asks for root permissions, you have a way to control (and deny, if you didnt initiate it) the request. They make using root 'safer' lol. If you want the apk, throw the rom into dsixda's kitchen and add root that way...that will do the binary, apk, and changes to the install script for you.

To retain custom recovery I would delete the install-recovery files from the rom as well and/or make sure there are no calls to the install-recovery script (may as well do both) from inside your updater-script.

Good luck! Hope this helps.

Sent from my Infamous Tab.
[Samsung Galaxy Nexus] jjhiza:
Thank you very much! I'll give your suggestions a shot, and, with any luck, I'll have a nice, new rooted build up and running by tomorrow! Then I can get to theming it! Thanks again! :):thumbup:
[Samsung Galaxy Nexus] shenye:
go take a look around github. or you'll just have to dev it yourself :P
[Samsung Galaxy Nexus] :
i found krylon 360 sk4g files and the branch but in ther termianl i get a basg syntax error near unexpected token ;;
[Samsung Galaxy Nexus] _Sparks:
can this work for xperia x8?
[Samsung Galaxy Nexus] gferen:
ok im stuck or mayybe not in step 4. as i am trying this for 2.3.7 just need to know step 4 skip or not? or what :o
[Samsung Galaxy Nexus] shenye:
You will need to find the binaries for the device, or the graphics and radio won't work.
[Samsung Galaxy Nexus] gferen:
any tiny clue where to find? :o trying to find but im no smart enough :D
[Samsung Galaxy Nexus] flipper203:
Do you know where I can find a tutorial to compile from android ? (and use eclipse to edit files)?
[Samsung Galaxy Nexus] th3d:
thanks! It's great ;)
[Samsung Galaxy Nexus] MrMakeIt:
Stuck at add-apt-repository

After entering add-apt-repository "deb http://archive.canonical.com/ lucid partner" , I receive an error when I try to enter ' apt-get update ' on the next line. The error reads:

E: Malformed line 55 in source list /etc/apt/sources.list (dist parse)

Any idea why I am receiving the error, or if I could be doing something wrong? Everything seems to have gone very smoothly up to this point.

Thanks!

EDIT --- Figured out my problem. Mistyped a line (forgot .com -- oops). Was able to edit my sources list [ gksu gedit /etc/apt/sources.list ] then re-add with correct info. Hopefully this helps some other sucker like myself down the line :-)
[Samsung Galaxy Nexus] Carsten4207:
Thank You for this post. I've always wanted to learn how to do this.
[Samsung Galaxy Nexus] XAviierG:
Will this work for other devices if I use my source tree and our device proprietary binary?
[Samsung Galaxy Nexus] :
Don't mind. But, How to add other devices? :-/
[Samsung Galaxy Nexus] Carsten4207:
When I do the Repo Sync. It dies here:

Fetching projects: 52% (119/228) error: Cannot fetch platform/external/sqlite

error: Cannot fetch platform/external/sonivox

Any idea? I've tried twice so far.

EDIT: I changed my VirtualBox's network from NAT to Bridged and it seems to be working now.
[Samsung Galaxy Nexus] rayfin:
root@ubuntu:~/ANDROIDSRC/system# make -j1 otapackage

============================================

PLATFORM_VERSION_CODENAME=REL

PLATFORM_VERSION=4.0.3

TARGET_PRODUCT=full_toro

TARGET_BUILD_VARIANT=userdebug

TARGET_BUILD_TYPE=release

TARGET_BUILD_APPS=

TARGET_ARCH=arm

TARGET_ARCH_VARIANT=armv7-a-neon

HOST_ARCH=x86

HOST_OS=linux

HOST_BUILD_TYPE=release

BUILD_ID=IML74K

============================================

frameworks/base/Android.mk:326: frameworks/base/../../system/media/mca/Docs.mk: No such file or directory

No private recovery resources for TARGET_DEVICE toro

make: *** No rule to make target `frameworks/base/../../system/media/mca/Docs.mk'. Stop.

Any help?
[Samsung Galaxy Nexus] RogerPodacter:
Crap I'm just about to setup my build environment and I have to ask is it necessary to have a 64 bit system? Actually all I care about is compiling the kernel and not the full ROM. All previous kernels I use my 32 bit Ubuntu virtual machine with 1.5 gb of ram and now I'm worried ice cream sandwich kernel needs higher resources. Anyone know what the minimum requirements are?
[Samsung Galaxy Nexus] shenye:
Are you sure you have fully synced the source?

Did you use a GMail account? Firewall?
[Samsung Galaxy Nexus] naddie:
Thanks for the tutorial. I'm actually working on setting up my Ubuntu environment in VirtualBox right now.

I currently have a Samsung Vibrant with a FFC mod. Am I able to use the Nexus S binaries? I'm not sure if the Vibrant's hardware is the same as the Nexus S, which is why I'm asking. Also, because if it is, then I won't have to buy a new phone to play around with. :)

The Vibrant is not my daily, of course. If I have to, I will sell it for a Nexus S or a GNexus just for the sole purpose of learning on it.
[Samsung Galaxy Nexus] housry23:
I am a noob to this and pretty much to Ubuntu in general. I've been playing around with Linux Mint, Ubuntu and Android for a couple years now, but have never used Linux on my computer as my main OS. That is exactly what I am trying to do starting a couple days ago. This tutorial is great! I really want to build from source for the Verizon GNex. I followed the tuorial just fine adn everything worked great. I ran into problems when trying to access the ICS_SOURCE folder and all it's subfolders. I enabled root and logged in as root and gave permission to access the root folder to my account. When I logged back into my account I could open the root folder in the file system, but still couldn't access any of the folders inside the root folder. So, I figured I would either have to work from within the root account, or I would have to go through and grant access to each and every folder and file in the ICS_SOURCE directory.

I have a couple questions now. Is there any way to access the ICS_SOURCE folder in the file system without being logged in as root? Also, after I follow the last step and build a flashable .zip, is it stored in the ICS_SOURCE folder or is there another place where it builds to? If it doesn't output what is built inside the ICS_SOURCE folder then I really don't need to access the root folder. Like I said I am new to Ubuntu and Linux in General. I would appreciate any help I could get. Thanks guys and keep the great tutorials coming!
[Samsung Galaxy Nexus] beekay201:
su binary present in userdebug/eng doesnt work with superuser or supersu apk, they supply their own binary. They need the hack.

There are quite a few ways to do this other than a kitchen (which, BTW, won't teach you a thing). I'll drop a few pointers later, on the phone right now.

Include/exclude stock recovery, copying su binary/superuser.apk, removing vendor check, allow copying prebuilts.

If you're building, why would you even use another person's kitchen?

Sent from my i9250
[Samsung Galaxy Nexus] jjhiza:
Good points. I was just eager to give my build a try last night, and figured I'd just give kitchen a go for that sole purpose. I really do want to learn as much as possible though, so any/all information you can provide, would be most appreciated. :thumbup:

As it pertains to kitchen though... Everything ran fine last night, and I got my ota.zip... Something must be wrong though, because when I try to flash it in TWRP, I get a status 6 error (error in data/media/0/ROMs &Gapps).

I did some digging, and comparing, and found that my updater script didn't look anything like other AOSP ROMs available for Toro. I made a few changes (using Notepad++) that seemed logical, but regardless of what I did, I still get the same status 6 error.

Since I'm at an impasse, and clearly not skilled enough to troubleshoot on my own yet, I'll await some feedback from those of you who have been at this longer than I have.

Thank you guys...I know you'll point me in the right direction, and help a Linux and ROM building n00b learn how to build successfully. :)
[Samsung Galaxy Nexus] djmatt604:
The dsixda kitchen was definitely designed to make stuff easier, but not to be used as a long term crutch or to replace actually learning how to do things yourself manually. That's why his scripts and hard work are openly viewable...it was his intention for users of the kitchen to review those scripts to see what they're doing and further the learning process for new ppl....myself included :) he states this in his OP too. His many hours of work has made it possible for folks to really understand what it takes to do everything the kitchen offers in the way of features and options - rooting, init.d support, busybox, kernel unpacking, zipalign, the list goes on.

A status 6 when flashing a kitchen-made rom, especially if it has been signed thru the kitchen, could also mean the signatures and/or update-binary file under META-INF are the wrong ones. I experienced this too. Try swapping in the update-binary and signatures from the otapackage you compiled and see if that helps...that's my contribution. Also, if you have a retouch_binaries call in your script, I think the kitchen nukes it because it doesn't know how to translate that command when converting the script content. Just another possibility...

PS. Hopefully I haven't ruffled any feathers by suggesting use of the kitchen, but I do believe that's what its there for...to teach. :)

Sent from my Infamous Tab.
[Samsung Galaxy Nexus] jjhiza:
I agree... I wasn't looking for a long term, easy out when building ROMs...I was just geeked up to try my build. I'm not sure what happened (kitchen or user error), but I just compiled a fresh build in Eclipse, checked the updater script, and it looks perfect... nothing like the odd stuff I was setting after kitchen got through doing it's thing.

I'm gong to save this build as a base, and run a copy of it through kitchen again, to see if I come up with different results. I do remember seeing a notification in that kitchen alters the updater script, so I'll poke around, and see if I can leave it in tact. I'm certainly looking forward to learning how to push root, busybox, scripts, etc manually though. Thank you for the help! :thumbup:

*BTW... Is there any reason why I would have (what appears to be) a script, called "file_contexts" in the root of my ota.zip? I've never seen that file on any ROM I've run in the past... Does it belong here, or somewhere else? :confused:

--------------------------------------------------

Progress update: So the second build won't flash either, but I'm getting different errors...

Warning: No file_contexts

set_perm some changes not made

status 7 error

As I mentioned before, my file_contexts ARE there... they're just in the root of my zip file for some reason, along with boot.img, META-INF, and system... I've never seen that file there before. I'm also using the latest TWRP for Toro, and I've downloaded the zip twice, just to see if it's bad... I'm at a loss.

If it'll help, I can upload my build later, if anyone wants to take a look at it. :o
[Samsung Galaxy Nexus] beekay201:
You can read about how to do it yourself on the source code of many roms too. :)

what branch are you building?

----

advice: learn what android tree is about, all the different projects, watch rom's github's, see how they do it, adapt it to yourself;

"how to" examples, credits to peteralfonso and cm:

Remove vendor check -

https://github.com/peteralfonso/platform_build/commit/8ecf30ff370326fd7230770bb24c9dbfea5d2cf4

Allow copying prebuilts -

https://github.com/peteralfonso/platform_build/commit/971e805fcbfcaff6e681fbba3308403716ab0f85

Add ability to enable or disable recovery inclusion-

https://github.com/peteralfonso/platform_build/commit/1dc37ddca903358f6915f4457f800c9f76fff5ea

insecure, deodexed, user build -

https://github.com/peteralfonso/platform_build/commit/204cd1662bb25d212ce35b5efa49eccf3b50d03e

add oc-

https://github.com/CyanogenMod/andr...mmit/4a361cc1b994c05322aa7c6ca1d6c4be6cf0e23e

gpu oc-

https://github.com/CyanogenMod/andr...mmit/32080d8b7fd838692407078fe5b1ac0e1e11ea5b

kernel config-

https://github.com/CyanogenMod/andr...mmit/4c1362892b3161bc7e48492b6c08a0a790a95be0

customize included apps, etc-

https://github.com/CyanogenMod/android_build/commit/112ae682d4ad581c7524faafbe186a216ca2edb3

init.d permissions-

https://github.com/CyanogenMod/android_system_core/commit/af1ea6604fa4cb929e30a59b3b7da5ed70862416

Disable Pinyin and Openwnn IME's by default-

https://github.com/CyanogenMod/android_build/commit/02167af01998d7b881c8bb73f0bd0cbed1c10b1e

Dont build certain apps-

https://github.com/CyanogenMod/android_build/commit/4cac7eee02422417d86237269f9bab226d90f582

"boost" cpu:

https://github.com/CyanogenMod/andr...mmit/e943a896aa113708294da9d18f8973f390e6ed10

https://github.com/CyanogenMod/andr...mmit/1d96fbc43ef01cd765a79e24c220960b371ac03a

new vendor:

https://github.com/peteralfonso/platform_vendor_pete

https://github.com/CyanogenMod/android_vendor_cm

;)
[Samsung Galaxy Nexus] jjhiza:
I'm trying to get a full toro 4.2.1 AOSP build. Repo sync went fine, and the compile was fine as well. My plan was to get a simple, functioning ROM, that I could further modify, as my knowledge and skill increased. I'll go through your recommended reading though, and try to assimilate it all, before I go any father. Thank you very much. :)
[Samsung Galaxy Nexus] djmatt604:
I agree, thanks a ton for putting this all together!

Sent from my Infamous Tab.
[Samsung Galaxy Nexus] beekay201:
No, I mean, what branch are you building?

When you started the repo for the first time did you:

repo init -u https://android.googlesource.com/platform/manifest

or

repo init -u https://android.googlesource.com/platform/manifest -b android-4.2.1_r1

it has been explained here, but the "-b" parameter defines the branch you want to build from. In this case, android-4.2.1_r1 is a release tag, which is a mark in development history.

If you went with the first command, you didn't specify any branch/release tag, and you're then building from aosp's master branch (gerrit here). Way more experimental. I got those "status 7" errors; flashed with fastboot after building, done.

fastboot flashall -w

note: "-w" wipes userdata.
[Samsung Galaxy Nexus] jjhiza:
I want to say that I'm building from the release tag of 4.2.1_r1, but I honestly can't remember, and I'm not near my computer at the moment. Of it turns out that I'm building from the master branch, is out safe for me to simply delete those files, and sync the release tag repo instead?

I have a build that flashes with only the "No file_contexts" warning, but it appears to be hanging on a black screen (I forgot to put in a boot animation last night). Hopefully this signifies some progress, and I've got two more builds (both with boot animations), one signed and one unsigned, and one bare bones build that hasn't been touched by the kitchen (just has root and the boot animation). Hourly one of these works... I'm going to test now.

Thank you again for being patient, and helping me out with this. I'm really excited to *fingers crossed* get a build up and running. :)

Update: Well, that was interesting... The two builds run through kitchen simply didn't flash (status 6), but I must have forgotten to remove the recovery folder from the "untouched" build, because I've managed to nuke TWRP :rolleyes:. I'll try to flash TWRP when I get home, but it looks like I'm soft-bricked for the next few hours. Trial and error I guess...And once I get the phone up and running again, I'll check to see what branch my builds are from, and re-sync if I need to.
[Samsung Galaxy Nexus] beekay201:
(may or may not be related to some issues)

I didn't notice there was a new file needed:

http://review.cyanogenmod.org/#/c/27027/2/extract-files.sh

confirmed here:

https://android.googlesource.com/device/samsung/maguro/+/android-4.2.1_r1/proprietary-blobs.txt

/system/lib/libdrmdecrypt.so

(been going at this because i'm starting fresh)
[Samsung Galaxy Nexus] beekay201:
Me again;

for some real time discussion, created #aosp-building@irc.freenode.net

I'll be dropping by everyday, nickname k201; feel free to join in and identify yourselves, be helped (hopefully! ;)) and help others!
[Samsung Galaxy Nexus] jjhiza:
Awesome addition to an already very helpful thread/community... Thank you!!

Quick question... You mentioned that I need to verify which branch in building from. I've spent some time tearing through my file system, looking, but I'm not finding any info. It's there a command line I can enter that will locate which branch I synced with?

Sorry for all the noob questions... I'm 100% new to command line, Linux, and ROM building. I really appreciate all the help you guys are giving me. :o
[Samsung Galaxy Nexus] djmatt604:
Think back to when you downloaded your source. If you followed a guide, look at it again. When you did your repo init statement, what was it? Did it have a -b in it followed by some other stuff, like '-b android-4.2.1_r1' or something like that? If it does you didn't sync the master branch.

Sent from my Infamous Tab.
[Samsung Galaxy Nexus] beekay201:
either what djmatt604 suggested, or just look in $ANDROID_BUILD_TOP/.repo/manifest.xml for:

tango% cat .repo/manifest.xml | head
<?xml version="1.0" encoding="UTF-8"?>
<manifest>

<remote name="aosp"
fetch=".."
review="https://android-review.googlesource.com/" />
<default revision="refs/tags/android-4.2.1_r1"
remote="aosp"
sync-j="4" />

notice default revision="refs/tags/android-4.2.1_r1"

which relates to repo init, like djmatt604 stated:

repo init -u https://android.googlesource.com/platform/manifest -b android-4.2.1_r1
[Samsung Galaxy Nexus] jjhiza:
Thanks guys. I'm confident that I synced from the 4.2.1_r1 tag, now that I've gone back, and mirrored the steps I took during setup. I just start second guessing myself, since I'm new to all of this. I'm going to double and triple check to make sure I've done everything right, and I'll try compiling another build this evening. The builds I make will flash, but won't boot, so there must be something I'm missing. Hopefully I'll get it sorted out. :)
[Samsung Galaxy Nexus] mbroeders:
One tip, perhaps it will help others, it certainly has given me some headaches! With recent builds, I wasn't able to use wifi and mobile networks to find my location, instead, I had to enable GPS. After a lot of searching, I found that you have to add a line to frameworks/base/core/res/res/values.xml. By default it's:

<string-array name="config_locationProviderPackageNames" translatable="false">
<!-- The standard AOSP fused location provider -->
<item>com.android.location.fused</item>
</string-array>

And you have to change it to:

<string-array name="config_locationProviderPackageNames" translatable="false">
<!-- The standard AOSP fused location provider -->
<item>com.android.location.fused</item>
<!-- The Google provider -->
<item>com.google.android.location</item>
</string-array>

You can of course create an overlay folder in your vendor tree, but if not, then this will do.
[Samsung Galaxy Nexus] beekay201:
good find :)

edit: wait, please share your line of thought to debug that. :)
[Samsung Galaxy Nexus] rasengan82:
Looks like this is only for 4.2. In 4.1.2, config_locationProviderPackageNames does not exist.
[Samsung Galaxy Nexus] svprm:
During synchronising of source, terminal get closed.

I sync it again. It goes well.

But I have doubt about that.

Does my source get corrupted?
[Samsung Galaxy Nexus] rasengan82:
I believe repo sync will start from where it left so you should be safe.
[Samsung Galaxy Nexus] svprm:
Thanks.

Let you know when I finished downloading.
[Samsung Galaxy Nexus] beekay201:
Also building right now.
[Samsung Galaxy Nexus] svprm:
I have slow internet around 60KB/s.

So i will download the source in the night and stop it in the morning(By closing the terminal).

Each time i start the sync in the night it will resume from where it stopped.

I did like this for 3 days.

Day before yesterday i started the sync,it show a progress from

Console:

Fetching Projects:0% (1/293) to Fetching Projects:99% (290/293)

Then it started download two projects and showed a progress like below

Console:

Receiving Objects: 1%(120/25998)
Receiving Objects: 1%(680/658998)

In the morning when i see

It stopped at 85% it downloaded around 450MB both.

But it does not show any error.

Yesterday i did the same.

Same problem but at 80%.

How to download the source completely?

How to know the status of my download?
[Samsung Galaxy Nexus] creeve4:
Where is "THIS GUIDE" ???
[Samsung Galaxy Nexus] MBQ_:
Try clicking on those words.
[Samsung Galaxy Nexus] creeve4:
There is no link...
[Samsung Galaxy Nexus] Deadly:
Search "guide Ubuntu" as thread titles in advanced search... you will get many... or try Googling.. there are many guides for this..

____________________________________

Falling Doesn’t Make You a Failure, Staying Down Does
[Samsung Galaxy Nexus] masteroftime666:
some one please help. I am trying to compile android from source on Ubuntu 12.04 64 bit. I am using sun jdk 6. During the compile process it unsuccessful stops here.

make: *** No rule to make target `out/host/common/obj/JAVA_LIBRARIES/mockwebserver-hostdex_intermediates/javalib.jar', needed by `out/host/common/obj/JAVA_LIBRARIES/core-tests-hostdex_intermediates/classes-full-debug.jar'. Stop.

make: *** Waiting for unfinished jobs....

host Java: sqlite-jdbc-host (out/host/common/obj/JAVA_LIBRARIES/sqlite-jdbc-host_intermediates/classes)

Note: external/eyes-free/AccessCheck/src/com/android/accessibility/AccessibilityValidationContentHandler.java uses or overrides a deprecated API.

Note: Recompile with -Xlint:deprecation for details.

Note: Some input files use or override a deprecated API.

Note: Recompile with -Xlint:deprecation for details.

Note: Some input files use or override a deprecated API.

Note: Recompile with -Xlint:deprecation for details.

Note: Some input files use unchecked or unsafe operations.

Note: Recompile with -Xlint:unchecked for details.

Note: Some input files use unchecked or unsafe operations.

Note: Recompile with -Xlint:unchecked for details.

Note: Some input files use unchecked or unsafe operations.

Note: Recompile with -Xlint:unchecked for details.

Note: Some input files use or override a deprecated API.

Note: Recompile with -Xlint:deprecation for details.

Note: Some input files use unchecked or unsafe operations.

Note: Recompile with -Xlint:unchecked for details.

Note: Some input files use or override a deprecated API.

Note: Recompile with -Xlint:deprecation for details.

Note: Some input files use unchecked or unsafe operations.

Note: Recompile with -Xlint:unchecked for details.
[Samsung Galaxy Nexus] beekay201:
people need to provide more information:

- have you built sucessfully before?

- what branch/release tag are building against?

- did you try to 'make clean' or 'rm -rf out/', from the root of the build tree?
[Samsung Galaxy Nexus] masteroftime666:
Thanks for the response I have not built successfully. i did try rm -rf out. I freshly installed ubuntu 12.04 on a parition (grub main bootloader). Then installed make 3.82. Downloaded all the required packages. When i did repo sync it successfuly synced the master branch. Then i followed the building process, source build/envsetup.sh then lunch then make -j8. When i used openjdk it gave me error

Your version is: java version "1.6.0_24".

The correct version is: Java SE 1.6.

so i download sun jdk instead. With sun jdk it gave me that error instead.
[Samsung Galaxy Nexus] masteroftime666:
It was an error in the repo

"Until it gets fixed in AOSP, you can rename mockwebserver-hostdex to mockwebserver-host in libcore/JavaLibrary.mk (line 155). It got changed in mockwebserver n Change-Id: I0853a728ca8ff8a5ca43f15fc83656304bc822a1 but it was not changed here." -Alexandre Dumont

anyone seeking info go here: https://groups.google.com/forum/?fromgroups=#!topic/android-building/o8Qg4CVrN70