dos.pp 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172
  1. {
  2. This file is part of the Free Pascal run time library.
  3. Copyright (c) 2022 by the Free Pascal Compiler development team
  4. See the file COPYING.FPC, included in this distribution,
  5. for details about the copyright.
  6. This program is distributed in the hope that it will be useful,
  7. but WITHOUT ANY WARRANTY; without even the implied warranty of
  8. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  9. **********************************************************************}
  10. unit Dos;
  11. interface
  12. {$MODE objfpc}
  13. type
  14. SearchRec = Packed Record
  15. AnchorPtr : Pointer; { Pointer to the Anchorpath structure }
  16. Fill: Array[1..15] of Byte; {future use}
  17. {End of replacement for fill}
  18. Attr : BYTE; {attribute of found file}
  19. Time : LongInt; {last modify date of found file}
  20. Size : LongInt; {file size of found file}
  21. Name : String[255]; {name of found file}
  22. End;
  23. {$I dosh.inc}
  24. implementation
  25. {$define HAS_GETMSCOUNT}
  26. {$I dos.inc}
  27. {******************************************************************************
  28. --- Info / Date / Time ---
  29. ******************************************************************************}
  30. function DosVersion: Word;
  31. begin
  32. result := 0;
  33. end;
  34. procedure GetDate(Var Year, Month, MDay, WDay: Word);
  35. begin
  36. Year := 0;
  37. Month := 0;
  38. MDay := 0;
  39. WDay := 0;
  40. end;
  41. procedure SetDate(Year, Month, Day: Word);
  42. begin
  43. end;
  44. procedure GetTime(Var Hour, Minute, Second, Sec100: Word);
  45. begin
  46. Hour := 0;
  47. Minute := 0;
  48. Second := 0;
  49. Sec100 := 0;
  50. end;
  51. Procedure SetTime(Hour, Minute, Second, Sec100: Word);
  52. begin
  53. end;
  54. function GetMsCount: int64;
  55. begin
  56. result := 0;
  57. end;
  58. {******************************************************************************
  59. --- Exec ---
  60. ******************************************************************************}
  61. procedure Exec(const Path: PathStr; const ComLine: ComStr);
  62. begin
  63. end;
  64. {******************************************************************************
  65. --- Disk ---
  66. ******************************************************************************}
  67. Function DiskFree(Drive: Byte): int64;
  68. Begin
  69. result := -1;
  70. end;
  71. Function DiskSize(Drive: Byte): int64;
  72. Begin
  73. result := -1;
  74. end;
  75. procedure FindFirst(const Path: PathStr; Attr: Word; Var f: SearchRec);
  76. begin
  77. DosError:=18;
  78. end;
  79. procedure FindNext(Var f: SearchRec);
  80. begin
  81. DosError:=18;
  82. end;
  83. procedure FindClose(Var f: SearchRec);
  84. begin
  85. DosError:=18;
  86. end;
  87. {******************************************************************************
  88. --- File ---
  89. ******************************************************************************}
  90. function FSearch(path: PathStr; dirlist: String) : PathStr;
  91. begin
  92. result := '';
  93. end;
  94. Procedure getftime (var f; var time : longint);
  95. begin
  96. end;
  97. Procedure setftime(var f; time : longint);
  98. Begin
  99. End;
  100. procedure getfattr(var f; var attr : word);
  101. begin
  102. End;
  103. procedure setfattr(var f; attr : word);
  104. begin
  105. end;
  106. {******************************************************************************
  107. --- Environment ---
  108. ******************************************************************************}
  109. function EnvCount: Longint;
  110. begin
  111. result := -1;
  112. end;
  113. function EnvStr(Index: LongInt): String;
  114. begin
  115. result := '';
  116. end;
  117. function GetEnv(envvar : String): String;
  118. begin
  119. result := '';
  120. end;
  121. end.