FORUMS

[TOOL] Android Image Kitchen - Unpack/Repack Kernel Ramdisk [Win/Android/Linux/Mac]

14,178 posts
Thanks Meter: 31,659
 
By osm0sis, Senior Recognized Developer / Recognized Contributor on 30th December 2012, 03:55 PM
Post Reply Email Thread
8th April 2014, 06:05 AM |#281  
MrMarkEdward's Avatar
Senior Member
Flag New Llano, Louisiana
Thanks Meter: 416
 
More
Quote:
Originally Posted by osm0sis

TWRP pre-Loki's their images. See the OP for the addon to unpack, and links to info on how to flash the repacked image.

TY so much worked awesome TY again
The Following User Says Thank You to MrMarkEdward For This Useful Post: [ View ] Gift MrMarkEdward Ad-Free
8th April 2014, 07:40 AM |#282  
Senior Member
Thanks Meter: 121
 
More
Quote:
Originally Posted by osm0sis

I also just finished getting a crosstool-ng cross-compiler from Cygwin to Linux build working which I'll detail soon.

Anyone willing to test out the AIK-Linux version I just made? PM me please. I've got dynamically linked binaries in there but if those don't work, then I'll make some static binaries.

You testing these on the Nexus 7? I might have to get a phone for testing this out. Sounds interesting
8th April 2014, 09:08 AM |#283  
osm0sis's Avatar
OP Senior Recognized Developer / Recognized Contributor
Flag Halifax
Thanks Meter: 31,659
 
Donate to Me
More
Quote:
Originally Posted by nk7

You testing these on the Nexus 7? I might have to get a phone for testing this out. Sounds interesting

The AIK-Mobile one runs from the command-line on the N7 and any other ARM device (I use it on my GN as well). The new AIK-Linux one is similarly for desktop Linux's command-line. I'll probably load up a virtual machine tomorrow to test if no Linux users volunteer first.
9th April 2014, 04:27 AM |#284  
HolyAngel's Avatar
Recognized Developer / Inactive Recognized Contributor
Flag Springfield
Thanks Meter: 13,689
 
Donate to Me
More
This is the only thing I've been able to use repack the boot images for HTC One M8, works absolutely perfectly! Thank you very much for the hard work! ^^

Sent from my HTC One_M8 using XDA Premium 4 mobile app
The Following User Says Thank You to HolyAngel For This Useful Post: [ View ]
10th April 2014, 05:44 AM |#285  
Member
Thanks Meter: 20
 
More
Hi. Could I check you AI kitchen under linux? I've checked the repacked boot.img & recovery.img under Win7x64 on my K910S before. it's working fine, thanx for the hard work.

HolyAngel
There is another new tool for repacking boot & recovery on the net from And_pda. It works fine like the AIK did.
10th April 2014, 06:03 AM |#286  
osm0sis's Avatar
OP Senior Recognized Developer / Recognized Contributor
Flag Halifax
Thanks Meter: 31,659
 
Donate to Me
More
Please don't advertise other tools in my thread..
10th April 2014, 06:08 AM |#287  
Senior Member
Thanks Meter: 214
 
More
Brother, why don't you add MTK boot/recovery.img unpacking repacking support in this amazing tool?

---------- Post added at 10:08 AM ---------- Previous post was at 10:07 AM ----------

This way we can have all in one tool
10th April 2014, 06:16 AM |#288  
osm0sis's Avatar
OP Senior Recognized Developer / Recognized Contributor
Flag Halifax
Thanks Meter: 31,659
 
Donate to Me
More
I appreciate the love, but my tool deals with images that follow the Android image standard. MTK chose not to follow it for whatever reason..

Info/links are available via the OP to a good simple MTK repack tool by @bgcngm.
The Following 2 Users Say Thank You to osm0sis For This Useful Post: [ View ]
10th April 2014, 06:23 AM |#289  
Senior Member
Thanks Meter: 214
 
More
Yes i know about that tool, and another windows tool... But i wanted to have a all in one tool and your tool is very well coded
11th April 2014, 11:07 PM |#290  
osm0sis's Avatar
OP Senior Recognized Developer / Recognized Contributor
Flag Halifax
Thanks Meter: 31,659
 
