[uClinux-dev] JFFS question

Greg Ungerer gerg at snapgear.com
Thu Oct 6 01:43:29 EDT 2005


Hi Robin,

Robin Getz wrote:
> Greg wrote:
> 
>> Current (and at least somewhat recent - including 20041215) 
>> uClinux-dist packages have:
>>
>> if [ "$CONFIG_USER_MTDUTILS" = "y" ]; then
>>          define_bool CONFIG_LIB_ZLIB y
>> fi
>>
>> Which should take care of this.
> 
> 
> Actually - I had that, and it doesn't take care of it.
> 
> the problem I was having was users who wanted to use JFFS2 (compiled in 
> kernel support), but didn't want the target user tools, and 
> CONFIG_USER_MTDUTILS was not selected.

Ahh, I see.


> since in ./uClinux-dist/user/Makefile:
> 
> dir_$(CONFIG_JFFS_FS)                       += mtd-utils
> dir_$(CONFIG_JFFS2_FS)                      += mtd-utils
> 
> If the kernel settings are selected, then the mtd-utils directory is 
> added without setting CONFIG_USER_MTDUTILS, and without setting 
> CONFIG_LIB_ZLIB - hence the build error.
> 
> I hacked this in our cvs with similar lines in ./uClinux-dist/lib/Makefile
> 
> dir_$(CONFIG_JFFS_FS)                       += zlib
> dir_$(CONFIG_JFFS2_FS)                      += zlib
> 
> you could add something in ./uClinux-dist/config/config.in as well:
> if [ "$CONFIG_JFFS2_FS" = "y" ]; then
>          define_bool CONFIG_USER_MTDUTILS y
> fi
> 
> Up to you...

I changed the mtd-utils/Makefile now so it only builds the tools
you actually selected. And only builds the host mkfs.jffs/mkfs.jffs2
if the kernel fs for those is turned on. Should cover all cases.

Thanks
Greg



------------------------------------------------------------------------
Greg Ungerer  --  Chief Software Dude       EMAIL:     gerg at snapgear.com
SnapGear -- a CyberGuard Company            PHONE:       +61 7 3435 2888
825 Stanley St,                             FAX:         +61 7 3891 3630
Woolloongabba, QLD, 4102, Australia         WEB: http://www.SnapGear.com



More information about the uClinux-dev mailing list