Target Board ubi tool cross-Compilation

Source: Internet
Author: User

To use ubifs on the target board, you need some ubi tools, which can be obtained from the MTD-utils tool.

The cross-Compilation Method for mtd-utils-1.2.0 has been introduced in previous articles, but this version of software can only get the ubi tool for the target board, without the ubi tool for the host. The mtd-1.3.0 and above contain ubi tools for the target end and host. Compilation on the host has been introduced, and now introduces the cross-compilation mtd-utils-1.4.2. It is also compiled in the Fedora Core 9 environment. Of course, like the cross-compilation mtd-1.2.0, zlib, lzo are indispensable for cross-compilation, and installed into the cross tool chain, no longer introduced. Cross-compilation mtd-1.4.2 also requires UUID, UUID included in e2fsprogs software package, so download for cross-compilation. ---------------------------------------------------------------------------------- Download e2fsprogs:Wget http://prdownloads.sourceforge.net/e2fsprogs/e2fsprogs-1.41.14.tar.gz cross compiling Script :. /configure -- Host = arm-VFP-Linux -- enable-elf-shlibs \ -- prefix =/opt/NXP/gcc-4.3.2-glibc-2.7/ARM-VFP-Linux-GNU/Makemake installmkdir/opt/ NXP/gcc-4.3.2-glibc-2.7/ARM-VFP-Linux-GNU/include/uuidcp lib/UUID. h/opt/NXP/gcc-4.3.2-glibc-2.7/ARM-VFP-Linux-GNU/include/UUID/install libuuid and UUID. h file. Bytes ------------------------------------------------------------------------------------ Download mtd-utils-1.4.2Wget ftp://ftp.infradead.org/pub/mtd-utils/mtd-utils-1.4.2.tar.bz2 cross compilation: make cross = arm-VFP-Linux-GNU- Without_xattr = 1Some errors may occur during compilation, so ignore them. Flash_erase and other tools are generated under the arm-VFP-Linux-gnu directory. Note: The flash_eraseall tool has been replaced by flash_erase. Run the libmtd command in the arm-VFP-Linux-GNU/lib directory. copy A to the cross tool chain Directory: sudo CP libmtd. a/opt/NXP/gcc-4.3.2-glibc-2.7/ARM-VFP-Linux-GNU/lib enter the ubi-utils directory, enter make cross = arm-VFP-Linux-GNU-in the RM-VFP-Linux-gnu directory, ubimkvol/ubiattachden and other tools used on the target board will be generated. Bytes ---------------------------------------------------------------------------------------- The following provides a simpler method without cross-compiling e2fsprogs:Because it is only used on the target board, mkfs is generally not required on the target board. ubifs and other tools, so you do not need to compile this directory and directly modify it in makefile to remove mkfs. ubifs Directory: # subdirs = lib ubi-utils mkfs. ubifssubdirs = lib ubi-utils remove items related to jffs2. Make cross = arm-VFP-Linux-GNU- Without_xattr = 1Make cross = arm-VFP-Linux-GNU--C ubi-utils and enter: make cross = arm-VFP-Linux-GNU- Without_xattr = 1You can. Jffs2 errors may occur during compilation. If you do not want to see these errors, you can remove the items related to jffs2 in makefile. After compilation, generate flash_erase and other tools under the arm-VFP-Linux-gnu directory, generate libmtd library under the arm-VFP-Linux-GNU/lib directory, and convert libmtd. copy A to the cross tool chain directory. Enter the ubi-utils directory and enter make cross = arm-VFP-Linux-GNU.
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.