Related
Cyanogenmod Compiler (CMC) GUI
Build cyanogenmod with a gui.
{
"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"
}
Known issues:
- Currently no multi-threading, which means when you press sync or compile, there is no loading bar (app looks like its failing, its not.). I am working on that.
(If you want to watch the output of the sync or compile, just open a terminal and type "cmc", I log all to the system.)
- When locking the CMCompiler to the unity launcher you have to logout and log back in refer: ubuntu bug 916098
- Currently there isn't great error logic and dialogs to warn you about everything. Something that is still being working on. Just run from the terminal if you have an issue that you need to report.
- Missing make clean and make installclean. These will be added in the future.
Found bugs to fix v0.1:
- No "/" at the end of custom repo string path.
- Error checking for compile start
*Please any issue that should arise, I apologize in advanced. Please let me know with as much detail as possible to replicate the issue and I will resolve it.
Please read:
I have thought maybe times different ways I was going to go about this. Ads, donate version, paid app, etc. I choose to keep the project open, as that's how I roll. I do ask that if you enjoy the application that you try to donate something. This was my first gui project and took a lot of time and effort to even get it to where it is right now. I hope everyone enjoys the app as much as I enjoy working on it.
Install:
Note: If you are using the old ppa then look at post # 2 on how to remove it before adding this.
Code:
sudo apt-add-repository ppa:lithid/ppa
sudo apt-get update
Install daily dev builds:
Code:
sudo apt-get install cmcompiler-daily
Install beta builds:
Note: Not yet available.
Code:
sudo apt-get install cmcompiler-beta
Install stable builds:
Note: Not yet available.
Code:
sudo apt-get install cmcompiler
Note: You cannot have daily and stable at the same time. You can only use either or.
Source code | Bugs | Answers
Build info:
daily-builds
Enjoy some signatures from SavocaFTW:
You can follow me on google+ I tend to talk about it a bit on there as well.
Cyanogenmod Compiler (CMCompiler) HALP!
Error Codes:
Error: Need to sync first - After choosing compile, the program didn't find the needed .repo folder in your repo path. This assumes you never ran sync, so you never downloaded the code. You could have also renamed the .repo folder to something else, which would cause this error as well.
Error: device not found - Your device was not found in the repo, might be unsupported.
Error: Adb isn't running - First time running compile, you will need to have your phone connected and ADB running in order to pull off needed files from your phone.
Error: Extract-files came back False - This means a script called extract-files.sh failed to pull off those needed files from your phone.
Error: Compile error please check - This indicates that your build failed. You will need to run cmcompiler via terminal to get why.
Error: Repo Script needs setup - You don't have the repo script installed. Install it.
Code:
curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ~/repo
chmod a+x ~/repo
sudo mv ~/repo /usr/local/bin/repo
Error: No device configured - Appears there is no device configured, just select one from the setup menu.
Removing old ppa:
Code:
sudo apt-get remove cmcompiler-daily
sudo apt-get install ppa-purge
sudo ppa-purge ppa:long-jeremie/ppa
About Cmcompiler CLI
** If you are still using the CLI version, I have not updated it in sometime. I might get back to that but for right now the gui is my main focus. Please understand. You could always clone and make edits to the CLI here
This changes everything, again.
Great idea. Thanks.
Awesome! Thank you very much
this is neat! good job
Is there any support for pulling propriety files from a new phone or is that too specific?
Sent from my M9300 using xda premium
Jamin13 said:
Is there any support for pulling propriety files from a new phone or is that too specific?
Sent from my M9300 using xda premium
Click to expand...
Click to collapse
Currently there is only support for devices from within the CM repo. There could be a plugin created though for specific devices that are not "supported" by cm. You would still need someone to write that plugin for that device since prop files are different for each device.
lithid-cm said:
Software for compiling on ubuntu:
32 bit:
Code:
git-core gnupg flex bison gperf libsdl1.2-dev libesd0-dev libwxgtk2.6-dev squashfs-tools build-essential zip curl libncurses5-dev zlib1g-dev sun-java6-jdk pngcrush schedtool
64 bit:
Code:
g++-multilib lib32z1-dev lib32ncurses5-dev lib32readline5-dev gcc-4.3-multilib g++-4.3-multilib
Click to expand...
Click to collapse
lib32readline5-dev has been replaced by lib32readline-gplv2-dev on 11.10
And "gcc-4.3-multilib g++-4.3-multilib" aren't used from 11.04 and up - not needed.
Nice work though!
lithid-cm said:
If you are wondering how you can use this software its easy. You can clone my repo for now. and run the CMCompiler script:
Code:
git clone https://[email protected]/lithid/CMC.git
cd CMC
./CMCompiler
Click to expand...
Click to collapse
Hmmmm.
Code:
git clone https://github.com/lithid/CMC.git
cd CMC
./CMCompiler
Now we're talkin'!
Novek said:
lib32readline5-dev has been replaced by lib32readline-gplv2-dev on 11.10
And "gcc-4.3-multilib g++-4.3-multilib" aren't used from 11.04 and up - not needed.
Nice work though!
Click to expand...
Click to collapse
Updated second post. Thanks!
aorth said:
Hmmmm.
Code:
git clone https://github.com/lithid/CMC.git
cd CMC
./CMCompiler
Now we're talkin'!
Click to expand...
Click to collapse
I fixed that. No idea why I put that in their like that. Thanks!
lithid-cm said:
Currently there is only support for devices from within the CM repo. There could be a plugin created though for specific devices that are not "supported" by cm. You would still need someone to write that plugin for that device since prop files are different for each device.
Click to expand...
Click to collapse
Thanks.
If I could just figure out how to do it normally, I'd be fine.
unfortunately I can't seem to find anything about doing that.
Sent from my M9300 using xda premium
TEH KANGENAT0rZ!!!!1on1on1oneone!!
Jamin13 said:
Thanks.
If I could just figure out how to do it normally, I'd be fine.
unfortunately I can't seem to find anything about doing that.
Sent from my M9300 using xda premium
Click to expand...
Click to collapse
If you are looking to build on a new device. Go to cms github and grab a device tree from a similar device. Then you can see how everything is working... gather the stuff you need along with the device specific edits and hours and hours of trial and error. You will eventually get it... Its a learning process.
optedoblivion said:
TEH KANGENAT0rZ!!!!1on1on1oneone!!
Click to expand...
Click to collapse
King Kang?
This looks awesome! Thank you! I'm gonna try this out sometime this week. Thanks again!
This is a really cool project. For those of us who are uninitiated in using Git/Repo, will this make "making changes" to CM easy for us? Obviously, I see "Update Repo" as an option, but it will really take care of the rest for us?
Shidell said:
This is a really cool project. For those of us who are uninitiated in using Git/Repo, will this make "making changes" to CM easy for us? Obviously, I see "Update Repo" as an option, but it will really take care of the rest for us?
Click to expand...
Click to collapse
As of this moment. This doesn't support the needed bits for when you need to commit the code back to cm gerrit. This is something I am working on for my stable release. At this current state you can download the repo, assign a device, compile and update without any work needed done by the end user. When the rom is done downloading it gets placed in your home directory. I am not sure if that answered the question or not...
Soon there will be an option to make changes to the repo. This would enable repo start it would wait until you press enter again once changes are done and then commit them with repo upload. Of course this is still being worked out though.
Awesome--yeah, that answers my question. Thanks!
Nice job. Thank you for it.
Hi guys I am kind of a noob when it comes to linux and compiling and have hit a brick wall. I have this posted here in Chef Central and in general android Q&A so hopefully someone has an idea. I have been trying to compile CM9 for about three days now and no matter what I do I get this output. It is 95% of the time after the "install libwebcore.so" line.
Code:
install: out/target/product/maguro/system/lib/libwebcore.so
UNEXPECTED TOP-LEVEL ERROR:
java.lang.OutOfMemoryError: GC overhead limit exceeded
at com.android.dx.util.IntList.(IntList.java:87)
at com.android.dx.rop.code.RopMethod.calcPredecessors(RopMethod.java:154)
at com.android.dx.rop.code.RopMethod.labelToPredecessors(RopMethod.java:95)
at com.android.dx.dex.code.RopTranslator.pickOrder(RopTranslator.java:352)
at com.android.dx.dex.code.RopTranslator.translateAndGetResult(RopTranslator.java:212)
at com.android.dx.dex.code.RopTranslator.translate(RopTranslator.java:106)
at com.android.dx.dex.cf.CfTranslator.processMethods(CfTranslator.java:293)
at com.android.dx.dex.cf.CfTranslator.translate0(CfTranslator.java:134)
at com.android.dx.dex.cf.CfTranslator.translate(CfTranslator.java:87)
at com.android.dx.command.dexer.Main.processClass(Main.java:483)
at com.android.dx.command.dexer.Main.processFileBytes(Main.java:455)
at com.android.dx.command.dexer.Main.access$400(Main.java:67)
at com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:394)
at com.android.dx.cf.direct.ClassPathOpener.processArchive(ClassPathOpener.java:245)
at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:131)
at com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:109)
at com.android.dx.command.dexer.Main.processOne(Main.java:418)
at com.android.dx.command.dexer.Main.processAllFiles(Main.java:329)
at com.android.dx.command.dexer.Main.run(Main.java:206)
at com.android.dx.command.dexer.Main.main(Main.java:174)
at com.android.dx.command.Main.main(Main.java:95)
make: *** [out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/noproguard.classes-with-local.dex] Error 3
Before I tried to compile CM I did successfully compile AOSP for my Gnex. I have searched and tried everything I could find. I've tried these values in the common.py file and just about every combo I could think of per recommendations I found online.
Code:
check = (sys.maxsize > 2**32)
if check is True:
cmd = ["java", "Xmx2048m", "-jar",
os.path.join(OPTIONS.search_path, "framework", "signapk.jar")]
else:
cmd = ["java", "-Xmx1024m", "-jar",
os.path.join(OPTIONS.search_path, "framework", "signapk.jar")]
I have also checked my swap and as far as I can tell its there and working but it seams to never be used. I have tried all the commands I could find online to make sure it was enabled but Idk what else to try or check.
Also I am using a quad core AMD with 6GB of RAM if anyone is curious. Any and all advice/ideas would be very much appreciated at this point I am at a complete loss. Thanks for looking and helping guys.
EDIT:I just finished a successful build of AOSP for my galaxy nexus so I am really confused as to why I run out of memory for CM9.
Sky-
Try something for me please.
open your terminal. Can you run this please?
test.py
Code:
#!/usr/bin/env python
import sys
import platform
p = platform.dist()
distro = p[0]
version = p[1]
name = p[2]
check = (sys.maxsize > 2**32)
print "Distro: %s\nVersion: %s\n Name: %s\n 64bit OS: %s" % (distro, version, name, check)
Code:
python test.py
Alright I just got home from work so just give me about 30 mins or so and I'll give it a try.
Sent from my GT-N7000 or Galaxy Nexus
I tried the commands you posted here and either I am missing some stuff that should be installed on my computer or I am to much of a noob to enter the commands correctly. Here was my output as I entered the commands.
Code:
[email protected]:~$ test.py
test.py: command not found
[email protected]:~$ #!/usr/bin/env python
[email protected]:~$ import sys
[email protected]:~$ import platform
[email protected]:~$
[email protected]:~$ p = platform.dist()
bash: syntax error near unexpected token `('
[email protected]:~$ distro = p[0]
distro: command not found
[email protected]:~$ version = p[1]
version: command not found
[email protected]:~$ name = p[2]
No command 'name' found, did you mean:
Command 'named' from package 'bind9' (main)
Command 'namei' from package 'util-linux' (main)
Command 'lame' from package 'lame' (multiverse)
Command 'cname' from package 'cfs' (universe)
Command 'uname' from package 'coreutils' (main)
Command 'mame' from package 'sdlmame' (multiverse)
name: command not found
[email protected]:~$
[email protected]:~$ check = (sys.maxsize > 2**32)
bash: syntax error near unexpected token `('
[email protected]:~$
[email protected]:~$ print "Distro: %s\nVersion: %s\n Name: %s\n 64bit OS: %s" % (distro, version, name, check)
bash: syntax error near unexpected token `('
[email protected]:~$ python test.py
python: can't open file 'test.py': [Errno 2] No such file or directory
[email protected]:~$
Sorry if I entered them incorrectly, I am learning linux as fast as I can. Should I have entered them differently?
Sky-
Haha..yes...you needed to put everything from the # all the way to the end of check) in a file called test.py...then enter python test.py in your command line
Use your editor of choice
Don't worry, everyone was new once.
Sent from my SGH-I757M using xda premium
reallybigabe said:
Haha..yes...you needed to put everything from the # all the way to the end of check) in a file called test.py...then enter python test.py in your command line
Use your editor of choice
Don't worry, everyone was new once.
Sent from my SGH-I757M using xda premium
Click to expand...
Click to collapse
Thank you sir. I'm such a dope . I'll do that tonight when I get home from work.
Sent from my GT-N7000 or Galaxy Nexus
sorry about that, I didn't know you were new. Apologies.
Copy and paste these commands.
Command 1:
Code:
(cat << EOF) > $HOME/test.py
#!/usr/bin/env python
import sys
import platform
p = platform.dist()
distro = p[0]
version = p[1]
name = p[2]
check = (sys.maxsize > 2**32)
print "Distro: %s\nVersion: %s\n Name: %s\n 64bit OS: %s" % (distro, version, name, check)
EOF
press [enter]
Command 2:
Code:
chmod a+x $HOME/test.py
Command 3:
Code:
python $HOME/test.py
Thanks for the beginners guide lol, it worked now. Here was the output of that command.
Code:
[email protected]:~$ python $HOME/test.py
Distro: Ubuntu
Version: 10.04
Name: lucid
64bit OS: True
[email protected]:~$
That's what you were looking for correct?
If I were you I would run a mem check on your memory. There shouldn't be any reason that your getting those errors.
I have 8 gigs and I never have an issue.
lithid-cm said:
If I were you I would run a mem check on your memory. There shouldn't be any reason that your getting those errors.
I have 8 gigs and I never have an issue.
Click to expand...
Click to collapse
How would I go about doing that? Sorry for the noobish questions I just have never had to do this before on any of my PC's. Its just so weird because I'm compiling AOSP as we speak. Just wish it was CM lol.
EDIT: My bad I can do it with the ubuntu install dvd I have.
Sent from my GT-N7000 or Galaxy Nexus
Also if you dont mind me asking lithid, what version of linux do you use to build?
skyhigh2004 said:
Also if you dont mind me asking lithid, what version of linux do you use to build?
Click to expand...
Click to collapse
ubuntu 12.04 64bit
Well I am running a mem test now. If it all goes just fine I think I'm gonna do a fresh install of 12.04 and reset everything up and try again. I'm at a complete loss .
Sent from my GT-N7000 or Galaxy Nexus
Well my computer passed the memory rest with zero errors. So I'm installing 12.04 on a fresh format so hopefully I have better luck later tonight or tomorrow getting it to build.
Sent from my GT-N7000 or Galaxy Nexus
skyhigh2004 said:
Well my computer passed the memory rest with zero errors. So I'm installing 12.04 on a fresh format so hopefully I have better luck later tonight or tomorrow getting it to build.
Sent from my GT-N7000 or Galaxy Nexus
Click to expand...
Click to collapse
I am really interested in this. Please keep this post updated with your success!
lithid-cm said:
I am really interested in this. Please keep this post updated with your success!
Click to expand...
Click to collapse
I'll definitely keep you posted. I'm syncing tonight, then hopefully I'll set it up to build when I leave for work in the morning and I'll have good news when I get off in the afternoon.
Sent from my GT-N7000 or Galaxy Nexus
Well all I can say is ***k yeah. I guess reinstalling ubuntu and upgrading to 12.04 in the process cured my computer . I still have no idea as to why I couldnt build before but at least it works now.
Code:
Package complete: /home/skylar/cm9/out/target/product/maguro/update-cm-9.0.0-RC0-maguro-UNOFFICIAL-signed.zip
097429908172684449fb5a3fe796c290 update-cm-9.0.0-RC0-maguro-UNOFFICIAL-signed.zip
[email protected]:~/cm9$
Now to learn how to cherry pick
skyhigh2004 said:
Well all I can say is ***k yeah. I guess reinstalling ubuntu and upgrading to 12.04 in the process cured my computer . I still have no idea as to why I couldnt build before but at least it works now.
Code:
Package complete: /home/skylar/cm9/out/target/product/maguro/update-cm-9.0.0-RC0-maguro-UNOFFICIAL-signed.zip
097429908172684449fb5a3fe796c290 update-cm-9.0.0-RC0-maguro-UNOFFICIAL-signed.zip
[email protected]:~/cm9$
Now to learn how to cherry pick
Click to expand...
Click to collapse
Easy man.
Click cherry pick.
{
"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"
}
Click copy
change directories in your repo path corresponding to the change. In this example frameworks_base from your repo path.
Code:
cd frameworks/base
paste in that command you just copied. press enter and you have just cherry picked to test a new cm commit.
That sounds very easy. Thanks again for a noob tutorial . Also what would you do to remove the cherry pick if you didnt like the commit? Is that path just added to the local manifest just like device trees and kernels sources?
Sent from my GT-N7000 or Galaxy Nexus
skyhigh2004 said:
That sounds very easy. Thanks again for a noob tutorial . Also what would you do to remove the cherry pick if you didnt like the commit? Is that path just added to the local manifest just like device trees and kernels sources?
Sent from my GT-N7000 or Galaxy Nexus
Click to expand...
Click to collapse
While inside the same path you applied the cp.
git reset --hard HEAD
That will reset to the last cm commit. You can do specific files as well by appending the file path after the command.
Sent from my Nexus S 4G using xda premium
****NOOB GUIDE ON HOW TO BUILD CM OR CM BASED ROM FROM SOURCE FOR S2****
****FULL SUPPORT ****
So guys from the concept of sharing and caring ..am going to share the way through which i have succeeded to compile my first rom based on omni source.
I will try to make this guide as much as easy ..so dont worry..and feel free to ask any doubt if u have..
Note: Most of the instructions are fit for Ubuntu running normally on any PC and not specific to Virtual Box
Things Required:
**Computer/Laptop with decent amount of ram (min 6gb)and also decent storage
**Internet connection(now thats obvious)
**Some knowledge about linux commands..like basic command such as cd for “change directory”,(anyways even if u dont know just copy and paste the codes given in the thread
**Last but not least "U must have android mobie" not an iphone (kidding)
This Guide will cover below things:
** How to install Ubuntu on virtual box
**How to set up Build environment
**How to build and compile rom
**transfer the zip from ubuntu to your phone
So lets begin
How to install ubuntu on Virtual box:
1. Download ubuntu from HERE(download ubuntu 12.04 LTS 64 bit)if u are having system with 2gb then pls dont try to compile
2. Download virtual box from HERE(download the latestwindows version x86/amd64)
3. After downloading vm click on it and select "NEXT"
4.Choose not to install USB support, networking, or Python support. Do this by clicking the grey icon near each option and selecting the red X or “Entire feature will be unavailable”. Then click “Next” to continue.
{
"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"
}
5.Uncheck the Quick Launch Bar checkbox and click “Next” to continue
6.Click install and finish.
7.Now click the new button at the top to create a new virtual machine.
8.Give your virtual machine a name and select the operating system you’ll be running(for e,g select version as ubuntu 64 if u are on 64bit os). Click “Next”.then slect create virtual hard drive now
9.now type the amount of memory ..(4gb is absolute minimum)
10.Click “Next” to create a new virtual hard disk, then click “Next” again
11.Select dyanmically allocated storage
12.now type the amount of storage(200 gb is minimum) and click create .
13.Select your new virtual machine. Once you've done this, click the “Settings” button.
14.Click “Storage” tab and Click the “CD/DVD icon" having "+" on it and select ISO to mount.
15.Click system on the left and Choose boot order and keep CD/DVD on the top as first priority.
16.Now close the settings window and Select your virtual machine. Then click the “Start” button
15.Now ubuntu will start and select the language
16.select install ubuntu
17.click continue and select the first radio button ..then hit continue again and install now(wait for some time)
18.Go through all the steps and finally u should have the below screen.(if u have got that screen then u are ok to proceed ahead )
16.So i assume you have got the ubuntu desktop .
17.click on ubuntu software centre avaliable on the left side and select edit/software sources
18.click on update tab and follow the screenshot below
19.After couple of min u should see update box is dancing on the left side , click that and install all the update packages
How to set up build environment:
1. Go to THIS awesome thread , I Bet u would not have any problem in setting up build environment if u had followed it correctly..
2.If u have any troubles in setting up build env then u are free to ask/post in this thread.
3.You can also set up adb and fast boot very easily instead of sdk tools (but remember it does not mean u can skip downloading sdk tools, you have to download all the packages .
Set up adb and fastboot with ease
4.you only need to download the below packages
JDK 6
Python
Git 1.7
Android SDK
ia32libs
So i assume you have set up your build environment successfully ..
How to build and compile :
1.We will install build packages needed to compile the rom.
2.Open your ubuntu terminal by pressing ctrl+alt+t
3.As of now u cannot copy/paste text between ubuntu and your windows ..so we will be installing guest addition cd image which u can install by clicking on Devices/install guest addition cd image .
4.it will install now , after that select Devices/share clipboard/bidirectional ..now reboot your ubuntu by typing the below code in terminal
Code:
sudo reboot
5.Now copy paste the below code in terminal to install build packages
Code:
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
Code:
sudo apt-get update
Code:
apt-get install g++-4.7 gcc-4.7
For 32-bit & 64-bit systems
Code:
git-core gnupg flex bison gperf libsdl1.2-dev libesd0-dev libwxgtk2.8-dev squashfs-tools build-essential zip curl
libncurses5-dev zlib1g-dev openjdk-6-jre openjdk-6-jdk pngcrush schedtool
For 64-bit only systems
Code:
g++-multilib lib32z1-dev lib32ncurses5-dev lib32readline-gplv2-dev gcc-4.7-multilib g++-4.5-multilib
6.You should not have any problem in installing the above packages if u had followed it correctly.
7.Now Create the directories
Code:
mkdir -p ~/bin
8.Install the repo command
:
Code:
curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
chmod a+x ~/bin/repo
9.Important thing now is u have to put the bin directory in your path of execution..to do so ..copy and paste the below code
Code:
export PATH=${PATH}:~/bin
10. type
Code:
gedit ~/.bashrc
and now paste
Code:
export PATH=${PATH}:~/bin
11.save it by pressing ctrl+x
12. now we have to create a directory in which our source will get downloaded
Code:
mkdir -p dirname
(type the directory name )
Code:
cd dirname
13.Now its time for us to initialize the repository
Syntax :
Code:
repo init -u url -b branch
for e.g am going to fetch omni source..so i wil type as
Code:
repo init -u https://github.com/omnirom/android.git -b android-4.4
for pacman
Code:
repo init -u git://github.com/PAC-man/pacman.git -b pac-4.4
for slimbean( google, exynos and non qcom devices)
Code:
repo init -u git://github.com/SlimRoms/platform_manifest.git -b kk4.4
slimbean(for qcom devices which are using CodeAuroraForum trees)
Code:
repo init -u git://github.com/SlimRoms/platform_manifest.git -b kk4.4-caf
for cm
Code:
repo init -u git://github.com/CyanogenMod/android.git -b cm-11.0
14.then go to THISanother awesome thread to understand about the local manifest ,manifest and many more..(this thread is highly recommended to those who have poor internet connection)
15.IF u are lazy and dont want to go throu the above thread then u can skip and follow the below steps.
16.type
Code:
repo sync -c -j4
Note: if u have low bandwidth the use -j2 instead of -j4 and if u have good internet connection use -j16 instead of -j4
repo sycn -c will download only the current version so it saves time for u
17.repo sync will take more time..(for me it took 3 days to complete because my internet speed was 50kb/sec
18.After repo sync is done u have to fetch some additional repoistory using local_manifest.xml
Code:
<remote fetch="https://github.com/DonkeyCoyote" name="donkey" />
<project name="DonkeyCoyote/proprietary_vendor_samsung" path="vendor/samsung" remote="github" revision="android-4.4" />
<project name="android_device_samsung_i9100" path="device/samsung/i9100" remote="omnirom" revision="android-4.4" />
<project name="android_device_samsung_galaxys2-common" path="device/samsung/galaxys2-common" remote="omnirom" revision="android-4.4" />
thanks to chasmodo
note: above is an example for omni rom...if u are fetching aokp,pac etc then u have to change the path , remote , revision accordingly
19.Let's configure ccache too. It will reduce the build time to 40% after first build
Code:
echo "export USE_CCACHE=1" >> ~/.bashrc
Code:
directoryname/prebuilts/misc/linux-x86/ccache/ccache -M 25G
25G means it will use upto 25 gb of disk space for ccaching. Atleast 10 gb is recommended.
20.Now its time for compiling .simply type
Code:
. build/envsetup.sh
Code:
brunch i9100
21.it may take some time depending upon your pc/laptop configuration
22.u should get package complete at the end..(unfortunately i could not save screenshot of that..but soon s.s will be posted when i repo sync again)
23.If yes then u have successfully built your rom ..congrats:good:
24.now how to transfer that zip to the phone for flashing?..follow the below steps
how to transfer files from ubuntu to your phone:
1: Download and install the AirDroid app to your Android device.
2: Launch the app and read the starter guide. As soon as you’re done, click “Start”.
3: Take note of the web address that is being shown on the app. You’ll need that web address to access your smartphone through your computer’s web browser.
4.now type the code in ubuntu browser and there u go ...u have connected your phone to ubuntu.
5.transfer the file by selection files/sdcard/upload
6.Done
Hope this guide helps u the most.
IF U HAVE ANY QUESTION FEEL FREE TO POST ..cheers.
GOOD LUCK:good:
Credits:
@Myself5 (this guy really deserves it)
@chasmodo @engloa
google
Hit the thanks button if u think it deserves to have..:highfive:
Nice!
-Grift- said:
Nice!
Click to expand...
Click to collapse
Thanks buddy.
Took me 3hr to write.. Phew
Sent from my GT-I9100 using Tapatalk 2
corruptionfreeindia said:
Thanks buddy.
Took me 3hr to write.. Phew
Sent from my GT-I9100 using Tapatalk 2
Click to expand...
Click to collapse
*Browser crashes just before you get to post* FUUUUUU:laugh:
Will Surely try................... Great effort thou.....
Although this is of immense help, IMO this shows the huge amount of work put out by our ROM developers.
So, thank you @cfi and hopefully some new devs will grow out of this.
Sent from my GT-I9100 using XDA Premium 4 mobile app
corruptionfreeindia said:
Thanks buddy.
Took me 3hr to write.. Phew
Sent from my GT-I9100 using Tapatalk 2
Click to expand...
Click to collapse
It took me 3hr to read and Digest Phew!!U should also Add the Min Hardware requirement to the guide
Sun90 said:
It took me 3hr to read and Digest Phew!!U should also Add the Min Hardware requirement to the guide
Click to expand...
Click to collapse
Min hardware requirement of what mate?
if you mean virtualbox, you can check this out
engloa said:
Min hardware requirement of what mate?
if you mean virtualbox, you can check this out
Click to expand...
Click to collapse
The system (computer) hardware requirement ma8
Thanks "again" for a "monster" thread
Sun90 said:
It took me 3hr to read and Digest Phew!!U should also Add the Min Hardware requirement to the guide
Click to expand...
Click to collapse
Sure buddy..I will.
Am already tired.
Have to go college tomo
Sent from my GT-I9100 using Tapatalk 2
-Grift- said:
*Browser crashes just before you get to post* FUUUUUU:laugh:
Click to expand...
Click to collapse
Lol
Sent from my GT-I9100 using Tapatalk 2
Sun90 said:
The system (computer) hardware requirement ma8
Click to expand...
Click to collapse
You could (theoretically) build with almost everything where you get Linux to work on but remember, it will then finish today's nightly in 3 days Also there are some people reporting compiling crashes when you don't have enough RAM (@corruptionfreeindia was one of them ).
Greetings
Myself5
Myself5 said:
Also there are some people reporting compiling crashes when you don't have enough RAM (@corruptionfreeindia was one of them ).
Greetings
Myself5
Click to expand...
Click to collapse
haha..;D
Great thread,thanks
keep it up:good::good:
Set up ADB and Fastboot for Ubuntu with ease
http://www.webupd8.org/2012/08/install-adb-and-fastboot-android-tools.html
After installing it this way you can excess ADB or Fastboot commands through the terminal from anywhere. This integrates the commands perfectly
-Grift- said:
Set up ADB and Fastboot for Ubuntu with ease
http://www.webupd8.org/2012/08/install-adb-and-fastboot-android-tools.html
After installing it this way you can excess ADB or Fastboot commands through the terminal from anywhere. This integrates the commands perfectly
Click to expand...
Click to collapse
Buddy..thanks.
Looks so easy.
Adding it to the op if u dont mind.
Biftor said:
Great thread,thanks
keep it up:good::good:
Click to expand...
Click to collapse
Thanks biftor.
Sent from my GT-I9100 using Tapatalk 2
corruptionfreeindia said:
Buddy..thanks.
Looks so easy.
Adding it to the op if u dont mind.
Thanks biftor.
Sent from my GT-I9100 using Tapatalk 2
Click to expand...
Click to collapse
Im cool with that
Nice guide.. very lucid and simple language. easy to learn. Thanks!
awesome it will b very helpful.... such a nice thread you wrote
Huawei have helpfully released the kernel source for the Huawei P9 Plus on their download site. Impressively, the version posted there (3.10.90) actually matches the current release build. However, the download itself is only part of the puzzle - it's important to then know how to compile it and use it. Hence this guide.
Some points to note first of all...
This guide refers to building on Linux. You can probably build on OSX or whatever too but seriously, it's less pain in the long run to spin up an Ubuntu VM.
In the download linked above, as well as the kernel, there are some other bits and pieces (some of which are quite bizarre). I've mirrored the kernel to Bitbucket, so you don't need to grab the whole download.
Got that? OK, so here's a step by step on how to build the kernel! I strongly recommend building stock first and testing that works for you, then you can start adding your tweaks in. I'm interested to hear what you add / change!
Open a terminal window on your Linux machine / in your Linux VM. No GUIs here. Change to the directory where you want the kernel / toolchain to live.
First of all, we're going to clone the toolchain from AOSP.
Code:
git clone https://android.googlesource.com/platform/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9
Next we're going to clone the kernel source itself from my git repo on bitbucket.
Code:
git clone https://gitlab.com/paulobrien/android_kernel_huawei_p9plus.git kernel
We need to add the toolchain location to the path.
Code:
export PATH=$(pwd)/aarch64-linux-android-4.9/bin:$PATH
We need to specify that we are cross compiling for arm64.
Code:
export CROSS_COMPILE=$(pwd)/aarch64-linux-android-4.9/bin/aarch64-linux-android-
Let's create a directory for our output to go in to.
Code:
mkdir out
We've got the kernel downloaded, so let's change to that directory so we're ready to go.
Code:
cd kernel
A bit of cleaning up before we get started...
Code:
make ARCH=arm64 O=../out mrproper
Specify that we're building for the P9 (hisi3650 chipset)...
Code:
make ARCH=arm64 O=../out p9plus_extracted_defconfig
And build it!
Code:
make ARCH=arm64 O=../out -j8
When this process completes, we can check the '../out' directory and you should find the file arch/arm64/boot/Image. This is the kernel that you've just built! You can't flash it as is though, you need to put it into a boot image first.
Here's how you do it...
Change out of the kernel directory back to its parent.
Code:
cd ..
Download tools for manipulating the boot image.
Code:
git clone https://github.com/xiaolu/mkbootimg_tools.git
Download the stock boot image (actually we're using the root ready version for convenience).
Code:
wget -O boot.img http://nigella.modaco.com/files/boot.stock.huaweip9plus.b161.img
Extract the boot image.
Code:
mkbootimg_tools/mkboot boot.img boot.extracted
Copy the new kernel into the extracted boot folder.
Code:
cp out/arch/arm64/boot/Image.gz boot.extracted/kernel
Build a new boot image.
Code:
mkbootimg_tools/mkboot boot.extracted boot.newkernel.img
You now have a new boot image (boot.newkernel.img). All that's left is to flash it to your device! Reboot to bootloader (either using 'adb reboot bootloader' or by powering on with volume down held), flash using 'fastboot flash boot boot.newkernel.img' and then reboot using 'fastboot reboot'. Job done! In the About screen of settings you should see the date of the new kernel and details of your build machine.
Great work mate. You are rock
paulobrien said:
Huawei have helpfully released
will this work for the latest nougat?
Click to expand...
Click to collapse
Hi @paulobrien, does this guide works for Huawei P10 souce code downloaded from here?? http://consumer.huawei.com/en/opensource/detail/
I am trying to compile aosp for Huawei p10.
Thank you.
Update: How to build the kernel for your Huawei P9 Plus
Hello Fellows,
thank you @paulobrien for this nice and handy How To.
It didn't work for me so I've updated your How To a little to compile the P9 Plus kernel for the VIE-L09 Device.
The kernel source and config file comes from the Huawei Opensource Website.
https://consumer.huawei.com/en/opensource/
Filtered for P9 Plus
-> P9 Plus, VIE-AL10, Android 7.0, EMUI 5.0
The source is from the VIE-AL10 but works great with the VIE-L09 as well.
I've put the unmodified kernelsource to github.
The updated How To is also inspired by this [ULTIMATE GUIDE] and the View attachment README_Kernel.txt from the Huawei VIE_NG_EMUI5.0_opensource.tar.gz
Thanks and Credits to @paulobrien, @osm0sis and @Eliminator79
Preconditions:
An unlocked bootloader and rooted P9 Plus
A dump of the phones boot.img for ex. with DD if=/dev/block/mmcblk0p28 of=/...boot.img
A Linux System to compile the source
A working fastboot connection
optional: A working ADB connection (to pull the dumped boot.img)
optional: A working SSH connection (to pull the dumped boot.img)
install ubuntu-14.04.6-desktop-amd64.iso
user and machine name will be displayed in the kernel
update git:
Code:
sudo apt-get install git
git --version -> git version 1.9.1
sudo add-apt-repository ppa:git-core/ppa
sudo apt-get update && sudo apt-get install git
git --version -> [B]git version 2.26.2[/B]
menuconfig classic:
Code:
sudo apt-get install build-essential libssl-dev libncurses5-dev bison flex
menuconfig modern GUI:
Code:
sudo apt-get install libqt4-dev pkg-config
get the ndk r16b toolchain aarch64-linux-android-4.9 from Google:
Code:
wget https://dl.google.com/android/repository/android-ndk-r16b-linux-x86_64.zip
extract the aarch64 folder:
Code:
unzip android-ndk-r16b-linux-x86_64.zip android-ndk-r16b/toolchains/aarch64-linux-android-4.9/prebuilt/linux-x86_64/*
mv android-ndk-r16b/toolchains/aarch64-linux-android-4.9/prebuilt/linux-x86_64 aarch64-linux-android-4.9 && rm -Rf android-ndk-r16b
export path and cross_compiler: (needs to be done every reboot)
Code:
export PATH=$PATH:$(pwd)/aarch64-linux-android-4.9/bin
export CROSS_COMPILE=$(pwd)/aarch64-linux-android-4.9/bin/aarch64-linux-android-
install fastboot
Code:
sudo apt-get install android-tools-fastboot
sudo apt-get install android-tools-adb
Clone the actually source or extract the downloaded one in a directory for ex. P9PLUSKERNELSRC
just compile it or make some changes as well.
clone the Huawei P9 Plus Nougat Stock Kernel Source 4.1.18:
Code:
git clone https://github.com/newbit1/HUAWEI_P9PLUS_VIENNA_NG_EMUI5.0_STOCK_KERNEL_4.1.18.git P9PLUSKERNELSRC
Update 30.04.2020: OREO repo added
alternative for OREO, clone the P9 Plus Oreo Stock Kernel Source 4.4.23:
The OREO Kernel will not boot the P9Plus with Nougat on it. But It has its config.gz already included.
Code:
git clone https://github.com/newbit1/HUAWEI_P9PLUS_VIENNA_OREO_EMUI8.0_STOCK_KERNEL_4.4.23.git P9PLUSKERNELSRC
the stock default kernel config file is in "kernel/arch/arm64/configs/merge_hi3650_defconfig":
Code:
cd P9PLUSKERNELSRC/kernel
make ARCH=arm64 distclean
rm ../out -Rf && make clean && make mrproper && mkdir ../out
make ARCH=arm64 O=../out merge_hi3650_defconfig
If you want to make changes, use the menu to config the kernel:
menuconfig classic:
Code:
make ARCH=arm64 O=../out menuconfig
menuconfig modern GUI:
Code:
make ARCH=arm64 O=../out xconfig
compile the kernel... and have a drink
Code:
make ARCH=arm64 O=../out -j8
If/when the kernel is compiled, pack it with AIK-Linux in the dumped and unpacked boot.img from your P9-Plus.
An unlocked bootloader and rooted P9 Plus is a precondition!
For example purposes in this How To I use the boot.img from my phone.
It has a init with magisk root 20.3
get the Android Image Kitchen from osm0sis xda:
Code:
wget https://forum.xda-developers.com/attachment.php?attachmentid=4825093 -O AIK-Linux-v3.6-ALL.tar.gz
tar -xvzf AIK-Linux-v3.6-ALL.tar.gz
cd AIK-Linux
wget https://github.com/newbit1/HUAWEI_P9PLUS_VIENNA_NG_EMUI5.0_STOCK_KERNEL_4.1.18/raw/master/HUAWEI_P9PLUS_NG_STOCK_BOOT_KERNEL_4.1.18.img -O boot.img
./unpackimg.sh
rm -f split_img/boot.img-zImage
put the just compiled kernel into the AIK and repack it:
Code:
mv ~/P9PLUSKERNELSRC/out/arch/arm64/boot/Image.gz ~/AIK-Linux/split_img/boot.img-zImage
./repackimg.sh
the repacked boot image-new.img is ready to be flashed into the P9 Plus
checking the ADB connection:
Enable USB Debugging and connect the P9 Plus via USB:
Code:
adb devices
List of devices attached
N9xxxxxxxxxxxxxx device
checking the Fastboot connection:
unplug the usb cable in
switch off the phone
hold the volume down button and keep holding it
plug the usb cable in
phone boots into fastboot mode
release the volume down button
check the fastboot connection with the P9 Plus
Code:
sudo fastboot devices
N9xxxxxxxxxxxxxx fastboot
flash image-new.img with the new kernel
Code:
sudo fastboot flash boot image-new.img
target reported max download size of 471859200 bytes
sending 'boot' (16238 KB)...
OKAY [ 0.844s]
writing 'boot'...
OKAY [ 0.121s]
finished. total time: 0.965s
reboot the phone and unplug the cable
Code:
sudo fastboot reboot
your phone is booting now...
Enjoy your new kernel
{
"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"
}
@newbit, you think nice, but its old and not useful anymore for newer android versions. 2nd i think, your cam is broken.
dkionline said:
@newbit, you think nice, but its old and not useful anymore for newer android versions. 2nd i think, your cam is broken.
Click to expand...
Click to collapse
Thank you @dkionline for your feedback.
I have to admit, you did put me in shock for like a half of heartbeat regarding the camera.
However, no, the Cams are working fine. So far everything else as well, and yes it is possible
That something is not working as it should. I did not do any special hardware test yet.
Any suggestions on how to do this?
I agree, the topic is relatively old, but it was very useful to me, even though it was not working as described.
In addition, I do not like to spam the forum with similar topics, so I have just updated it.
The main reason for the need to compile it was the outdated kernel version.
Unfortunately I don't make any progress yet to upgrade my kernel, but I will publish it If I am going to make
any progress.
If you have any idea on how to cherry-pick a stable-linux kernel version into an android Linux kernel? Please be my guest,
any support is very much appreciated.
Cheers
NewBit
Edit: 02.05.2020
Your comment didn't let me go after all... How does this "cam is broken" manifest in detail?
I've notices I can only take some fotos right after the phone booted, and then it says loading
and keeps deleting the just taken photos. Video recording works. A non stock camera app
also still works. When I put the stock kernel back, it doesn't delete the photos anymore.
Where does this come from? The stock camera app itself? What is the reason behind this?
I can remember I had a very similar issue some time ago, but this was solved with a simple reboot, this isn't.
Thanks again for your feedback!
newbit said:
Edit: 02.05.2020
Your comment didn't let me go after all... How does this "cam is broken" manifest in detail?
I've notices I can only take some fotos right after the phone booted, and then it says loading
and keeps deleting the just taken photos. Video recording works. A non stock camera app
also still works. When I put the stock kernel back, it doesn't delete the photos anymore.
Where does this come from? The stock camera app itself? What is the reason behind this?
I can remember I had a very similar issue some time ago, but this was solved with a simple reboot, this isn't.
Thanks again for your feedback!
Click to expand...
Click to collapse
In detail, the cam cant save pictures in Nougat, in all EMUI 5 sources we got. So, if you want, better update to EMUI 8 and build a kernel there. All works well, but just GCC4.9 toolchains.
Universal Authority to have Total control of all Android ROMs using Gscript
Before making any changes always create a back up.
Click HERE for How to Backup and Restore using TWRP Recovery
Have all the proper software available to be use, if any wrong doing.
The Novacom drivers are essential to repair any damages.
Click HERE for HP TOUCHPAD Novacom Repair Android
In any Device Operating System, Desktop or Mobile the changes are apply using simple command lines. There are Apps that allows easier interaction by providing a
GUI ( Graphical User Interface ). The Apps provide specific functions or Tweaks in a general setting to accommodate a wide range of Devices.
The Apps will use resources ( RAM ) and if the device is low in Memory it will create more issues than improvement.
The Gscript App provides the ability to make all changes to the system in a very basic, simple but effective way.
The developer and creator of Gscript is @rogro82, and the original Thread can be found here:
Click HERE for the original Gscipt Thread
The provided Gscript from this guide was modified to work better on the Tablet, but the functionality is the same.
The user has full Authority to modify any Android ROM and specifically create any script command for any use.
Creating the script is as simple as using the App.
Paste the command in the App, give it a name and save it.
A list of command can easily be enter on any OS using a basic text editor.
The only requirement is to save the file with the extension .sh
Flash the file in TWRP Recovery:
Boot into Android and install the gscript_modified.apk App. A list of scripts are provided to make changes to the Optimize Settings.
Click HERE to Download HpTp_Universal_Authority flash File.
SuperSu SR5-SuperSU-v2.82 must be flash to all ROMs:
Click HERE to Download SR5-SuperSU-v2.82
{
"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"
}
Many thanks to @rogro82 for creating the most powerful App, that with a touch from the Home Screen everything is under control !
PIE Commands
Android Pie uses the Toybox:
http://landley.net/toybox/
The best and fastest way to get all the command available is using ADB Shell.
[email protected]:/ # cd system/bin
Get all available command line utilities
[email protected]:/system/bin # ls
or by just typing toybox
[email protected]:/ # toybox
Oreo Commands
Android Oreo uses the Toybox:
http://landley.net/toybox/
The best and fastest way to get all the command available is using ADB Shell.
[email protected]:/ # cd system/bin
Get all available command line utilities
[email protected]:/system/bin # ls
or by just typing toybox
[email protected]:/ # toybox
Nougat Commands
Android Nougat uses the Toybox:
http://landley.net/toybox/
The best and fastest way to get all the command available is using ADB Shell.
[email protected]:/ # cd system/bin
Get all available command line utilities
[email protected]:/system/bin # ls
or by just typing toybox
[email protected]:/ # toybox
Lollipop Commands
Android Lollipop uses the busybox:
https://busybox.net/
The best and fastest way to get all the command available is using ADB Shell.
[email protected]:/ # cd system/bin
Get all available command line utilities
[email protected]:/system/bin # ls
or by just typing busybox --list
[email protected]:/ # busybox --list
Kitkat Commands
Android Kitkat uses the busybox:
https://busybox.net/
The best and fastest way to get all the command available is using ADB Shell.
[email protected]:/ # cd system/bin
Get all available command line utilities
[email protected]:/system/bin # ls
or by just typing busybox --list
[email protected]:/ # busybox --list
Universal Commands
Universal Commands
Journey to Planet "Universal Authority"
Well while HP_TOUCHPAD is still trying to get out of his 'technical blackhole' one step at a time, I though I would take my first journey to the planet "Universal Authority" and report my findings, and to see if there is any life. I brought my trusty camera to document my journey and I added annotations to all my journey pictures at the bottom of the post.
First I downloaded the zip file called HpTp_Universal_Authority.zip and investigated it before I flashed it. The key file in the zip is called gscript_modified.apk and key the directory is called /gscript, both are important, these files will take permanent residence on your HP Touchpad
once you flash the zip.
The /gscript directory contains 20 separate Linux scripts that perform various tasks on your HP TOUCHPAD using Linux commands, the APK file is the modified gscript application that you will install once the flash copies it to the download directory. The updater-script of the zip has various edify commands that get run at flash time too.
So once I installed the modified gscrips app, I opened it and it was empty of any commands, so I added one at a time with the "add script" button. Then I did some testing on the planet "Universal Authority", by selecting the "run" and "edit" commands on the popup menu of the various scripts that I loaded.
It was a good first journey, and I plan to go again soon. I hope you all visit too, the natives are friendly and they have good home cooking. They told me that Captain Kirk and Spock were here and I just missed them.
Somehow missed this newcomer the other day while resurrecting one of mine.
Thanks @HP_TOUCHPAD for taking the time to post all this info.
Saw 'GScript' and my first thought was of GhostScript which is over 30 years old.
Going to have to rework my thought process...
DoubleStuff said:
...SNIP...
+1
It was a good first journey, and I plan to go again soon. I hope you all visit too, the natives are friendly and they have good home cooking. They told me that Captain Kirk and Spock were here and I just missed them.
Click to expand...
Click to collapse
How are the Craft Brews - any good?