yashsingh1/xdaforums huggingface dataset:
[Android] desalesouche:
hi <while compiling cm11 on that fresh install of unbutu 14.04 i have that weird error? any idea? thank you.

Can't locate Switch.pm in [MENTION=328088]Inc[/MENTION] (you may need to install the Switch module

[MENTION=328088]Inc[/MENTION] contains: /etc/perl /usr/local/lib/perl/5.18.2 /usr/local/share/perl/5.18.2 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.18 /usr/share/perl/5.18 /usr/local/lib/site_perl .) at external/webkit/Source/WebCore/make-hash-tools.pl line 23.

BEGIN failed--compilation aborted at external/webkit/Source/WebCore/make-hash-tools.pl line 23.

Import includes file: /home/desalesouche/cm11m3/out/target/product/u8860/obj/STATIC_LIBRARIES/libwebcore_intermediates/import_includes

make: *** [/home/desalesouche/cm11m3/out/target/product/u8860/obj/STATIC_LIBRARIES/libwebcore_intermediates/Source/WebCore/html/DocTypeStrings.cpp] Error 2

edit: i think i foound the solution here

http://answers.yahoo.com/question/index?qid=20130510115737AAfIgU5

hi did in terminal :

cpan App::cpanminus

then i choosed solution with sudo.

then i did in new terminal:

cpanm Switch

i restarted cm build and error seem to be gone... will confirm that.
[Android] bamsbamx:
this seems to work succesfully also with Ubuntu 13.10.... now I have to wait for "repo sync":p

