FCNTL.DEF 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. (* Release 3.10 *)
  2. (*-------------------------------------------------------------------------*
  3. * *
  4. * FCNTL.DEF - Modula-2 interface to FCNTL.H *
  5. * *
  6. * COPYRIGHT (C) 1989..1992 Clarion Software Corporation. *
  7. * All Rights Reserved *
  8. * *
  9. *--------------------------------------------------------------------------*)
  10. (*# project("#set tsc='on'") *)
  11. (*# call(o_a_size=>off, o_a_copy=>off, c_conv=>on, result_optional=>on) *)
  12. (*# module(implementation=>off, init_code=>off) *)
  13. (*# name(prefix=>c) *)
  14. DEFINITION MODULE fcntl;
  15. CONST
  16. O_RDONLY = 0;
  17. O_WRONLY = 1;
  18. O_RDWR = 2;
  19. O_CREAT = 100H; (* create and open file *)
  20. O_TRUNC = 200H; (* open with truncation *)
  21. O_EXCL = 400H; (* exclusive open *)
  22. O_EOF = 200H; (* set when text file hits ^Z *)
  23. (* A file in append mode may be written to only at its end. *)
  24. O_APPEND = 800H; (* to end of file *)
  25. (* File mode special bits. User may only read these bits *)
  26. O_CHANGED = 1000H; (* File has been written *)
  27. O_DEVICE = 2000H; (* user read only flag *)
  28. O_TEXT = 4000H; (* CR-LF translation *)
  29. O_BINARY = 8000H; (* no translation *)
  30. (* DOS 3.x file sharing options *)
  31. SH_NOINHERIT = 80H;
  32. SH_COMPAT = 00H;
  33. SH_DENYRW = 10H;
  34. SH_DENYWR = 20H;
  35. SH_DENYRD = 30H;
  36. SH_DENYNO = 40H;
  37. SH_DENYNONE = SH_DENYNO;
  38. VAR
  39. fmode : CARDINAL;
  40. END fcntl.