Building Omni from source for Nexus 4 on Ubuntu 13.04 64 - Omni Q&A

edit: title should say 64bit
----
Hey trying to build OmniROM but getting an error, first time doing, I've got stock android to repo correctly but just can't get this one to work.
Code:
[email protected]:~/android/omni$ repo init -u ssh://[email protected]/android.git -b android-4.3
No command 'repo' found, did you mean:
Command 'rep' from package 'rep' (universe)
Command 'repl' from package 'mailutils-mh' (universe)
Command 'repl' from package 'nmh' (universe)
Command 'repro' from package 'repro' (universe)
repo: command not found
This is the repo document in the /Bin/ folder: http://pastebin.com/x9i1TBqT
Folder I've got.
Home/Bin
Home/Android
Home/Android/eclipse
Home/Android/sdk
Home/Android/omni​
AFAIK I've got everything installed. Been following this: http://docs.omnirom.org/Setting_Up_A_Compile_Environment

parker09 said:
Hey trying to build OmniROM but getting an error, first time doing, I've got stock android to repo correctly but just can't get this one to work.
Code:
[email protected]:~/android/omni$ repo init -u ssh://[email protected]/android.git -b android-4.3
No command 'repo' found, did you mean:
Command 'rep' from package 'rep' (universe)
Command 'repl' from package 'mailutils-mh' (universe)
Command 'repl' from package 'nmh' (universe)
Command 'repro' from package 'repro' (universe)
repo: command not found
Click to expand...
Click to collapse
Try this command:
repo init -u git://github.com/omnirom/android.git -b android-4.3

EmptyGODFATHER said:
Try this command:
repo init -u git://github.com/omnirom/android.git -b android-4.3
Click to expand...
Click to collapse
Thanks for the quick reply but I get the same error.

Looks like you didn't install repo...

parker09 said:
Thanks for the quick reply but I get the same error.
Click to expand...
Click to collapse
Did you "chmod a+x ~/bin/repo" ? or chmod a+x ~/path/to/your/repo

EmptyGODFATHER said:
Did you "chmod a+x ~/bin/repo" ? or chmod a+x ~/path/to/your/repo
Click to expand...
Click to collapse
I did /bin/repo
Code:
[email protected]:~$ curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ~/bin/repo
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 22889 100 22889 0 0 25679 0 --:--:-- --:--:-- --:--:-- 26615
[email protected]:~$ chmod a+x ~/bin/repo
[email protected]:~$

parker09 said:
I did /bin/repo
Code:
[email protected]:~$ curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ~/bin/repo
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 22889 100 22889 0 0 25679 0 --:--:-- --:--:-- --:--:-- 26615
[email protected]:~$ chmod a+x ~/bin/repo
[email protected]:~$
Click to expand...
Click to collapse
~/bin/ is probably not in your path.
check it
Pvy.

parker09 said:
I did /bin/repo
Code:
[email protected]:~$ curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ~/bin/repo
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 22889 100 22889 0 0 25679 0 --:--:-- --:--:-- --:--:-- 26615
[email protected]:~$ chmod a+x ~/bin/repo
[email protected]:~$
Click to expand...
Click to collapse
OK. Standard there is no path to ~/bin because it is in the home directory. Try ~/bin/repo
Sent from my TF300T using Tapatalk 4

Use this just make sure your sdk tools path matches the path in the command. I had to change mine since I use Android studio.
echo "export PATH=${PATH}:~/android/sdk/platform-tools/:~bin" >> ~/.bashrc; export PATH=${PATH}:~/android/sdk/platform-tools/:~bin
P.s. this can be found at docs.omnirom.org
Sent from my One using XDA Premium 4 mobile app

Added the path
Now getting this error:
Code:
[email protected]:~$ mkdir ~/bin
[email protected]:~$ PATH=~/bin:$PATH
[email protected]:~$ curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 23618 100 23618 0 0 38994 0 --:--:-- --:--:-- --:--:-- 41435
[email protected]:~$ chmod a+x ~/bin/repo
[email protected]:~$ cd ~/android/omni
[email protected]:~/android/omni$ repo init -u ssh://[email protected]/android.git -b android-4.3
Permission denied (publickey).
Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.

parker09 said:
Added the path
Now getting this error:
Code:
[email protected]:~$ mkdir ~/bin
[email protected]:~$ PATH=~/bin:$PATH
[email protected]:~$ curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 23618 100 23618 0 0 38994 0 --:--:-- --:--:-- --:--:-- 41435
[email protected]:~$ chmod a+x ~/bin/repo
[email protected]:~$ cd ~/android/omni
[email protected]:~/android/omni$ repo init -u ssh://[email protected]/android.git -b android-4.3
Permission denied (publickey).
Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
Click to expand...
Click to collapse
Try the repo init command in the second post.
Sent from my GT-I9500 now Free

runedrune said:
Try the repo init command in the second post.
Sent from my GT-I9500 now Free
Click to expand...
Click to collapse
Ah yep, it's moving now
Is it supposed to download stuff for other devices eg. asus_flo? I realise I haven't done any mako specific commands because I'm just trying to do the build environment but is that normal or was I supposed to do something to disregard other devices?

runedrune said:
Try the repo init command in the second post.
Sent from my GT-I9500 now Free
Click to expand...
Click to collapse
I error out with this:
" * [new tag] v1.9.5 -> v1.9.5
* [new tag] v1.9.6 -> v1.9.6
object e76efdd7b342577c40aa271fa5ded9d66a783a9b
type commit
tag v1.12.4
tagger Conley Owens <[email protected]> 1380645867 -0700
repo 1.12.4
gpg: Signature made Tue 01 Oct 2013 17:44:27 BST using RSA key ID 692B382C
gpg: Can't check signature: public key not found
error: could not verify the tag 'v1.12.4'"

radjad said:
I error out with this:
" * [new tag] v1.9.5 -> v1.9.5
* [new tag] v1.9.6 -> v1.9.6
object e76efdd7b342577c40aa271fa5ded9d66a783a9b
type commit
tag v1.12.4
tagger Conley Owens <[email protected]> 1380645867 -0700
repo 1.12.4
gpg: Signature made Tue 01 Oct 2013 17:44:27 BST using RSA key ID 692B382C
gpg: Can't check signature: public key not found
error: could not verify the tag 'v1.12.4'"
Click to expand...
Click to collapse
Fix by doing
curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
chmod a+x ~/bin/repo

parker09 said:
Ah yep, it's moving now
Is it supposed to download stuff for other devices eg. asus_flo? I realise I haven't done any mako specific commands because I'm just trying to do the build environment but is that normal or was I supposed to do something to disregard other devices?
Click to expand...
Click to collapse
Right now we don't have roomservice implemented, so you'll need to put the device tree, kernel tree, and any dependencies in a local manifest.
We plan on fixing this in the coming week. roomservice is critical for the sanity of anyone building, but work couldn't start until we switched to github.