Thanks!!!!!!!!!!!!!!!:fingers-crossed::fingers-crossed::fingers-crossed::fingers-crossed:
[Android] SchmilK:
I keep trying to only compile HTC One Sense kernels from source with the problem of arm-eabi-gcc never being found. :( Even when I manually install gcc toolchain and update paths, it errors saying it can't be found.

Any ideas?
[Android] rboy28:
Is there any way make it work on Ubuntu 32 bit? I tried various How To's but every time it fails at installing the libs [5.)]
[Android] calikevin:
My bad, error was due to VirtualBox, just needed to reinstall
[Android] sylentprofet:
fixed two-liner

The command for fetching repo from googleapi's was incorrect. Had an elipsis in the link instead of the proper url. Here's the fixed version:

sudo apt-get purge openjdk-\* icedtea-\* icedtea6-\* && sudo add-apt-repository ppa:webupd8team/java && sudo apt-get update && sudo apt-get install oracle-java6-installer && sudo apt-get install git gnupg ccache lzop libglapi-mesa-lts-utopic:i386 libgl1-mesa-dri-lts-utopic:i386 flex bison gperf build-essential zip curl zlib1g-dev zlib1g-dev:i386 libc6-dev lib32bz2-1.0 lib32ncurses5-dev x11proto-core-dev libx11-dev:i386 libreadline6-dev:i386 lib32z1-dev libgl1-mesa-glx-lts-utopic:i386 libgl1-mesa-dev-lts-utopic g++-multilib mingw32 tofrodos python-markdown libxml2-utils xsltproc libreadline6-dev lib32readline-gplv2-dev libncurses5-dev bzip2 libbz2-dev libbz2-1.0 libghc-bzlib-dev lib32bz2-dev squashfs-tools pngcrush schedtool dpkg-dev && sudo ln -s /usr/lib/i386-linux-gnu/mesa/libGL.so.1 /usr/lib/i386-linux-gnu/libGL.so && mkdir ~/bin && curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo && chmod a+x ~/bin/repo && sudo nano ~/.bashrc

At the bottom of bashrc paste the following line:

export PATH=~/bin:$PATH

Ctrl-O to save and Ctrl-X to exit. Then run:

source ~/.bashrc && mkdir ~/android && cd ~/android

Thanks Aaahh!
[Android] Aaahh:
yeah i allways forget about that. Thanks
[Android] calikevin:
When I run this, I get these errors at the end-

W: Failed to fetch cdrom://Xubuntu 14.04 LTS _Trusty Tahr_ - Alpha amd64 (20140121.1)/dists/trusty/main/binary-amd64/Packages Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs

W: Failed to fetch cdrom://Xubuntu 14.04 LTS _Trusty Tahr_ - Alpha amd64 (20140121.1)/dists/trusty/multiverse/binary-amd64/Packages Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs

W: Failed to fetch cdrom://Xubuntu 14.04 LTS _Trusty Tahr_ - Alpha amd64 (20140121.1)/dists/trusty/restricted/binary-amd64/Packages Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs

W: Failed to fetch cdrom://Xubuntu 14.04 LTS _Trusty Tahr_ - Alpha amd64 (20140121.1)/dists/trusty/universe/binary-amd64/Packages Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs

W: Failed to fetch cdrom://Xubuntu 14.04 LTS _Trusty Tahr_ - Alpha amd64 (20140121.1)/dists/trusty/main/binary-i386/Packages Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs

W: Failed to fetch cdrom://Xubuntu 14.04 LTS _Trusty Tahr_ - Alpha amd64 (20140121.1)/dists/trusty/multiverse/binary-i386/Packages Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs

W: Failed to fetch cdrom://Xubuntu 14.04 LTS _Trusty Tahr_ - Alpha amd64 (20140121.1)/dists/trusty/restricted/binary-i386/Packages Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs

W: Failed to fetch cdrom://Xubuntu 14.04 LTS _Trusty Tahr_ - Alpha amd64 (20140121.1)/dists/trusty/universe/binary-i386/Packages Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs

E: Some index files failed to download. They have been ignored, or old ones used instead.

Will these affect building in any way? Is there no way to get these online instead of using the CD, I cannot find a mirror of the release it mentions.
[Android] sylentprofet:
Ubuntu is looking for the original install CD as a software repository. You can remove it from the apt list by going to Settings Manager > Software and Updates > Other Software. Uncheck the cdrom entry and make sure you have the online sources selected.

Your error is kind of uncommon in my experience. Without knowing more about your system setup (internet access, etc) it's kind of hard to pin down.
[Android] MJPollard:
Just wanted to add that your guide also works, with only one or two minor changes, with the 64-bit version of Linux Mint 16, which is based on Ubuntu. There are only a few minor differences:

A fresh install of Mint does not have a .bashrc file in the home directory. It has to be created, with export PATH=~/bin:$PATH the only entry.

The built-in pluma editor can be used to create .bashrc (nano is included, but pluma seems to be more "modern" and intuitive, especially for people used to something like the Windows Notepad editor).

I found that closing the terminal window and re-opening it takes care of updating PATH after creating the .bashrc file, and is a concept that's a bit easier to understand for most people.

Other than those minor differences, your guide works beautifully. I did this on both a fresh install on a PC and a VirtualBox VM on my existing Windows 7 64-bit setup. If you want to update your guide to include the differences for Linux Mint 16 (for those of us who prefer it over Ubuntu and believe that Unity should burn in hell for a dozen eternities :D), those are really the only differences that have to be taken into account.
[Android] vivmar:
from ubuntu 14.04 x64:

any idea?
[Android] galapagos:
Download the installer and install it manually.
[Android] linhbs:
Thanks so much
[Android] x1123:
For using linux no need to use sun/oracle Java. open-jdk / icedtea is suitable for building android in linux machine. The most reason AOSP sites suggested sun/oracle java, due to sun/oracle is the most stable and suitable for windows/osx platform (and Linux). for linux users, using open-jdk is best choice due to all "java related" in linux "linked" into open-jdk/icedtea.
[Android] x1123:
I got another machine and wish to dedicate installing ubuntu 14.04 for compiling ubuntu touch ( and Android for sure ). I got trouble installed 32-libs required above. Copy paste above give me confusing :

I have enabled whole ubuntu repositories which is NOT WISE for fresh release ubuntu :)

Understood ia32-libs is renamed in ubuntu 14.04 respository to lib32-blah.... your guide supposed to less head-ache and straight forward to set the machine. I copy paste your command > put on text file and make it executable thus easy for me to just execute command ./something ... :)

I want clean install via apt which is handy and trackable. Is there any info the above package renamed (?)

I stop to set up to find any good way ... below is terminal output >

My target is clean install ubuntu 14.04 command line only No DESKTOP .... for browsing w3m is sufficient :)

Thanks for any help
[Android] fakeblitz:
Thanks for the guide, it has been very helpful!
[Android] NellyWhads:
Dependency addition

Hey man, First of all, this is awesome - so simple (linking them all together) that I'm upset I didn't think of it :p

Well I used it and ended up finding that a dependency was not included in the first command - you may want to add "dpkg-dev" to your install section of that first mega command so it stays a two-step method :)

- NellyWhads
[Android] :
http://xdaforums.com/showpost.php?p=41429986&postcount=37

A better guide for setting up a build environment.

It won't pull in all those unneeded ia32 libs and it will only pull in what it needs.

I been using this custom setup since Ubuntu 12.04

It will never have any dependency issues nor make you install a bunch of crap you don't need.
[Android] MattBooth:
In 13.10 I get build errors if I don't use Java 7 (open jdk works well). Also, the official AOSP build guide states Open JDK 7.