Donate to Me
More
Another longtime request. New Linux version of Android Image Kitchen up in the OP! Bringing my updated binaries back home!

Now also supporting macOS out-of-the-box (i.e. no Homebrew or MacPorts addons needed) with v3.0+!

AIK-Linux:
- Complete feature parity with the Windows/Android versions, including compression support, --original to repack with the original ramdisk, --origsize to pad the repacked image to the size of the original, --level to change the compression level of the repacked ramdisk, --avbkey to change the key used for Android Verified Boot signing of the repacked image, and --forceelf to make an older unpacked Sony ELF file repack as an ELF.
- Unpacks as root by default to maintain full control over all repacked ramdisk file permissions, --nosudo argument available to attempt unpack/repack as user if possible.
- All scripts allow unpacking/repacking with the current directory instead of the AIK directory if --local is the first command-line argument.
- "--help" is also available for all included scripts.
- Unpack with "tar -xzvf AIK-Linux-*.tar.gz" in your home directory then you can go to AIK-Linux and use, eg. "./unpackimg.sh boot.img" to get started.

mkbootimg, unpackbootimg: https://github.com/osm0sis/mkbootimg
pxa-mkbootimg, pxa-unpackbootimg: https://github.com/osm0sis/pxa-mkbootimg
elftool: https://github.com/osm0sis/elftool
unpackelf: https://github.com/osm0sis/unpackelf
mboot: https://github.com/osm0sis/mboot
dumpimage, mkimage: https://www.denx.de/wiki/U-Boot/WebHome
mkmtkhdr: https://github.com/osm0sis/mkmtkhdr
loki_tool: https://github.com/djrbliss/loki
futility: https://github.com/osm0sis/futility
boot_signer.jar (requires JRE 8+): https://forum.xda-developers.com/and...ified-t3600606
blobpack, blobunpack: https://github.com/AndroidRoot/BlobTools
dhtbsign: https://github.com/osm0sis/dhtbsign
rkcrc: https://github.com/rockchip-linux/rkflashtool
sony_dump: https://forum.xda-developers.com/cro...image-t3530077
lz4: https://lz4.github.io/lz4/
magic: https://www.darwinsys.com/file/
cpio, dd, file, lzop, tail, truncate, xz; libiconv.2, libintl.8, liblzma.5, liblzo2.2, libmagic.1 (macOS): https://www.macports.org/
gzip, bzip2, lzop, xz; awk, basename, bash, cpio, cut, dd, dirname, env, file, find, grep, hexdump, printf, rev, sed, stat, sudo, tail, truncate, wc (Linux): (required system packages/commands)

GitHub: https://github.com/osm0sis/Android-I...mits/AIK-Linux

Most included binaries were compiled using my patched crosstool-ng i686 and x86_64 Cygwin to Linux cross-compiler toolchains, now as part of my own AIK Build Farm.

macOS compiles built with osxcross. Instructions available via my Build Farm post.

I'm not going to interfere with anyone's Linux installations, nor needlessly bundle a ton of commonly available binaries, so if you need extra compression support you need to have those packages installed. In my Ubuntu Server VM gzip, bzip2 and xz/lzma all seem to come pretty much by default, and "apt-get install lzop" handles lzop. Java depends on your setup, but openjdk-8-jre will be what most will want if not already included. lz4 would be the only one that would have to be built from source on many distros, so I have considered it an exception, built it and included it myself.

Thanks to shoey63 and talich for testing. Cheers!


If you are reporting a problem with your device, please clearly state your device name and model/variant as well as provide a link to the image file.
The Following 34 Users Say Thank You to osm0sis For This Useful Post: [ View ]
14th April 2014, 03:22 PM |#291  
Senior Member
Flag Foshan
Thanks Meter: 674
 
More
Works very well,thanks!
The Following User Says Thank You to kin912 For This Useful Post: [ View ] Gift kin912 Ad-Free
Post Reply Subscribe to Thread

Tags
kernel, ramdisk, recovery, repack, unpack

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes