Building From Source? - Android

im trying to build android from source on ubuntu 10.04. im on a 64 bit system . but this is what im stuck on.
when i enter the repo command:
repo init -u git://android.git.kernel.org/platform/manifest.git -b eclair
it get this error back
exec: 23: python: not found
any ideas.

python: not found

yeah how do i fix it though?
thanks

install python

i have it installed already v2.6

You may have to install a version of python prior to the version you've got installed. Check which version the SDK is compatible with. =)

INSANENEIVIESIS said:
im trying to build android from source on ubuntu 10.04. im on a 64 bit system . but this is what im stuck on.
when i enter the repo command:
repo init -u git://android.git.kernel.org/platform/manifest.git -b eclair
it get this error back
exec: 23: python: not found
any ideas.
Click to expand...
Click to collapse
Unsure what you have done up to this point. It seems as though your PATH to repo is not set. I'm assuming you have already done this:
$ mkdir ~/bin
$ curl http://android.git.kernel.org/repo >~/bin/repo
$ chmod +x ~/bin/repo
$ export PATH="${PATH}:~/bin"
$ mkdir ~/xdandroid
$ cd ~/xdandroid
Have you checked your PATH settings to make sure ~/bin is in there?
Code:
echo $PATH
If you are following the wiki, the command that's on there for path doesn't work for Ubuntu (I experienced it myself and haven't looked into why...it could be because it needs to be done as sudo). Try this in terminal:
Code:
gedit ~/.bashrc
then go to the end of the file and add this to the end:
Code:
PATH=~/bin:"${PATH}"
Close any terminal windows you have open and then reopen terminal. Try the command again...

Related

[HOW-TO] Building CM10, AOKP & TeamBaked For The JB Bootloader [Ubuntu 12.04+ 64-bit]

[HOW-TO] Building CM10, AOKP & TeamBaked For The JB Bootloader [Ubuntu 12.04+ 64-bit]
As many of you know, I no longer have my Transformer Prime, and hence cannot continue development for this device. So until the official CM10, AOKP and TeamBaked ROMs are updated to support the new JellyBean bootloader, as a final useful contribution to this device, I decided to provide a how-to guide to help people make their own builds.
This guide assumes that you have some experience building ROMs for Android and that you are comfortable with Linux. It is focused towards building on Ubuntu 12.04+ 64-bit.
1. Prepare the system (common for CM10, AOKP & TeamBaked)
a. Install Java JDK6
Code:
$ wget https://raw.github.com/flexiondotorg/oab-java6/master/oab-java.sh
$ chmod +x oab-java.sh
$ sudo ./oab-java.sh
$ sudo apt-get install sun-java6-jdk
b. Install required applications
Code:
$ sudo apt-get install git-core gnupg flex bison gperf build-essential \
zip curl libc6-dev libncurses5-dev:i386 x11proto-core-dev \
libx11-dev:i386 libreadline6-dev:i386 libgl1-mesa-glx:i386 \
libgl1-mesa-dev g++-multilib mingw32 tofrodos python-markdown \
libxml2-utils xsltproc zlib1g-dev:i386 schedtool pngcrush
$ sudo ln -s /usr/lib/i386-linux-gnu/mesa/libGL.so.1 /usr/lib/i386-linux-gnu/libGL.so
c. Get the repo binary
Code:
$ mkdir -p ~/bin
$ curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ~/bin/repo
$ chmod a+x ~/bin/repo
2. Building CM10
a. Get the CM10 source
Code:
$ mkdir -p ~/CM10
$ cd ~/CM10
$ repo init -u git://github.com/CyanogenMod/android.git -b jellybean
$ repo sync -j8
b. Get my JB device, kernel & vendor source trees (You could use any other, just make sure it includes the changes needed for the JB bootloader and has the 3.1 kernel)
Code:
//JB device source to device/asus/tf201
$ mkdir -p ~/CM10/device/asus
$ cd ~/CM10/device/asus
$ git clone git://github.com/craigacgomez/android_device_asus_tf201.git -b cm_jb tf201
//JB kernel source to kernel/asus/tf201
$ mkdir -p ~/CM10/kernel/asus
$ cd ~/CM10/kernel/asus
$ git clone git://github.com/craigacgomez/android_kernel_asus_tf201 -b 10.4.2.15-nvtegra tf201
//JB vendor source to vendor/asus/tf201
$ mkdir -p ~/CM10/vendor/asus
$ cd ~/CM10/vendor/asus
$ git clone git://github.com/craigacgomez/vendor_proprietary_asus_tf201 -b jellybean tf201
c. Comment out CMUpdater since this is not an official build (No harm in leaving it there as long as people are instructed not to use it)
Code:
$ cd ~/CM10/vendor/cm/config/
$ gedit common.mk [comment the line which says CMUpdater \]
d. Resync & build
Code:
$ cd ~/CM10
$ repo sync -j8
$ sh vendor/cm/get-prebuilts
$ . build/envsetup.sh && brunch tf201
3. Building TeamBaked
a. Get the TeamBaked source
Code:
$ mkdir -p ~/BAKED
$ cd ~/BAKED
$ repo init -u https://github.com/TeamBAKED/platform_manifest.git -b jb
$ repo sync -j8
b. Delete the tf201 directories
Code:
$ mkdir -p ~/BAKED/device/asus
$ rm -rf tf201
$ mkdir -p ~/BAKED/kernel/asus
$ rm -rf tf201
$ mkdir -p ~/BAKED/vendor/asus
$ rm -rf tf201
c. Get my JB device, kernel & vendor source trees (You could use any other, just make sure it includes the changes needed for the JB bootloader and has the 3.1 kernel)
Code:
//JB device source to device/asus/tf201
$ mkdir -p ~/BAKED/device/asus
$ cd ~/BAKED/device/asus
$ git clone git://github.com/craigacgomez/android_device_asus_tf201.git -b blackbean_jb tf201
//JB kernel source to kernel/asus/tf201
$ mkdir -p ~/BAKED/kernel/asus
$ cd ~/BAKED/kernel/asus
$ git clone git://github.com/craigacgomez/android_kernel_asus_tf201 -b 10.4.2.15-nvtegra tf201
//JB vendor source to vendor/asus/tf201
$ mkdir -p ~/BAKED/vendor/asus
$ cd ~/BAKED/vendor/asus
$ git clone git://github.com/craigacgomez/vendor_proprietary_asus_tf201 -b jellybean tf201
d. Resync & build
Code:
$ cd ~/BAKED
$ repo sync -j8
$ . build/envsetup.sh && brunch tf201
4. Building AOKP
a. Get the AOKP source
Code:
$ mkdir -p ~/AOKP
$ cd ~/AOKP
$ repo init -u https://github.com/AOKP/platform_manifest.git -b jb
$ repo sync -j8
b. Get my JB device, kernel & vendor source trees (You could use any other, just make sure it includes the changes needed for the JB bootloader and has the 3.1 kernel)
Code:
//JB device source to device/asus/tf201
$ mkdir -p ~/AOKP/device/asus
$ cd ~/AOKP/device/asus
$ git clone git://github.com/craigacgomez/android_device_asus_tf201.git -b aokp_jb tf201
//JB kernel source to kernel/asus/tf201
$ mkdir -p ~/AOKP/kernel/asus
$ cd ~/AOKP/kernel/asus
$ git clone git://github.com/craigacgomez/android_kernel_asus_tf201 -b 10.4.2.15-nvtegra tf201
//JB vendor source to vendor/asus/tf201
$ mkdir -p ~/AOKP/vendor/asus
$ cd ~/AOKP/vendor/asus
$ git clone git://github.com/craigacgomez/vendor_proprietary_asus_tf201 -b jellybean tf201
c. Add tf201 to the vendor & build setup
Code:
$ cd ~/AOKP/vendor/aokp
$ gedit vendorsetup.sh
Add this line vendorsetup.sh below add_lunch_combo aokp_tf101-userdebug
Code:
add_lunch_combo aokp_tf201-userdebug
Code:
$ cd ~/AOKP/vendor/aokp/products
$ gedit AndroidProducts.mk
Add this line vendorsetup.sh below $(LOCAL_DIR)/tf101.mk \
Code:
$(LOCAL_DIR)/tf201.mk \
Code:
$ cd ~/AOKP/vendor/aokp/products
$ touch tf201.mk
$ gedit tf201.mk
Add these line to tf201.mk
Code:
# Inherit device configuration for tf201.
$(call inherit-product, device/asus/tf201/full_tf201.mk)
# Inherit some common AOKP stuff.
$(call inherit-product, vendor/aokp/configs/common_tablet.mk)
$(call inherit-product, vendor/aokp/configs/gsm.mk)
PRODUCT_NAME := aokp_tf201
PRODUCT_DEVICE := tf201
PRODUCT_BRAND := asus
PRODUCT_MODEL := Transformer Prime TF201
PRODUCT_MANUFACTURER := asus
PRODUCT_BUILD_PROP_OVERRIDES += \
PRODUCT_NAME=EeePad \
BUILD_FINGERPRINT="asus/US_epad/EeePad:4.1.1/JRO03C/US_epad-10.4.2.15-20120917:user/release-keys" \
PRIVATE_BUILD_DESC="US_epad-user 4.1.1 JRO03C US_epad-10.4.2.15-20120917 release-keys" \
PRODUCT_COPY_FILES += \
vendor/aokp/prebuilt/bootanimation/bootanimation_1280_800.zip:system/media/bootanimation.zip
d. Resync & build
Code:
$ cd ~/AOKP
$ repo sync -j8
$ . build/envsetup.sh && brunch tf201
Craig, you are so awesome. Thank you so much for all you have done for the community. I hope I can end up with a nexus so I can continue to follow your development, but I'm also glad for the instruction and inspiration to start figuring out how to do more myself. Thanks again.
You're an absolute legend.
I just pressed return to start the build of my first ROM from your previous guide when I saw this..
qubz said:
Your an absolute legend.
Click to expand...
Click to collapse
I'm so sorry if I seem mean... but I just had to do this... I'm a grammar nazi!!
{
"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"
}
craigacgomez said:
I'm so sorry if I seem mean... but I just had to do this... I'm a grammar nazi!!
Click to expand...
Click to collapse
Ha ha, you got me. It's been a long day. Unfortunately the reply box had no compiler, fix uploaded.
Hey craigacgomez,
thanks for your work.
But I got a problem while trying to build CM10.
Pastebin entry:
http://pastebin.com/st0DfWv4
I'm trying to build it on a server without a gui, what should make no problems. Installed all the requirements you mentioned.
Do you know how to get rid of this error?
Greetz
Chrischdi
chrischdi said:
Hey craigacgomez,
thanks for your work.
But I got a problem while trying to build CM10.
Pastebin entry:
http://pastebin.com/st0DfWv4
I'm trying to build it on a server without a gui, what should make no problems. Installed all the requirements you mentioned.
Do you know how to get rid of this error?
Greetz
Chrischdi
Click to expand...
Click to collapse
libjli.so is a Java binary... somehow it cannot find it... could you try this...
http://serverfault.com/questions/57...ject-file-libjli-so-no-such-file-or-directory
Thanks for this.
I'm hoping to keep your work going , this is a great start
its sad that you no longer have a prime though.
sent from my Prime
Thanks for posting this! You are an absolute legend! It is a massive help as I just started setting up my build environment for compiling my own CM10 and maybe even look at Paranoid :silly:
marko! said:
Thanks for this.
I'm hoping to keep your work going , this is a great start
its sad that you no longer have a prime though.
sent from my Prime
Click to expand...
Click to collapse
gunzy83 said:
Thanks for posting this! You are an absolute legend! It is a massive help as I just started setting up my build environment for compiling my own CM10 and maybe even look at Paranoid :silly:
Click to expand...
Click to collapse
Nice to see people pick up where I left off... to be honest, all I did for this device was the first time for me... I've just been good at modding and I never dug deep into ROM & kernel work before, so I'm pretty sure you guys could do the same or even better!
Hi,
many thanks again Craig for all your work..
I tried to follow your guide for Team Baked, and ended up with::
""build/core/product_config.mk:193: *** _nic.PRODUCTS.[[vendor/baked/products/p5wifi.mk]]: "device/samsung/p5wifi/p5wifi.mk" does not exist. "Stop.
"** Don't have a product spec for: 'baked_tf201'
"** Do you have the right repo manifest?
"
Itried running breakfeast command as suggested but same error.
Anyone has a suggestion ?
Thanks
Striatum_bdr said:
Hi,
many thanks again Craig for all your work..
I tried to follow your guide for Team Baked, and ended up with::
""build/core/product_config.mk:193: *** _nic.PRODUCTS.[[vendor/baked/products/p5wifi.mk]]: "device/samsung/p5wifi/p5wifi.mk" does not exist. "Stop.
"** Don't have a product spec for: 'baked_tf201'
"** Do you have the right repo manifest?
"
Itried running breakfeast command as suggested but same error.
Anyone has a suggestion ?
Thanks
Click to expand...
Click to collapse
Don't run breakfast... just brunch... looks like it has something to do with the p5wifi... try resyncing or comment out that 'add_lunch_combo baked_p5wifi-userdebug' from vendor/baked/vendorsetup.sh
craigacgomez said:
Don't run breakfast... just brunch... looks like it has something to do with the p5wifi... try resyncing or comment out that 'add_lunch_combo baked_p5wifi-userdebug' from vendor/baked/vendorsetup.sh
Click to expand...
Click to collapse
My noob is going to start showing here, but when you say "Comment out" does that simply mean putting brackets around? Does it mean deleting that from the script? I haven't tried to build since your first little guide, but I think I put brackets around what it said to "Comment out."
lortay78 said:
My noob is going to start showing here, but when you say "Comment out" does that simply mean putting brackets around? Does it mean deleting that from the script? I haven't tried to build since your first little guide, but I think I put brackets around what it said to "Comment out."
Click to expand...
Click to collapse
That means out a # at the beginning of the line.
Hi,
Commented out all lines except tf201 in vendorsetup.sh and same error.
Striatum_bdr said:
Hi,
Commented out all lines except tf201 in vendorsetup.sh and same error.
Click to expand...
Click to collapse
Add these lines to the manifest.xml, then repo sync and brunch tf201:
<project path="device/samsung/p4-common" name="device_samsung_p4-common" remote="baked" revision="jb" />
<project path="device/samsung/p5wifi" name="device_samsung_p5wifi" remote="baked" revision="jb" /> :good:
csrabear said:
Add these lines to the manifest.xml, then repo sync and brunch tf201:
<project path="device/samsung/p4-common" name="device_samsung_p4-common" remote="baked" revision="jb" />
<project path="device/samsung/p5wifi" name="device_samsung_p5wifi" remote="baked" revision="jb" /> :good:
Click to expand...
Click to collapse
Great !
It does the trick but... lol
Then error with prebuilts arm toolchain,
/bin/bash: prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.6/bin/arm-linux-androideabi-gcc : binary file impossible to execute
Same error endless. Files are there, permission set to executable...
Is there a way to use arm ubuntu toolchain (easily installed by Synaptic)?
Thanks again
Striatum_bdr said:
Great !
It does the trick but... lol
Then error with prebuilts arm toolchain,
/bin/bash: prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.6/bin/arm-linux-androideabi-gcc : binary file impossible to execute
Same error endless. Files are there, permission set to executable...
Is there a way to use arm ubuntu toolchain (easily installed by Synaptic)?
Thanks again
Click to expand...
Click to collapse
Hi,
Try this thread for answer---
http://www.google.com/url?sa=t&rct=j&q=%2Fbin%2Fbash%3A%20prebuilts%2Fgcc%2Flinux-x86%2Farm%2Farm-linux-androideabi-4.6%2Fbin%2Farm-linux-androideabi-gcc%20%3A%20binary%20file%20impossible%20to%20execute&source=web&cd=1&cad=rja&ved=0CDAQFjAA&url=http%3A%2F%2Fforum.xda-developers.com%2Fshowthread.php%3Ft%3D1762641%26page%3D34&ei=T9KsUOnCMIuK8QS0wYHIAQ&usg=AFQjCNEZuCIRoHJX7_h_34dD3tvmeBbVsQ
or maybe this one will help--
http://www.google.com/url?sa=t&rct=j&q=%2Fbin%2Fbash%3A%20prebuilts%2Fgcc%2Flinux-x86%2Farm%2Farm-linux-androideabi-4.6%2Fbin%2Farm-linux-androideabi-gcc%20%3A%20binary%20file%20impossible%20to%20execute&source=web&cd=2&cad=rja&ved=0CDkQFjAB&url=http%3A%2F%2Fforum.xda-developers.com%2Fshowthread.php%3Ft%3D1807505%26page%3D2&ei=T9KsUOnCMIuK8QS0wYHIAQ&usg=AFQjCNE0FwC2wWy8UE5QHperdU0rI72MKw
csrabear said:
Hi,
Try this thread for answer---
or maybe this one will help--
http://www.google.com/url?sa=t&rct=j&q=%2Fbin%2Fbash%3A%20prebuilts%2Fgcc%2Flinux-x86%2Farm%2Farm-linux-androideabi-4.6%2Fbin%2Farm-linux-androideabi-gcc%20%3A%20binary%20file%20impossible%20to%20execute&source=web&cd=2&cad=rja&ved=0CDkQFjAB&url=http%3A%2F%2Fforum.xda-developers.com%2Fshowthread.php%3Ft%3D1807505%26page%3D2&ei=T9KsUOnCMIuK8QS0wYHIAQ&usg=AFQjCNE0FwC2wWy8UE5QHperdU0rI72MKw
Click to expand...
Click to collapse
Thanks that's what I suspected, I build on a 32bits machine, found 32 arm binaries in the above post.
Will try later. Thanks.
You really need a 64 bit os. Compilation started fine, but a some point gcc sdk binaries are used and again the default paths lead only to 64 bits ones.
I'll install a 64 version if ubuntu.
Thanks guys for you helps

[HELP] Building CM12 'No ~/android/system/vendor/cm'

Hi there, I'm extremely new to building a ROM or even to git and other stuff and am now trying to learn to build ROM. I have downloaded the cm12 sources for now, and trying to learn how it works, but seems to have stuck at a location.
I have been following the cm build page instructions for now from this page, and have done following stuff until now:
Make folders:
Code:
mkdir -p ~/bin
$ mkdir -p ~/android/system
Installed the repo command and entered the following to download the "repo" binary and make it executable (runnable):
Code:
$ curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
$ chmod a+x ~/bin/repo
Put the ~/bin directory in your path of execution
Initialize the CyanogenMod source repository and initialized the repository:
Code:
$ cd ~/android/system/
$ repo init -u https://github.com/CyanogenMod/android.git -b ics
Downloaded the source code
Code:
$ repo sync -j4 -f -c
[*]Get prebuilt apps
Code:
$ cd ~/android/system/vendor/cm
Now when I get to the get prebuilt apps, and I run cd ~/android/system/vendor/cm, I get the
Code:
cd ~/android/system/vendor/cm bash: No such file or directory
I tried opening the location manually, but I find no "vendor" folder under the "android/system" folder. However, there is a "vendor" folder under "android" and that "vendor" consists of folders like "cm", "cyngn" and "sony", where "sony" is related to My phone.
Under system I have folders like "core", "extras", "keymaster", "media", "netd", "qcom", "security" and "vold".
Before You say that I might have not done repo sync properly, it did complete properly. I have attached the image of completion of first time the repo sync was complete. Then a log of second time when the repo sync was done to get the device specific related stuff. I used the -f since the download of source had been interrupted due to the error "error: Exited sync due to fetch errors".
Also, don't know if it matters, but I have built a ROM before on the same system, but it was by following the instructions as posted to do. The sources were all coded to suit My phone, and all I was doing was "repo sync" and building the ROM via source with commands build/envsetup.sh
and breakfast nozomi and used to get a working build.
So please help Me out where I went wrong as I do want to learn to how to build a ROM.
Edit:
I had also tried searching for "get-prebuilts", "envsetup.sh" too, but couldn't find them either, and yes, I was always in the root directory of the source code (~/android/system).
Same issue here. Ironically I can build AICP (which is Cyanogenmod based). I can build any AOSP Rom without compiling problems also. This is a Cyanogenmod thing. It's also frustrating that even if you do manage to compile it, you probably won't be able to flash it. That happened to me with 5.0
Just for kicks, what is your OS? I'm running Linux Peppermint. I wonder if that could be the issue, since Ubuntu is recommended?
Check your java & sdk version

[GUIDE] Build Cyanogenmod from Source

Hi,
I have decided to write this post after reading so many different guides on my journey to build my own version of Cyanogenmod and after countless tries and hours of research I succeeded. Here's how:
You will need:
A Ubuntu box
A basic knowledge of Linux
A fast internet connection or a lot of patience.
Once you have setup your Ubuntu box either in a Virtual Machine of as a stand alone PC you will need to open a terminal, this can be done by pressing 'CTRL + ALT + T' or opening the search menu and typing "Terminal".
You should see the following:
Code:
[email protected]:~$
We will need to install all the necessary files in order to build and download Cyanogenmod, we can do this by running the following command:
Code:
sudo apt-get install bison build-essential curl flex git gnupg gperf libesd0-dev liblz4-tool libncurses5-dev libsdl1.2-dev libwxgtk2.8-dev libxml2 libxml2-utils lzop pngcrush schedtool squashfs-tools xsltproc zip zlib1g-dev openjdk-7-jdk openjdk-7-jre
As many Linux users have more than one version of Java installed we will need to set the the version we just installed as our default version.
Code:
sudo update-alternatives --config java
sudo update-alternatives --config javac
If by any chance you have a 64-bit version of Ubuntu installed we will require some extra files, if not please skip this command.
Code:
sudo apt-get install g++-multilib gcc-multilib lib32ncurses5-dev lib32readline-gplv2-dev lib32z1-dev
We will now for simplicity's sake need to create the following directories in your home folder. These directories will host our build.
Code:
mkdir -p ~/bin
mkdir -p ~/android/system
Once you have setup everything correctly we will now to download the Cyanogenmod source code of which we are going to use the 'Repo' utility. This utility is an automated tool for GitHub cloning. We can download this and set the correct permissions by running the following commands.
Code:
curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
chmod a+x ~/bin/repo
To continue with download the source code we will now initialize the GitHub repository that holds Cyanogenmod. We are going to need to specify the repository with -u and the branch with -b. Here I am going to download the latest available version of Cyanagenmod 13.0.
Code:
cd ~/android/system/
~/bin/repo init -u https://github.com/CyanogenMod/android.git -b cm-13.0
And to finally start downloading the source:
Code:
~/bin/repo sync -c -f -j8
Where:
-c Download the current version instead of all history.
-F Forces the connection to continue even if a connection error occurs.
-j8 This specifies the number of parallel operations. Use -j8 for a quad core processor and a -j16 for an octa-core.
Once the download completes successfully we will need to download the device specific code, this includes specific applications and kernel configurations for your device. To start downloading the files type:
Code:
source build/envsetup.sh
breakfast angler
The download should now start, it should only take minutes however this depends on your internet connection.
Again once this completes, we need to grab proprietary specific files. We first need to navigate to ~/android/system/device/huawei/angler. You can do this by running the following command:
Code:
cd ~/android/system/device/huawei/angler
As the script we are going to use has some dependencies we will need to get them first.
Code:
git clone https://github.com/JesusFreke/smali
cd smali
./gradlew build
cd ..
Additionally we need to download a Google Stock Image, I'm using angler-mmb29m-factory-8c31db3f.tgz, once downloaded you will need to unzip it and cd to it within the terminal.
and then download:
Code:
wget http://people.canonical.com/~mfisch/tools/ext4_utils.tar.gz
tar xzsf ext4_utils.tar.gz
cd ext4_utils
mv simg2img ../angler-mmb29m/
cd ../angler-mmb29m/
We will now convert the system and vendor img's using simg2img to a readable format and mount them so we extract the propriety files using ./extract_files.sh
We can do all of this by using the following commands.
Code:
./simg2img system.img system.ext4
./simg2img vendor.img vendor.ext4
sudo mkdir -p /mnt/system
sudo mkdir -p /mnt/vendor
sudo mount -rw system.ext4 /mnt/system
sudo mount -rw vendor.ext4 /mnt/vendor
Finally we can extract the proprietary files for the system image by running the following commands.
Code:
cd ~/android/system/device/huawei/angler/
./extract_files /mnt/ smali/
Finally we can finish off by our by running the brunch command to build and generate the .zip file of our own Cyanogenmod.
Code:
brunch angler
Note: This will take 20 mins - 2 hours - 2 days depending on your hardware spec.
And well that's it, the location of your generated .zip file should be in blue at the end of your terminal.
Reserved
N/A
This is amazing. Many thanks.
Great I've been looking
Sent from my XT1526 using XDA Forums Pro.
If there are bugs how can we fix that .Such as camera ,ril.For nexus 6p it is fine but for other phones
AANISH said:
If there are bugs how can we fix that .Such as camera ,ril.For nexus 6p it is fine but for other phones
Click to expand...
Click to collapse
As I have only just started my journey on this long path I have done a bit of research for you. Google released there own device specific binaries for the Nexus devices of which usually include the following:
NFC, Bluetooth and Wi-Fi
Media, Audio, Thermal, Touch Screen, Sensors
GPS, Camera, Gestures, Graphics, DRM, Video
This to me suggests that the chipset suppliers supply them - Broadcom, Qualcomm... or even other companies like Motorola. So if you are looking for binaries for other devices I would start with there chipset.
If you would like to look at Google's binaries following the link below however before you go looking for the 6P binaries they haven't been uploaded yet + if you do find any further information please reply to this comment or PM me.
Just saying, the official guide on the wiki works just fine. Been building for all my CM12-capable devices since 2015. Good for people who don't go there, though.
Sent from Google Nexus 6P @ CM13
[WARNING: XDA One have not implemented "mark forum as read" - do not use]
AndyYan said:
Just saying, the official guide on the wiki works just fine. Been building for all my CM12-capable devices since 2015. Good for people who don't go there, though.
Sent from Google Nexus 6P @ CM13
[WARNING: XDA One have not implemented "mark forum as read" - do not use]
Click to expand...
Click to collapse
That is true but I had major difficulties with it, for example it asks you to initialise the cm 12.1 branch when it wasn't available and I had a major pain with extract_files as it wouldnt use adb but instead had to use stock firmware to grab the proprietary files.
connectionalive said:
That is true but I had major difficulties with it, for example it asks you to initialise the cm 12.1 branch when it wasn't available and I had a major pain with extract_files as it wouldnt use adb but instead had to use stock firmware to grab the proprietary files.
Click to expand...
Click to collapse
You still have to spot the tiny mistakes in the guide, of course. The guide hasn't been updated in a long time.
I didn't grab any proprietary files for any of my devices and the builds still run fine - the files should already be in the repo.
Sent from Google Nexus 6P @ CM13
[WARNING: XDA One have not implemented "mark forum as read" - do not use]
AndyYan said:
You still have to spot the tiny mistakes in the guide, of course. The guide hasn't been updated in a long time.
I didn't grab any proprietary files for any of my devices and the builds still run fine - the files should already be in the repo.
Sent from Google Nexus 6P @ CM13
[WARNING: XDA One have not implemented "mark forum as read" - do not use]
Click to expand...
Click to collapse
Ah I didn't know this, I have only just started learning and researching all of this so all helps, if you could point me in the right direction, it would be greatly appreciated.
connectionalive said:
Ah I didn't know this, I have only just started learning and researching all of this so all helps, if you could point me in the right direction, it would be greatly appreciated.
Click to expand...
Click to collapse
I'm also just at the beginning - building according to official guides without modifying the source. Just giving some tips so that you don't step on the same mines as I did
P.S. Transition from CM12.1 to CM13 was a real PITA...
Sent from Google Nexus 6P @ CM13
[WARNING: XDA One have not implemented "mark forum as read" - do not use]
Great guide, I have a build environment setup on Linux Mint, but I am curious to know if the simg2img stuff and extraction is necessary, I thought the initial build process took care of that??
adzcache said:
Great guide, I have a build environment setup on Linux Mint, but I am curious to know if the simg2img stuff and extraction is necessary, I thought the initial build process took care of that??
Click to expand...
Click to collapse
It's not, it's a lot easier to just use the Muppets and not worry about it.
akellar said:
It's not, it's a lot easier to just use the Muppets and not worry about it.
Click to expand...
Click to collapse
I suppose I should start learning how to building up a roomservice.xml for this 6P then. Thanks for the confirmation.
akellar said:
It's not, it's a lot easier to just use the Muppets and not worry about it.
Click to expand...
Click to collapse
I couldn't find it on their repository under Google or Huawei
connectionalive said:
I couldn't find it on their repository under Google or Huawei
Click to expand...
Click to collapse
Look under the right branch
Code:
./simg2img system.img system.ext4
./simg2img vendor.img vendor.ext4
sudo mkdir -p /mnt/system
sudo mkdir -p /mnt/vendor
sudo mount -rw system.ext4 /mnt/system
sudo mount -rw vendor.ext4 /mnt/vendor
Code:
cd ~/android/system/device/huawei/angler/
./extract_files /mnt/ smali/
You have to take ownership of the mounted images before you can extract the blobs. Otherwise you have to use sudo for extract. Then the folder is root and make is denied permission while compiling.
XxMORPHEOUSxX said:
Code:
./simg2img system.img system.ext4
./simg2img vendor.img vendor.ext4
sudo mkdir -p /mnt/system
sudo mkdir -p /mnt/vendor
sudo mount -rw system.ext4 /mnt/system
sudo mount -rw vendor.ext4 /mnt/vendor
Code:
cd ~/android/system/device/huawei/angler/
./extract_files /mnt/ smali/
You have to take ownership of the mounted images before you can extract the blobs. Otherwise you have to use sudo for extract. Then the folder is root and make is denied permission while compiling.
Click to expand...
Click to collapse
I had no issues when actioning any of these commands but in theory you are correct.
connectionalive said:
I had no issues when actioning any of these commands but in theory you are correct.
Click to expand...
Click to collapse
I ran into issues. That's why I mentioned it. Also the extract-files tool is formatted different in my tree. After mounting these were are my exact commands. Maybe it will help someone else.
Code:
sudo chown -hR <user> /mnt/system
sudo chown -hR <user> /mnt/vendor
cd ~/android/system/device/huawei/angler
./extract-files.sh /mnt/ smali/
Hola
I have gone through this guide (really well put together) but I am getting an error almost at the very end and I need some guidance please:
I invoke brunch angler command but it shows:
~/android/system/device/huawei/angler$ brunch angler
bash: build/tools/roomservice.py: No such file or directory
** Don't have a product spec for: 'cm_angler'
** Do you have the right repo manifest?
No such item in brunch menu. Try 'breakfast'
I tried the lunch and breakfast commands but it comes up with the same error.
I did run both:
source build/envsetup.sh
breakfast angler
from the right directory and no errors came up. Can anyone assist me? Thanks.

[HELP!] Lineageos 15.1 build fails with "ninja failed with: exit status 1"

Hi everyone!
I'm trying to build LineageOS 15.1 for my Samsung Galaxy S5 - klte. Everything is good until I start compiling and then the build fails with an error "ninja failed with: exit status 1".
I've gone through the output from the build, but I can't find anything that sticks out. I also have tried Googling the problem, but I can't find anything that matches my problem. Here are my build steps:
## Create the directories
mkdir -p ~/bin
mkdir -p ~/android/lineage
## Install the repo
curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
chmod a+x ~/bin/repo
## Put the ~/bin directory in my path
nano ~/.profile
# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ] ; then
PATH="$HOME/bin:$PATH"
fi
source ~/.profile
## Initialize the source repository
cd ~/android/lineage
repo init -u https://github.com/LineageOS/android.git -b lineage-15.1
## Download the source code
repo sync -f --force-sync -j8 -c
source build/envsetup.sh
breakfast klte
cd ~/android/lineage/device/samsung/klte
./extract-files.sh
cd ~/android/lineage
export USE_CCACHE=1
./prebuilts/sdk/tools/jack-admin kill-server
export JACK_SERVER_VM_ARGUMENTS="-Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx15g"
./prebuilts/sdk/tools/jack-admin start-server
## Prepare the device-specific code
source build/envsetup.sh
breakfast klte
## Start the build
croot
brunch klte
Here is a link for the output from the build:
http://www.ohsmeg.com/bill/projects/android/lineageos/ninja_error.html
My build machine is an i7-950 with 16gb of memory, running Ubuntu 16.04 headless.
Any suggestions?
Thanks!
zog

Chromium OS building

After building Chromium OS kernel 4.14.96 & my inability to figure out how to properly deploy it as an update to an existing Chromium OS installation like Arnoldthebat v72 (with Chrome OS Kernel 4.14.83)
efforts here -
https://forum.xda-developers.com/showpost.php?p=78830818&postcount=3
I will post here my efforts at building the full Chromium OS with the latest available Kernel - I will try & start with same version as arnoldthebat i.e. v72 which has now reached stable...
There will be a lot of editing here, as it's a learning curve to me...
First is to clone the Google Chrome OS repo -
I was given this link to learn how to do this -
https://chromium.googlesource.com/chromiumos/docs/+/master/developer_guide.md
As for building Kernel for ATB v72 - I will be keeping a log of instructions here...
I do the work from within a Ubuntu xenial 16.04.xx box as suggested by the documentation,
Preparation instructions:
Create a folder where the code will be stored (they suggest chromeos) I used code
from an ext4 partition/disk with plenty of space (mine 150 GB+)
$ mkdir code
input instructions to get to clone the repo later to reach here:
$ sudo apt-get install repo
$ sudo apt-get install git-core gitk git-gui curl lvm2 thin-provisioning-tools \
python-pkg-resources python-virtualenv python-oauth2client
Install depot_tools
$ git config --global user.name "John Doe"
$ git config --global user.email "[email protected]"
$ git config --global core.autocrlf false
$ git config --global core.filemode false
$ # and for fun!
$ git config --global color.ui true
Tweak your sudoers configuration
cd /tmp
cat > ./sudo_editor <<EOF
#!/bin/sh
echo Defaults \!tty_tickets > \$1 # Entering your password in one shell affects all shells
echo Defaults timestamp_timeout=180 >> \$1 # Time between re-requesting your password, in minutes
EOF
chmod +x ./sudo_editor
sudo EDITOR=./sudo_editor visudo -f /etc/sudoers.d/relax_requirements
Configure git
git config --global user.email "[email protected]"
git config --global user.name "Your Name"
Verify that your default file permissions (umask) setting is correct
put the following line into your ~/.bashrc
umask 022
preparation for enough disk space
in folder code/
sudo dd if=/dev/zero of=swapfile bs=1024 count=$((1024*3000))
mkswap swapfile
sudo swapon swapfile
git config --global http.sslVerify false
git config --global http.postBuffer 1048576000
initialise the repo
$ repo init
$ repo init -u https://chromium.googlesource.com/chromiumos/manifest.git --repo-url https://chromium.googlesource.com/external/repo.git [-g minilayout]
get the source code
$ repo sync -j4
getting/syncing the source code took a long time as it kept failing...
I am now in this position with the source code in code/
I will fill in gaps of instructions I missed later...
Create a chroot
make sure depot_tools/ is inside the folder code/: code/depot_tools
temporary put depot_tools in the path
export PATH=$PATH:depot_tools
$ cros_sdk
... this will take some time...
NOTICE: Mounted .../code/chroot.img on chroot
NOTICE: Downloading SDK tarball..
All done
INFO cros_sdk:make_chroot: Elapsed time (make_chroot.sh): 74m37s
cros_sdk:make_chroot: All set up. To enter the chroot, run:
$ cros_sdk --enter
CAUTION: Do *NOT* rm -rf the chroot directory; if there are stale bind
mounts you may end up deleting your source tree too. To unmount and
delete the chroot cleanly, use:
$ cros_sdk --delete
(cr) ((c62d307...)) [email protected] ~/trunk/src/scripts $
now comes the real stuff...
Notes -
some extra commands might be needed to get this working:
$ sudo apt-get update
$ sudo apt-get upgrade
$ sudo apt-get install linux-generic
$ sudo apt-get install fakeroot build-essential crash kexec-tools makedumpfile kernel-wedge
$ sudo apt-get install git-core libncurses5 libncurses5-dev libelf-dev asciidoc binutils-dev
...
Hello, My guide should fill in the blanks for you (Specifically the Over The Air Upgrades) - https://kmyers.me/blog/chromeos/a-g...s-distribution-with-ota-updates-and-crostini/
could someone please tell me if there is a rpm file so chromium os could be installed on top of ubuntu using alien cause terminal too difficult for noobs to understand but rpm and alien super easy
ghostdogg49504 said:
could someone please tell me if there is a rpm file so chromium os could be installed on top of ubuntu using alien cause terminal too difficult for noobs to understand but rpm and alien super easy
Click to expand...
Click to collapse
No, ChromiumOS is a operating system that either replaces your default operating system or that you dual boot into. It is not simply a application that you can install. If you want to run it without installing it, you could in theory build it yourself and convert the image to a virtual machine image and run it in Qemu or VirtualBox.
KMyers said:
No, ChromiumOS is a operating system that either replaces your default operating system or that you dual boot into. It is not simply a application that you can install. If you want to run it without installing it, you could in theory build it yourself and convert the image to a virtual machine image and run it in Qemu or VirtualBox.
Click to expand...
Click to collapse
fydeos has a installer in fydeos store with dualboot option but its in chinese

Categories

Resources