http://source.android.com/source/initializing.html

$ sudo apt-get update
$ sudo apt-get install openjdk-7-jdk

There's also no need to remove any existing Java versions...

$ sudo update-alternatives --config java
$ sudo update-alternatives --config javac

EDIT:

This following commit to OmniROM is nice also:

https://github.com/omnirom/android_...mmit/ca7700b6b7b380ac9059a3331dcc1a3697be1555
[Android] sylentprofet:
Some would beg to differ, but thanks anyway.

I used to like your minimal GAPPs package, good work on that.
[Android] :
Well I meant no offense on the already posted method lol. It is I have tested my version with all the others against most guides on the net and on here and it pulls in the least amount packages since it won't pull unneeded stuff. Also I have never had any dependency issues ever from Ubuntu 12-04 to 14.04. Most guides I used or tried left stuff with broken dependency issues in terminal blah etc. I have built everything under the sun with this setup with no issues.

---------- Post added at 05:57 PM ---------- Previous post was at 05:54 PM ----------

Untouched AOSP requires Sun Java 6 GingerBread to Kitkat. AOSP Master untouched requires Sun Java 7.
[Android] nasr18:
step 5

bro fifth step is not working. what to do????:confused:
[Android] ksjuggalo:
I recently got the wild hair to really try my hand at Android development and custom ROMs, etc. I decided to go with Lubuntu to keep the OS light but still follow the mainstream (i really hate saying that, but its so much easier to find help when ya need it). I decided to give your simple 2 step setup.

I am in no way complaining, and i guess if someone is here then they probably know how to resolve dependency errors. But just in case.....

When i first ran the command to install everything i got dependency errors about the following:

build-essentials --i think, it was a build-something package but in my haste i didn't bother to write it

down before i filled my terminals buffer

g++-multilib

libghc-bzlib-dev

I went into synaptic and searched for those 3 packages and installed them there. All dependencies installed fine there so, i ran the install commands again and everything went fine. Im not sure why apt-get didnt install the dependencies. And there may be a better way to do what i did, but i know just enough *nix to be dangerous. :eek:

Wish me luck :fingers-crossed:
[Android] TSFox0317:
i keep getting this error when trying to build for the s4, any suggestions on what to do

Your identity is: DocOc317 <TSFox317@gmail.com>

If you want to change this, please re-run 'repo init' with --config-name

repo has been initialized in /home/dococ317/android

dococ317@DocOc:~/android$ . build/envsetup.sh && brunch jflteincluding device/generic/armv7-a-neon/vendorsetup.sh

including vendor/aokp/vendorsetup.sh

including sdk/bash_completion/adb.bash

including vendor/aokp/vendorsetup.sh

build/core/product_config.mk:238: *** _nic.PRODUCTS.[[vendor/aokp/products/jflte.mk]]: "device/samsung/jflte/full_jflte.mk" does not exist. Stop.

** Don't have a product spec for: 'aokp_jflte'

** Do you have the right repo manifest?

No such item in brunch menu. Try 'breakfast'

dococ317@DocOc:~/android$
[Android] sylentprofet:
Sounds like your repo isn't properly initialized. To build AOKP for the samsung galaxy s4, the command to initialize your repo folder would be:

repo init -u https://github.com/AOKP/platform_manifest.git -b kitkat -g all,-notdefault,jflte,samsung

Then repo sync, and it should download the missing device/vendor/kernel or whatever files you need.
[Android] TSFox0317:
everything went well........then this happened

target thumb C++: content_content_common_gyp <= external/chromium_org/content/common/android/hash_set.cc

In file included from external/chromium_org/content/common/android/hash_set.cc:5:0:

/home/dococ317/android/out/target/product/jflte/obj/GYP/shared_intermediates/content/jni/HashSet_jni.h:10:26: error: extra tokens at end of #ifndef directive [-Werror]

/home/dococ317/android/out/target/product/jflte/obj/GYP/shared_intermediates/content/jni/HashSet_jni.h:11:26: error: missing whitespace after the macro name [-Werror]

target thumb C++: content_content_common_gyp <= external/chromium_org/content/common/android/surface_texture_peer.cc

In file included from external/chromium_org/content/common/android/hash_set.cc:5:0:

/home/dococ317/android/out/target/product/jflte/obj/GYP/shared_intermediates/content/jni/HashSet_jni.h:24:20: error: expected initializer before '<' token

/home/dococ317/android/out/target/product/jflte/obj/GYP/shared_intermediates/content/jni/HashSet_jni.h:26:17: error: expected initializer before '<' token

/home/dococ317/android/out/target/product/jflte/obj/GYP/shared_intermediates/content/jni/HashSet_jni.h:29:22: error: expected '{' before '<' token

