Basically it is possible to build U-boot tools (particularly -
fw_printenw) under LTIB using U-boot package :
$ ./ltib -m prep -p u-boot
$ ./ltib -m scbuild -p u-boot
$ ./ltib -m shell
LTIB> cd rpm/BUILD/u-boot-2009.08
LTIB> make env
After that directory rpm/BUILD/u-boot-2009.08 /tools/env contains the needed files.
To configure correctly fw_env.config, please use section FLASH and environment
organization in board header file (say, mx35_3stack.h or mx35_3stack_mmc.h)
in U-boot directory
include/configs/mx35_<reference board name>.h
There environment parameters are as following :
CONFIG_ENV_OFFSET, CONFIG_ENV_SIZE, CONFIG_ENV_SIZE.
Linux fw_env.config may be as following :
# MTD device name Device offset Env. size Flash sector size Number of sectors
/dev/mtd0 0xC0000 0x2000 0x2000 1
Device offset = CONFIG_ENV_OFFSET in mx35_3stack.h (768 * 1024)
- Env. size = CONFIG_ENV_SIZE in mx35_3stack.h (128 * 1024)
Flash sector size = CONFIG_ENV_SIZE.