i_bsd.pas 38 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074
  1. {
  2. Copyright (c) 1998-2008 by Peter Vreman
  3. This unit implements support information structures for FreeBSD/NetBSD,
  4. OpenBSD and Darwin (Mac OS X)
  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, rescmn;
  26. const
  27. res_macho_info : tresinfo =
  28. (
  29. id : res_macho;
  30. resbin : 'fpcres';
  31. rescmd : '-o $OBJ -a $ARCH -s $SUBARCH -of mach-o $DBG';
  32. rcbin : 'windres';
  33. rccmd : '--include $INC -O res -D FPC -o $RES $RC';
  34. resourcefileclass : nil;
  35. resflags : [];
  36. );
  37. res_macosx_ext_info : tresinfo =
  38. (
  39. id : res_ext;
  40. resbin : 'fpcres';
  41. rescmd : '-o $OBJ -a $ENDIAN -of external $DBG';
  42. rcbin : 'windres';
  43. rccmd : '--include $INC -O res -D FPC -o $RES $RC';
  44. resourcefileclass : nil;
  45. resflags : [res_external_file,res_arch_in_file_name];
  46. );
  47. system_i386_freebsd_info : tsysteminfo =
  48. (
  49. system : system_i386_FreeBSD;
  50. name : 'FreeBSD/ELF for i386';
  51. shortname : 'FreeBSD';
  52. flags : [tf_pic_uses_got,tf_files_case_sensitive,
  53. {$ifdef segment_threadvars}
  54. tf_section_threadvars,
  55. {$endif segment_threadvars}
  56. tf_needs_symbol_type,tf_needs_symbol_size,tf_smartlink_library
  57. ,tf_smartlink_sections,tf_has_winlike_resources];
  58. cpu : cpu_i386;
  59. unit_env : 'BSDUNITS';
  60. extradefines : 'UNIX;BSD;HASUNIX';
  61. exeext : '';
  62. defext : '.def';
  63. scriptext : '.sh';
  64. smartext : '.sl';
  65. unitext : '.ppu';
  66. unitlibext : '.ppl';
  67. asmext : '.s';
  68. objext : '.o';
  69. resext : '.res';
  70. resobjext : '.or';
  71. sharedlibext : '.so';
  72. staticlibext : '.a';
  73. staticlibprefix : 'libp';
  74. sharedlibprefix : 'lib';
  75. sharedClibext : '.so';
  76. staticClibext : '.a';
  77. staticClibprefix : 'lib';
  78. sharedClibprefix : 'lib';
  79. importlibprefix : 'libimp';
  80. importlibext : '.a';
  81. Cprefix : '';
  82. newline : #10;
  83. dirsep : '/';
  84. assem : as_i386_elf32;
  85. assemextern : as_gas;
  86. link : ld_none;
  87. linkextern : ld_bsd;
  88. ar : ar_gnu_ar;
  89. res : res_elf;
  90. dbg : dbg_stabs;
  91. script : script_unix;
  92. endian : endian_little;
  93. alignment :
  94. (
  95. procalign : 4;
  96. loopalign : 4;
  97. jumpalign : 0;
  98. constalignmin : 0;
  99. constalignmax : 4;
  100. varalignmin : 0;
  101. varalignmax : 4;
  102. localalignmin : 0;
  103. localalignmax : 4;
  104. recordalignmin : 0;
  105. recordalignmax : 2;
  106. maxCrecordalign : 4
  107. );
  108. first_parm_offset : 8;
  109. stacksize : 262144;
  110. stackalign : 4;
  111. abi : abi_default;
  112. );
  113. system_x86_64_freebsd_info : tsysteminfo =
  114. (
  115. system : system_x86_64_freebsd;
  116. name : 'FreeBSD for x86-64';
  117. shortname : 'FreeBSD';
  118. flags : [tf_needs_symbol_size,tf_needs_dwarf_cfi,tf_library_needs_pic,tf_needs_symbol_type,
  119. tf_files_case_sensitive,tf_smartlink_library,
  120. tf_dwarf_only_local_labels,
  121. {tf_pic_uses_got,}tf_smartlink_sections,tf_has_winlike_resources];
  122. cpu : cpu_x86_64;
  123. unit_env : 'BSDUNITS';
  124. extradefines : 'UNIX;HASUNIX;BSD';
  125. exeext : '';
  126. defext : '.def';
  127. scriptext : '.sh';
  128. smartext : '.sl';
  129. unitext : '.ppu';
  130. unitlibext : '.ppl';
  131. asmext : '.s';
  132. objext : '.o';
  133. resext : '.res';
  134. resobjext : '.or';
  135. sharedlibext : '.so';
  136. staticlibext : '.a';
  137. staticlibprefix : 'libp';
  138. sharedlibprefix : 'lib';
  139. sharedClibext : '.so';
  140. staticClibext : '.a';
  141. staticClibprefix : 'lib';
  142. sharedClibprefix : 'lib';
  143. importlibprefix : 'libimp';
  144. importlibext : '.a';
  145. Cprefix : '';
  146. newline : #10;
  147. dirsep : '/';
  148. assem : as_x86_64_elf64;
  149. assemextern : as_gas;
  150. link : ld_none;
  151. linkextern : ld_bsd;
  152. ar : ar_gnu_ar;
  153. res : res_elf;
  154. dbg : dbg_dwarf2; //dbg_stabs;
  155. script : script_unix;
  156. endian : endian_little;
  157. alignment :
  158. (
  159. procalign : 8;
  160. loopalign : 4;
  161. jumpalign : 0;
  162. constalignmin : 0;
  163. constalignmax : 8;
  164. varalignmin : 0;
  165. varalignmax : 16;
  166. localalignmin : 4;
  167. localalignmax : 16;
  168. recordalignmin : 0;
  169. recordalignmax : 16;
  170. maxCrecordalign : 16
  171. );
  172. first_parm_offset : 16;
  173. stacksize : 256*1024;
  174. stackalign : 16;
  175. abi : abi_default;
  176. );
  177. system_x86_64_dragonfly_info : tsysteminfo =
  178. (
  179. system : system_x86_64_dragonfly;
  180. name : 'DragonFly for x86-64';
  181. shortname : 'DragonFly';
  182. flags : [tf_needs_symbol_size,tf_needs_dwarf_cfi,tf_library_needs_pic,tf_needs_symbol_type,
  183. tf_files_case_sensitive,tf_smartlink_library,
  184. tf_dwarf_only_local_labels,
  185. {tf_pic_uses_got,}tf_smartlink_sections,tf_has_winlike_resources];
  186. cpu : cpu_x86_64;
  187. unit_env : 'BSDUNITS';
  188. extradefines : 'UNIX;HASUNIX;BSD';
  189. exeext : '';
  190. defext : '.def';
  191. scriptext : '.sh';
  192. smartext : '.sl';
  193. unitext : '.ppu';
  194. unitlibext : '.ppl';
  195. asmext : '.s';
  196. objext : '.o';
  197. resext : '.res';
  198. resobjext : '.or';
  199. sharedlibext : '.so';
  200. staticlibext : '.a';
  201. staticlibprefix : 'libp';
  202. sharedlibprefix : 'lib';
  203. sharedClibext : '.so';
  204. staticClibext : '.a';
  205. staticClibprefix : 'lib';
  206. sharedClibprefix : 'lib';
  207. importlibprefix : 'libimp';
  208. importlibext : '.a';
  209. Cprefix : '';
  210. newline : #10;
  211. dirsep : '/';
  212. assem : as_x86_64_elf64;
  213. assemextern : as_gas;
  214. link : ld_none;
  215. linkextern : ld_bsd;
  216. ar : ar_gnu_ar;
  217. res : res_elf;
  218. dbg : dbg_dwarf2; //dbg_stabs;
  219. script : script_unix;
  220. endian : endian_little;
  221. alignment :
  222. (
  223. procalign : 8;
  224. loopalign : 4;
  225. jumpalign : 0;
  226. constalignmin : 0;
  227. constalignmax : 8;
  228. varalignmin : 0;
  229. varalignmax : 16;
  230. localalignmin : 4;
  231. localalignmax : 16;
  232. recordalignmin : 0;
  233. recordalignmax : 16;
  234. maxCrecordalign : 16
  235. );
  236. first_parm_offset : 16;
  237. stacksize : 256*1024;
  238. stackalign : 16;
  239. abi : abi_default;
  240. );
  241. system_i386_netbsd_info : tsysteminfo =
  242. (
  243. system : system_i386_NetBSD;
  244. name : 'NetBSD for i386';
  245. shortname : 'NetBSD';
  246. flags : [tf_pic_uses_got,tf_under_development,tf_files_case_sensitive,tf_smartlink_library,tf_has_winlike_resources];
  247. cpu : cpu_i386;
  248. unit_env : 'BSDUNITS';
  249. extradefines : 'UNIX;BSD;HASUNIX';
  250. exeext : '';
  251. defext : '.def';
  252. scriptext : '.sh';
  253. smartext : '.sl';
  254. unitext : '.ppu';
  255. unitlibext : '.ppl';
  256. asmext : '.s';
  257. objext : '.o';
  258. resext : '.res';
  259. resobjext : '.or';
  260. sharedlibext : '.so';
  261. staticlibext : '.a';
  262. staticlibprefix : 'libp';
  263. sharedlibprefix : 'lib';
  264. sharedClibext : '.so';
  265. staticClibext : '.a';
  266. staticClibprefix : 'lib';
  267. sharedClibprefix : 'lib';
  268. importlibprefix : 'libimp';
  269. importlibext : '.a';
  270. Cprefix : '';
  271. newline : #10;
  272. dirsep : '/';
  273. assem : as_i386_elf32;
  274. assemextern : as_gas;
  275. link : ld_none;
  276. linkextern : ld_bsd;
  277. ar : ar_gnu_ar;
  278. res : res_elf;
  279. dbg : dbg_stabs;
  280. script : script_unix;
  281. endian : endian_little;
  282. alignment :
  283. (
  284. procalign : 16;
  285. loopalign : 4;
  286. jumpalign : 0;
  287. constalignmin : 0;
  288. constalignmax : 8;
  289. varalignmin : 0;
  290. varalignmax : 16;
  291. localalignmin : 4;
  292. localalignmax : 8;
  293. recordalignmin : 0;
  294. recordalignmax : 16;
  295. maxCrecordalign : 4
  296. );
  297. first_parm_offset : 8;
  298. stacksize : 262144;
  299. stackalign : 4;
  300. abi : abi_default;
  301. );
  302. system_i386_openbsd_info : tsysteminfo =
  303. (
  304. system : system_i386_OpenBSD;
  305. name : 'OpenBSD for i386';
  306. shortname : 'OpenBSD';
  307. flags : [tf_pic_uses_got,tf_under_development,tf_files_case_sensitive,tf_smartlink_library,tf_smartlink_sections,tf_has_winlike_resources];
  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. constalignmin : 0;
  349. constalignmax : 8;
  350. varalignmin : 0;
  351. varalignmax : 16;
  352. localalignmin : 4;
  353. localalignmax : 8;
  354. recordalignmin : 0;
  355. recordalignmax : 16;
  356. maxCrecordalign : 4
  357. );
  358. first_parm_offset : 8;
  359. stacksize : 262144;
  360. stackalign : 4;
  361. abi : abi_default;
  362. );
  363. system_x86_64_openbsd_info : tsysteminfo =
  364. (
  365. system : system_x86_64_openbsd;
  366. name : 'OpenBSD for x86-64';
  367. shortname : 'OpenBSD';
  368. flags : [tf_needs_symbol_size,tf_needs_dwarf_cfi,tf_library_needs_pic,tf_needs_symbol_type,
  369. tf_files_case_sensitive,tf_smartlink_library, tf_under_development,
  370. tf_dwarf_only_local_labels, tf_pic_default,
  371. { tf_pic_uses_got,}tf_smartlink_sections,tf_has_winlike_resources];
  372. cpu : cpu_x86_64;
  373. unit_env : 'BSDUNITS';
  374. extradefines : 'UNIX;HASUNIX;BSD';
  375. exeext : '';
  376. defext : '.def';
  377. scriptext : '.sh';
  378. smartext : '.sl';
  379. unitext : '.ppu';
  380. unitlibext : '.ppl';
  381. asmext : '.s';
  382. objext : '.o';
  383. resext : '.res';
  384. resobjext : '.or';
  385. sharedlibext : '.so';
  386. staticlibext : '.a';
  387. staticlibprefix : 'libp';
  388. sharedlibprefix : 'lib';
  389. sharedClibext : '.so';
  390. staticClibext : '.a';
  391. staticClibprefix : 'lib';
  392. sharedClibprefix : 'lib';
  393. importlibprefix : 'libimp';
  394. importlibext : '.a';
  395. Cprefix : '';
  396. newline : #10;
  397. dirsep : '/';
  398. assem : as_x86_64_elf64;
  399. assemextern : as_gas;
  400. link : ld_none;
  401. linkextern : ld_bsd;
  402. ar : ar_gnu_ar;
  403. res : res_elf;
  404. dbg : dbg_dwarf2; //dbg_stabs;
  405. script : script_unix;
  406. endian : endian_little;
  407. alignment :
  408. (
  409. procalign : 8;
  410. loopalign : 4;
  411. jumpalign : 0;
  412. constalignmin : 0;
  413. constalignmax : 8;
  414. varalignmin : 0;
  415. varalignmax : 16;
  416. localalignmin : 4;
  417. localalignmax : 16;
  418. recordalignmin : 0;
  419. recordalignmax : 16;
  420. maxCrecordalign : 16
  421. );
  422. first_parm_offset : 16;
  423. stacksize : 256*1024;
  424. stackalign : 16;
  425. abi : abi_default;
  426. );
  427. system_m68k_netbsd_info : tsysteminfo =
  428. (
  429. system : system_m68k_NetBSD;
  430. name : 'NetBSD for m68k';
  431. shortname : 'NetBSD';
  432. flags : [tf_under_development,tf_files_case_sensitive,tf_smartlink_library,tf_has_winlike_resources];
  433. cpu : cpu_m68k;
  434. unit_env : 'BSDUNITS';
  435. extradefines : 'UNIX;BSD;HASUNIX';
  436. exeext : '';
  437. defext : '.def';
  438. scriptext : '.sh';
  439. smartext : '.sl';
  440. unitext : '.ppu';
  441. unitlibext : '.ppl';
  442. asmext : '.s';
  443. objext : '.o';
  444. resext : '.res';
  445. resobjext : '.or';
  446. sharedlibext : '.so';
  447. staticlibext : '.a';
  448. staticlibprefix : 'libp';
  449. sharedlibprefix : 'lib';
  450. sharedClibext : '.so';
  451. staticClibext : '.a';
  452. staticClibprefix : 'lib';
  453. sharedClibprefix : 'lib';
  454. importlibprefix : 'libimp';
  455. importlibext : '.a';
  456. Cprefix : '';
  457. newline : #10;
  458. dirsep : '/';
  459. assem : as_gas;
  460. assemextern : as_gas;
  461. link : ld_none;
  462. linkextern : ld_bsd;
  463. ar : ar_gnu_ar;
  464. res : res_elf;
  465. dbg : dbg_stabs;
  466. script : script_unix;
  467. endian : endian_big;
  468. alignment :
  469. (
  470. procalign : 4;
  471. loopalign : 4;
  472. jumpalign : 0;
  473. constalignmin : 0;
  474. constalignmax : 1;
  475. varalignmin : 0;
  476. varalignmax : 1;
  477. localalignmin : 0;
  478. localalignmax : 1;
  479. recordalignmin : 0;
  480. recordalignmax : 2;
  481. maxCrecordalign : 4
  482. );
  483. first_parm_offset : 8;
  484. stacksize : 262144;
  485. stackalign : 4;
  486. abi : abi_default;
  487. );
  488. system_powerpc_netbsd_info : tsysteminfo =
  489. (
  490. system : system_powerpc_netbsd;
  491. name : 'NetBSD for PowerPC';
  492. shortname : 'NetBSD';
  493. flags : [tf_under_development,tf_files_case_sensitive,tf_smartlink_library,tf_has_winlike_resources];
  494. cpu : cpu_powerpc;
  495. unit_env : '';
  496. extradefines : 'UNIX;BSD;HASUNIX';
  497. exeext : '';
  498. defext : '.def';
  499. scriptext : '.sh';
  500. smartext : '.sl';
  501. unitext : '.ppu';
  502. unitlibext : '.ppl';
  503. asmext : '.s';
  504. objext : '.o';
  505. resext : '.res';
  506. resobjext : '.or';
  507. sharedlibext : '.so';
  508. staticlibext : '.s';
  509. staticlibprefix : 'libp';
  510. sharedlibprefix : 'lib';
  511. sharedClibext : '.so';
  512. staticClibext : '.a';
  513. staticClibprefix : 'lib';
  514. sharedClibprefix : 'lib';
  515. importlibprefix : 'libimp';
  516. importlibext : '.a';
  517. Cprefix : '';
  518. newline : #10;
  519. dirsep : '/';
  520. assem : as_gas;
  521. assemextern : as_gas;
  522. link : ld_none;
  523. linkextern : ld_bsd;
  524. ar : ar_gnu_ar;
  525. res : res_elf;
  526. dbg : dbg_stabs;
  527. script : script_unix;
  528. endian : endian_big;
  529. alignment :
  530. (
  531. procalign : 4;
  532. loopalign : 4;
  533. jumpalign : 0;
  534. constalignmin : 0;
  535. constalignmax : 4;
  536. varalignmin : 0;
  537. varalignmax : 4;
  538. localalignmin : 0;
  539. localalignmax : 4;
  540. recordalignmin : 0;
  541. recordalignmax : 2;
  542. maxCrecordalign : 4 // should be 8 probably
  543. );
  544. first_parm_offset : 8;
  545. stacksize : 32*1024*1024;
  546. stackalign : 16;
  547. { abi_powerpc_sysv doesn't work yet }
  548. abi : abi_powerpc_aix;
  549. );
  550. system_x86_64_netbsd_info : tsysteminfo =
  551. (
  552. system : system_x86_64_netbsd;
  553. name : 'NetBSD for x86-64';
  554. shortname : 'NetBSD';
  555. flags : [tf_needs_symbol_size,tf_needs_dwarf_cfi,tf_library_needs_pic,tf_needs_symbol_type,
  556. tf_files_case_sensitive,tf_smartlink_library, tf_under_development,
  557. tf_dwarf_only_local_labels,
  558. { tf_pic_uses_got,}tf_smartlink_sections,tf_has_winlike_resources];
  559. cpu : cpu_x86_64;
  560. unit_env : 'BSDUNITS';
  561. extradefines : 'UNIX;HASUNIX;BSD';
  562. exeext : '';
  563. defext : '.def';
  564. scriptext : '.sh';
  565. smartext : '.sl';
  566. unitext : '.ppu';
  567. unitlibext : '.ppl';
  568. asmext : '.s';
  569. objext : '.o';
  570. resext : '.res';
  571. resobjext : '.or';
  572. sharedlibext : '.so';
  573. staticlibext : '.a';
  574. staticlibprefix : 'libp';
  575. sharedlibprefix : 'lib';
  576. sharedClibext : '.so';
  577. staticClibext : '.a';
  578. staticClibprefix : 'lib';
  579. sharedClibprefix : 'lib';
  580. importlibprefix : 'libimp';
  581. importlibext : '.a';
  582. Cprefix : '';
  583. newline : #10;
  584. dirsep : '/';
  585. assem : as_x86_64_elf64;
  586. assemextern : as_gas;
  587. link : ld_none;
  588. linkextern : ld_bsd;
  589. ar : ar_gnu_ar;
  590. res : res_elf;
  591. dbg : dbg_dwarf2; //dbg_stabs;
  592. script : script_unix;
  593. endian : endian_little;
  594. alignment :
  595. (
  596. procalign : 8;
  597. loopalign : 4;
  598. jumpalign : 0;
  599. constalignmin : 0;
  600. constalignmax : 8;
  601. varalignmin : 0;
  602. varalignmax : 16;
  603. localalignmin : 4;
  604. localalignmax : 16;
  605. recordalignmin : 0;
  606. recordalignmax : 16;
  607. maxCrecordalign : 16
  608. );
  609. first_parm_offset : 16;
  610. stacksize : 256*1024;
  611. stackalign : 16;
  612. abi : abi_default;
  613. );
  614. system_powerpc_darwin_info : tsysteminfo =
  615. (
  616. system : system_powerpc_darwin;
  617. name : 'Darwin for PowerPC';
  618. shortname : 'Darwin';
  619. flags : [tf_p_ext_support,tf_files_case_sensitive,tf_smartlink_sections,tf_dwarf_relative_addresses,tf_dwarf_only_local_labels,tf_pic_default,tf_has_winlike_resources];
  620. cpu : cpu_powerpc;
  621. unit_env : 'BSDUNITS';
  622. extradefines : 'UNIX;BSD;HASUNIX';
  623. exeext : '';
  624. defext : '.def';
  625. scriptext : '.sh';
  626. smartext : '.sl';
  627. unitext : '.ppu';
  628. unitlibext : '.ppl';
  629. asmext : '.s';
  630. objext : '.o';
  631. resext : '.res';
  632. resobjext : '.or';
  633. sharedlibext : '.dylib';
  634. staticlibext : '.a';
  635. staticlibprefix : 'libp';
  636. sharedlibprefix : 'lib';
  637. sharedClibext : '.dylib';
  638. staticClibext : '.a';
  639. staticClibprefix : 'lib';
  640. sharedClibprefix : 'lib';
  641. importlibprefix : 'libimp';
  642. importlibext : '.a';
  643. Cprefix : '_';
  644. newline : #10;
  645. dirsep : '/';
  646. assem : as_darwin;
  647. assemextern : as_darwin;
  648. link : ld_none;
  649. linkextern : ld_bsd;
  650. ar : ar_gnu_ar;
  651. res : res_macho;
  652. dbg : dbg_stabs;
  653. script : script_unix;
  654. endian : endian_big;
  655. alignment :
  656. (
  657. procalign : 16;
  658. loopalign : 4;
  659. jumpalign : 0;
  660. constalignmin : 0;
  661. constalignmax : 4;
  662. varalignmin : 0;
  663. varalignmax : 4;
  664. localalignmin : 0;
  665. localalignmax : 4;
  666. recordalignmin : 0;
  667. recordalignmax : 4;
  668. maxCrecordalign : 4
  669. );
  670. first_parm_offset : 24;
  671. stacksize : 262144;
  672. stackalign : 16;
  673. abi : abi_powerpc_aix;
  674. );
  675. system_i386_darwin_info : tsysteminfo =
  676. (
  677. system : system_i386_darwin;
  678. name : 'Darwin for i386';
  679. shortname : 'Darwin';
  680. flags : [tf_p_ext_support,tf_files_case_sensitive,tf_smartlink_sections,tf_dwarf_relative_addresses,tf_dwarf_only_local_labels,tf_pic_uses_got,tf_pic_default,tf_has_winlike_resources];
  681. cpu : cpu_i386;
  682. unit_env : 'BSDUNITS';
  683. extradefines : 'UNIX;BSD;HASUNIX';
  684. exeext : '';
  685. defext : '.def';
  686. scriptext : '.sh';
  687. smartext : '.sl';
  688. unitext : '.ppu';
  689. unitlibext : '.ppl';
  690. asmext : '.s';
  691. objext : '.o';
  692. resext : '.res';
  693. resobjext : '.or';
  694. sharedlibext : '.dylib';
  695. staticlibext : '.a';
  696. staticlibprefix : 'libp';
  697. sharedlibprefix : 'lib';
  698. sharedClibext : '.dylib';
  699. staticClibext : '.a';
  700. staticClibprefix : 'lib';
  701. sharedClibprefix : 'lib';
  702. importlibprefix : 'libimp';
  703. importlibext : '.a';
  704. Cprefix : '_';
  705. newline : #10;
  706. dirsep : '/';
  707. assem : as_clang;
  708. assemextern : as_clang;
  709. link : ld_none;
  710. linkextern : ld_bsd;
  711. ar : ar_gnu_ar;
  712. res : res_macho;
  713. dbg : dbg_dwarf2;
  714. script : script_unix;
  715. endian : endian_little;
  716. alignment :
  717. (
  718. procalign : 16;
  719. loopalign : 4;
  720. jumpalign : 0;
  721. constalignmin : 0;
  722. constalignmax : 8;
  723. varalignmin : 0;
  724. varalignmax : 16;
  725. localalignmin : 0;
  726. localalignmax : 8;
  727. recordalignmin : 0;
  728. recordalignmax : 16;
  729. maxCrecordalign : 16
  730. );
  731. first_parm_offset : 8;
  732. stacksize : 262144;
  733. stackalign : 16;
  734. abi : abi_default;
  735. );
  736. system_i386_iphonesim_info : tsysteminfo =
  737. (
  738. system : system_i386_iphonesim;
  739. name : 'Darwin/iPhoneSim for i386';
  740. shortname : 'iPhoneSim';
  741. flags : [tf_p_ext_support,tf_files_case_sensitive,tf_smartlink_sections,tf_dwarf_relative_addresses,tf_dwarf_only_local_labels,tf_pic_uses_got,tf_pic_default,tf_has_winlike_resources];
  742. cpu : cpu_i386;
  743. unit_env : 'BSDUNITS';
  744. extradefines : 'UNIX;BSD;HASUNIX;DARWIN'; // also define darwin for code compatibility
  745. exeext : '';
  746. defext : '.def';
  747. scriptext : '.sh';
  748. smartext : '.sl';
  749. unitext : '.ppu';
  750. unitlibext : '.ppl';
  751. asmext : '.s';
  752. objext : '.o';
  753. resext : '.res';
  754. resobjext : '.or';
  755. sharedlibext : '.dylib';
  756. staticlibext : '.a';
  757. staticlibprefix : 'libp';
  758. sharedlibprefix : 'lib';
  759. sharedClibext : '.dylib';
  760. staticClibext : '.a';
  761. staticClibprefix : 'lib';
  762. sharedClibprefix : 'lib';
  763. importlibprefix : 'libimp';
  764. importlibext : '.a';
  765. Cprefix : '_';
  766. newline : #10;
  767. dirsep : '/';
  768. assem : as_clang;
  769. assemextern : as_clang;
  770. link : ld_none;
  771. linkextern : ld_bsd;
  772. ar : ar_gnu_ar;
  773. res : res_macho;
  774. dbg : dbg_dwarf2;
  775. script : script_unix;
  776. endian : endian_little;
  777. alignment :
  778. (
  779. procalign : 16;
  780. loopalign : 4;
  781. jumpalign : 0;
  782. constalignmin : 0;
  783. constalignmax : 8;
  784. varalignmin : 0;
  785. varalignmax : 16;
  786. localalignmin : 0;
  787. localalignmax : 8;
  788. recordalignmin : 0;
  789. recordalignmax : 16;
  790. maxCrecordalign : 16
  791. );
  792. first_parm_offset : 8;
  793. stacksize : 262144;
  794. stackalign : 16;
  795. abi : abi_default;
  796. );
  797. system_powerpc64_darwin_info : tsysteminfo =
  798. (
  799. system : system_powerpc64_darwin;
  800. name : 'Darwin for PowerPC64';
  801. shortname : 'Darwin';
  802. flags : [tf_p_ext_support,tf_files_case_sensitive,tf_smartlink_sections,tf_dwarf_relative_addresses,tf_dwarf_only_local_labels,tf_pic_default,tf_has_winlike_resources];
  803. cpu : cpu_powerpc64;
  804. unit_env : 'BSDUNITS';
  805. extradefines : 'UNIX;BSD;HASUNIX';
  806. exeext : '';
  807. defext : '.def';
  808. scriptext : '.sh';
  809. smartext : '.sl';
  810. unitext : '.ppu';
  811. unitlibext : '.ppl';
  812. asmext : '.s';
  813. objext : '.o';
  814. resext : '.res';
  815. resobjext : '.or';
  816. sharedlibext : '.dylib';
  817. staticlibext : '.a';
  818. staticlibprefix : 'libp';
  819. sharedlibprefix : 'lib';
  820. sharedClibext : '.dylib';
  821. staticClibext : '.a';
  822. staticClibprefix : 'lib';
  823. sharedClibprefix : 'lib';
  824. importlibprefix : 'libimp';
  825. importlibext : '.a';
  826. Cprefix : '_';
  827. newline : #10;
  828. dirsep : '/';
  829. assem : as_darwin;
  830. assemextern : as_darwin;
  831. link : ld_none;
  832. linkextern : ld_bsd;
  833. ar : ar_gnu_ar;
  834. res : res_macho;
  835. dbg : dbg_dwarf2;
  836. script : script_unix;
  837. endian : endian_big;
  838. alignment :
  839. (
  840. procalign : 16;
  841. loopalign : 4;
  842. jumpalign : 0;
  843. constalignmin : 4;
  844. constalignmax : 8;
  845. varalignmin : 4;
  846. varalignmax : 8;
  847. localalignmin : 4;
  848. localalignmax : 8;
  849. recordalignmin : 0;
  850. recordalignmax : 8;
  851. maxCrecordalign : 4
  852. );
  853. first_parm_offset : 48;
  854. stacksize : 262144;
  855. stackalign : 16;
  856. abi : abi_powerpc_aix;
  857. );
  858. system_x86_64_darwin_info : tsysteminfo =
  859. (
  860. system : system_x86_64_darwin;
  861. name : 'Darwin for x86_64';
  862. shortname : 'Darwin';
  863. flags : [tf_p_ext_support,tf_files_case_sensitive,tf_smartlink_sections,tf_dwarf_relative_addresses,tf_dwarf_only_local_labels,tf_pic_default,tf_has_winlike_resources];
  864. cpu : cpu_x86_64;
  865. unit_env : 'BSDUNITS';
  866. extradefines : 'UNIX;BSD;HASUNIX';
  867. exeext : '';
  868. defext : '.def';
  869. scriptext : '.sh';
  870. smartext : '.sl';
  871. unitext : '.ppu';
  872. unitlibext : '.ppl';
  873. asmext : '.s';
  874. objext : '.o';
  875. resext : '.res';
  876. resobjext : '.or';
  877. sharedlibext : '.dylib';
  878. staticlibext : '.a';
  879. staticlibprefix : 'libp';
  880. sharedlibprefix : 'lib';
  881. sharedClibext : '.dylib';
  882. staticClibext : '.a';
  883. staticClibprefix : 'lib';
  884. sharedClibprefix : 'lib';
  885. importlibprefix : 'libimp';
  886. importlibext : '.a';
  887. Cprefix : '_';
  888. newline : #10;
  889. dirsep : '/';
  890. assem : as_clang;
  891. assemextern : as_clang;
  892. link : ld_none;
  893. linkextern : ld_bsd;
  894. ar : ar_gnu_ar;
  895. res : res_macho;
  896. dbg : dbg_dwarf2;
  897. script : script_unix;
  898. endian : endian_little;
  899. alignment :
  900. (
  901. procalign : 8;
  902. loopalign : 4;
  903. jumpalign : 0;
  904. constalignmin : 0;
  905. constalignmax : 8;
  906. varalignmin : 0;
  907. varalignmax : 16;
  908. localalignmin : 4;
  909. localalignmax : 16;
  910. recordalignmin : 0;
  911. recordalignmax : 16;
  912. maxCrecordalign : 16
  913. );
  914. first_parm_offset : 16;
  915. stacksize : 262144;
  916. stackalign : 16;
  917. abi : abi_default;
  918. );
  919. system_arm_darwin_info : tsysteminfo =
  920. (
  921. system : system_arm_darwin;
  922. name : 'Darwin for ARM';
  923. shortname : 'Darwin';
  924. flags : [tf_p_ext_support,tf_requires_proper_alignment,tf_files_case_sensitive,tf_smartlink_sections,tf_dwarf_relative_addresses,tf_dwarf_only_local_labels,tf_has_winlike_resources,tf_pic_default];
  925. cpu : cpu_arm;
  926. unit_env : 'BSDUNITS';
  927. extradefines : 'UNIX;BSD;HASUNIX;CPUARMEL';
  928. exeext : '';
  929. defext : '.def';
  930. scriptext : '.sh';
  931. smartext : '.sl';
  932. unitext : '.ppu';
  933. unitlibext : '.ppl';
  934. asmext : '.s';
  935. objext : '.o';
  936. resext : '.res';
  937. resobjext : '.or';
  938. sharedlibext : '.dylib';
  939. staticlibext : '.a';
  940. staticlibprefix : 'libp';
  941. sharedlibprefix : 'lib';
  942. sharedClibext : '.dylib';
  943. staticClibext : '.a';
  944. staticClibprefix : 'lib';
  945. sharedClibprefix : 'lib';
  946. importlibprefix : 'libimp';
  947. importlibext : '.a';
  948. Cprefix : '_';
  949. newline : #10;
  950. dirsep : '/';
  951. assem : as_darwin;
  952. assemextern : as_darwin;
  953. link : ld_none;
  954. linkextern : ld_bsd;
  955. ar : ar_gnu_ar;
  956. res : res_macho;
  957. dbg : dbg_dwarf2;
  958. script : script_unix;
  959. endian : endian_little;
  960. alignment :
  961. (
  962. procalign : 4;
  963. loopalign : 4;
  964. jumpalign : 0;
  965. constalignmin : 0;
  966. constalignmax : 8;
  967. varalignmin : 0;
  968. varalignmax : 8;
  969. localalignmin : 4;
  970. localalignmax : 8;
  971. recordalignmin : 0;
  972. recordalignmax : 8;
  973. maxCrecordalign : 8
  974. );
  975. first_parm_offset : 8;
  976. stacksize : 262144;
  977. stackalign : 4;
  978. abi : abi_default
  979. );
  980. implementation
  981. initialization
  982. {$ifdef cpui386}
  983. {$ifdef FreeBSD}
  984. set_source_info(system_i386_FreeBSD_info);
  985. {$endif}
  986. {$ifdef NetBSD}
  987. set_source_info(system_i386_NetBSD_info);
  988. {$endif}
  989. {$ifdef OpenBSD}
  990. set_source_info(system_i386_OpenBSD_info);
  991. {$endif}
  992. {$ifdef Darwin}
  993. set_source_info(system_i386_Darwin_info);
  994. {$endif Darwin}
  995. {$endif cpui386}
  996. {$ifdef cpux86_64}
  997. {$ifdef FreeBSD}
  998. set_source_info(system_x86_64_FreeBSD_info);
  999. {$endif}
  1000. {$ifdef DragonFly}
  1001. set_source_info(system_x86_64_DragonFly_info);
  1002. {$endif}
  1003. {$ifdef OpenBSD}
  1004. set_source_info(system_x86_64_OpenBSD_info);
  1005. {$endif}
  1006. {$ifdef NetBSD}
  1007. set_source_info(system_x86_64_NetBSD_info);
  1008. {$endif}
  1009. {$ifdef Darwin}
  1010. set_source_info(system_x86_64_darwin_info);
  1011. {$endif}
  1012. {$endif}
  1013. {$ifdef cpu68}
  1014. {$ifdef NetBSD}
  1015. set_source_info(system_m68k_NetBSD_info);
  1016. {$endif NetBSD}
  1017. {$endif cpu68}
  1018. {$ifdef cpupowerpc32}
  1019. {$ifdef Darwin}
  1020. set_source_info(system_powerpc_darwin_info);
  1021. {$endif Darwin}
  1022. {$ifdef NetBSD}
  1023. set_source_info(system_powerpc_netbsd_info);
  1024. {$endif}
  1025. {$endif cpupowerpc32}
  1026. {$ifdef cpupowerpc64}
  1027. {$ifdef Darwin}
  1028. set_source_info(system_powerpc64_darwin_info);
  1029. {$endif Darwin}
  1030. {$endif powerpc64}
  1031. {$ifdef cpuarm}
  1032. {$ifdef Darwin}
  1033. set_source_info(system_arm_darwin_info);
  1034. {$endif Darwin}
  1035. {$endif cpuarm}
  1036. end.