/home/dococ317/android/out/target/product/jflte/obj/GYP/shared_intermediates/content/jni/HashSet_jni.h:29:22: error: expected unqualified-id before '<' token

external/chromium_org/content/common/android/hash_set.cc:30:1: error: expected '}' at end of input

target thumb C++: content_content_common_gyp <= external/chromium_org/content/common/android/trace_event_binding.cc

cc1plus: all warnings being treated as errors

make: *** [/home/dococ317/android/out/target/product/jflte/obj/STATIC_LIBRARIES/content_content_common_gyp_intermediates/content/common/android/hash_set.o] Error 1

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

dococ317@DocOc:~/android$
[Android] katinatez:
Hello, I have decided to install Linux on my desktop to learn to compile OmniRom, and Cyanogenmod. My dedicated build machine is a EVGA X58 Classified with I7 Intel CPU with 12 GB of Ram with a Kingston 240 GB SSD, also have a couple WD Velociraptor 300GB HDD I would like to use for cache just dont know how to link to primary SSD.

Do I still need to add swap file even though I have 12GB of Ram? If so how much?

How do I add an external HDD for dedicated cache (all 300 GB)?

How to add a second HDD for media or data?

My dedicated test devices will be the I9300 and Nexus 7, since this are the only devices I have to test. I think I read something about a local manifest.xlm to just repo sync only for this 2 devices, thus shortening the sync time. How do I go about doing this? Or how would the manifest look like?

Any help would be appreciated.
[Android] x1123:
I suggested for ubuntu stick at 12.04. Most default package on 12.04 like python, gcc, make are suitable for android dev.

Swap is not necessary, unless you want to have your pc sleep or hybernate for long time. Disk swap will slower your build. Today RAM is generally huge size. Ram is not required anymore.

Google search. Your devices are very popular devices. Too many guide for both devices.
[Android] SchmeeForce:
Is Ccache setup already in this distro?
[Android] Kapiljhajhria:
32 bit system and kali compatibitlity?

