[U-Boot] problem building fw_printenv

twebb taliaferro62 at gmail.com
Thu Dec 10 22:20:02 CET 2009


>
> I think it comes from the libc, so it wouldn't be present if someone just
> installed binutils+gcc for standalone development.
>
Great, that was the clue.  I was compiling using cross-compile tools
from android that don't use a standard libc.  When I changed to using
Codesourcery tools, I got farther...

jb at jb:u-boot-arm$ make env ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi-
make -C tools/env all MTD_VERSION= || exit 1
make[1]: Entering directory `/home/jb/work-1130/boot/u-boot-arm/tools/env'
arm-none-linux-gnueabi-gcc -Wall -DUSE_HOSTCC
-I/home/jb/work-1130/boot/u-boot-arm/include crc32.c  fw_env.c
fw_env_main.c -o fw_printenv
fw_env.c:43:27: error: mtd/mtd-user.h: No such file or directory

So then, I have this problem with mtd-user.h not being found.  If I
define MTD_VERSION=old, it then uses mtd.h and gets further but
encounters another error within mtd.h.

jb at jb:u-boot-arm$ make env ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi-
make -C tools/env all MTD_VERSION=old || exit 1
make[1]: Entering directory `/home/jb/work-1130/boot/u-boot-arm/tools/env'
arm-none-linux-gnueabi-gcc -Wall -DUSE_HOSTCC
-I/home/jb/work-1130/boot/u-boot-arm/include -DMTD_OLD crc32.c
fw_env.c  fw_env_main.c -o fw_printenv
In file included from fw_env.c:40:
/home/jb/work-1130/boot/u-boot-arm/include/linux/mtd/mtd.h:143: error:
expecteddeclaration specifiers or '...' before 'phys_addr_t'
make[1]: *** [fw_printenv] Error 1
make[1]: Leaving directory `/home/jb/work-1130/boot/u-boot-arm/tools/env'
make: *** [env] Error 1

Seems like I shouldn't have to define MTD_VERSION=old in the first
place, but without it no mtd-user.h file.  Any more suggestions?

Thanks,
twebb


More information about the U-Boot mailing list