i_bsd.pas 28 KB

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