How to build a system.img for Nexus One? - Nexus One General

Greetings,
I have a brand new Nexus One and I am eager to void the warranty.
I have downloaded the Android Eclair source (v2.1r2) and built the system image (system.img) and it works great on the Android emulator. I am hoping this forum will tell me two things:
1. What do I do differently to build a system image for the Nexus one? I'm pretty sure I'm going to need different drivers and libraries - how do I get them and how do I insert them into my build process?
2. How do I get (flash) the system image onto the Nexus one phone? I'm guessing I use this command: fastboot flash system system.img, but I'm not sure.
Thanks. I apologize in advance if this is the wrong forum for these questions.
-Sam

Related

[Q] install Android 4.3 modem, etc

I'm currently at the running CyanogenMod 10.1, and I think I'm just going to wait until they release a 10.2 build. I am however interested in updating the rest of the firmware, without flashing the system
. Is this possible? Can I just download the factor image and edit it? Would deleting the system partition be enough?
adriangb said:
I'm currently at the running CyanogenMod 10.1, and I think I'm just going to wait until they release a 10.2 build. I am however interested in updating the rest of the firmware, without flashing the system
. Is this possible? Can I just download the factor image and edit it? Would deleting the system partition be enough?
Click to expand...
Click to collapse
When you download the factory image, it is a package with different parts in it. You will find the new bootloader and the new radio. Just extract what you want from the package and install them. If you are familiar with fastboot it is really easy. If you look around a bit you'll probably even find some flashable zips in this forum.
Edit: I looked for you. http://forum.xda-developers.com/showthread.php?t=2361437
obtained said:
When you download the factory image, it is a package with different parts in it. You will find the new bootloader and the new radio. Just extract what you want from the package and install them. If you are familiar with fastboot it is really easy. If you look around a bit you'll probably even find some flashable zips in this forum.
Edit: I looked for you. http://forum.xda-developers.com/showthread.php?t=2361437
Click to expand...
Click to collapse
Just flashed the new bootloader and the modem thru fastboot -thanks for confirming!
And thanks for looking, picked up the camera APK from that thread, cool, thanks.
Booted, seems to be working fine.

[Q] Read the Sticky, still can't flash stock or lollipop kernels

