【问题标题】:How to install uboot tools in centos 8centos 8如何安装uboot工具
【发布时间】:2021-01-07 18:44:13
【问题描述】:

我想在我的 Centos 8 中使用命令 mkimage。

我尝试使用命令 dnf install uboot-tools 以 root 身份安装 uboot-tools,但这不可用。

谁能指导我如何在我的系统上安装 uboot-tools?

【问题讨论】:

    标签: centos boot u-boot


    【解决方案1】:

    我建议从头开始构建 u-boot 工具,这不会花很长时间:

    wget https://github.com/u-boot/u-boot/archive/v2020.07.tar.gz
    tar zxf v2020.07.tar.gz
    make  -C u-boot-2020.07 mrproper qemu-x86_64_defconfig tools
    

    mkimage 将在此处提供:u-boot-2020.07/tools/mkimage

    ls -gG u-boot-2020.07/tools/mkimage
    -rwxrwxr-x 1 240152 Sep 22 08:13 u-boot-2020.07/tools/mkimage
    
    u-boot-2020.07/tools/mkimage 
    Error: Missing output filename
    Usage: u-boot-2020.07/tools/mkimage -l image
              -l ==> list image header information
           u-boot-2020.07/tools/mkimage [-x] -A arch -O os -T type -C comp -a addr -e ep -n name -d data_file[:data_file...] image
              -A ==> set architecture to 'arch'
              -O ==> set operating system to 'os'
              -T ==> set image type to 'type'
              -C ==> set compression type 'comp'
              -a ==> set load address to 'addr' (hex)
              -e ==> set entry point to 'ep' (hex)
              -n ==> set image name to 'name'
              -d ==> use image data from 'datafile'
              -x ==> set XIP (execute in place)
           u-boot-2020.07/tools/mkimage [-D dtc_options] [-f fit-image.its|-f auto|-F] [-b <dtb> [-b <dtb>]] [-i <ramdisk.cpio.gz>] fit-image
               <dtb> file is used with -f auto, it may occur multiple times.
              -D => set all options for device tree compiler
              -f => input filename for FIT source
              -i => input filename for ramdisk file
    Signing / verified boot not supported (CONFIG_FIT_SIGNATURE undefined)
           u-boot-2020.07/tools/mkimage -V ==> print version information and exit
    Use '-T list' to see a list of available image types
    

    你现在可以将它移动到/usr/local/bin

    sudo cp u-boot-2020.07/tools/mkimage /usr/local/bin
    

    【讨论】:

    • 嗨@Prasanna Kotrappa 如果这个或任何答案已经解决了您的问题,请考虑通过单击复选标记接受它。这向更广泛的社区表明您已经找到了解决方案,并为回答者和您自己提供了一些声誉。没有义务这样做。
    • 嗨,我试过了,但出现了一些错误,[root@loke zip_fpga]# make -C u-boot-2020.07 mrproper qemu-x86_64_defconfig tools make: Entering directory '/mnt/asic_work/kotrappa/zip_fpga /u-boot-2020.07' CLEAN spl/u-boot.cfg CLEAN u-boot.cfg CLEAN scripts/basic CLEAN scripts/dtc/pylibfdt CLEAN scripts/kconfig CLEAN include/config include/generated spl CLEAN .config .config.old include/autoconf.mk include/autoconf.mk.dep include/config.h HOSTCC scripts/basic/fixdep HOSTCC scripts/kconfig/conf.o YACC scripts/kconfig/zconf.tab.c
    • HOSTCC scripts/kconfig/zconf.tab.o HOSTLD scripts/kconfig/conf ##配置写入.config #scripts/kconfig/conf --syncconfig Kconfig UPD include/config.h CFG u- boot.cfg GEN include/autoconf.mk GEN include/autoconf.mk.dep CFG spl/u-boot.cfg GEN spl/include/autoconf.mk UPD include/config/uboot.release UPD include/generated/version_autogenerated.h UPD include/generated/timestamp_autogenerated.h UPD include/generated/dt.h CC lib/asm-offsets.s UPD include/generated/generic-asm-offsets.h
    • CC arch/x86/lib/asm-offsets.s UPD 包含/生成/asm-offsets.h 运送脚本/dtc/pylibfdt/libfdt.i PYMOD 脚本/dtc/pylibfdt/_libfdt.so无法执行“swig”:没有这样的文件或目录错误:命令“swig”失败,退出状态为 1 make[4]: *** [scripts/dtc/pylibfdt/Makefile:27: scripts/dtc/pylibfdt/_libfdt.所以] 错误 1 ​​make[3]: *** [scripts/Makefile.build:419: scripts/dtc/pylibfdt] 错误 2 make[2]: *** [scripts/Makefile.build:419: scripts/dtc]错误 2 make[1]: *** [Makefile:577: 脚本] 错误 2
    • make: *** [Makefile:547: __build_one_by_one] 错误 2 make: 离开目录 '/mnt/asic_work/kotrappa/zip_fpga/u-boot-2020.07'
    猜你喜欢
    • 1970-01-01
    • 2021-09-14
    • 2020-06-29
    • 1970-01-01
    • 2023-03-20
    • 2021-06-23
    • 1970-01-01
    • 2019-08-16
    • 2020-11-07
    相关资源
    最近更新 更多