qnx.inc 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. {
  2. $Id: qnx.inc,v 1.1.2.2 2002/05/01 14:10:36 carl Exp $
  3. Copyright (c) 2002 by Carl Eric Codere
  4. Implements QNX system calls and types
  5. This program is free software; you can redistribute it and/or modify
  6. it under the terms of the GNU General Public License as published by
  7. the Free Software Foundation; either version 2 of the License, or
  8. (at your option) any later version.
  9. This program is distributed in the hope that it will be useful,
  10. but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. GNU General Public License for more details.
  13. You should have received a copy of the GNU General Public License
  14. along with this program; if not, write to the Free Software
  15. Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
  16. MA 02110-1301, USA.
  17. ****************************************************************************
  18. }
  19. const
  20. _FSTYPSZ = 16;
  21. type
  22. fsblkcnt_t = int64;
  23. fsfilcnt_t = int64;
  24. statvfs_t = packed record
  25. f_bsize : cardinal; {* fundamental file system block size *}
  26. f_frsize : cardinal; {* fragment size *}
  27. f_blocks : fsblkcnt_t; {* total blocks of f_frsize on fs *}
  28. f_bfree : fsblkcnt_t; {* total free blocks of f_frsize *}
  29. f_bavail : fsblkcnt_t; {* free blocks avail to non-superuser *}
  30. f_files : fsfilcnt_t; {* total file nodes (inodes) *}
  31. f_free : fsfilcnt_t; {* total free file nodes *}
  32. f_favail : fsfilcnt_t; {* free nodes avail to non-superuser *}
  33. f_fsid : cardinal; {* file system id (dev for now) *}
  34. f_basetype : array[0.._FSTYPSZ-1] of char; {* target fs type name null terminated *}
  35. f_flag : cardinal; {* bit-mask of flags *}
  36. f_namemax : cardinal; {* maximum file name length *}
  37. f_filler : array[1..21] of cardinal; {* reserved for future expansion *}
  38. end;
  39. function sys_statvfs(const path: pchar; var buf : statvfs_t): cint; cdecl; external name 'statvfs';
  40. {
  41. $Log: qnx.inc,v $
  42. Revision 1.1.2.2 2002/05/01 14:10:36 carl
  43. * Correct structures for stat and dirent
  44. * correct some compilation problems
  45. * change types according to 80x86 version
  46. Revision 1.1.2.1 2001/12/20 02:55:01 carl
  47. + QNX versions (still untested)
  48. }