i_bsd.pas 32 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864
  1. {
  2. Copyright (c) 1998-2008 by Peter Vreman
  3. This unit implements support information structures for FreeBSD/NetBSD
  4. and OpenBSD
  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., 675 Mass Ave, Cambridge, MA 02139, USA.
  16. ****************************************************************************
  17. }
  18. { This unit implements support information structures for FreeBSD/NetBSD.
  19. OpenBSD is only added for i386 for now, though it exists for most
  20. other common CPU's too}
  21. unit i_bsd;
  22. {$i fpcdefs.inc}
  23. interface
  24. uses
  25. systems;
  26. const
  27. system_aarch64_freebsd_info : tsysteminfo =
  28. (
  29. system : system_aarch64_freebsd;
  30. name : 'FreeBSD for aarch64';
  31. shortname : 'FreeBSD';
  32. flags : [tf_needs_symbol_size,
  33. tf_needs_symbol_type,
  34. tf_files_case_sensitive,
  35. tf_requires_proper_alignment,tf_safecall_exceptions,
  36. tf_smartlink_sections,tf_pic_uses_got,
  37. tf_has_winlike_resources
  38. {$ifdef llvm}
  39. ,tf_use_psabieh
  40. {$endif llvm}
  41. ,tf_supports_hidden_symbols
  42. ];
  43. cpu : cpu_aarch64;
  44. unit_env : 'BSDUNITS';
  45. extradefines : 'UNIX;HASUNIX;BSD';
  46. exeext : '';
  47. defext : '.def';
  48. scriptext : '.sh';
  49. smartext : '.sl';
  50. unitext : '.ppu';
  51. unitlibext : '.ppl';
  52. asmext : '.s';
  53. objext : '.o';
  54. resext : '.res';
  55. resobjext : '.or';
  56. sharedlibext : '.so';
  57. staticlibext : '.a';
  58. staticlibprefix : 'libp';
  59. sharedlibprefix : 'lib';
  60. sharedClibext : '.so';
  61. staticClibext : '.a';
  62. staticClibprefix : 'lib';
  63. sharedClibprefix : 'lib';
  64. importlibprefix : 'libimp';
  65. importlibext : '.a';
  66. Cprefix : '';
  67. newline : #10;
  68. dirsep : '/';
  69. assem : as_gas;
  70. assemextern : as_gas;
  71. link : ld_none;
  72. linkextern : ld_bsd;
  73. ar : ar_gnu_ar;
  74. res : res_elf;
  75. dbg : dbg_dwarf2; //dbg_stabs;
  76. script : script_unix;
  77. endian : endian_little;
  78. alignment :
  79. (
  80. procalign : 8;
  81. loopalign : 4;
  82. jumpalign : 0;
  83. jumpalignskipmax : 0;
  84. coalescealign : 0;
  85. coalescealignskipmax: 0;
  86. constalignmin : 0;
  87. constalignmax : 16;
  88. varalignmin : 0;
  89. varalignmax : 16;
  90. localalignmin : 4;
  91. localalignmax : 16;
  92. recordalignmin : 0;
  93. recordalignmax : 16;
  94. maxCrecordalign : 16
  95. );
  96. first_parm_offset : 16;
  97. stacksize : 8*1024*1024;
  98. stackalign : 16;
  99. abi : abi_default;
  100. llvmdatalayout : 'e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128';
  101. mos6502page0alloc : [];
  102. );
  103. system_i386_freebsd_info : tsysteminfo =
  104. (
  105. system : system_i386_FreeBSD;
  106. name : 'FreeBSD/ELF for i386';
  107. shortname : 'FreeBSD';
  108. flags : [tf_pic_uses_got,tf_files_case_sensitive,
  109. {$ifdef tls_threadvars}
  110. tf_section_threadvars,
  111. {$endif tls_threadvars}
  112. tf_needs_symbol_type,tf_needs_symbol_size
  113. ,tf_smartlink_sections,tf_has_winlike_resources
  114. ,tf_supports_hidden_symbols];
  115. cpu : cpu_i386;
  116. unit_env : 'BSDUNITS';
  117. extradefines : 'UNIX;BSD;HASUNIX';
  118. exeext : '';
  119. defext : '.def';
  120. scriptext : '.sh';
  121. smartext : '.sl';
  122. unitext : '.ppu';
  123. unitlibext : '.ppl';
  124. asmext : '.s';
  125. objext : '.o';
  126. resext : '.res';
  127. resobjext : '.or';
  128. sharedlibext : '.so';
  129. staticlibext : '.a';
  130. staticlibprefix : 'libp';
  131. sharedlibprefix : 'lib';
  132. sharedClibext : '.so';
  133. staticClibext : '.a';
  134. staticClibprefix : 'lib';
  135. sharedClibprefix : 'lib';
  136. importlibprefix : 'libimp';
  137. importlibext : '.a';
  138. Cprefix : '';
  139. newline : #10;
  140. dirsep : '/';
  141. assem : as_i386_elf32;
  142. assemextern : as_gas;
  143. link : ld_none;
  144. linkextern : ld_bsd;
  145. ar : ar_gnu_ar;
  146. res : res_elf;
  147. dbg : dbg_stabs;
  148. script : script_unix;
  149. endian : endian_little;
  150. alignment :
  151. (
  152. procalign : 4;
  153. loopalign : 4;
  154. jumpalign : 0;
  155. jumpalignskipmax : 0;
  156. coalescealign : 0;
  157. coalescealignskipmax: 0;
  158. constalignmin : 0;
  159. constalignmax : 4;
  160. varalignmin : 0;
  161. varalignmax : 4;
  162. localalignmin : 0;
  163. localalignmax : 4;
  164. recordalignmin : 0;
  165. recordalignmax : 2;
  166. maxCrecordalign : 4
  167. );
  168. first_parm_offset : 8;
  169. stacksize : 262144;
  170. stackalign : 4;
  171. abi : abi_default;
  172. { note: default LLVM stack alignment is 16 bytes for this target }
  173. llvmdatalayout : 'e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64-f80:32:32-n8:16:32-S32';
  174. mos6502page0alloc : [];
  175. );
  176. system_x86_64_freebsd_info : tsysteminfo =
  177. (
  178. system : system_x86_64_freebsd;
  179. name : 'FreeBSD for x86-64';
  180. shortname : 'FreeBSD';
  181. flags : [tf_needs_symbol_size,tf_needs_dwarf_cfi,tf_library_needs_pic,tf_needs_symbol_type,
  182. tf_files_case_sensitive,
  183. tf_dwarf_only_local_labels,
  184. {tf_pic_uses_got,}tf_smartlink_sections,tf_has_winlike_resources,tf_supports_hidden_symbols];
  185. cpu : cpu_x86_64;
  186. unit_env : 'BSDUNITS';
  187. extradefines : 'UNIX;HASUNIX;BSD';
  188. exeext : '';
  189. defext : '.def';
  190. scriptext : '.sh';
  191. smartext : '.sl';
  192. unitext : '.ppu';
  193. unitlibext : '.ppl';
  194. asmext : '.s';
  195. objext : '.o';
  196. resext : '.res';
  197. resobjext : '.or';
  198. sharedlibext : '.so';
  199. staticlibext : '.a';
  200. staticlibprefix : 'libp';
  201. sharedlibprefix : 'lib';
  202. sharedClibext : '.so';
  203. staticClibext : '.a';
  204. staticClibprefix : 'lib';
  205. sharedClibprefix : 'lib';
  206. importlibprefix : 'libimp';
  207. importlibext : '.a';
  208. Cprefix : '';
  209. newline : #10;
  210. dirsep : '/';
  211. assem : as_x86_64_elf64;
  212. assemextern : as_gas;
  213. link : ld_none;
  214. linkextern : ld_bsd;
  215. ar : ar_gnu_ar;
  216. res : res_elf;
  217. dbg : dbg_dwarf2; //dbg_stabs;
  218. script : script_unix;
  219. endian : endian_little;
  220. alignment :
  221. (
  222. procalign : 8;
  223. loopalign : 4;
  224. jumpalign : 0;
  225. jumpalignskipmax : 0;
  226. coalescealign : 0;
  227. coalescealignskipmax: 0;
  228. constalignmin : 0;
  229. constalignmax : 16;
  230. varalignmin : 0;
  231. varalignmax : 16;
  232. localalignmin : 4;
  233. localalignmax : 16;
  234. recordalignmin : 0;
  235. recordalignmax : 16;
  236. maxCrecordalign : 16
  237. );
  238. first_parm_offset : 16;
  239. stacksize : 256*1024;
  240. stackalign : 16;
  241. abi : abi_default;
  242. llvmdatalayout : 'e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128';
  243. mos6502page0alloc : [];
  244. );
  245. system_x86_64_dragonfly_info : tsysteminfo =
  246. (
  247. system : system_x86_64_dragonfly;
  248. name : 'DragonFly for x86-64';
  249. shortname : 'DragonFly';
  250. flags : [tf_needs_symbol_size,tf_needs_dwarf_cfi,tf_library_needs_pic,tf_needs_symbol_type,
  251. tf_files_case_sensitive,
  252. tf_dwarf_only_local_labels,
  253. {tf_pic_uses_got,}tf_smartlink_sections,tf_has_winlike_resources,tf_supports_hidden_symbols];
  254. cpu : cpu_x86_64;
  255. unit_env : 'BSDUNITS';
  256. extradefines : 'UNIX;HASUNIX;BSD';
  257. exeext : '';
  258. defext : '.def';
  259. scriptext : '.sh';
  260. smartext : '.sl';
  261. unitext : '.ppu';
  262. unitlibext : '.ppl';
  263. asmext : '.s';
  264. objext : '.o';
  265. resext : '.res';
  266. resobjext : '.or';
  267. sharedlibext : '.so';
  268. staticlibext : '.a';
  269. staticlibprefix : 'libp';
  270. sharedlibprefix : 'lib';
  271. sharedClibext : '.so';
  272. staticClibext : '.a';
  273. staticClibprefix : 'lib';
  274. sharedClibprefix : 'lib';
  275. importlibprefix : 'libimp';
  276. importlibext : '.a';
  277. Cprefix : '';
  278. newline : #10;
  279. dirsep : '/';
  280. assem : as_x86_64_elf64;
  281. assemextern : as_gas;
  282. link : ld_none;
  283. linkextern : ld_bsd;
  284. ar : ar_gnu_ar;
  285. res : res_elf;
  286. dbg : dbg_dwarf2; //dbg_stabs;
  287. script : script_unix;
  288. endian : endian_little;
  289. alignment :
  290. (
  291. procalign : 8;
  292. loopalign : 4;
  293. jumpalign : 0;
  294. jumpalignskipmax : 0;
  295. coalescealign : 0;
  296. coalescealignskipmax: 0;
  297. constalignmin : 0;
  298. constalignmax : 16;
  299. varalignmin : 0;
  300. varalignmax : 16;
  301. localalignmin : 4;
  302. localalignmax : 16;
  303. recordalignmin : 0;
  304. recordalignmax : 16;
  305. maxCrecordalign : 16
  306. );
  307. first_parm_offset : 16;
  308. stacksize : 256*1024;
  309. stackalign : 16;
  310. abi : abi_default;
  311. llvmdatalayout : 'e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128';
  312. mos6502page0alloc : [];
  313. );
  314. system_i386_netbsd_info : tsysteminfo =
  315. (
  316. system : system_i386_NetBSD;
  317. name : 'NetBSD for i386';
  318. shortname : 'NetBSD';
  319. flags : [tf_pic_uses_got,tf_under_development,tf_files_case_sensitive,tf_smartlink_library,tf_has_winlike_resources,
  320. tf_supports_hidden_symbols];
  321. cpu : cpu_i386;
  322. unit_env : 'BSDUNITS';
  323. extradefines : 'UNIX;BSD;HASUNIX';
  324. exeext : '';
  325. defext : '.def';
  326. scriptext : '.sh';
  327. smartext : '.sl';
  328. unitext : '.ppu';
  329. unitlibext : '.ppl';
  330. asmext : '.s';
  331. objext : '.o';
  332. resext : '.res';
  333. resobjext : '.or';
  334. sharedlibext : '.so';
  335. staticlibext : '.a';
  336. staticlibprefix : 'libp';
  337. sharedlibprefix : 'lib';
  338. sharedClibext : '.so';
  339. staticClibext : '.a';
  340. staticClibprefix : 'lib';
  341. sharedClibprefix : 'lib';
  342. importlibprefix : 'libimp';
  343. importlibext : '.a';
  344. Cprefix : '';
  345. newline : #10;
  346. dirsep : '/';
  347. assem : as_i386_elf32;
  348. assemextern : as_gas;
  349. link : ld_none;
  350. linkextern : ld_bsd;
  351. ar : ar_gnu_ar;
  352. res : res_elf;
  353. dbg : dbg_stabs;
  354. script : script_unix;
  355. endian : endian_little;
  356. alignment :
  357. (
  358. procalign : 16;
  359. loopalign : 4;
  360. jumpalign : 0;
  361. jumpalignskipmax : 0;
  362. coalescealign : 0;
  363. coalescealignskipmax: 0;
  364. constalignmin : 0;
  365. constalignmax : 16;
  366. varalignmin : 0;
  367. varalignmax : 16;
  368. localalignmin : 4;
  369. localalignmax : 8;
  370. recordalignmin : 0;
  371. recordalignmax : 16;
  372. maxCrecordalign : 4
  373. );
  374. first_parm_offset : 8;
  375. stacksize : 262144;
  376. stackalign : 4;
  377. abi : abi_default;
  378. llvmdatalayout : 'e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64-f80:32:32-n8:16:32-S32';
  379. mos6502page0alloc : [];
  380. );
  381. system_i386_openbsd_info : tsysteminfo =
  382. (
  383. system : system_i386_OpenBSD;
  384. name : 'OpenBSD for i386';
  385. shortname : 'OpenBSD';
  386. flags : [tf_pic_default,tf_pic_uses_got,tf_under_development,tf_files_case_sensitive,tf_smartlink_sections,tf_has_winlike_resources,
  387. tf_supports_hidden_symbols];
  388. cpu : cpu_i386;
  389. unit_env : 'BSDUNITS';
  390. extradefines : 'UNIX;BSD;HASUNIX';
  391. exeext : '';
  392. defext : '.def';
  393. scriptext : '.sh';
  394. smartext : '.sl';
  395. unitext : '.ppu';
  396. unitlibext : '.ppl';
  397. asmext : '.s';
  398. objext : '.o';
  399. resext : '.res';
  400. resobjext : '.or';
  401. sharedlibext : '.so';
  402. staticlibext : '.a';
  403. staticlibprefix : 'libp';
  404. sharedlibprefix : 'lib';
  405. sharedClibext : '.so';
  406. staticClibext : '.a';
  407. staticClibprefix : 'lib';
  408. sharedClibprefix : 'lib';
  409. importlibprefix : 'libimp';
  410. importlibext : '.a';
  411. Cprefix : '';
  412. newline : #10;
  413. dirsep : '/';
  414. assem : as_gas;
  415. assemextern : as_gas;
  416. link : ld_none;
  417. linkextern : ld_bsd;
  418. ar : ar_gnu_ar;
  419. res : res_elf;
  420. dbg : dbg_stabs;
  421. script : script_unix;
  422. endian : endian_little;
  423. alignment :
  424. (
  425. procalign : 16;
  426. loopalign : 4;
  427. jumpalign : 0;
  428. jumpalignskipmax : 0;
  429. coalescealign : 0;
  430. coalescealignskipmax: 0;
  431. constalignmin : 0;
  432. constalignmax : 16;
  433. varalignmin : 0;
  434. varalignmax : 16;
  435. localalignmin : 4;
  436. localalignmax : 8;
  437. recordalignmin : 0;
  438. recordalignmax : 16;
  439. maxCrecordalign : 4
  440. );
  441. first_parm_offset : 8;
  442. stacksize : 262144;
  443. stackalign : 4;
  444. abi : abi_default;
  445. { note: default LLVM stack alignment is 16 bytes for this target }
  446. llvmdatalayout : 'e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64-f80:32:32-n8:16:32-S32';
  447. mos6502page0alloc : [];
  448. );
  449. system_x86_64_openbsd_info : tsysteminfo =
  450. (
  451. system : system_x86_64_openbsd;
  452. name : 'OpenBSD for x86-64';
  453. shortname : 'OpenBSD';
  454. flags : [tf_needs_symbol_size,tf_needs_dwarf_cfi,tf_library_needs_pic,tf_needs_symbol_type,
  455. tf_files_case_sensitive, tf_under_development,
  456. tf_dwarf_only_local_labels, tf_pic_default,
  457. {$ifdef llvm}
  458. tf_use_psabieh,
  459. {$endif llvm}
  460. { tf_pic_uses_got,}tf_smartlink_sections,tf_has_winlike_resources,tf_supports_hidden_symbols];
  461. cpu : cpu_x86_64;
  462. unit_env : 'BSDUNITS';
  463. extradefines : 'UNIX;HASUNIX;BSD';
  464. exeext : '';
  465. defext : '.def';
  466. scriptext : '.sh';
  467. smartext : '.sl';
  468. unitext : '.ppu';
  469. unitlibext : '.ppl';
  470. asmext : '.s';
  471. objext : '.o';
  472. resext : '.res';
  473. resobjext : '.or';
  474. sharedlibext : '.so';
  475. staticlibext : '.a';
  476. staticlibprefix : 'libp';
  477. sharedlibprefix : 'lib';
  478. sharedClibext : '.so';
  479. staticClibext : '.a';
  480. staticClibprefix : 'lib';
  481. sharedClibprefix : 'lib';
  482. importlibprefix : 'libimp';
  483. importlibext : '.a';
  484. Cprefix : '';
  485. newline : #10;
  486. dirsep : '/';
  487. assem : as_x86_64_elf64;
  488. assemextern : as_gas;
  489. link : ld_none;
  490. linkextern : ld_bsd;
  491. ar : ar_gnu_ar;
  492. res : res_elf;
  493. dbg : dbg_dwarf2; //dbg_stabs;
  494. script : script_unix;
  495. endian : endian_little;
  496. alignment :
  497. (
  498. procalign : 8;
  499. loopalign : 4;
  500. jumpalign : 0;
  501. jumpalignskipmax : 0;
  502. coalescealign : 0;
  503. coalescealignskipmax: 0;
  504. constalignmin : 0;
  505. constalignmax : 16;
  506. varalignmin : 0;
  507. varalignmax : 16;
  508. localalignmin : 4;
  509. localalignmax : 16;
  510. recordalignmin : 0;
  511. recordalignmax : 16;
  512. maxCrecordalign : 16
  513. );
  514. first_parm_offset : 16;
  515. stacksize : 256*1024;
  516. stackalign : 16;
  517. abi : abi_default;
  518. llvmdatalayout : 'e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128';
  519. mos6502page0alloc : [];
  520. );
  521. system_m68k_netbsd_info : tsysteminfo =
  522. (
  523. system : system_m68k_NetBSD;
  524. name : 'NetBSD for m68k';
  525. shortname : 'NetBSD';
  526. flags : [tf_under_development,tf_needs_symbol_size,tf_needs_symbol_type,tf_requires_proper_alignment,
  527. tf_files_case_sensitive,tf_smartlink_sections,tf_has_winlike_resources,tf_supports_hidden_symbols];
  528. cpu : cpu_m68k;
  529. unit_env : 'BSDUNITS';
  530. extradefines : 'UNIX;BSD;HASUNIX';
  531. exeext : '';
  532. defext : '.def';
  533. scriptext : '.sh';
  534. smartext : '.sl';
  535. unitext : '.ppu';
  536. unitlibext : '.ppl';
  537. asmext : '.s';
  538. objext : '.o';
  539. resext : '.res';
  540. resobjext : '.or';
  541. sharedlibext : '.so';
  542. staticlibext : '.a';
  543. staticlibprefix : 'libp';
  544. sharedlibprefix : 'lib';
  545. sharedClibext : '.so';
  546. staticClibext : '.a';
  547. staticClibprefix : 'lib';
  548. sharedClibprefix : 'lib';
  549. importlibprefix : 'libimp';
  550. importlibext : '.a';
  551. Cprefix : '';
  552. newline : #10;
  553. dirsep : '/';
  554. assem : as_gas;
  555. assemextern : as_gas;
  556. link : ld_none;
  557. linkextern : ld_bsd;
  558. ar : ar_gnu_ar;
  559. res : res_elf;
  560. dbg : dbg_stabs;
  561. script : script_unix;
  562. endian : endian_big;
  563. alignment :
  564. (
  565. procalign : 4;
  566. loopalign : 4;
  567. jumpalign : 0;
  568. jumpalignskipmax : 0;
  569. coalescealign : 0;
  570. coalescealignskipmax: 0;
  571. constalignmin : 0;
  572. constalignmax : 1;
  573. varalignmin : 0;
  574. varalignmax : 1;
  575. localalignmin : 0;
  576. localalignmax : 1;
  577. recordalignmin : 0;
  578. recordalignmax : 4;
  579. maxCrecordalign : 8
  580. );
  581. first_parm_offset : 8;
  582. stacksize : 262144;
  583. stackalign : 4;
  584. abi : abi_default;
  585. llvmdatalayout : 'todo';
  586. mos6502page0alloc : [];
  587. );
  588. system_powerpc_netbsd_info : tsysteminfo =
  589. (
  590. system : system_powerpc_netbsd;
  591. name : 'NetBSD for PowerPC';
  592. shortname : 'NetBSD';
  593. flags : [tf_under_development,tf_files_case_sensitive,tf_smartlink_library,tf_has_winlike_resources,tf_supports_hidden_symbols];
  594. cpu : cpu_powerpc;
  595. unit_env : '';
  596. extradefines : 'UNIX;BSD;HASUNIX';
  597. exeext : '';
  598. defext : '.def';
  599. scriptext : '.sh';
  600. smartext : '.sl';
  601. unitext : '.ppu';
  602. unitlibext : '.ppl';
  603. asmext : '.s';
  604. objext : '.o';
  605. resext : '.res';
  606. resobjext : '.or';
  607. sharedlibext : '.so';
  608. staticlibext : '.s';
  609. staticlibprefix : 'libp';
  610. sharedlibprefix : 'lib';
  611. sharedClibext : '.so';
  612. staticClibext : '.a';
  613. staticClibprefix : 'lib';
  614. sharedClibprefix : 'lib';
  615. importlibprefix : 'libimp';
  616. importlibext : '.a';
  617. Cprefix : '';
  618. newline : #10;
  619. dirsep : '/';
  620. assem : as_gas;
  621. assemextern : as_gas;
  622. link : ld_none;
  623. linkextern : ld_bsd;
  624. ar : ar_gnu_ar;
  625. res : res_elf;
  626. dbg : dbg_stabs;
  627. script : script_unix;
  628. endian : endian_big;
  629. alignment :
  630. (
  631. procalign : 4;
  632. loopalign : 4;
  633. jumpalign : 0;
  634. jumpalignskipmax : 0;
  635. coalescealign : 0;
  636. coalescealignskipmax: 0;
  637. constalignmin : 0;
  638. constalignmax : 4;
  639. varalignmin : 0;
  640. varalignmax : 4;
  641. localalignmin : 0;
  642. localalignmax : 4;
  643. recordalignmin : 0;
  644. recordalignmax : 2;
  645. maxCrecordalign : 4 // should be 8 probably
  646. );
  647. first_parm_offset : 8;
  648. stacksize : 32*1024*1024;
  649. stackalign : 16;
  650. { abi_powerpc_sysv doesn't work yet }
  651. abi : abi_powerpc_aix;
  652. llvmdatalayout : 'E-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v128:128:128-n32';
  653. mos6502page0alloc : [];
  654. );
  655. system_x86_64_netbsd_info : tsysteminfo =
  656. (
  657. system : system_x86_64_netbsd;
  658. name : 'NetBSD for x86-64';
  659. shortname : 'NetBSD';
  660. flags : [tf_needs_symbol_size,tf_needs_dwarf_cfi,tf_library_needs_pic,tf_needs_symbol_type,
  661. tf_files_case_sensitive, tf_under_development,
  662. tf_dwarf_only_local_labels,
  663. { tf_pic_uses_got,}tf_smartlink_sections,tf_has_winlike_resources,tf_supports_hidden_symbols];
  664. cpu : cpu_x86_64;
  665. unit_env : 'BSDUNITS';
  666. extradefines : 'UNIX;HASUNIX;BSD';
  667. exeext : '';
  668. defext : '.def';
  669. scriptext : '.sh';
  670. smartext : '.sl';
  671. unitext : '.ppu';
  672. unitlibext : '.ppl';
  673. asmext : '.s';
  674. objext : '.o';
  675. resext : '.res';
  676. resobjext : '.or';
  677. sharedlibext : '.so';
  678. staticlibext : '.a';
  679. staticlibprefix : 'libp';
  680. sharedlibprefix : 'lib';
  681. sharedClibext : '.so';
  682. staticClibext : '.a';
  683. staticClibprefix : 'lib';
  684. sharedClibprefix : 'lib';
  685. importlibprefix : 'libimp';
  686. importlibext : '.a';
  687. Cprefix : '';
  688. newline : #10;
  689. dirsep : '/';
  690. assem : as_x86_64_elf64;
  691. assemextern : as_gas;
  692. link : ld_none;
  693. linkextern : ld_bsd;
  694. ar : ar_gnu_ar;
  695. res : res_elf;
  696. dbg : dbg_dwarf2; //dbg_stabs;
  697. script : script_unix;
  698. endian : endian_little;
  699. alignment :
  700. (
  701. procalign : 8;
  702. loopalign : 4;
  703. jumpalign : 0;
  704. jumpalignskipmax : 0;
  705. coalescealign : 0;
  706. coalescealignskipmax: 0;
  707. constalignmin : 0;
  708. constalignmax : 16;
  709. varalignmin : 0;
  710. varalignmax : 16;
  711. localalignmin : 4;
  712. localalignmax : 16;
  713. recordalignmin : 0;
  714. recordalignmax : 16;
  715. maxCrecordalign : 16
  716. );
  717. first_parm_offset : 16;
  718. stacksize : 256*1024;
  719. stackalign : 16;
  720. abi : abi_default;
  721. llvmdatalayout : 'e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128';
  722. mos6502page0alloc : [];
  723. );
  724. system_arm_netbsd_info : tsysteminfo =
  725. (
  726. system : system_arm_netbsd;
  727. name : 'NetBSD for ARMHF';
  728. shortname : 'NetBSD';
  729. flags : [tf_under_development,tf_requires_proper_alignment,tf_files_case_sensitive,tf_smartlink_sections,tf_has_winlike_resources,
  730. tf_supports_hidden_symbols];
  731. cpu : cpu_arm;
  732. unit_env : '';
  733. extradefines : 'UNIX;BSD;HASUNIX';
  734. exeext : '';
  735. defext : '.def';
  736. scriptext : '.sh';
  737. smartext : '.sl';
  738. unitext : '.ppu';
  739. unitlibext : '.ppl';
  740. asmext : '.s';
  741. objext : '.o';
  742. resext : '.res';
  743. resobjext : '.or';
  744. sharedlibext : '.so';
  745. staticlibext : '.s';
  746. staticlibprefix : 'libp';
  747. sharedlibprefix : 'lib';
  748. sharedClibext : '.so';
  749. staticClibext : '.a';
  750. staticClibprefix : 'lib';
  751. sharedClibprefix : 'lib';
  752. importlibprefix : 'libimp';
  753. importlibext : '.a';
  754. Cprefix : '';
  755. newline : #10;
  756. dirsep : '/';
  757. assem : as_gas; {as_arm_elf32;}
  758. assemextern : as_gas;
  759. link : ld_none;
  760. linkextern : ld_bsd;
  761. ar : ar_gnu_ar;
  762. res : res_elf;
  763. dbg : dbg_dwarf2;
  764. script : script_unix;
  765. endian : endian_big;
  766. alignment :
  767. (
  768. procalign : 4;
  769. loopalign : 4;
  770. jumpalign : 0;
  771. jumpalignskipmax : 0;
  772. coalescealign : 0;
  773. coalescealignskipmax: 0;
  774. constalignmin : 0;
  775. constalignmax : 4;
  776. varalignmin : 0;
  777. varalignmax : 4;
  778. localalignmin : 0;
  779. localalignmax : 4;
  780. recordalignmin : 0;
  781. recordalignmax : 2;
  782. maxCrecordalign : 4 // should be 8 probably
  783. );
  784. first_parm_offset : 8;
  785. stacksize : 32*1024*1024;
  786. stackalign : 16;
  787. abi : abi_eabihf;
  788. llvmdatalayout : 'todo';
  789. mos6502page0alloc : [];
  790. );
  791. implementation
  792. initialization
  793. {$ifdef cpuaarch64}
  794. {$ifdef FreeBSD}
  795. set_source_info(system_aarch64_freebsd_info);
  796. {$endif FreeBSD}
  797. {$endif cpuaarch64}
  798. {$ifdef cpui386}
  799. {$ifdef FreeBSD}
  800. set_source_info(system_i386_FreeBSD_info);
  801. {$endif}
  802. {$ifdef NetBSD}
  803. set_source_info(system_i386_NetBSD_info);
  804. {$endif}
  805. {$ifdef OpenBSD}
  806. set_source_info(system_i386_OpenBSD_info);
  807. {$endif}
  808. {$endif cpui386}
  809. {$ifdef cpux86_64}
  810. {$ifdef FreeBSD}
  811. set_source_info(system_x86_64_FreeBSD_info);
  812. {$endif}
  813. {$ifdef DragonFly}
  814. set_source_info(system_x86_64_DragonFly_info);
  815. {$endif}
  816. {$ifdef OpenBSD}
  817. set_source_info(system_x86_64_OpenBSD_info);
  818. {$endif}
  819. {$ifdef NetBSD}
  820. set_source_info(system_x86_64_NetBSD_info);
  821. {$endif}
  822. {$endif}
  823. {$ifdef cpu68}
  824. {$ifdef NetBSD}
  825. set_source_info(system_m68k_NetBSD_info);
  826. {$endif NetBSD}
  827. {$endif cpu68}
  828. {$ifdef cpupowerpc32}
  829. {$ifdef NetBSD}
  830. set_source_info(system_powerpc_netbsd_info);
  831. {$endif}
  832. {$endif cpupowerpc32}
  833. {$ifdef cpuarm}
  834. {$ifdef NetBSD}
  835. set_source_info(system_arm_netbsd_info);
  836. {$endif}
  837. {$endif cpuarm}
  838. end.