yashsingh1/xdaforums huggingface dataset:
[Nexus 7 Android Development] .torrented:
Yeah Linux doen't use MTP it does use FTP(picture transfer)

im testing this right now but you might be able to use adb sideload with CWM... ill edit this when I know for sure

It works here what you need to do:

sudo gedit /etc/udev/rules.d/51-android.rules

Copy and Paste the below into the file when it opens up and replace username with your linux username.

# adb protocol on grouper (Nexus 7)
SUBSYSTEM=="usb", ATTR{idVendor}=="18d1", ATTR{idProduct}=="d001", MODE="0600", OWNER="username"

1) Save that and then run this : " sudo service udev restart " (no quotes"")

1a) If you need to wipe your ROM data and Cache make sure you do that before you continue

2) Plug in your tablet and boot into CWM recovery and click on "Install zip from sideload"

3) Open a terminal (or just use the one that was already open) change directory to where your ROM is

(mine for example was "cd Downloads/")

4) Type in this: "abd sideload your-rom.zip"

5) Watch as your ROM is flashed to your tablet via adb sideload and CWM :)

edit* I just successfully Flashed a ROM and Gapps to my tablet without any issues via adb sideload
[Nexus 7 Android Development] EnemyOfGlaDOS:
cool.. I was just trying something else I was reading but didn't work. I'll give this a go. I have to flash recovery back to the device though because I got an android with a red exclamation everytime I tried booting to recovery.

*edit* reflashed recovery.img and am now making a backup. I'll do my wipes and then try the above commands
[Nexus 7 Android Development] sparksco:
Sideload is super slow IMO.

---------- Post added at 02:46 AM ---------- Previous post was at 02:44 AM ----------

Airdroid is good, simple and easy to use. Transfer time is super fast. I just prefer to load it onto a USB flash drive and flash it in twrp.
[Nexus 7 Android Development] EnemyOfGlaDOS:
I could not figure out how to get files from my computer to my device. I could get files from my device just fine, but couldn't figure out the other way around :(

on another note..

I'm running an OS I built myself from source!!

Just another big thank you to .torrented and also sparksco for helping me get through the little bumps I encountered! This is truly a great day for me, words can't describe how happy I am!! :silly::laugh::p:cool:

fattire, another thanks for this thread. This is really something that anyone can do. The end result and knowing you put this together is really really cool. Thanks for this oppertunity! I plan to get more practice and update when I feel the need! Thanks :)
[Nexus 7 Android Development] sparksco:
It is simple, you just drag the files into your browser.
[Nexus 7 Android Development] .torrented:
I gotta disagree... I think it went pretty quick... From the time it took for the rom to get loaded to the device was about the time it would normally take to copy over in windows, plus you are already booted into the recovery so you dont got to worry about copying the files THEN booting into recovery, then it automatically flashes it without me having to click any buttons... idk I personally enjoy doing it that way... but to each his own i guess
[Nexus 7 Android Development] doctapeppa:
woot woot!

At the build step. Just did "brunch grouper" and there is a bunch of text flying by real fast, Seems normal. Hope I did everything alright. This thread rocks. Sub'd.

peppa
[Nexus 7 Android Development] EnemyOfGlaDOS:
Yep, normal. When the build finishes you'll see CM-blahblah-unnofficial.zip and a md5 at the very end! Your almost there!

<sent from my quad-core S3>
[Nexus 7 Android Development] fattire:
Congratulations!

(my eyes! they burn!)
[Nexus 7 Android Development] fattire:
So this was a bug in the wiki... the command to type is:

brunch grouper

not

brunch {{{device}}} or brunch {{{grouper}}}

The wiki template was supposed to replace {{{device}}} with the name of the device ("grouper") but didn't..

it's been fixed, though the formatting is slightly screwy but it's better for now. Thanks for pointing it out.
[Nexus 7 Android Development] fattire:
What to do AFTER you build...

So I started this page. If you have ideas for things to add, join in!
[Nexus 7 Android Development] doctapeppa:
Last night I was able to build a zip with no probs and It flashed perfectly to my N7, Today I tried the same thing with a laptop and I'm getting some errors when I start the build.

Here are the last few lines from when it quit:

Copy xml: /home/frank/android/system/out/target/product/grouper/system/etc/permissions/android.software.sip.voip.xml

Copy xml: /home/frank/android/system/out/target/product/grouper/system/etc/permissions/com.cyanogenmod.android.xml

/bin/bash: xmllint: command not found

/bin/bash: xmllint: command not found

