sysutils.pp 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279
  1. {
  2. This file is part of the Free Pascal run time library.
  3. Copyright (c) 2004 by the Free Pascal development team
  4. Sysutils unit for the embedded target.
  5. See the file COPYING.FPC, included in this distribution,
  6. for details about the copyright.
  7. This program is distributed in the hope that it will be useful,
  8. but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  10. **********************************************************************}
  11. {$MODE objfpc}
  12. {$MODESWITCH OUT}
  13. {$H+}
  14. unit sysutils;
  15. interface
  16. { Include platform independent interface part }
  17. {$i sysutilh.inc}
  18. implementation
  19. uses
  20. sysconst,heapmgr;
  21. { Include platform independent implementation part }
  22. {$i sysutils.inc}
  23. {****************************************************************************
  24. File Functions
  25. ****************************************************************************}
  26. function FileOpen(const FileName: string; Mode: Integer): LongInt;
  27. begin
  28. result := -1;
  29. end;
  30. function FileGetDate(Handle: LongInt) : LongInt;
  31. begin
  32. result := -1;
  33. end;
  34. function FileSetDate(Handle, Age: LongInt) : LongInt;
  35. begin
  36. result := -1;
  37. end;
  38. function FileCreate(const FileName: string) : LongInt;
  39. begin
  40. result := -1;
  41. end;
  42. function FileCreate(const FileName: string; Rights: integer): LongInt;
  43. begin
  44. result := -1;
  45. end;
  46. function FileCreate(const FileName: string; ShareMode: integer; rights : integer): LongInt;
  47. begin
  48. result := -1;
  49. end;
  50. function FileRead(Handle: LongInt; Out Buffer; Count: LongInt): LongInt;
  51. begin
  52. result := -1;
  53. end;
  54. function FileWrite(Handle: LongInt; const Buffer; Count: LongInt): LongInt;
  55. begin
  56. result := -1;
  57. end;
  58. function FileSeek(Handle, FOffset, Origin: LongInt) : LongInt;
  59. begin
  60. result := -1;
  61. end;
  62. function FileSeek(Handle: LongInt; FOffset: Int64; Origin: Longint): Int64;
  63. begin
  64. result := -1;
  65. end;
  66. procedure FileClose(Handle: LongInt);
  67. begin
  68. end;
  69. function FileTruncate(Handle: THandle; Size: Int64): Boolean;
  70. begin
  71. result := false;
  72. end;
  73. function DeleteFile(const FileName: string) : Boolean;
  74. begin
  75. result := false;
  76. end;
  77. function RenameFile(const OldName, NewName: string): Boolean;
  78. begin
  79. result := false;
  80. end;
  81. Function FileAge (Const FileName : String): Longint;
  82. begin
  83. result := -1;
  84. end;
  85. Function FileExists (Const FileName : String) : Boolean;
  86. Begin
  87. result := false;
  88. end;
  89. Function FindFirst (Const Path : String; Attr : Longint; Out Rslt : TSearchRec) : Longint;
  90. begin
  91. result := -1;
  92. end;
  93. Function FindNext (Var Rslt : TSearchRec) : Longint;
  94. begin
  95. result := -1;
  96. end;
  97. Procedure FindClose (Var F : TSearchrec);
  98. begin
  99. end;
  100. Function FileGetAttr (Const FileName : String) : Longint;
  101. begin
  102. result := -1;
  103. end;
  104. Function FileSetAttr (Const Filename : String; Attr: longint) : Longint;
  105. begin
  106. result := -1;
  107. end;
  108. {****************************************************************************
  109. Disk Functions
  110. ****************************************************************************}
  111. Procedure AddDisk(const path:string);
  112. begin
  113. end;
  114. Function DiskFree(Drive: Byte): int64;
  115. Begin
  116. result := -1;
  117. End;
  118. Function DiskSize(Drive: Byte): int64;
  119. Begin
  120. result := -1;
  121. End;
  122. Function GetCurrentDir : String;
  123. begin
  124. result := '';
  125. end;
  126. Function SetCurrentDir (Const NewDir : String) : Boolean;
  127. begin
  128. result := false;
  129. end;
  130. Function CreateDir (Const NewDir : String) : Boolean;
  131. begin
  132. result := false;
  133. end;
  134. Function RemoveDir (Const Dir : String) : Boolean;
  135. begin
  136. result := false;
  137. end;
  138. function DirectoryExists(const Directory: string): Boolean;
  139. begin
  140. result := false;
  141. end;
  142. {****************************************************************************
  143. Misc Functions
  144. ****************************************************************************}
  145. Function GetLastOSError : Integer;
  146. begin
  147. Result:=-1;
  148. end;
  149. {****************************************************************************
  150. Locale Functions
  151. ****************************************************************************}
  152. Procedure GetLocalTime(var SystemTime: TSystemTime);
  153. begin
  154. end ;
  155. function SysErrorMessage(ErrorCode: Integer): String;
  156. begin
  157. { Result:=StrError(ErrorCode);}
  158. result := '';
  159. end;
  160. {****************************************************************************
  161. OS utility functions
  162. ****************************************************************************}
  163. Function GetEnvironmentVariable(Const EnvVar : String) : String;
  164. begin
  165. result := '';
  166. end;
  167. Function GetEnvironmentVariableCount : Integer;
  168. begin
  169. result := -1;
  170. end;
  171. Function GetEnvironmentString(Index : Integer) : String;
  172. begin
  173. result := '';
  174. end;
  175. function ExecuteProcess (const Path: AnsiString; const ComLine: AnsiString;Flags:TExecuteFlags=[]): integer;
  176. begin
  177. result := -1;
  178. end;
  179. function ExecuteProcess (const Path: AnsiString;
  180. const ComLine: array of AnsiString;Flags:TExecuteFlags=[]): integer;
  181. begin
  182. result := -1;
  183. end;
  184. {****************************************************************************
  185. Initialization code
  186. ****************************************************************************}
  187. Initialization
  188. InitExceptions;
  189. Finalization
  190. DoneExceptions;
  191. end.