can i use 32 bit system ? becasue i was told android development is only possible on 64bit machines. i tried all this 2 times and downloaded all stuff in GBs (i don't have unlimited plan) and it was a huge disaapointment when i was told that i need 64bit system.

later i checked that all the ubuntu softwares needed for android developmet are available for 32bit system as well. so it should work. but i let it go as i will be buying new laptop soon in a moth or two.

also can i use kali isntead of ubuntu?

i just switched from lubuntu 14.04 to kali today (kali is updating at the moment)
[Android] ShinySide:
Been learning to make scripts (still new at it really) because Im a little lazy and been switching distros lately....thought I'd share here since this OP is where I got all the packages from and make it even easier for people that like to try out different distros often or shopping around for a keeper, so all the copying and pasting isnt needed anymore.

This script will complete steps 1-6 just by running it. Still need to accept oracle license so not completely run and walk away. Feel free to use/edit/improve at will, just credit in the fine print if re-distributed is all thats asked. enjoy.

Download, extract, make executable (right click, properties, check executable box), open terminal run sudo ./env-setup enter password and does the rest for you as far as steps 1-6. (Except accept Oracles license. Havent figured that out yet)
[Android] katinatez:
Nice script,I am one of those trying different flavors of Linux. Is there any way you could add to the script up to step 11? I also follow this tutorial to install sdk, fastboot & adb, eclipse, android.rules, android studio. found here

http://xdaforums.com/showthread.php?t=2302780

Is that something you could add to the script as well? More than happy to donate if all this is possible. every tiime I install a new distro it take me about 45 minutes to set everything up.

Thank you for the script!
[Android] ShinySide:
Im not sure how I can do steps 7-11 yet. Since the script is ran as root. bin would be set to root for permissions instead of user/s. So until I figure that one out its gonna have to be done manually. So what I did, I forgot I already added adb to the first script, but I added fastboot on this one attached.

Same would go for the files/programs you asked as far as the permissions if added to env-setup so I went ahead and made a separate script for them. Except for android.rules is not in it. Because everyone/distros use different text editors and Im not sure how to make it pick up and use the default and the only other way I know how to do it is with a command that I'd have to use "" around all the text, which the text for android.rules has tons of "" so it screws that command up.

But for the tools script, just make it executable and run ./tools in the term. Itll make ~/development, sdk eclipse and android studio will download into it, all 3 tars will extract and then the tars will be deleted.

btw no donation needed.
[Android] katinatez:
Having build errors trying to compile cm11 for i9300

errors are

File "build/tools/findleaves.py", line 95
print r
^
SyntaxError: invalid syntax
File "build/tools/findleaves.py", line 95
print r
^
SyntaxError: invalid syntax
File "build/tools/diff_package_overlays.py", line 88
print r
^
SyntaxError: invalid syntax
PRODUCT_COPY_FILES device/samsung/smdk4412-common/rootdir/init.trace.rc:root/init.trace.rc ignored.
PRODUCT_COPY_FILES device/samsung/smdk4412-common/configs/audio_effects.conf:system/etc/audio_effects.conf ignored.
PRODUCT_COPY_FILES vendor/samsung/i9300/proprietary/system/usr/idc/sec_touchscreen.idc:system/usr/idc/sec_touchscreen.idc ignored.
No private recovery resources for TARGET_DEVICE i9300
make: *** No rule to make target '/home/john/android/cyanogenmod/out/host/linux-x86/bin/mkbootimg', needed by '/home/user/android/cyanogenmod/out/target/product/i9300/boot.img'. Stop.

Can someone tell whats going on here.

Thank you
[Android] ShinySide:
Try running make -j4 otatools and try building again. If not you'll just have to wait for cm and keep repo syncing or check Gerrit for unyet merged android_build commits and cherry pick them and see if they fix the issue. They've been doing a lot if merging
[Android] katinatez:
Did not work. But found solution, I was using python 3. Switched to python 2 and no more errors.
[Android] L.E.D 26:
Thank you, finally got my first build for my device :D
[Android] FlynnLives:
I'm having the same issue as katinatez, but running 'make -j4 otatools' returns the following:

make: *** No rule to make target '/home/username/SourceCode/CyanogenMod/android/system/out/host/linux-x86/bin/minigzip', needed by 'otatools'. Stop.

What do I need to 'make' in order to make minigzip, so that I can make otatools, so that I can make CyanogenMod?
[Android] blttalas:
Btw im getting

Unpackbootimg not found

Error
[Android] autotech40:
repo initialize comand

i have an azpen a821 with android 4.2.2 on it it has an a20 processor i want to mess with..can anyone help me with the command to initialize the repo to get the files needed for this device.i had a look at github.com and there where just too many files and i'm a rooky android guy.i did search for 4.22,a20,etc. and got like 20 pages on every search nothing really jumped out as to what i needed.i didnt see the aosp master there.
[Android] kl522:
What's next after 'repo sync'

How come the instruction is stopping at 'repo sync' ?

What's need to be done after that ?

Do I follow the instruction here after that ?

https://source.android.com/source/building-running.html

On my system the 'lunch' command is not found.

Thanks.
[Android] jsauder2:
After repo sync, you should have the source downloaded and everything setup ready to build. That's all this thread is for, "How to Prepare.....to Compile..."

Once the repo syncs, ya, you follow the guide on that site if you want to build AOSP. So first you would run

source build/envsetup.sh

Then

lunch

Then choose the number of the device you are building for, and finally

make -j4

You can add otapackage to the end if you want a flashable zip, and also change the -j4 to something else if you have more cores, but -j4 should be fine. So if you want a zip to be output as well, just use

make -j4 otapackage

Instead of just make -j4.

What directory are you trying to run the lunch command from? If it's not finding it, it's likely that you're not in the source directory (wherever you downloaded everything while doing "repo sync." For example, mines in a folder titled "aosp" in my home folder. If you run the command from somewhere else, it won't find the lunch command.
[Android] kl522:
The lunch command things is fixed. It had problem earlier likely because I did not source the envsetup.sh.

Now I have a new problem after I run 'make -j4'. If this thread is not the right place to ask the compilation errors, please point me to the right thread :-

make: *** No rule to make target `/home/xxxxxx/android/out/target/product/generic/obj/KERNEL_OBJ/usr', needed by `/home/xxxxxx/android/out/target/product/generic/obj/STATIC_LIBRARIES/libminui_intermediates/events.o'. Stop.

I have done 'repo sync' a few times.
[Android] sylentprofet:
Instead of "lunch" and "make", try brunch instead.

So after the repo is sync'd:

source build/envsetup.sh
brunch yourdevicenamehere

Building for the nexus 4 would be "brunch mako". Nexus 5 is "brunch hammerhead" and so on.

"brunch" is a more streamlined process, and most flavors support it (AOKP, CM, Slim, etc.) Some have their own build scripts, like Liquid Smooth, so it's a little different, but, this should help you get the gist of it.

Good luck!
[Android] kl522:
I tried 'brunch mako' :-

Then I tried 'breakfast mako' :-

Then I tried 'breakfast aosp_arm-eng' :-

But still hit the same error after typing 'make -j4'.