I wonder whether there is help for someone who thought he knew how to flash a kernel but apparently is deluded. I have the original nexus seven Wi-Fi tablet android version 4.3 build number JWR66V. The system still wants to update me to 4.3 because I ripped some files out of the cache directory to prevent OTA updates. I have both fastboot and adb. I have read the stickies about flashing.
The phone is rooted and the bootloader is unlocked. I use TWRP custom recovery, and it's a good thing, because I solidly bricked myself up just trying to get my lollipop. I know there are tools to root a nexus seven even with stock lollipop, so I thought I'd upgrade my phone to stock lollipop and then use one of those methods. I tried both the stock lollipop kernel and the one provided by chain fire, which I understand is rooted already. (I'm assuming upgrading to lollipop will lose me my root, unless I want to recover back to 4.3.)
I tried to do these things a couple of different ways. When I tried fast boot, I got the message "error: neither -p product specified nor ANDROID_PRODUCT_OUT set". There was a YouTube video suggesting how to deal with this error message. I'm pretty sure I followed the instructions but no go. (I was using the "flash all" command.) This was after I had put the file containing lollipop in the directory, both zipped and unzipped (so that I had an .img file instead of a zip file). I tried using both the zip file with all of the lollipop partitions and the system image file individually. No go. I also had a message that android-info.txt could not be found, even though it was in the same, working directory.
I could be wrong but I don't think you can install a complete updated kernel from a file on the device. I think that works only with update.zip.
I'm still thinking fastboot is my best bet, but there are dependencies apparently and I don't know what files to include in its directory. Then, am I wise to go to stock and then root, or should I simply flash the stock kernel already rooted? I assume that's what chainfire is providing, correct?
I notice the lollipop official ROM nor Chainfire’s supposedly-rooted image have any file named nakasi. I have only .img files, no .zip files.
I found a dozen sets of instructions on how to flash a kernel but something I need is missing from all of them. Does anyone know what it is or can anyone offer some helpful advice?
Thank you,
Leon M.

What is Vendor.img?

Hi guys,
I've seen this question asked a few times, but no one ever answers it. I tried looking around on other sites, but can't seem to find an answer.
I just came over from a Galaxy S5, and I don't think we ever used those. Is there anybody who'd be willing to point me in the direction of knowing?
It holds proprietary binaries for the Nexus 5x, 6p and 9, from what I've read.
Hey OP, did you find out what a vendor.img is yet? Have also come to Nexus from Samsung. Flashing my first rom, and don't know what this vendor file is. Or if I even need it. Like you, have found threads where people ask, but no definitive answers...
I've been curious about this, too.
Also wondering how the Vendor partition differs from System. What do the data/functions in the Vendor partition do?
EFS partition seems to be specific to the individual device (unique IMEI). Is Vendor specific to each phone too, or do all Nexus 6Ps have the same thing in the Vendor partition (assuming they're on the same build of Android)?
The vendor.img is important to this device if you upgrade your OS. You might have to flash it with every update too or your camera won´t work. This IMG is indeed strange if you´re used to older devices which are not as complicated.
Gorgtech said:
The vendor.img is important to this device if you upgrade your OS. You might have to flash it with every update too or your camera won´t work. This IMG is indeed strange if you´re used to older devices which are not as complicated.
Click to expand...
Click to collapse
OK cool, so the vendor file is Nexus specific. And the OS won't operate properly without it? So I assume it's not possible to bake the vendor file straight into a custom rom? Just flashed pure nexus vendor.img along with the rom. Still not exactly sure what it does, but hey, if I need it, I'll flash it if I change roms.
Gorgtech said:
The vendor.img is important to this device if you upgrade your OS. You might have to flash it with every update too or your camera won´t work. This IMG is indeed strange if you´re used to older devices which are not as complicated.
Click to expand...
Click to collapse
Supplemental information about Vendor from a former member of the Android team
SlimSnoopOS said:
Supplemental information about Vendor from a former member of the Android team
Click to expand...
Click to collapse
Thanks for the link. So from my understanding, all the proprietary nexus files are stored on it's own 'vendor' partition, separate from the OS. And is updatable with it's own .img. Which is different to touchwiz (for eg.), which merges it's own files with android into the one partition.
Edit: FYI, just found this in PureNexus FAQ's:
Q: What is the vendor.img/vendor.zip? (5X and 6P only)
A: The vendor partition is new to Nexus phones with the 5X and 6P. Previous devices had the vendor files (proprietary binaries and drivers) within the system partition (/system/vendor); on these devices, they now have it in their own partition (/vendor). If this is not up to date, you will get an error message and need to flash the latest one so your phone continues to work properly. Beans has made this a TWRP flashable file available in the OP of the 5X and 6P threads (also linked below) so you do not have to fastboot it.
I'm a bit late on this one, but does anyone know if updating OTA (stock android updater) updates the vendor partition as well or do you specifically have to flash it?
So, with this partition for drivers ROMs can keep the same camera quality as stock?
Llaver said:
I'm a bit late on this one, but does anyone know if updating OTA (stock android updater) updates the vendor partition as well or do you specifically have to flash it?
Click to expand...
Click to collapse
No, the vendor.img does not need to be flashed independently of the OTA update.
I have seen it in many phones other than mentioned in the thread, it is even in infinix phones. what i think is it contains apps from google like maps, drive, gmail, photos, and also some apps from the manufacturer of the phone. why i think this is the case? here is the my guess.
yesterday when i tried to remove google bloatware and manufacturer bloatware with root permissions etc. it didn't work.
i have magisk root, i had set selinux permissive as someone told me it would help BUT i was still unable to remove bloatware. they were removed for now but whenever i rebooted my phone, they were reinstalled and i think this vendor file does that.
as per google's android documents here is the difinitoin.
vendor: The vendor partition contains any binary that is not distributable to the Android open source project.
means, google apps are never distributed with AOSP but manufacturers does that via vendor.img to make it non-removable? i guess.
jameeldroid said:
I have seen it in many phones other than mentioned in the thread, it is even in infinix phones. what i think is it contains apps from google like maps, drive, gmail, photos, and also some apps from the manufacturer of the phone. why i think this is the case? here is the my guess.
yesterday when i tried to remove google bloatware and manufacturer bloatware with root permissions etc. it didn't work.
i have magisk root, i had set selinux permissive as someone told me it would help BUT i was still unable to remove bloatware. they were removed for now but whenever i rebooted my phone, they were reinstalled and i think this vendor file does that.
as per google's android documents here is the difinitoin.
vendor: The vendor partition contains any binary that is not distributable to the Android open source project.
means, google apps are never distributed with AOSP but manufacturers does that via vendor.img to make it non-removable? i guess.
Click to expand...
Click to collapse
????? This is a nexus, it contains no bloat because its a google device, its not a Motorola , lg, samjunk etc. Those devices contain "bloat" there are zero applications installed from the mfg, its stock android.
Not sure why you can't remove system apps, sounds like user error. I have never had an issue removing something with root and titanium backup.
The vendor contains what it says it does the binarys, blobs and other interworking's of the device that are needed for it to operate.
Hello. I'm a new to Android world. I have a Moto G4 (XT1622) and I install AOSiP-8.1-Derp-athene-20180501/Android Open Source Illusion Project ROM (arm64).
I see 'your vendor image does not match the system' message on every boot with a prompt to flash npjs25.93-14-13.
I download latest Nougat ROMs (arm32) (both adb and twrp flashable). Try both methods of flashing with success.
Then I install custom ROM again (with TWRP, clean) and see the same message again.
I search regarding this problem and everything ends with flashing Stock ROM and perform installing custom one again, what I done and mention of vendor.img file.
I try to find such file but no luck, my device has only vendor folder.
So my question is: how to remove this message in the custom ROM?
I post it here because ROM's thread is closed
Thanks.

Confusion and/or problem with vendor - Help greatly appriciated

Hello everyone. So I'm brand new to not only xda but rooting and the likes all together. Yesterday I rooted my nexus 6p without issue and I will now list what I used. Twrp 3.0.0 -1-angler, BETA-SuperSU-v2.67-20160121175247. My phone build was MMB29P. then I flashed on pure_nexus_angler-6.0.1-20160315-CMTE and PureNexus_Dynamic_GApps_6.x.x_3-15-16.zip. Now my phone is saying its build MHC19J. I don't know if that is normal, but now I'm confused. When I boot up I get an Android System message saying " It appears your vendor image may be out of date. Please flash the latest vendor image for your device. " So followed the link to the vendor images and I see the list of vendor images however I don't see my build MHC19J.. or am I to get MMB29P? also once I do get it downloaded and load up twrp I see the option to click image and there's several boxes there to check/uncheck.. Do i just check vendor? So put as short as possible I need to know which vendor image i should get and how to flash it from twrp. Thanks for reading and your help will be greatly appreciated.
Also I almost forgot.. Will i need to flash a raido file or anything like that??
Read this first: http://forum.xda-developers.com/showpost.php?p=64399854
Then read this: http://forum.xda-developers.com/showpost.php?p=65102741&postcount=7741
The answers to your question are both in those links, which you should ALWAYS read. You'll thank me later for making you read those.
Danzilla79 said:
Hello everyone. So I'm brand new to not only xda but rooting and the likes all together. Yesterday I rooted my nexus 6p without issue and I will now list what I used. Twrp 3.0.0 -1-angler, BETA-SuperSU-v2.67-20160121175247. My phone build was MMB29P. then I flashed on pure_nexus_angler-6.0.1-20160315-CMTE and PureNexus_Dynamic_GApps_6.x.x_3-15-16.zip. Now my phone is saying its build MHC19J. I don't know if that is normal, but now I'm confused. When I boot up I get an Android System message saying " It appears your vendor image may be out of date. Please flash the latest vendor image for your device. " So followed the link to the vendor images and I see the list of vendor images however I don't see my build MHC19J.. or am I to get MMB29P? also once I do get it downloaded and load up twrp I see the option to click image and there's several boxes there to check/uncheck.. Do i just check vendor? So put as short as possible I need to know which vendor image i should get and how to flash it from twrp. Thanks for reading and your help will be greatly appreciated.
Also I almost forgot.. Will i need to flash a raido file or anything like that??
Click to expand...
Click to collapse
The vendor version you need is MHC19I which you can download following the link on the first post on the pure nexus ROM. Flash it via TWRP by hitting the flash img button and then selecting the vendor partition (duh). It's also good to make sure you are running the latest bootloader and radio (the bootloader should be on version 3.51 and the radio on 3.61).

Fixed 6P bootlooping, now i want to update to Oreo

Hi all, I posted this in the 6P bootloop thread, but didn't get a response. As that is a pretty LONG thread, i'm thinking my question may have gotten lost in the jumble.
Quick run down.
A few months back my 6P started the BLOD. I found the fix listed on these pages, applied it, and have been happily using my phone ever since. Phone is bone stock 7.1.2 other than the TWRP recovery and the modified EX kernel for 4 cores.
Since the fix, my phone FINALLY got the OTA update to go to Android 8.0 and i obviously want to get it done. My concern is HOW to do this without causing more headache.
Can anyone point me in the right direction? Should i use the OTA update or download the factory image from Google?
I've got some knowledge as i used to be into the "rooting" scene back in the day, but haven't for a while, so i feel a little lost.
Thanks for any help.
johnnyphive said:
Hi all, I posted this in the 6P bootloop thread, but didn't get a response. As that is a pretty LONG thread, i'm thinking my question may have gotten lost in the jumble.
Quick run down.
A few months back my 6P started the BLOD. I found the fix listed on these pages, applied it, and have been happily using my phone ever since. Phone is bone stock 7.1.2 other than the TWRP recovery and the modified EX kernel for 4 cores.
Since the fix, my phone FINALLY got the OTA update to go to Android 8.0 and i obviously want to get it done. My concern is HOW to do this without causing more headache.
Can anyone point me in the right direction? Should i use the OTA update or download the factory image from Google?
I've got some knowledge as i used to be into the "rooting" scene back in the day, but haven't for a while, so i feel a little lost.
Thanks for any help.
Click to expand...
Click to collapse
Well, for starters do NOT take the OTA. It will either fail or boot loop your phone. Due to the fact you have a modified boot.img you will need to update manually using fastboot with the full image. Re-apply the modified kernel after you finish updating the partitions, but BEFORE booting the first time. You can follow most guides on how to manually update a full image using fastboot, just add the step of flashing the modified kernel before booting.
Thanks for the reply and the help. If i could ask for a little more help, as this is my only phone.
Can you explain the difference between the modified boot.img and the modified kernel?
If i download the factory image from here (https://developers.google.com/android/images) is it ok to the get the latested one (Nov 2017) or do i need to get the original one (Sep 2017 as i'm on Fi)
Once i flash the factory image, is it going to replace the modified boot image as well as the modified kernel?
Follow the OP on this thread (https://forum.xda-developers.com/nexus-6p/general/guide-fix-nexus-6p-bootloop-death-blod-t3640279) in the downloads section there appear to be 2 files i would need, the "Boot.img from stock 6.17, 8.0 firmware" and "EX kernel version 5.03". Am i understanding that correctly?
Like i said, this is my only phone, and i'm probably just being overly paranoid about bricking it, but any clarification would be greatly appreciated.
johnnyphive said:
Thanks for the reply and the help. If i could ask for a little more help, as this is my only phone.
Can you explain the difference between the modified boot.img and the modified kernel?
If i download the factory image from here (https://developers.google.com/android/images) is it ok to the get the latested one (Nov 2017) or do i need to get the original one (Sep 2017 as i'm on Fi)
Once i flash the factory image, is it going to replace the modified boot image as well as the modified kernel?
Follow the OP on this thread (https://forum.xda-developers.com/nexus-6p/general/guide-fix-nexus-6p-bootloop-death-blod-t3640279) in the downloads section there appear to be 2 files i would need, the "Boot.img from stock 6.17, 8.0 firmware" and "EX kernel version 5.03". Am i understanding that correctly?
Like i said, this is my only phone, and i'm probably just being overly paranoid about bricking it, but any clarification would be greatly appreciated.
Click to expand...
Click to collapse
Use the latest November image. The boot.img contains the kernel and ramdisk, critical files necessary to load the device before the filesystem can be mounted. When you flash the new boot.img contained in the Google image, it will overwrite the patched kernel. You then need to re-patch it by installing EX kernel before booting. EX writes to (modifies) the stock boot.img. There are also pre-modifed boot.img files floating around. You will probably get more detailed help in the dedicated thread. Learning to flash manually (or remember how) is not really a big deal and a necessary skill for modding (and for getting yourself out of trouble). Good luck. :good:
v12xke said:
Use the latest November image. The boot.img contains the kernel and ramdisk, critical files necessary to load the device before the filesystem can be mounted. When you flash the new boot.img contained in the Google image, it will overwrite the patched kernel. You then need to re-patch it by installing EX kernel before booting. EX writes to (modifies) the stock boot.img. There are also pre-modifed boot.img files floating around. You will probably get more detailed help in the dedicated thread. Learning to flash manually (or remember how) is not really a big deal and a necessary skill for modding (and for getting yourself out of trouble). Good luck. :good:
Click to expand...
Click to collapse
Ok, so 1 last time (sorry)
1 - Downloaded the latest 8.0.0 factory image from google (this contains the bootloader, radio, and partitions (.zip).
2 - Get phone to fastboot and apply the above 3 new images
3- before rebooting, flash oreo4core (new, modified boot.img), TWRP recovery.img
4- reboot to recovery (TWRP) and apply the modified EX kernel
5 - reboot and (hopefully) profit
Am i missing anything, or doing anything that isn't needed?
johnnyphive said:
Ok, so 1 last time (sorry)
1 - Downloaded the latest 8.0.0 factory image from google (this contains the bootloader, radio, and partitions (.zip).
2 - Get phone to fastboot and apply the above 3 new images
3- before rebooting, flash oreo4core (new, modified boot.img), TWRP recovery.img
4- reboot to recovery (TWRP) and apply the modified EX kernel
5 - reboot and (hopefully) profit
Am i missing anything, or doing anything that isn't needed?
Click to expand...
Click to collapse
<<Disclaimer: I don't use the 4 core kernel, so I don't know if it comes with installer script or someone has just modified the latest boot.img>> Unzip the "partitions" zip you refer to and extract those image files to the same folder as bootloader and modem. For example, you can keep TWRP recovery if you don't flash the recovery.img. That is how you preserve your custom recovery. So in other words you'll now have a folder (your ADB folder?) with 5 image files.... bootloader, radio, boot, system, and vendor all in one folder. <<Note: it is my understanding you just substitute the latest oreo4core file (should be boot.img?) If this is true, copy that file into your ADB folder and let it overwrite the stock boot.img. Stop. Copy over flash-all.bat, change the *.bat extension to *.txt and open in notepad. You will see (and can copy/paste) the fastboot commands to get you started with bootloader and radio. Then flash the last 3 (boot, system, vendor). At this point you can reboot into the OS. Since you substituted the oreo4core boot.img file for the stock boot.img there is no need to use TWRP to flash anything. That and since you skipped flashing the recovery.img, TWRP is still there.
v12xke said:
<<Disclaimer: I don't use the 4 core kernel, so I don't know if it comes with installer script or someone has just modified the latest boot.img>> Unzip the "partitions" zip you refer to and extract those image files to the same folder as bootloader and modem. For example, you can keep TWRP recovery if you don't flash the recovery.img. That is how you preserve your custom recovery. So in other words you'll now have a folder (your ADB folder?) with 5 image files.... bootloader, radio, boot, system, and vendor all in one folder. <<Note: it is my understanding you just substitute the latest oreo4core file (should be boot.img?) If this is true, copy that file into your ADB folder and let it overwrite the stock boot.img. Stop. Copy over flash-all.bat, change the *.bat extension to *.txt and open in notepad. You will see (and can copy/paste) the fastboot commands to get you started with bootloader and radio. Then flash the last 3 (boot, system, vendor). At this point you can reboot into the OS. Since you substituted the oreo4core boot.img file for the stock boot.img there is no need to use TWRP to flash anything. That and since you skipped flashing the recovery.img, TWRP is still there.
Click to expand...
Click to collapse
Thank for the help! Everything seems to be up and running. I know you said you don't use the "4 cores" (can only assume your either on a different phone or yours isn't affected by the BLOD), but do you know if i still need to apply the EX kernel update, or know of a way to tell if it's already been applied?
Thanks again for all the help. I was pretty much in the right direction, but being as how i'd been away from it for a while, i wanted some backup
johnnyphive said:
Thank for the help! Everything seems to be up and running. I know you said you don't use the "4 cores" (can only assume your either on a different phone or yours isn't affected by the BLOD), but do you know if i still need to apply the EX kernel update, or know of a way to tell if it's already been applied? Thanks again for all the help. I was pretty much in the right direction, but being as how i'd been away from it for a while, i wanted some backup
Click to expand...
Click to collapse
I don't think you can flash EX kernel from now on. I think you have to use a modded boot.img that will contain his kernel/ramdisk. This is my guess. You really should be getting your information in the dedicated thread where everyone is actually installing and using it. Google "oreo 4 core" and you will find the XDA thread is the first hit. Good luck. :good:

Categories

Resources