make: *** [/home/frank/android/system/out/target/product/grouper/system/etc/permissions/android.software.sip.voip.xml] Error 127

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

make: *** [/home/frank/android/system/out/target/product/grouper/system/etc/permissions/com.cyanogenmod.android.xml] Error 127

frank@Satellite:~/android/system$

Another thing that i notice that might be wrong is when it starts off It does this:

PLATFORM_VERSION_CODENAME=REL

PLATFORM_VERSION=4.2.1

TARGET_PRODUCT=cm_grouper

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_OS_EXTRA=Linux-3.5.0-21-generic-x86_64-with-Ubuntu-12.10-quantal

HOST_BUILD_TYPE=release

BUILD_ID=JOP40D

OUT_DIR=/home/frank/android/system/out

Is it normal for the TARGET_BUILD_APPS= to be empty?

Oh and here are some more error looking things:

/bin/bash: xsltproc: command not found

/bin/bash: xsltproc: command not found

find: `src': No such file or directory

build/core/base_rules.mk:525: system/core/mkbootimg/Android.mk: Module "unpackbootimg" has useless module tags: eng. It will be installed anyway.

build/core/Makefile:44: warning: overriding commands for target `/home/frank/android/system/out/target/product/grouper/system/etc/mkshrc'

build/core/base_rules.mk:502: warning: ignoring old commands for target `/home/frank/android/system/out/target/product/grouper/system/etc/mkshrc'

No private recovery resources for TARGET_DEVICE grouper

Is there hope for me?
[Nexus 7 Android Development] fattire:
I tlooks like there's some xml-related stuff missing. Try:

sudo apt-get install xsltproc

sudo apt-get install libxml2-utils
[Nexus 7 Android Development] doctapeppa:
That seems to have worked! Thanks.
[Nexus 7 Android Development] EnemyOfGlaDOS:
Just need a little clarification before I build again.. Now that's I've got my build environment set up I don't need to do that again, but just unsure where I should start if I want to update my CM10.1 ROM.. I was gonna guess and just try a few things but I thought I'd better not :silly:

Do I just get into the right directory: cd ~/android/system and then brunch grouper or is there more to it?
[Nexus 7 Android Development] doctapeppa:
Do $ repo sync first.
[Nexus 7 Android Development] natedroid:
2nd build

2 days ago I built android for the first time, today after running a repo sync, I started my second build. The build completed, but the zip was still dated as the fourteenth once it completed. I was under the assumption that whenever a build is completed it would contain the date of the build within the file name. Any idea what i did wrong?
[Nexus 7 Android Development] EnemyOfGlaDOS:
that's it? Do I have to initialize the repository like I did the first time around? Also.. do I need to *Get Prebuilt apps* or *Prepare Device Specific Code* or *Extract proprietary blobs* ??

..all these are listed after repo sync, but I'm unclear whether it needs to be done again or if I just move onto the building?

So.. repo sync, cd android/system/, . build/envsetup.sh, make clobber, brunch gouper... profit?
[Nexus 7 Android Development] BMP7777:
I am relatively new to grouper building, but have been working on skyrockets for a while and the process is pretty much the same.

cd to your build directory

Then:

repo init -u git://github.com/CyanogenMod/android.git -b jellybean

or

repo init -u git://github.com/CyanogenMod/android.git -b 10.1

or

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

for AOSP, which is what I am working on now. Then, like doctapeppa said:

repo sync

If you want to get a fresh start, don't forget to

make clean

or

make clobber

before syncing up again. Good Luck!!

UPDATE: Just caught your response. Depending on what you're building, you may need to get your prebuilts again. With the constant updates on git for CM especially, you would want to take all the steps; this will go further to avoiding issues.
[Nexus 7 Android Development] fattire:
Wikiwikiwiki

So a couple things--

1. Normally to update your code just do a repo sync and then you can brunch grouper again. The way the build system works, only the stuff that has changes to the source code will be rebuilt before the new .zip is packaged. This is a nice time and energy saver. You don't have to re-init the repo, *Get Prebuilt apps* or *Prepare Device Specific Code* or *Extract proprietary blobs* if you've done this already. (The exception is if you are moving to a new branch (such as from Android gingerbread->jellybean), which would require a new repo init to get source code for the new branch, and possibly new proprietary blobs, if they have been updated for the new version.)

2. The build date in the file name will not change, however, unless you wipe out everything with a make clean or make clobber. You can read the wiki for an explanation of the difference.

3. You don't need to do a new repo init command every time unless you want to switch to a new branch, such as from gingerbread to jellybean or something.

4. Over the last month or so, in addition to getting the build guides for every CM-supported device working, I also spent a while writing up all kinds of build-related articles at the wiki. If you haven't had a chance to look at it, it may help you gain a wider understanding of the build process and other development-related stuff.

Hope this is helpful!
[Nexus 7 Android Development] BMP7777:
He is exactly right on all accounts. I was assuming that you would want to start a fresh build every time; hence my explanation. When releasing ROMs for the skyrocket, if they had the same date as the previous release, everyone would assume nothing had been changed. So, I have gotten in the habit of making clean before every new build. I also neglected to mention that extracting blobs or preparing the device code should only need to be done once, unless like the man says, you are changing to a new branch. Even then, I don't think it's neccesary. But, being new to this device, I could be wrong :eek: I am working on an AOSP build for the N7(grouper) as we speak. Performed my sync of build directory files, but I have had issues with extracting the blobs until now due to that pesky connection with Linux issue. I have installed all of the recommended software to workaround that problem and will extract this evening. Hopefully, I will be successful and will share the fruits of my labor with anyone who wants it. Thanks to fattire for the tut; I will be looking into your wikis this evening as well.
[Nexus 7 Android Development] EnemyOfGlaDOS:
That is very helpful! Thank you very much! :good:
[Nexus 7 Android Development] BMP7777:
Syncing for AOKP now, and although the sync progresses, I see a lot of this:

curl: (22) The requested URL returned error: 404 Server does not provide clone bundle; ignoring

Sorry if this has been covered already; I've looked elsewhere and haven't gotten much of an answer. Thought I'd ask here.....:confused:

I realize this is not a thread for AOKP, just wanted to throw this out there and see if anyone had encountered this....I don't think it is an error strictly related to AOKP. Could be wrong.....
[Nexus 7 Android Development] doctapeppa:
I have a question. Lets say I want to make my build with a different app than CM normally comes with. Say..SuperSU instead of Superuser. Where do I put my SuperSU apk so that it gets incorporated into my rom in place of Superuser?
[Nexus 7 Android Development] eug89:
I haven't tried it but this is what I would do:

Download Supersu on my phone, extract it, either with adb pull or an app like rootexplorer

Copy SuperSU.apk in /vendor/cm/proprietary

In /vendor/cm/config/common.mk

change

PRODUCT_PACKAGES += \
Camera \
Development \
LatinIME \
SpareParts \
Superuser \
su

to

PRODUCT_PACKAGES += \
Camera \
Development \
LatinIME \
SpareParts \
su

And add, in the same file, this line

PRODUCT_COPY_FILES += \
vendor/cm/proprietary/SuperSU.apk:system/app/SuperSU.apk \

I think this should work.

Probably at the first boot you'll need to update the su binary through the SuperSU app like you do when you install it from the market.
[Nexus 7 Android Development] AidenM:
With APKs I bet you could put it in the build itself but sometimes it's just easier to copy it into the zip file.
[Nexus 7 Android Development] gabx:
Here is what I do when building AOSP (I guess the same is valid for CM).

-install SuperSu on device

-adb pull /system/xbin/su and /data/app/eu.chainfire.supersu-1.apk

-AFTER the build, remove /system/xbin/su and replace with the one from your device

-put eu.chainfire.supersu-1.apk in the /data/app/

As I think this app is open source, another possibility is to include it BEFORE you build. In that case, you will need to have a look at your makefile (/build/core/main.mk) and make sure there is nothing to edit. I would say (never tried) you can place safely the source folder in /system/core/ and build
[Nexus 7 Android Development] TheDarkDefender:
Is 'programming knowledge' a requirement for this ?
[Nexus 7 Android Development] gabx:
For first solution, NO. Second one, depends on waht you call programming knowledges. Building a ROM has nothing to do with programming. Just try to understand how the make command works and wich config files it will read.
[Nexus 7 Android Development] Mr.Oug:
Which version of Ubuntu should i use the latest one.....?
[Nexus 7 Android Development] TheDarkDefender:
Ha. Thanks. I was asking generally. Didn't mean to quote what you said :)

---------- Post added at 02:12 AM ---------- Previous post was at 02:11 AM ----------

As the cm wiki says, the latest version is always recommended,which is 12.10
[Nexus 7 Android Development] .torrented:
Use 12.10 and make sure you get 64-Bit
[Nexus 7 Android Development] EnemyOfGlaDOS:
*deleted*
[Nexus 7 Android Development] churd83:
I have had success with building cm from source but now i want to add some apps to the build that will install when flashing the ROM.

How do i go about adding the apps i want to install during the flash?
[Nexus 7 Android Development] TheDarkDefender:
Re: [HOWTO] Build CM10.1 for Nexus 7

Correct me if Im wrong. But the easiest way is to add the apps to /system/app in the zip. Winrar allows you to modify the zip without extraction. Works for me. :)
[Nexus 7 Android Development] fattire:
How to automatically add an app to your build.

This has been asked before, so I just wrote it up in the wiki. Also realized there wasn't anything about edify, and since I refer to it in that article, I wrote something up about edify too.
[Nexus 7 Android Development] TheDarkDefender:
Re: [HOWTO] Build CM10.1 for Nexus 7

Awesome. That cleared a lot. Thanks!
[Nexus 7 Android Development] fattire:
Just to keep everyone updated, I added an article on local manifests.

To anyone building, I do recommend checking out the wiki, particularly the dev center area, as I've been brain-dumping almost everything I can think of there. Hopefully the info is useful to people.
[Nexus 7 Android Development] EnemyOfGlaDOS:
Re: [HOWTO] Build CM10.1 for Nexus 7

Great thank you.. its all very helpful
[Nexus 7 Android Development] churd83:
Re: [HOWTO] Build CM10.1 for Nexus 7

Thanks, will tackle this feat this weekend, then on to figuring out aroma.
[Nexus 7 Android Development] azoller1:
Re: [HOWTO] Build CM10.1 for Nexus 7

Anyone know how to set up a 64 bit Ubuntu version on virtual box off of windows because its not working for me
[Nexus 7 Android Development] doctapeppa:
What exactly is not working?

Without knowing though.. I would really look into actually installing ubuntu on the computer. You can install it on a separate partition than windows and it will be way easier and less hassle than running it in virtualbox. Quite a bit faster too.
[Nexus 7 Android Development] azoller1:
Re: [HOWTO] Build CM10.1 for Nexus 7

Yeah I've done that but its only limited to 30gb of max space isn't it?
[Nexus 7 Android Development] doctapeppa:
No. You can give it any amount you want. Part of the setup will ask you how you want to set up your drive and you can assign as much or as little space as you want to your linux partitions. The installer will even let you resize your windows partition to make room for your linux one.

Here are some instructions on doing that: https://help.ubuntu.com/community/WindowsDualBoot
[Nexus 7 Android Development] yogi2010:
Re: [HOWTO] Build CM10.1 for Nexus 7

Have you heard of any problems installing Linux lately? My Dell N5050 didn't come with Win 8, but i have tried Ubuntu 12.10, and 3 of the latest versions of Linux Mint, and they all hang at the screen where you input your name and a password. I try to click 'continue' and it goes nowhere. At the bottom i see it creates the file system, copies files, but basically just stops there!

Sorry to go on that tangent, but maybe it's in the ballpark, haha. I really want to get this sorted if possible! I started a thread in XDA General Q&A as well.

Edit: i have read of some people having this issue with Linux Mint 14. Ubuntu did the same for me as well.
[Nexus 7 Android Development] .torrented:
Ive been able to install Ubuntu 10.04, 12.10, Mint 14, and Fedora 18 without any problems
[Nexus 7 Android Development] EnemyOfGlaDOS:
I got some serious reading to do lol. One link led me to another, to another, to another. I'm gonna start at the beginning of the wiki and even read the stuff I know, but this is great. To be honest after building I still didn't know how to use code other than what I copied and pasted so this will be a good way to stick my foot in. I may even build for my S3 or try to Port it. But either way I have got a LOT of reading to do! The wiki is well written too, Thanks so much! :D
[Nexus 7 Android Development] yogi2010:
Re: [HOWTO] Build CM10.1 for Nexus 7

Yep ok, thanks. I'm sure isn't Linux in general. I haven't figured it out, never had this issue before. Maybe something specific to this machine? The thing is, this particular model is actually mentioned on the Ubuntu site as being 'certified to run Ubuntu' lol.
[Nexus 7 Android Development] doctapeppa:
This is strange. I would check the MD5 hash on the iso you downloaded and make sure it's not corrupted. I used to get problems with different linux distros and it was because my downloads where corrupt. Now, rather than doing http downloads I torrent them. (Torrent files are always automatically hash checked when they download) Also, if you are burning it to a disk before installing, try burning it at the slowest speed possible (1x or 2x). A linux install has thousands and thousands of files and the possibility of losing a byte here or there is very high. Sometimes it doesn't matter but a lot of the times a corrupt iso can cause weird problems.

Also, if you aren't, make sure you get the 64 bit of ubuntu and not the 32 bit as you need the 64 bit to build jellybean.
[Nexus 7 Android Development] yogi2010:
Re: [HOWTO] Build CM10.1 for Nexus 7

Thanks, i really hope the issue is corrupt downloads. But i have downloaded 4 or 5 distros and they all do the exact same thing! I've tried them mostly on a usb unstaller, but i think i tried a cd as well. Thanks for the suggestions. And i always go with 64-bit btw :)
[Nexus 7 Android Development] azoller1:
Re: [HOWTO] Build CM10.1 for Nexus 7

When I reboot my computer I get 2 Ubuntu boot options how do I get rid of one?

---------- Post added at 11:06 PM ---------- Previous post was at 10:55 PM ----------

I'm scared!!! What do I choose!
[Nexus 7 Android Development] TheDarkDefender:
Re: [HOWTO] Build CM10.1 for Nexus 7

I just installed 12.10 on a partition of 60Gig, made out of a 2 TB hard drive. Dual booted with win7. The maximum I could allocate during setup of ubuntu was 30GB.

Afterwards, I read a tutorial where it said we require atleast 60gig for a single build and 100gig or more for a set of builds.

I'm confused. How is that possible, when all it allows is a mere 30 gig?

P.s I'm a total noob to linux,and I'm desperate to compile my first Rom. Sorry. And thanks.
[Nexus 7 Android Development] doctapeppa:
Check out step 5 here. http://www.ubuntu.com/download/help/install-desktop-latest

Unless your windows is using up a ton of space on your drive you should be able to give your Ubuntu install way more than 30 gb. I have a Tb drive as well and I gave halftone windows and the other half to Ubuntu.
[Nexus 7 Android Development] TheDarkDefender:
Re: [HOWTO] Build CM10.1 for Nexus 7

Saw that. I used the Windows installer. But the maximum I could allocate is 30gig. My question is do I have to live with that, or can I expand that, since a Rom will require more?
[Nexus 7 Android Development] .torrented:
make a bootable usb and then install ubuntu onto your partition that way
[Nexus 7 Android Development] TheDarkDefender:
Re: [HOWTO] Build CM10.1 for Nexus 7

Wubi within windows.
[Nexus 7 Android Development] .torrented:
I editied my post and yea dont use wubi or else you are stuck with at most 30Gbs
[Nexus 7 Android Development] TheDarkDefender:
Re: [HOWTO] Build CM10.1 for Nexus 7

Uhh.. Damn! I finished the install, jdk, sdk everything.

Is there no other way?

Do I have to do everything again?! :confused::eek::eek:
[Nexus 7 Android Development] doctapeppa:
The Wubi installer is just to give ubuntu a test drive. Don't worry. Installing linux is part of the fun of linux. You will learn a lot by doing it. Make a bootable USB such as one from http://www.pendrivelinux.com/ or burn it to a dvd and install from there. Either way you want to do this after booting up your computer so that you aren't doing it from within windows.
[Nexus 7 Android Development] fattire:
Thanks. I'm just trying to get the ball rolling... hopefully the articles will get better and better as time goes on, with more detail and explanation coming from everyone. We're really hoping to make the wiki a "world-class" source for Android, since a lot of stuff isn't really written down anywhere and just gets passed along from dev to dev...

Since you mentioned it, I should add that I just updated the porting page with some new info...
[Nexus 7 Android Development] TheDarkDefender:
Re: [HOWTO] Build CM10.1 for Nexus 7

Thank you. I ll do that. The next time when it asks for allocating space, how much do you recommend? I have around around 750gig remaining. Win7 occupies the rest.
[Nexus 7 Android Development] doctapeppa:
I think 100 is plenty to get your feet wet with ubuntu.
[Nexus 7 Android Development] TheDarkDefender:
Re: [HOWTO] Build CM10.1 for Nexus 7

Thanks!
[Nexus 7 Android Development] natedroid:
wubi

I had major issues with performance on wubi, as in I got the build to start, and 6 hours later it failed due to lack of space. The same system with a real install built and completed it in about an hour and twenty minutes.
[Nexus 7 Android Development] azoller1:
Re: [HOWTO] Build CM10.1 for Nexus 7

How do I install mint Linux correctly? I put the Iso on a live CD then booted it up then clicked install linux mint then I get confised
[Nexus 7 Android Development] TheDarkDefender:
Re: [HOWTO] Build CM10.1 for Nexus 7

Ok. Thanks. I'll do that then.
[Nexus 7 Android Development] azoller1:
Re: [HOWTO] Build CM10.1 for Nexus 7

Got Ubuntu to install from a live CD now can't boot into windows 7.....