esotericizm said:
Fix by doing
curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
chmod a+x ~/bin/repo
Click to expand...
Click to collapse
Thanks for the suggestion, but I got the same error and this doesn't help
Code:
$ repo init -u git://github.com/omnirom/android.git -b android-4.3
.
.
.
object e76efdd7b342577c40aa271fa5ded9d66a783a9b
type commit
tag v1.12.4
tagger Conley Owens <[email protected]> 1380645867 -0700
repo 1.12.4
gpg: Signature made Tue 01 Oct 2013 06:44:27 PM CEST using RSA key ID 692B382C
gpg: Can't check signature: public key not found
error: could not verify the tag 'v1.12.4'
I also tried it with https:// and ssh:// for the init command. Do I need to configure something beforehand? I've just set up a new environment to build.
EDIT: It worked now with the command above. There was probably something wrong with the link. Here it ist without the xda-link:
Code:
$ curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
$ chmod a+x ~/bin/repo

Excappe said:
Thanks for the suggestion, but I got the same error and this doesn't help
Code:
$ repo init -u git://github.com/omnirom/android.git -b android-4.3
.
.
.
object e76efdd7b342577c40aa271fa5ded9d66a783a9b
type commit
tag v1.12.4
tagger Conley Owens <[email protected]> 1380645867 -0700
repo 1.12.4
gpg: Signature made Tue 01 Oct 2013 06:44:27 PM CEST using RSA key ID 692B382C
gpg: Can't check signature: public key not found
error: could not verify the tag 'v1.12.4'
I also tried it with https:// and ssh:// for the init command. Do I need to configure something beforehand? I've just set up a new environment to build.
Click to expand...
Click to collapse
This error is caused by an outdated repo. Definitely! It is! Ensure you are using your new repo command, not the old one.

FWIW I had to add the following to /.repo/manifest.xml in order to utilize my local_manifest:
Code:
<remote name="github"
fetch="https://github.com/" />

CMNein said:
FWIW I had to add the following to /.repo/manifest.xml in order to utilize my local_manifest:
Code:
<remote name="github"
fetch="https://github.com/" />
Click to expand...
Click to collapse
Same here, it wouldn't budge before I added this to manifest.xml:
Code:
<remote name="github"
fetch=".." />

Excappe said:
Thanks for the suggestion, but I got the same error and this doesn't help
Code:
$ repo init -u git://github.com/omnirom/android.git -b android-4.3
.
.
.
object e76efdd7b342577c40aa271fa5ded9d66a783a9b
type commit
tag v1.12.4
tagger Conley Owens <[email protected]> 1380645867 -0700
repo 1.12.4
gpg: Signature made Tue 01 Oct 2013 06:44:27 PM CEST using RSA key ID 692B382C
gpg: Can't check signature: public key not found
error: could not verify the tag 'v1.12.4'
I also tried it with https:// and ssh:// for the init command. Do I need to configure something beforehand? I've just set up a new environment to build.
EDIT: It worked now with the command above. There was probably something wrong with the link. Here it ist without the xda-link:
Code:
$ curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
$ chmod a+x ~/bin/repo
Click to expand...
Click to collapse
make sure you don't have an older version of repo on another $PATH
for instance I had an older version in /bin (not ~/bin) Which was causing issues.

Related

Getting Started

Hello,
I am following the instructions here: http://source.android.com/source/download.html but I find I am having some problems. I am using 32 bit ubuntu.
Firstly, I can not get Java 5 SDK the terminal reports an error that the package cant be found, what can I do to rectify this, is there a work around, is the google page just out dated now?
secondly, I come to the "Installing Repo" section and follow:
Make sure you have a~/bindirectory in your home directory, and check to be sure that this bin directory is in your path:
$ cd ~
$ mkdir bin
$ echo $PATH
Download thereposcript and make sure it is executable:
$ curl http://android.git.kernel.org/repo >~/bin/repo
$ chmod a+x ~/bin/repo
All of that seems to work, however, I must have done something wrong because when I get to the next bit "Initialising a Repo Client" I dont seem to be able to run:
repo init -u git://android.git.kernel.org/platform/manifest.git
I get the following error:
[email protected]:~$ repo init -u git://android.git.kernel.org/platform/manifest.git
No command 'repo' found, did you mean:
Command 'rep' from package 'rep' (universe)
Command 'repl' from package 'nmh' (universe)
Command 'repl' from package 'mailutils-mh' (universe)
repo: command not found
[email protected]:~$ cd bin
[email protected]:~/bin$ dir
repo
[email protected]:~/bin$
As you can see, I have a bin directory, and inside it is repo
Whats the score here??
Hi,
You can choose one of theese
a. ~/bin/repo init.....
b. export PATH=$PATH:~/bin/
repo init......
HTH
Hey that's got it, so simple really, but the best answers are... thanks bud

[Guide] Building CyanogenMod 7 (CM7) on Mac OSX Lion

This is a guide to build your own CM7 on Mac OSX Lion. I can't guarantee 100% that this will work for everyone, but it worked for me. I want to thank Paul from Modaco, CyanogenMod team, Batista Harahap, ahbeng, and anyone else I can't remember atm.
1. Download and install Xcode, Java Mac OS X 10.5 SDK (later versions don't seem to work)
2. I recommend uninstalling existing MacPorts (using the codes below) and then install a fresh copy just to be safe.
Code:
$ sudo port -fp uninstall --follow-dependents installed
$ sudo rm -rf /opt/local /Applications/DarwinPorts /Applications/MacPorts /Library/LaunchDaemons/org.macports.* /Library/Receipts/DarwinPorts*.pkg /Library/Receipts/MacPorts*.pkg /Library/StartupItems/DarwinPortsStartup /Library/Tcl/darwinports1.0 /Library/Tcl/macports1.0 ~/.macports
3. Follow these steps below to teleport String errors at compile time
Code:
$ sudo vi /opt/local/etc/macports/sources.conf
* press ]]
* press i
* Append # at the beginning of the line
* Press Enter
* Add the following lines
Code:
file:///Users/Shared/dports
rsync://rsync.macports.org/release/ports/
* Press Esc
* Type :wq and press enter
4. Update Macports and install the necessary packages and revert gmake to 3.81 (This takes a long time)
Code:
$ sudo port selfupdate
$ POSIXLY_CORRECT=1 sudo port install gmake libsdl git-core gnupg e2fsprogs gsed curl libiptcdata xorg-libX* pngcrush findutils
$ sudo ln -s /opt/local/bin/gsed /opt/local/bin/sed
$ sudo ln -s /opt/local/libexec/gnubin/find /opt/local/bin/find
$ vi /opt/local/etc/macports/sources.conf
$ mkdir /Users/Shared/dports
$ cd /Users/Shared/dports
$ svn co --revision 50980 http://svn.macports.org/repository/macports/trunk/dports/devel/gmake/ devel/gmake/
$ portindex /Users/Shared/dports
$ sudo port install gmake @3.81
5. comment a line in one of Darwin’s C Library to get rid of compile time errors
Code:
$ sudo vi /usr/include/string.h
* Press :143
* Press i
* Append //
* Press Esc
* Type :wq!
* Press enter
6. Add a symlink for 10.5 SDKs
Code:
$ sudo ln -s /Developer/SDKs/MacOSX10.6.sdk /Developer/SDKs/MacOSX10.5.sdk
7. Create a sparseimage with a Case Sensitive FS
a. Open the Disk Utility (/Applications/Utilities/Disk Utility.app).
b. Click on New Image.
c. Save as "cyanogenmod.sparseimage" and set the following parameters as followed:
d. Name: "cyanogenmod"
e. Size: 15 GB is minimum recommended (A sparseimage will save unused space)
f. Format: Mac OS Extended (CASE-SENSITIVE, Journaled)
g. Encryption: none, Partition- Single Apple Partition Map
h. Image Format: Sparse Disk Image (this will save you disk space)
i. Save this wherever you like, and then double-click the sparseimage file to mount.
j. Your workspace will be: /Volumes/cyanogenmod/
8. Macports version of e2fsprogs will fail to compile, download the source and compile it yourself
Code:
$ mkdir -p ~/src
$ cd ~/src
$ git clone http://git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git
$ cd e2fsprogs
$ ./configure --prefix=/opt/local
$ make -j4 && sudo make install
9. Set up the pre-requisites for CyanogenMod to compile, there are
Code:
$ cd /Volumes/cyanogenMod
$ mkdir -p bin
$ curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > bin/repo
$ chmod a+x bin/repo
$ mkdir -p android/system/
$ PATH=${PATH}:/Volumes/cyanogenmod/bin:
$ echo "PATH=\${PATH}:/Volumes/cyanogenmod/bin:" >> ~/.profile
10. Clone CyanogenMod repository into our sparse image (This takes a long time)
Code:
$ cd /Volumes/cyanogenmod/android/system
$ repo init -u git://github.com/CyanogenMod/android.git -b gingerbread
$ repo sync
11. Now to get all closed source binaries from the device and into our device build folder (replace *company* and *model* with the device you want e.g. /lge/p990)
Code:
$ cd /Volumes/cyanogenmod/android/system/device/*company*/*model*
$ ./extract-files.sh
12. ROMManager is a requirement for CyanogenMod
Code:
$ /Volumes/cyanogenmod/android/system/vendor/cyanogen/get-rommanager
13. edit cm source to make it compile on lion
Add lines in red to android/system/external/elfutils/config-compat-darwin.h:
Code:
[COLOR="Red"]#if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 1070
[/COLOR]
static inline size_t strnlen (const char *__string, size_t __maxlen)
{

int len = 0;
while (__maxlen-- && *__string++)
len++;

return len;
}
[COLOR="red"]#endif[/COLOR]
Comment out every line in android/system/external/qemu/Android.mk:
Code:
# the following test is made to detect that we were called
# through the 'm' or 'mm' build commands. if not, we use the

