README 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. Hi!
  2. I'm midnight commander's vfs layer. Before you start hacking me,
  3. please read this file. I'm integral part of midnight commander, but I
  4. try to go out and live my life myself as a shared library, too. That
  5. means that I should try to use as little functions from midnight as
  6. possible (so I'm tiny, nice and people like me), that I should not
  7. pollute name space by unnecessary symbols (so I do not crash fellow
  8. programs) and that I should have a clean interface between myself and
  9. midnight.
  10. Because I'm rather close to midnight, try to:
  11. * Keep updating ChangeLog file.
  12. * Keep the indentation as the rest of the code. Following could help
  13. you with your friend emacs:
  14. (defun mc-c-mode ()
  15. "C mode with adjusted defaults for use with the Midnight commander."
  16. (interactive)
  17. (c-mode)
  18. (c-set-style "K&R")
  19. (setq c-indent-level 4
  20. c-continued-statement-offset 4
  21. c-brace-offset 0
  22. c-argdecl-indent 4
  23. c-label-offset -4
  24. c-brace-imaginary-offset 0
  25. c-continued-brace-offset 0
  26. c-tab-always-indent nil
  27. c-basic-offset 4
  28. tab-width 8
  29. comment-column 60))
  30. (setq auto-mode-alist (cons '(".*/mc/.*\\.[ch]$" . mc-c-mode)
  31. auto-mode-alist))
  32. And because I'm trying to live life on my own as libvfs.so, try to:
  33. * Make sure all exported symbols are defined in vfs.h and begin with
  34. 'vfs_'.
  35. * Do not make any references from midnight into modules like tar. It
  36. would probably pollute name space and midnight would depend on concrete
  37. configuration of libvfs. mc_setctl() and mc_ctl() are your
  38. friends. (And mine too :-).
  39. Pavel Machek
  40. pavel@ucw.cz
  41. PS: If you'd like to use my features in whole operating system, you
  42. might want to link me to rpc.nfsd. On
  43. http://atrey.karlin.mff.cuni.cz/~pavel/podfuk/podfuk.html you'll find
  44. how to do it.
  45. PPS: I have a friend, shared library called avfs, which is LD_PRELOAD
  46. capable. You can reach her at http://www.inf.bme.hu/~mszeredi/avfs.