Difference between revisions of "Dtbtool"

From postmarketOS
Jump to navigation Jump to search
(explain how to use dtbtool-lineage, see https://github.com/postmarketOS/pmbootstrap/issues/1055)
 
Line 1: Line 1:
The <code>dtbtool</code> is needed to combine multiple <code>dtb</code> (device tree blob) files into one <code>dt.img</code> file, that can then be attached to the end of the <code>boot.img</code> for Android devices (<code>postmarketos-mkinitfs</code> does that).
+
The <code>dtbtool</code> is needed to combine multiple <code>dtb</code> ([[dtb|device tree blob]]) files into one <code>dt.img</code> file, that can then be attached to the end of the <code>boot.img</code> for Android devices (<code>postmarketos-mkinitfs</code> does that).
  
 
=== Do I need it? ===
 
=== Do I need it? ===

Revision as of 14:24, 21 January 2018

The dtbtool is needed to combine multiple dtb (device tree blob) files into one dt.img file, that can then be attached to the end of the boot.img for Android devices (postmarketos-mkinitfs does that).

Do I need it?

You only need this tool if pmbootstrap bootimg_analyze on a known working boot.img file for your device outputs:

deviceinfo_bootimg_qcdt="true"

Using an alternative version

There exist lots of versions of this dtbtool. We have packaged the (Python) version from Skales now, which seems to be properly maintained and versioned. But it may have incompatibilities with some (older?) kernels, where the dt.img file was properly generated with code based on the original C version.

If you would like to test if Skales' version produces the same output as the LineageOS version (which is what we had packaged before), download the files from here and place them in aports/main/dtbtool-lineage. Build it with pmbootstrap build dtbtool-lineage and depend on dtbtool-lineage instead of dtbtool in your kernel package, then change the dtbTool line in your kernel APKBUILD to dtbTool-lineage.