- 论坛徽章:
- 0
|
u-boot只能识别uImage格式的内核。如果使用u-boot来启动Linux的话就需要生成uImage。在linux 2.6以上的内核中,可以用make uImage去直接生成它,但是linux 2.4或者更早的linux的话,你就要自己手动去生成它。
现在我使用的是linux-2.6-22。在使用make uImage到最后一步时出现如下提示:
No jigdo file or MD5 file specified!
mkimage [OPTIONS]
Options:
-f Specify an input MD5 file. MD5s must be in jigdo's
pseudo-base64 format
-j Specify the input jigdo file
-t Specify the input template file
-m Map to to find the files in the mirror
-M Rather than try to build the image, just check that
all the needed files are available. If any are missing,
list them in this file.
-v Make the output logging more verbose
-l Specify a logfile to append to.
If not specified, will log to stderr
-o Specify a file to write the ISO image to.
If not specified, will write to stdout
-q Quick mode. Don't check MD5sums. Dangerous!
-s Start byte number; will start at 0 if not specified
-e End byte number; will end at EOF if not specified
-z Don't attempt to rebuild the image; simply print its
size in bytes
我查了很久,一直没有找到原因。后来把u-boot/tools/mkimage拷到/usr/bin/后问题解决。
怀疑是原来使用的那个mkimge版本不对,可能太高或者太低了。换u-boot里的mkimage就可以了。
内核用以生成uImage的命令语句在这:linux-2.6.22/scripts/mkuboot.sh
附:执行u-boot/tools/mkimage后应提示
Usage: mkimage -l image
-l ==> list image header information
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)
mkimage [-D dtc_options] -f fit-image.its fit-image
本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u2/86510/showart_1723868.html |
|