# standard QEMU Makefile
#
#ifeq ($(DEFAULT_GOAL),droid)
# LOCAL_PATH:= $(call my-dir)
# include $(LOCAL_PATH)/Makefile.android
#else
# include Makefile.qemu
#endif
14. Now here comes the real fun, let’s compile CyanogenMod. (replace *model* with the device you want e.g. cyanogen_p990)
Code:
$ cd /Volumes/gingerbread/android/system/
$ cp ./vendor/cyanogen/products/cyanogen_*model*.mk ./buildspec.mk
$ . build/envsetup.sh
$ lunch cyanogen_*model*-eng
$ make -j`sysctl -an hw.logicalcpu` bacon
If the build was successful, there should be an update-cm-X.X.X-RC0-KANG-signed.zip in the /android/system/out/target/product/*model* folder.
If you were successful, go get yourself a treat.

[GUIDE] Building CyanogenMod 9 from Source with openSuSE 12.1

Introduction
If you have tried to build Android on systems other than Ubuntu (or Ubuntu based systems) you may have noticed, that there are pretty much no guides for other systems.
I finally set up my openSuSE to build CM9 successfully, and would like to share the process with you.
I will also try to adopt this guide for CM10 if i find the time.
If you find mistakes feel free to post them here or PM me.
Contents
Requirements
About this guide
Install "Oracle JDK"
Install other needed packages
Install "make 3.81"
Install "Android SDK"
Set up source directories
Set up "repo"
Set up repositories
Update source code
Update device specific source code
Copy proprietary files
Download prebuilts
Build CyanogenMod 9
Done!
Possible build errors on openSuSE
Credits
1. Requirements
openSuSE 12.1 64bit (may work on other versions too)
a good internet connection
as much RAM as possible (at least 2GB to finish a build, but that will take very, very long.)
patience
common sense
Note: I did all this in a virtual machine, but i highly recommend installing Linux on your hardware. Building Android takes a long time even on high end hardware.
2. About this guide
Lines beginning with '$' are supposed to be entered in shell (without the $ sign).
File names are bold.
This guide assumes that you set up the sources at ~/android/system/. Feel free to change that.
bacon = device name (e.g. i9300 for Samsung Galaxy SIII I9300. See CyanogenMod Homepage for other devices.)
3. Install "Oracle JDK"
Download latest jdk-6uXX-linux-x64-rpm.bin from http://www.oracle.com/technetwork/java/javase/downloads/jdk6-downloads-1637591.html
$ <downloadfolder>/jdk-6uXX-linux-x64-rpm.bin -x
Open <downloadfolder> in your file manager
Right click jdk-6uXX-linux-x64-rpm -> open with -> Install Software
YaST Software Manager will open up.
DON'T click accept yet.
Search for openJDK and check uninstall for ALL openJDK packages.
DON'T click accept yet, go to next chapter.
4. Install other needed packages
Search and install following packages with YaST
git
gnupg
flex
bison
gperf
SDL-devel
esound-devel
wxGTK-devel
zip
curl
ncurses-devel
ncurses-devel 32bit
zlib-devel
zlib-devel 32bit
gcc-c++
glibc-devel 32bit
libstdc++ 32bit
mesa libs
Now click accept.
5. Install "make 3.81"
Note: Other versions won't work.
Download source from http://ftp.gnu.org/gnu/make/make-3.81.tar.gz.
Extract downloaded file.
$ cd <extracted folder>
$ ./configure
$ make
$ make install
6. Install "Android SDK"
Note: This is pretty straightforward. I will add this section later.
7. Set up source directories
$ mkdir ~/android
$ mkdir ~/android/system
$ mkdir ~/android/cache
8. Set up "repo"
Note: "repo" is a tool by Google, created to make access to git and gerrit very, very easy.
$ mkdir ~/bin
$ curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ~/bin/repo
$ chmod a+x ~/bin/repo
Open ~/.bashrc in a file editor (e.g. kwrite)
Add the following line:
PATH=~/bin:$PATH
Save and close.
Close your shell and re-open it.
9. Set up repositories
$ cd ~/android/system
$ repo init -u git://github.com/CyanogenMod/android.git -b ics
10. Update source code
$ cd ~/android/system
$ repo sync -jX
X = number of connections. Try X = 1 if there are problems downloading.
This will take a while.
11. Update device specific source code
$ cd ~/android/system
$ . build/envsetup.sh && breakfast bacon
12. Copy proprietary files
Note: This only needs to be run once. You will need CyanogenMod 9 running on the device you are building for to complete this.
Connect the phone via USB.
Install USB drivers to get ADB access.
$ cd ~/android/system/device/<manufacturer>/<devicename>
$ ./extract-files.sh
13. Download prebuilts
$ ~/android/system/vendor/cm/get-prebuilts
14. Build CyanogenMod 9
$ ~/android/system
$ . build/envsetup.sh && brunch bacon
15. Done!
You now should have a CWM-flashable .zip file ~/android/system/out/target/product/maguro/cm-9-XXXXX-UNOFFICIAL-bacon.zip.
16. Possible build errors on openSuSE
Because Ubuntu is based on Debian and openSuSE is based on Slackware, you will probable get some build errors. In post 2 is a list of errors that can occur and how to fix them.
Credits
CyanogenMod Team
CyanogenMod Wiki
The Software Rouge (http://thesoftwarerogue.blogspot.de/2011/11/building-android-ics-ice-cream-sandwich.html)
Note: I got the fixes for build errors from some page in Google Groups. I can't find it anymore. If someone finds it, please PM me.
Possible build errors on openSuSE
Note: I used kwrite as text editor. To use another, just change kwrite to whatever editor you want to use.
Note: Open shell and got to ~/android/system
Error 1
make gets killed at some point
Fix: you need more RAM to finish the build.
Error 2
Code:
frameworks/base/include/utils/KeyedVector.h:193:31: note: declarations in dependent base ‘android::KeyedVector<android::String8, android::sp<AaptDir> >’ are not found by unqualified lookup
frameworks/base/include/utils/KeyedVector.h:193:31: note: use ‘this->indexOfKey’ instead
make: *** [out/host/linux-x86/obj/EXECUTABLES/aapt_intermediates/AaptAssets.o] Error 1
Fix:
$ kwrite frameworks/base/tools/aapt/Android.mk
Add '-fpermissive' to line 31:
LOCAL_CFLAGS += -Wno-format-y2k -fpermissive
Error 3
Code:
frameworks/base/include/utils/KeyedVector.h:193:31: error: ‘indexOfKey’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
frameworks/base/include/utils/KeyedVector.h:193:31: note: declarations in dependent base ‘android::KeyedVector<android::String8, android::wp<android::AssetManager::SharedZip> >’ are not found by unqualified lookup
frameworks/base/include/utils/KeyedVector.h:193:31: note: use ‘this->indexOfKey’ instead
make: *** [out/host/linux-x86/obj/STATIC_LIBRARIES/libutils_intermediates/AssetManager.o] Error 1
Fix:
$ kwrite frameworks/base/libs/utils/Android.mk
Add '-fpermissive' to line 64:
LOCAL_CFLAGS += -DLIBUTILS_NATIVE=1 $(TOOL_CFLAGS) -fpermissive
Error 4
Code:
external/srec/tools/thirdparty/OpenFst/fst/lib/cache.h:136:11: note: use ‘this->SetState’ instead
make: *** [out/host/linux-x86/obj/EXECUTABLES/grxmlcompile_intermediates/grxmlcompile.o] Error 1
Fix:
$ cd external/srec
$ wget "https://github.com/CyanogenMod/android_external_srec/commit/4d7ae7b79eda47e489669fbbe1f91ec501d42fb2.diff"
$ patch -p1 < 4d7ae7b79eda47e489669fbbe1f91ec501d42fb2.diff
$ rm -f 4d7ae7b79eda47e489669fbbe1f91ec501d42fb2.diff
$ cd ../..
Error 5
Code:
development/tools/emulator/opengl/host/tools/emugen/main.cpp:79:9: error: ‘optind’ was not declared in this scope
development/tools/emulator/opengl/host/tools/emugen/main.cpp:92:45: error: ‘optind’ was not declared in this scope
make: *** [out/host/linux-x86/obj/EXECUTABLES/emugen_intermediates/main.o] Error 1
Fix:
$ kwrite development/tools/emulator/opengl/host/tools/emugen/main.cpp
Add '#include <getopt.h>' to list of includes:
#include <getopt.h>
Error 6
Code:
host C++: liboprofile_pp <= external/oprofile/libpp/arrange_profiles.cpp
In file included from external/oprofile/libpp/arrange_profiles.cpp:24:0:
external/oprofile/libpp/format_output.h:94:22: error: reference ‘counts’ cannot be declared ‘mutable’ [-fpermissive]
make: *** [out/host/linux-x86/obj/STATIC_LIBRARIES/liboprofile_pp_intermediates/arrange_profiles.o] Error 1
Fix:
$ kwrite external/oprofile/libpp/format_output.h
Remove 'mutable' from 'mutable counts_t & counts;' on line 94:
counts_t & counts;
Error 7
Code:
development/tools/emulator/opengl/shared/OpenglCodecCommon/GLSharedGroup.cpp:345:65: required from here
frameworks/base/include/utils/KeyedVector.h:193:31: error: ‘indexOfKey’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
frameworks/base/include/utils/KeyedVector.h:193:31: note: declarations in dependent base ‘android::KeyedVector<unsigned int, ShaderData*>’ are not found by unqualified lookup
frameworks/base/include/utils/KeyedVector.h:193:31: note: use ‘this->indexOfKey’ instead
make: *** [out/host/linux-x86/obj/STATIC_LIBRARIES/libOpenglCodecCommon_intermediates/GLSharedGroup.o] Error 1
Fix:
$ kwrite development/tools/emulator/opengl/Android.mk
Add '-fpermissive' to line 25:
EMUGL_COMMON_CFLAGS := -DWITH_GLES2 -fpermissive
Error 8
Code:
/usr/bin/ld: note: 'XInitThreads' is defined in DSO /lib/libX11.so.6 so try adding it to the linker command line
/lib/libX11.so.6: could not read symbols: Invalid operation
collect2: error: ld returned 1 exit status
make: *** [out/host/linux-x86/obj/EXECUTABLES/emulator_renderer_intermediates/emulator_renderer] Error 1
Fix:
$ kwrite development/tools/emulator/opengl/host/renderer/Android.mk
Add new entry 'LOCAL_LDLIBS += -lX11' after line 6 as shown:
LOCAL_SRC_FILES := main.cpp
LOCAL_CFLAGS += -O0 -g
LOCAL_LDLIBS += -lX11
#ifeq ($(HOST_OS),windows)
#LOCAL_LDLIBS += -lws2_32
Error 9
Code:
external/llvm/include/llvm/ADT/PointerUnion.h:56:10: error: enumeral mismatch in conditional expression: ‘llvm::PointerLikeTypeTraits<llvm::PointerUnion<clang::Stmt*, const clang::Type*> >::<anonymous enum>’ vs ‘llvm::PointerLikeTypeTraits<clang::eek:bjCInterfaceDecl*>::<anonymous enum>’ [-Werror]
cc1plus: all warnings being treated as errors
make: *** [out/host/linux-x86/obj/EXECUTABLES/llvm-rs-cc_intermediates/slang_rs.o] Error 1
Fix:
$ kwrite frameworks/compile/slang/Android.mk
Remove '-Werror' from line 22:
local_cflags_for_slang := -Wno-sign-promo -Wall -Wno-unused-parameter
Error 10
Code:
frameworks/base/libs/rs/rsFont.cpp:224:76: required from here
frameworks/base/include/utils/KeyedVector.h:193:31: error: ‘indexOfKey’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
frameworks/base/include/utils/KeyedVector.h:193:31: note: declarations in dependent base ‘android::KeyedVector<unsigned int, android::renderscript::Font::CachedGlyphInfo*>’ are not found by unqualified lookup
frameworks/base/include/utils/KeyedVector.h:193:31: note: use ‘this->indexOfKey’ instead
make: *** [out/host/linux-x86/obj/STATIC_LIBRARIES/libRS_intermediates/rsFont.o] Error 1
Fix:
$ kwrite frameworks/base/libs/rs/Android.mk
Add '-fpermissive' to line 183:
LOCAL_CFLAGS += -Werror -Wall -Wno-unused-parameter -Wno-unused-variable -fpermissive
Error 11
Code:
external/mesa3d/src/glsl/linker.cpp:1394:49: error: expected primary-expression before ‘,’ token
......
external/mesa3d/src/glsl/linker.cpp:1734:59: error: ‘offsetof’ was not declared in this scope
make: *** [out/host/linux-x86/obj/STATIC_LIBRARIES/libMesa_intermediates/src/glsl/linker.o] Error 1
Fix:
$ kwrite external/mesa3d/src/glsl/linker.cpp
Add '#include <stddef.h>' to list of includes as shown:
#include <climits>
#include <stddef.h>
#include <pixelflinger2/pixelflinger2_interface.h>
Error 12
Code:
external/gtest/src/../include/gtest/gtest-param-test.h:287:58: note: ‘template<class Container> testing::internal::ParamGenerator<typename Container::value_type> testing::ValuesIn(const Container&)’ declared here, later in the translation unit
make: *** [out/host/linux-x86/obj/STATIC_LIBRARIES/libgtest_host_intermediates/gtest-all.o] Error 1
Fix 1:
$ kwrite external/gtest/src/Android.mk
Add '-fpermissive' to lines 52 and 70 (both lines contain same info)
LOCAL_CFLAGS += -O0 -fpermissive
Fix 2:
$ kwrite external/gtest/include/gtest/internal/gtest-param-util.h
Add '#include <stddef.h>' to list of includes as shown:
#include <vector>
#include <stddef.h>
#include <gtest/internal/gtest-port.h>
Error 13
Code:
frameworks/compile/slang/slang_rs_export_foreach.cpp: In static member function ‘static slang::RSExportForEach* slang::RSExportForEach::Create(slang::RSContext*, const clang::FunctionDecl*)’:
frameworks/compile/slang/slang_rs_export_foreach.cpp:249:23: error: variable ‘ParamName’ set but not used [-Werror=unused-but-set-variable]
cc1plus: all warnings being treated as errors
make: *** [out/host/linux-x86/obj/EXECUTABLES/llvm-rs-cc_intermediates/slang_rs_export_foreach.o] Error 1
Fix:
$ kwrite kwrite frameworks/compile/slang/Android.mk
change
local_cflags_for_slang := -Wno-sign-promo -Wall -Wno-unused-parameter -Werror
to
local_cflags_for_slang := -Wno-sign-promo -Wall -Wno-unused-parameter
reserved #2
Wish somebody would build for the LG optimistic logic
Sent from my LGL35G using xda premium

[Guide] How to build kernel from source on ubuntu 13.10...

Here are the steps to build your own kernel from source. This guide is showing you how to build your first the stock kernel on your own..... It is kick start for making things on your own way....
This guide applies to i9082/i9082L and general devices also.:laugh:
This guide assumes you have basic knowledge of linux and linux system configuration.
Prerequisites
1. Ubuntu 13.10
2. patience...lots and lots of patience.
Click to expand...
Click to collapse
Here starts the fun:-
1. Installing ubuntu 13.10.
This can be done in 3 ways and I am not gonna cover it all.
- along with windows ,i.e dual boot
- in virtualbox within windows
- as a windows application installation with "wubi" installer
For starting user i think second option, i.e installing in virtualbox is best.
here's starting tutorials
http://www.youtube.com/watch?v=tDDRFiwHujg
NOTE - you should have atleast 100 Gb partion for virtualbox.
Click to expand...
Click to collapse
2. Getting the kernel source.
Download source from http://opensource.samsung.com/
Type i9082 in search box and download "GT-I9082_SEA_JB_Opensource_Update1.zip"
After download unzip the source into new folder in home directory.
Type in terminal from you kernel directory.
Code:
unzip GT-I9082_SEA_JB_Opensource_Update1.zip
Then extract tar.
Code:
mkdir kernel
tar xzf kernel.tar.gz -C kernel
Click to expand...
Click to collapse
3. Setting up building environment.
Copied from http://soupdawg.wordpress.com/
All credits goes to
mysteriously inconspicuous
Click to expand...
Click to collapse
Initializing a fresh Android Build Environment in Ubuntu 13.10 sucks, right? The instructions at the AOSP page are outdated and inaccurate. Near as I can tell, they try to have you install 2 JDKs, the first one not even being the correct link for Saucy Salamander, and the second being OpenJDK. Which might work. But I dunno about all that, I’d rather have Oracle’s official stamp when it comes to building for Android.
Currently most of the guides are up to 12.04 LTS, which is fine and dandy, but being on the cutting edge is nice too.
This guide applies to all variations of Ubuntu 13.10 Saucy Salamander 64 bit. Do not use the 32 Bit version. Also, PAY CLOSE ATTENTION when to use “sudo” and when to not. It can make things funky if you do something as root that you shouldn’t.
Much thanks goes out to Google, ProTekk, Canonical, and everyone else that I read a random paragraph here and snippet there.
First, let’s set up the correct JDK.
Many of you probably have some kind of wrong Java installed unless you’re starting with a fresh Ubuntu base, and even then maybe.
Let’s get rid of that. Copy and paste this into a Terminal window:
Code:
sudo apt-get purge openjdk-\* icedtea-\* icedtea6-\*
Follow the instructions to remove OpenJDK.
If you must keep it, it’s possible. But I’m not going to tell you how to do it here. I don’t want any chance of confusion or mistake.
Now copy and paste the following into the Terminal:
Code:
sudo add-apt-repository ppa:webupd8team/java
This will add the correct PPA to your system for updated builds of Java 6 JDK that are compatible with 13.10.
No more unrecognized Java version errors! And it will update automatically with the rest of your system.
Next, we actually need to install the package. More copy-paste:
Code:
sudo apt-get update && sudo apt-get install oracle-java6-installer
Follow the on-screen instructions. You have to Accept the Licensing Agreement to complete the install. Hopefully no human centipede clauses.
Let’s make sure the correct version of Java is activated, run the following Terminal command:
Code:
java -version
You should see something like the following:
Code:
java version “1.6.0_45″
Java(TM) SE Runtime Environment (build 1.6.0_45-b06)
Java HotSpot(TM) 64-Bit Server VM (build 20.12-b01, mixed mode)
Ok, back to a fresh Terminal prompt. Time for installing the guts to build stuff in Ubuntu:
Code:
sudo apt-get install git-core gnupg ccache lzop flex bison gperf build-essential zip curl zlib1g-dev zlib1g-dev:i386 libc6-dev lib32ncurses5 lib32z1 lib32bz2-1.0 lib32ncurses5-dev x11proto-core-dev libx11-dev:i386 libreadline6-dev:i386 lib32z-dev libgl1-mesa-glx:i386 libgl1-mesa-dev g++-multilib mingw32 tofrodos python-markdown libxml2-utils xsltproc readline-common libreadline6-dev libreadline6 lib32readline-gplv2-dev libncurses5-dev lib32readline5 lib32readline6 libreadline-dev libreadline6-dev:i386 libreadline6:i386 bzip2 libbz2-dev libbz2-1.0 libghc-bzlib-dev lib32bz2-dev libsdl1.2-dev libesd0-dev squashfs-tools pngcrush schedtool libwxgtk2.8-dev python
When that is done installing, run the following command in your Terminal window:
Code:
sudo ln -s /usr/lib/i386-linux-gnu/mesa/libGL.so.1 /usr/lib/i386-linux-gnu/libGL.so
That’s it on the package side of things.
You guessed it, time for more Terminal. This really is the easiest way, seriously. And it’s totally worth it when you’re basking in the glory of a bunch of people on XDA.
The binary for a program called “repo” will let you talk to git servers and download all that precious source code. That second part after the && allows it to be executable:
Code:
mkdir ~/bin && curl http://commondatastorage.googleapis.com/git-repo-downloads/repo ~/bin/repo && chmod a+x ~/bin/repo
Use your favorite text editor to open ~/.bashrc
I like nano:
Code:
sudo nano ~/.bashrc
At the very bottom, add the following line:
Code:
export PATH=~/bin:$PATH
Save it. In nano that would be Ctrl-O and then Enter. Then Ctrl-X to exit back to a prompt. Restart bash:
Code:
source ~/.bashrc
That should be everything. Now you’re ready to build Android the right way. Luck!
4. Installing toolchain
Anyway, first order of the day is to get the official arm toolchain, which I'm going to install in /usr/local/share/ since I plan to keep using it for some time:
Code:
# cd /usr/local/share/
# git clone https://android.googlesource.com/platform/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6
Cloning into 'arm-eabi-4.6'...
remote: Sending approximately 124.64 MiB ...
remote: Counting objects: 33, done
remote: Finding sources: 100% (33/33)
remote: Total 580 (delta 146), reused 580 (delta 146)
Receiving objects: 100% (580/580), 124.64 MiB | 715 KiB/s, done.
Resolving deltas: 100% (146/146), done.
Now, let's add that arm toolchain to our path:
Code:
# export PATH=$PATH:/usr/local/share/arm-eabi-4.6/bin
# arm-eabi-gcc --version
arm-eabi-gcc (GCC) 4.6.x-google 20120106 (prerelease)
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
5. Compiling kernel
Now we need to set the variables that will tell the OS that we're cross compiling (again, something that you may want to do in your .profile using something like alias cross='export ARCH="arm";export SUBARCH="arm";export CROSS_COMPILE="arm-eabi-"'):
Code:
# export ARCH=arm
# export SUBARCH=arm
# export CROSS_COMPILE=arm-eabi-
Finally, we can initialize our default config and get going:
Prepare source for new compilation
Code:
make bcm28155_capri_ss_baffin_rev05_defconfig
HOSTCC scripts/basic/fixdep
HOSTCC scripts/kconfig/conf.o
SHIPPED scripts/kconfig/zconf.tab.c
SHIPPED scripts/kconfig/lex.zconf.c
SHIPPED scripts/kconfig/zconf.hash.c
HOSTCC scripts/kconfig/zconf.tab.o
HOSTLD scripts/kconfig/conf
arch/arm/mach-capri/custom_boards/Kconfig:19:warning: defaults for choice values not supported
arch/arm/mach-capri/custom_boards/Kconfig:25:warning: defaults for choice values not supported
arch/arm/mach-capri/custom_boards/Kconfig:31:warning: defaults for choice values not supported
arch/arm/mach-capri/custom_boards/Kconfig:37:warning: defaults for choice values not supported
#
# configuration written to .config
#
Code:
# make -j*
(...)
OBJCOPY arch/arm/boot/zImage
Kernel: arch/arm/boot/zImage is ready
* stands for number of cpus your computer has.like my has 4 so I will make it j4
* bcm28155_capri_ss_baffin_rev05_defconfig is stock config, for cm11 you will have diffrent config and for some cutom kernel something else.
6. Crafting an Android boot.img
The format of this Android boot images can be found in the bootimg.h of the mkbootimg tool from the android platform/system/core source. I guess we have to start somewhere, and we'll need to produce our own images, so let's start by fetching and recompiling mkbootimg then.
Code:
# git clone https://android.googlesource.com/platform/system/core bootimg-tools
Cloning into 'bootimg-tools'...
remote: Counting objects: 92, done
remote: Finding sources: 100% (92/92)
remote: Total 19302 (delta 11674), reused 19302 (delta 11674)
Receiving objects: 100% (19302/19302), 5.87 MiB | 655 KiB/s, done.
Resolving deltas: 100% (11674/11674), done.
# cd bootimg-tools/libmincrypt/
# gcc -c *.c -I../include
# ar rcs libmincrypt.a *.o
# cd ../mkbootimg
# gcc mkbootimg.c -o mkbootimg -I../include ../libmincrypt/libmincrypt.a
mkbootimg.c: In function 'main':
mkbootimg.c:245:9: warning: assignment discards 'const' qualifier from pointer target type [enabled by default]
# cp mkbootimg /usr/local/bin/
# cd ../cpio
# gcc mkbootfs.c -o mkbootfs -I../include
# cp mkbootfs /usr/local/bin/
New improved bootimg-tools can be found at.
Code:
# wget https://github.com/pbatard/bootimg-tools/archive/master.zip
lets compile from there
Code:
# cd /usr/src/android/bootimg-tools/mkbootimg/
# wget https://raw.github.com/pbatard/bootimg-tools/master/mkbootimg/unmkbootimg.c
# gcc -o unmkbootimg unmkbootimg.c
# cp unmkbootimg /usr/local/bin/
Now at last, you have the minimum of unmkbootimg, mkbootimg and mkbootfs installed in your path, and we can get going with our testing of the kernel.
I'll assume that you have a /usr/src/android/boot where you copied your boot.img, so let's get going....
Code:
# cd /usr/src/android/boot/
# ls
boot.img
# unmkbootimg -i boot.img
kernel written to 'kernel' (4738320 bytes)
ramdisk written to 'ramdisk.cpio.gz' (516287 bytes)
To rebuild this boot image, you can use the command:
mkbootimg --base 0 --pagesize 4096 --kernel_offset 0xa2008000 --ramdisk_offset 0xa3000000 --second_offset 0xa2f00000 --tags_offset 0xa2000100 --cmdline 'console=ttyS0,115200n8 [email protected] androidboot.console=ttyS0 vc-cma-mem=0/[email protected]' --kernel kernel --ramdisk ramdisk.cpio.gz -o boot.img
Code:
# ls
boot.img kernel ramdisk.cpio.gz
As an aside that you don't need to run, but since it should be elementary that this is the basic functionality you want from a proper boot image unpack tool, we can confirm that the data provided by the unpack tool will produce a boot.img that is binary identical to the original one-
Code:
# mkbootimg --base 0 --pagesize 4096 --kernel_offset 0xa2008000 --ramdisk_offset 0xa3000000 --second_offset 0xa2f00000 --tags_offset 0xa2000100 --cmdline 'console=ttyS0,115200n8 [email protected] androidboot.console=ttyS0 vc-cma-mem=0/[email protected]' --kernel kernel --ramdisk ramdisk.cpio.gz -o myboot.img
Code:
# ls
boot.img kernel myboot.img ramdisk.cpio.gz
# cmp -l boot.img myboot.img
#
Moving on. Since we just want to test a kernel, we shouldn't really have to touch the cpio image (ramdisk), but then again, my goal here is to give you as many pointers as I can, so we might as well see how we craft our own ramdisk while we're at it. What we're going to do here, as an academical exercise, is add an it_works file at the root of the filesystem, which we'll look for after we booted, to confirm that can use our modified stuff all the way through.
Code:
# mkdir ramdisk
# cd ramdisk
# gunzip -c ../ramdisk.cpio.gz | cpio -iu
1841 blocks
# ls
charger init.superuser.rc
data init.trace.rc
default.prop init.usb.rc
dev lpm.rc
file_contexts proc
fstab.capri_ss_baffin property_contexts
fstab.goldfish res
init sbin
init.bcm281x5.usb.rc seapp_contexts
init.capri_ss_baffin.rc sepolicy
init.cm.rc sys
init.environ.rc system
init.goldfish.rc ueventd.capri_ss_baffin.rc
init.log.rc ueventd.goldfish.rc
init.rc ueventd.rc
init.recovery.capri_ss_baffin.rc
# touch it-works
# ls
charger init.superuser.rc
data init.trace.rc
default.prop init.usb.rc
dev it-works
file_contexts lpm.rc
fstab.capri_ss_baffin proc
fstab.goldfish property_contexts
init res
init.bcm281x5.usb.rc sbin
init.capri_ss_baffin.rc seapp_contexts
init.cm.rc sepolicy
init.environ.rc sys
init.goldfish.rc system
init.log.rc ueventd.capri_ss_baffin.rc
init.rc ueventd.goldfish.rc
init.recovery.capri_ss_baffin.rc ueventd.rc
# find . | cpio -o -H newc | gzip > ../myramdisk.cpio.gz
1850 blocks
# cd ..
# ls
boot.img kernel myramdisk.cpio.gz ramdisk/ ramdisk.cpio.gz
We're finally set for the last part, where we copy the kernel we compiled earlier, and invoke mkbootimg with the set of parameters we got from unmkbootimg, and use both our modified kernel and cpio image:
Code:
# cp ~/kernel/arch/arm/boot/zImage .
# ls
boot.img kernel myramdisk.cpio.gz ramdisk/ ramdisk.cpio.gz zImage*
# mkbootimg --base 0 --pagesize 4096 --kernel_offset 0xa2008000 --ramdisk_offset 0xa3000000 --second_offset 0xa2f00000 --tags_offset 0xa2000100 --cmdline 'console=ttyS0,115200n8 [email protected] androidboot.console=ttyS0 vc-cma-mem=0/[email protected]' --kernel zImage --ramdisk myramdisk.cpio.gz -o myboot.img
# ls
boot.img kernel myboot.img myramdisk.cpio.gz ramdisk/ ramdisk.cpio.gz zImage*
7. testing new boot.img
Finally, a custom boot.img we can test. Let's press on by copying this myboot.img file into the directory we have adb and fastboot installed and run the following ser of commands which, unlike what many other guides seem to advise (what the heck, guys?), is NOT going to flash the kernel/boot.img but simply run it from memory. This means that, in case there's any mishap, you can simply power the "grand" off and you'll be good as new:
Code:
# ./adb start-server
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
# ./adb reboot bootloader
# ./fastboot boot myboot.img
downloading 'boot.img'...
OKAY [ 0.223s]
booting...
OKAY [ 0.023s]
finished. total time: 0.246s
All in all, this looks fairly good. And a quick look to the root filesystem (through adb shell or through ssh) will also confirm that our it_works file is there, so we can also add whatever we want on the initial filesystem. Neat!
From there on, you can go ahead and tweak your kernel and initial filesystem exactly as you see fit. And after you have tested that everything works as it should, you can go ahead and flash the boot partition with your shiny custom boot.img, using:
ODIN or cwm flashable zip
This is last part...
8. making flashable files
Tar your boot.img file so it can be flashed with Odin.
tar cvf mynewkernel.tar boot.img
md5sum -t mynewkernel.tar >> mynewkernel.tar
mv mynewkernel.tar mynewkernel.tar.md5
Click to expand...
Click to collapse
Note:- myboot.img is renamed to boot.img
9.Flashing kernel through ODIN
Flash mynewkernel.tar.md5 with odin under PDA. Please follow the flashing guides found in other posts.
Hope i help few of you...
Please HIT thanks if you find this helpful.:laugh:
Thankyou k2wl for this tutorial and pls also tell how to get pawitp source code for rom and kernel from his repositries : https://github.com/pawitp/android_device_samsung_i9082
https://github.com/pawitp/android_kernel_samsung_i9082
Repo tool is not working because there is no android manifest file in his repository
Pls help me
mr.phantom said:
Thankyou k2wl for this tutorial and pls also tell how to get pawitp source code for rom and kernel from his repositries : https://github.com/pawitp/android_device_samsung_i9082
https://github.com/pawitp/android_kernel_samsung_i9082
Repo tool is not working because there is no android manifest file in his repository
Pls help me
Click to expand...
Click to collapse
run the following in terminal
$git clone https://github.com/pawitp/android_device_samsung_i9082.git
and
$ git clone https://github.com/pawitp/android_kernel_samsung_i9082.git
k2wl said:
run the following in terminal
$git clone https://github.com/pawitp/android_device_samsung_i9082.git
and
$ git clone https://github.com/pawitp/android_kernel_samsung_i9082.git
Click to expand...
Click to collapse
well i already have done that cloning for cm11 but it had only downloaded files around 200KB and i dont think so that cm11 source code would be that much small
hi
mr.phantom said:
well i already have done that cloning for cm11 but it had only downloaded files around 200KB and i dont think so that cm11 source code would be that much small
Click to expand...
Click to collapse
That's not cm11 source. For that u need another tutorial.
Meanwhile try wiki.CyanogenMod.org
It has instructions for Building for new device
Code:
unmkbootimg.c:25:21: fatal error: bootimg.h: No such file or directory
#include "bootimg.h"
^
compilation terminated.
Getting this while compiling unmkbootimg
i actually am surprises that there are many unofficial CMs in high ends with HALO IN IT.. though our developers try to make rom as close to real one as possible...what if the users want halo integration (as developers only know it :/)
help..
akiratoriyama said:
Code:
unmkbootimg.c:25:21: fatal error: bootimg.h: No such file or directory
#include "bootimg.h"
^
compilation terminated.
Getting this while compiling unmkbootimg
Click to expand...
Click to collapse
try compiling as a root.
k2wl said:
try compiling as a root.
Click to expand...
Click to collapse
How to convert zImage to boot.img
Or do I have to directly copy it ?
Sent from my GT-I9082 using Tapatalk
raghavsharmaxda said:
i actually am surprises that there are many unofficial CMs in high ends with HALO IN IT.. though our developers try to make rom as close to real one as possible...what if the users want halo integration (as developers only know it :/)
help..
Click to expand...
Click to collapse
k2wl said:
try compiling as a root.
Click to expand...
Click to collapse
akiratoriyama said:
How to convert zImage to boot.img
Or do I have to directly copy it ?
Sent from my GT-I9082 using Tapatalk
Click to expand...
Click to collapse
read the last section of post, it covers the conversion of zimage to boot.img...
seems you compiled successfully.
congrats.:victory:
But what about boot.img ?
We need a boot.img in /android/boot ?
Now at last, you have the minimum of unmkbootimg, mkbootimg and mkbootfs installed in your path, and we can get going with our testing of the kernel.
I'll assume that you have a /usr/src/android/boot where you copied your boot.img, so let's get going....
Click to expand...
Click to collapse
Hi @k2wl.For the part "make -j8",if you don't mind putting a sign for others to only compile at the amount of their CPU have otherwise it will caused some error for others who are compiling
1 CPU= make -j1 with least error
Sent from my iPad using Tapatalk
Really nice guide especially about packing the initramfs with the zimage to make boot.img.
Sent from my GT-I9082 using Tapatalk
akiratoriyama said:
But what about boot.img ?
We need a boot.img in /android/boot ?
Click to expand...
Click to collapse
take one from my stock kernel zip....
Techix18 said:
Hi @k2wl.For the part "make -j8",if you don't mind putting a sign for others to only compile at the amount of their CPU have otherwise it will caused some error for others who are compiling
1 CPU= make -j1 with least error
Sent from my iPad using Tapatalk
Click to expand...
Click to collapse
thanks for suggestion.
skullface said:
Really nice guide especially about packing the initramfs with the zimage to make boot.img.
Sent from my GT-I9082 using Tapatalk
Click to expand...
Click to collapse
thanks....will modify more..
k2wl said:
That's not cm11 source. For that u need another tutorial.
Meanwhile try wiki.CyanogenMod.org
It has instructions for Building for new device
Click to expand...
Click to collapse
ok will check it out and will you make a guide for that also??
mr.phantom said:
ok will check it out and will you make a guide for that also??
Click to expand...
Click to collapse
if people wanted it, will make cm11 compilation from source tutorial for it.
Thanks to ya k2wl
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Sent from my GT-I9082 using Tapatalk
happy developing.....glad i helped you...
keep trying for learning new features...
k2wl said:
if people wanted it, will make cm11 compilation from source tutorial for it.
Click to expand...
Click to collapse
Pls k2wl make a new tutorial which include cm11 compilation for grand from source and its kernel also
Hey @k2wl
Just wanted to say thank you for this comprehensive guide. Very detailed.
I never had any interest in tweaking a kernel. I am more of a java guy. But after reading your guide, I thought, why not?!
So I started working on it. Now I have a fully functional kernel compiled separately from the ROMs that I compile.
I even named it. Nebula Kernel.
Learning alot about kernels since I started working on it. As I am tweaking nebula for myself and i'll use this kernel as my daily driver so i'll add tweaks and governors according to me, the ones which I'll use. I like keeping things light and simple! I'll use your github for reference and help. If I face any problems, I'll ask you.
Thank you for the guide!

Miui 8

Miui 8 patch rom release, can someone port it for Nexus 4?
https://github.com/MiCode/patchrom/tree/marshmallow
I need it too...
You should contact to miui support forum or XDA devs, I hope they can build miui 8 for nexus 4
@Trickster22
Install Ubuntu.
Install Java
Guide to configure android SDK
Guide to configure repository:
Open terminal
Code:
mkdir -p ~/bin
Code:
PATH=~/bin:$PATH
Code:
cd ~/bin
Code:
curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
Code:
chmod a+x ~/bin/repo
Code:
mkdir ~/patchrom
Code:
cd ~/patchrom
Code:
repo init -u git://github.com/MiCode/patchrom.git -b marshmallow
Now you'll have to configure git. Run following commands in terminal
Code:
git config --global user.email ENTER_YOUR_EMAIL_ID_HERE
Code:
git config --global user.name ENTER_YOUR_REAL_NAME_HERE
Code:
repo init -u git://github.com/MiCode/patchrom.git -b marshmallow
Code:
repo sync
Wait......
after, Install the latest version of Fake nexus (marshmallow), reboot to device in mode recovery (TWRP).
PS.: After you finish generating the stockrom.zip of fake nexus, do the same for cm-13.0-20160820-SNAPSHOT-ZNH5YAO0J5-mako.zip
Reboot your device for recovery, use this comand to gerate stockrom.zip and metadata folder:
Code:
/home/"YOUR-USER-NAME-UBUNTU"/patchrom/tools/releasetools/ota_target_from_phone -r
Sende me stockrom.zip and metadata folder
Source: http://forum.xda-developers.com/android/software/guide-build-port-miui-rom-to-device-t3250984
Dio_S said:
@Trickster22
Install Ubuntu.
Install Java
Guide to configure android SDK
Guide to configure repository:
Open terminal
Code:
mkdir -p ~/bin
Code:
PATH=~/bin:$PATH
Code:
cd ~/bin
Code:
curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
Code:
chmod a+x ~/bin/repo
Code:
mkdir ~/patchrom
Code:
cd ~/patchrom
Code:
repo init -u git://github.com/MiCode/patchrom.git -b marshmallow
Now you'll have to configure git. Run following commands in terminal
Code:
git config --global user.email ENTER_YOUR_EMAIL_ID_HERE
Code:
git config --global user.name ENTER_YOUR_REAL_NAME_HERE
Code:
repo init -u git://github.com/MiCode/patchrom.git -b marshmallow
Code:
repo sync
Wait......
after, Install the latest version of Fake nexus (marshmallow), reboot to device in mode recovery (TWRP).
PS.: After you finish generating the stockrom.zip of fake nexus, do the same for cm-13.0-20160820-SNAPSHOT-ZNH5YAO0J5-mako.zip
use this comand to gerate stockrom.zip and metadata folder:
Code:
/home/"YOUR-USER-NAME-UBUNTU"/patchrom/tools/releasetools/ota_target_from_phone -r
Sende me stockrom.zip and metadata folder
Source: http://forum.xda-developers.com/android/software/guide-build-port-miui-rom-to-device-t3250984
Click to expand...
Click to collapse
Thank you sir for this valuable info/guide but I have a weak machine for Ubuntu like only 2 GB ram. This is why I was requesting others to build miui.
Trickster22 said:
Thank you sir for this valuable info/guide but I have a weak machine for Ubuntu like only 2 GB ram. This is why I was requesting others to build miui.
Click to expand...
Click to collapse
You should just generate the stockrom.zip + metadata and send me, I can do it, because I do not have the device
what ıs thıs ?
hasanben35 said:
what ıs thıs ?
Click to expand...
Click to collapse
For me to compile miui, I need the stockrom.zip plus the metadata folder generated by the patchrom, this guide shows how.
Sorry mt english
hım how long does it take
hasanben35 said:
hım how long does it take
Click to expand...
Click to collapse
This process should take around 1 hour if you already have Ubuntu installed and configured
multı rom nıtrogen os 7.1.1 and flyme ınstalled flyme remove ubuntu ınstall after _?
hasanben35 said:
mult? rom n?trogen os 7.1.1 and flyme ?nstalled flyme remove ubuntu ?nstall after _?
Click to expand...
Click to collapse
Ubuntu in PC "Desktop"
oh my god no no no waıtıng rom sorry ubuntu ınstall pc no
Okay, I'll make those files. Where should I send it?

Categories

Resources