i_win.pas 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315
  1. {
  2. Copyright (c) 1998-2008 by Peter Vreman
  3. This unit implements support information structures for win32
  4. This program is free software; you can redistribute it and/or modify
  5. it under the terms of the GNU General Public License as published by
  6. the Free Software Foundation; either version 2 of the License, or
  7. (at your option) any later version.
  8. This program is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. GNU General Public License for more details.
  12. You should have received a copy of the GNU General Public License
  13. along with this program; if not, write to the Free Software
  14. Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  15. ****************************************************************************
  16. }
  17. { This unit implements support information structures for win32. }
  18. unit i_win;
  19. {$i fpcdefs.inc}
  20. interface
  21. uses
  22. systems;
  23. const
  24. system_i386_win32_info : tsysteminfo =
  25. (
  26. system : system_i386_WIN32;
  27. name : 'Win32 for i386';
  28. shortname : 'Win32';
  29. flags : [tf_files_case_aware,tf_has_dllscanner,tf_smartlink_library
  30. ,tf_smartlink_sections{,tf_section_threadvars}{,tf_needs_dwarf_cfi},
  31. tf_winlikewidestring,tf_no_pic_supported,
  32. tf_no_generic_stackcheck,tf_has_winlike_resources,
  33. tf_dwarf_only_local_labels,
  34. tf_safecall_exceptions];
  35. cpu : cpu_i386;
  36. unit_env : 'WIN32UNITS';
  37. extradefines : 'MSWINDOWS;WINDOWS';
  38. exeext : '.exe';
  39. defext : '.def';
  40. scriptext : '.bat';
  41. smartext : '.sl';
  42. unitext : '.ppu';
  43. unitlibext : '.ppl';
  44. asmext : '.s';
  45. objext : '.o';
  46. resext : '.res';
  47. resobjext : '.or';
  48. sharedlibext : '.dll';
  49. staticlibext : '.a';
  50. staticlibprefix : 'libp';
  51. sharedlibprefix : '';
  52. sharedClibext : '.dll';
  53. staticClibext : '.a';
  54. staticClibprefix : 'lib';
  55. sharedClibprefix : '';
  56. importlibprefix : 'libimp';
  57. importlibext : '.a';
  58. Cprefix : '_';
  59. newline : #13#10;
  60. dirsep : '\';
  61. assem : as_i386_pecoff;
  62. assemextern : as_gas;
  63. link : nil;
  64. linkextern : nil;
  65. ar : ar_gnu_ar;
  66. res : res_gnu_windres;
  67. dbg : dbg_stabs;
  68. script : script_dos;
  69. endian : endian_little;
  70. alignment :
  71. (
  72. procalign : 16;
  73. loopalign : 4;
  74. jumpalign : 0;
  75. constalignmin : 0;
  76. constalignmax : 16;
  77. varalignmin : 0;
  78. varalignmax : 16;
  79. localalignmin : 4;
  80. localalignmax : 8;
  81. recordalignmin : 0;
  82. recordalignmax : 4;
  83. maxCrecordalign : 16
  84. );
  85. first_parm_offset : 8;
  86. stacksize : 16*1024*1024;
  87. abi : abi_default;
  88. );
  89. system_x64_win64_info : tsysteminfo =
  90. (
  91. system : system_x86_64_win64;
  92. name : 'Win64 for x64';
  93. shortname : 'Win64';
  94. flags : [tf_files_case_aware,tf_has_dllscanner,
  95. tf_smartlink_sections,tf_smartlink_library,tf_winlikewidestring,tf_no_pic_supported,
  96. tf_no_generic_stackcheck,tf_has_winlike_resources];
  97. cpu : cpu_x86_64;
  98. unit_env : 'WIN64UNITS';
  99. extradefines : 'MSWINDOWS;WINDOWS';
  100. exeext : '.exe';
  101. defext : '.def';
  102. scriptext : '.bat';
  103. smartext : '.sl';
  104. unitext : '.ppu';
  105. unitlibext : '.ppl';
  106. asmext : '.s';
  107. objext : '.o';
  108. resext : '.res';
  109. resobjext : '.obj';
  110. sharedlibext : '.dll';
  111. staticlibext : '.a';
  112. staticlibprefix : 'libp';
  113. sharedlibprefix : '';
  114. sharedClibext : '.dll';
  115. staticClibext : '.a';
  116. staticClibprefix : 'lib';
  117. sharedClibprefix : '';
  118. importlibprefix : 'libimp';
  119. importlibext : '.a';
  120. Cprefix : '';
  121. newline : #13#10;
  122. dirsep : '\';
  123. assem : as_x86_64_pecoff;
  124. assemextern : as_x86_64_masm;
  125. link : nil;
  126. linkextern : nil;
  127. ar : ar_gnu_ar;
  128. res : res_win64_gorc;
  129. dbg : dbg_stabs;
  130. script : script_dos;
  131. endian : endian_little;
  132. alignment :
  133. (
  134. procalign : 16;
  135. loopalign : 8;
  136. jumpalign : 0;
  137. constalignmin : 0;
  138. constalignmax : 16;
  139. varalignmin : 0;
  140. varalignmax : 16;
  141. localalignmin : 8;
  142. localalignmax : 16;
  143. recordalignmin : 0;
  144. recordalignmax : 8;
  145. maxCrecordalign : 16
  146. );
  147. first_parm_offset : 16;
  148. stacksize : 16*1024*1024;
  149. abi : abi_default;
  150. );
  151. system_arm_wince_info : tsysteminfo =
  152. (
  153. system : system_arm_wince;
  154. name : 'WinCE for ARM';
  155. shortname : 'WinCE';
  156. flags : [tf_files_case_aware{,tf_winlikewidestring},
  157. tf_smartlink_sections,tf_requires_proper_alignment,tf_no_pic_supported,
  158. tf_has_winlike_resources];
  159. cpu : cpu_arm;
  160. unit_env : '';
  161. extradefines : 'UNDER_CE;WINDOWS;UNICODE';
  162. exeext : '.exe';
  163. defext : '.def';
  164. scriptext : '.bat';
  165. smartext : '.sl';
  166. unitext : '.ppu';
  167. unitlibext : '.ppl';
  168. asmext : '.s';
  169. objext : '.o';
  170. resext : '.res';
  171. resobjext : '.or';
  172. sharedlibext : '.dll';
  173. staticlibext : '.a';
  174. staticlibprefix : 'libp';
  175. sharedlibprefix : '';
  176. sharedClibext : '.dll';
  177. staticClibext : '.a';
  178. staticClibprefix : 'lib';
  179. sharedClibprefix : '';
  180. importlibprefix : 'libimp';
  181. importlibext : '.a';
  182. Cprefix : '';
  183. newline : #13#10;
  184. dirsep : '\';
  185. assem : as_gas;
  186. assemextern : as_gas;
  187. link : nil;
  188. linkextern : nil;
  189. ar : ar_gnu_ar_scripted;
  190. res : res_gnu_windres;
  191. dbg : dbg_stabs;
  192. script : script_dos;
  193. endian : endian_little;
  194. alignment :
  195. (
  196. procalign : 4;
  197. loopalign : 4;
  198. jumpalign : 0;
  199. constalignmin : 0;
  200. constalignmax : 4;
  201. varalignmin : 0;
  202. varalignmax : 4;
  203. localalignmin : 0;
  204. localalignmax : 4;
  205. recordalignmin : 0;
  206. recordalignmax : 4;
  207. maxCrecordalign : 4
  208. );
  209. first_parm_offset : 8;
  210. stacksize : 262144;
  211. abi : abi_default;
  212. );
  213. system_i386_wince_info : tsysteminfo =
  214. (
  215. system : system_i386_wince;
  216. name : 'WinCE for i386';
  217. shortname : 'WinCE';
  218. flags : [tf_files_case_aware
  219. {,tf_winlikewidestring},tf_smartlink_sections,tf_no_pic_supported,
  220. tf_has_winlike_resources];
  221. cpu : cpu_i386;
  222. unit_env : '';
  223. extradefines : 'UNDER_CE;WINDOWS;UNICODE';
  224. exeext : '.exe';
  225. defext : '.def';
  226. scriptext : '.bat';
  227. smartext : '.sl';
  228. unitext : '.ppu';
  229. unitlibext : '.ppl';
  230. asmext : '.s';
  231. objext : '.o';
  232. resext : '.res';
  233. resobjext : '.or';
  234. sharedlibext : '.dll';
  235. staticlibext : '.a';
  236. staticlibprefix : 'libp';
  237. sharedlibprefix : '';
  238. sharedClibext : '.dll';
  239. staticClibext : '.a';
  240. staticClibprefix : 'lib';
  241. sharedClibprefix : '';
  242. importlibprefix : 'libimp';
  243. importlibext : '.a';
  244. Cprefix : '_';
  245. newline : #13#10;
  246. dirsep : '\';
  247. assem : as_i386_pecoffwince;
  248. assemextern : as_gas;
  249. link : nil;
  250. linkextern : nil;
  251. ar : ar_gnu_ar_scripted;
  252. res : res_gnu_windres;
  253. dbg : dbg_stabs;
  254. script : script_dos;
  255. endian : endian_little;
  256. alignment :
  257. (
  258. procalign : 4;
  259. loopalign : 4;
  260. jumpalign : 0;
  261. constalignmin : 0;
  262. constalignmax : 4;
  263. varalignmin : 0;
  264. varalignmax : 4;
  265. localalignmin : 4;
  266. localalignmax : 4;
  267. recordalignmin : 0;
  268. recordalignmax : 4;
  269. maxCrecordalign : 16
  270. );
  271. first_parm_offset : 8;
  272. stacksize : 262144;
  273. abi : abi_default;
  274. );
  275. implementation
  276. initialization
  277. {$ifdef CPU86}
  278. {$ifdef WIN32}
  279. {$ifndef WDOSX}
  280. set_source_info(system_i386_win32_info);
  281. {$endif WDOSX}
  282. {$endif WIN32}
  283. {$ifdef WINCE}
  284. set_source_info(system_i386_wince_info);
  285. {$endif WINCE}
  286. {$endif CPU86}
  287. {$ifdef CPUX86_64}
  288. {$ifdef WIN64}
  289. {$ifndef WDOSX}
  290. set_source_info(system_x64_win64_info);
  291. {$endif WDOSX}
  292. {$endif WIN64}
  293. {$endif CPUX86_64}
  294. {$ifdef CPUARM}
  295. {$ifdef WINCE}
  296. set_source_info(system_arm_wince_info);
  297. {$endif WINCE}
  298. {$endif CPUARM}
  299. end.