Chinaunix首页 | 论坛 | 博客
  • 博客访问: 15332316
  • 博文数量: 2005
  • 博客积分: 11986
  • 博客等级: 上将
  • 技术积分: 22535
  • 用 户 组: 普通用户
  • 注册时间: 2007-05-17 13:56
文章分类

全部博文(2005)

文章存档

2014年(2)

2013年(2)

2012年(16)

2011年(66)

2010年(368)

2009年(743)

2008年(491)

2007年(317)

分类: 嵌入式

2009-08-21 23:07:46

如果直接使用mount -t vfat -o iocharset=cp936 /dev/mtdblock3 /mnt挂载文件系统,那么会提示:
"mount: mounting /dev/mtdblock3 on /mnt failed: Invalid argument"

nls_cp936.ko包含cp936和gb2312这2种字符集.

luther@gliethttp:/vobs/works/linux-2.6.30.4$ make menuconfig
File systems  --->
-*- Native language support  --->
   Simplified Chinese charset (CP936, GB2312)  // 当然也可以直接buit-in进内核
luther@gliethttp:/vobs/works/linux-2.6.30.4$ make modules
  Building modules, stage 2.
  MODPOST 2 modules
  CC      drivers/scsi/scsi_wait_scan.mod.o
  LD [M]  drivers/scsi/scsi_wait_scan.ko
  CC      fs/nls/nls_cp936.mod.o
  LD [M]  fs/nls/nls_cp936.ko
luther@gliethttp:/vobs/works/linux-2.6.30.4$ cp fs/nls/nls_cp936.ko /vobs/nfs
luther@gliethttp:/vobs/works/linux-2.6.30.4$ arm-linux-strip -s /vobs/nfs/nls_cp936.ko
# mount -t vfat /dev/mtdblock3 /mnt/
# ls /mnt/
busybox       iso_????????
# umount /mnt/
# insmod /nfs/nls_cp936.ko
# mount -t vfat -o iocharset=cp936 /dev/mtdblock3 /mnt/
或者
# mount -t vfat -o iocharset=gb2312 /dev/mtdblock3 /mnt/
# ls /mnt/
busybox              iso_开发板光盘
#

阅读(3171) | 评论(2) | 转发(0) |
给主人留下些什么吧!~~

chinaunix网友2009-12-15 19:34:53

不要光丢下一句话嘛,给一个正确的答案,也好让后来的人知道究竟?

chinaunix网友2009-12-15 15:43:52

拜托先搞清楚cp936和gb2312的概念好不好