解决 ubuntu 1104 vm_share不能使用的问题

来源:互联网 发布:php excel 下拉菜单 编辑:程序博客网 时间:2024/06/14 09:49

If you’re trying to install vmware-tools inside a linux guest and get the dreaded
super.c:73: error: unknown field ‘clear_inode’ specified in initializer 
error while compiling vmhgfs for shared folder support (which I use a lot),

this will help (thanks to Anjo from German VMWare Forums):

  • unpack /usr/lib/vmware-tools/modules/source/vmhgfs.tar to somewhere
  • open vmhgfs-only/super.c in your favorite text editor
  • edit from
    1#ifndef VMW_USE_IGET_LOCKED
    2 .read_inode       = HgfsReadInode,
    3 #endif
    4 .clear_inode      = HgfsClearInode,
    5 .put_super        = HgfsPutSuper,
    6 .statfs              = HgfsStatfs,
    7 };

    to (note .clear_inode -> .evict_inode)

     

    1#ifndef VMW_USE_IGET_LOCKED
    2   .read_inode    = HgfsReadInode,
    3#endif
    4   .evict_inode   = HgfsClearInode,
    5   .put_super     = HgfsPutSuper,
    6   .statfs           = HgfsStatfs,
    7};
  • repack vmhgfs.tar including edited super.c
  • execute vmware-config-tools.pl
  • profit

 

原帖地址:http://gordonazmo.wordpress.com/2011/02/09/fixing-vmware-tools-vmhgfs-on-newer-kernels-probably-anything-2-6-36/

原创粉丝点击