i_darwin.pas 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680
  1. {
  2. Copyright (c) 1998-2008 by Peter Vreman
  3. This unit implements support information structures for Darwin
  4. (Mac OS X/OS X/macOS/iOS/iPhoneSimulator/...)
  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. unit i_darwin;
  19. {$i fpcdefs.inc}
  20. interface
  21. uses
  22. systems;
  23. const
  24. res_macho_info : tresinfo =
  25. (
  26. id : res_macho;
  27. resbin : 'fpcres';
  28. rescmd : '-o $OBJ -a $ARCH -s $SUBARCH -of mach-o $DBG';
  29. rcbin : 'windres';
  30. rccmd : '--include $INC -O res -D FPC -o $RES $RC';
  31. resourcefileclass : nil;
  32. resflags : [];
  33. );
  34. res_macosx_ext_info : tresinfo =
  35. (
  36. id : res_ext;
  37. resbin : 'fpcres';
  38. rescmd : '-o $OBJ -a $ENDIAN -of external $DBG';
  39. rcbin : 'windres';
  40. rccmd : '--include $INC -O res -D FPC -o $RES $RC';
  41. resourcefileclass : nil;
  42. resflags : [res_external_file,res_arch_in_file_name];
  43. );
  44. system_powerpc_darwin_info : tsysteminfo =
  45. (
  46. system : system_powerpc_darwin;
  47. name : 'Darwin for PowerPC';
  48. shortname : 'Darwin';
  49. 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];
  50. cpu : cpu_powerpc;
  51. unit_env : 'BSDUNITS';
  52. extradefines : 'UNIX;BSD;HASUNIX';
  53. exeext : '';
  54. defext : '.def';
  55. scriptext : '.sh';
  56. smartext : '.sl';
  57. unitext : '.ppu';
  58. unitlibext : '.ppl';
  59. asmext : '.s';
  60. objext : '.o';
  61. resext : '.res';
  62. resobjext : '.or';
  63. sharedlibext : '.dylib';
  64. staticlibext : '.a';
  65. staticlibprefix : 'libp';
  66. sharedlibprefix : 'lib';
  67. sharedClibext : '.dylib';
  68. staticClibext : '.a';
  69. staticClibprefix : 'lib';
  70. sharedClibprefix : 'lib';
  71. importlibprefix : 'libimp';
  72. importlibext : '.a';
  73. Cprefix : '_';
  74. newline : #10;
  75. dirsep : '/';
  76. assem : as_darwin;
  77. assemextern : as_darwin;
  78. link : ld_none;
  79. linkextern : ld_darwin;
  80. ar : ar_gnu_ar;
  81. res : res_macho;
  82. dbg : dbg_stabs;
  83. script : script_unix;
  84. endian : endian_big;
  85. alignment :
  86. (
  87. procalign : 16;
  88. loopalign : 4;
  89. jumpalign : 0;
  90. constalignmin : 0;
  91. constalignmax : 4;
  92. varalignmin : 0;
  93. varalignmax : 4;
  94. localalignmin : 0;
  95. localalignmax : 4;
  96. recordalignmin : 0;
  97. recordalignmax : 4;
  98. maxCrecordalign : 4
  99. );
  100. first_parm_offset : 24;
  101. stacksize : 262144;
  102. stackalign : 16;
  103. abi : abi_powerpc_darwin;
  104. 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:64:64-v128:128:128-n32';
  105. );
  106. system_i386_darwin_info : tsysteminfo =
  107. (
  108. system : system_i386_darwin;
  109. name : 'Darwin for i386';
  110. shortname : 'Darwin';
  111. 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,
  112. tf_pic_default,tf_has_winlike_resources,tf_use_hlcfi,tf_supports_symbolorderfile];
  113. cpu : cpu_i386;
  114. unit_env : 'BSDUNITS';
  115. extradefines : 'UNIX;BSD;HASUNIX';
  116. exeext : '';
  117. defext : '.def';
  118. scriptext : '.sh';
  119. smartext : '.sl';
  120. unitext : '.ppu';
  121. unitlibext : '.ppl';
  122. asmext : '.s';
  123. objext : '.o';
  124. resext : '.res';
  125. resobjext : '.or';
  126. sharedlibext : '.dylib';
  127. staticlibext : '.a';
  128. staticlibprefix : 'libp';
  129. sharedlibprefix : 'lib';
  130. sharedClibext : '.dylib';
  131. staticClibext : '.a';
  132. staticClibprefix : 'lib';
  133. sharedClibprefix : 'lib';
  134. importlibprefix : 'libimp';
  135. importlibext : '.a';
  136. Cprefix : '_';
  137. newline : #10;
  138. dirsep : '/';
  139. assem : as_clang_asdarwin;
  140. assemextern : as_clang_asdarwin;
  141. link : ld_none;
  142. linkextern : ld_darwin;
  143. ar : ar_gnu_ar;
  144. res : res_macho;
  145. dbg : dbg_dwarf2;
  146. script : script_unix;
  147. endian : endian_little;
  148. alignment :
  149. (
  150. procalign : 16;
  151. loopalign : 8;
  152. jumpalign : 16;
  153. constalignmin : 0;
  154. constalignmax : 16;
  155. varalignmin : 0;
  156. varalignmax : 16;
  157. localalignmin : 0;
  158. localalignmax : 8;
  159. recordalignmin : 0;
  160. recordalignmax : 16;
  161. maxCrecordalign : 16
  162. );
  163. first_parm_offset : 8;
  164. stacksize : 262144;
  165. stackalign : 16;
  166. abi : abi_i386_dynalignedstack;
  167. 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:128:128-n8:16:32-S128';
  168. );
  169. system_i386_iphonesim_info : tsysteminfo =
  170. (
  171. system : system_i386_iphonesim;
  172. name : 'Darwin/iPhoneSim for i386';
  173. shortname : 'iPhoneSim';
  174. flags : [tf_p_ext_support,tf_files_case_sensitive,tf_smartlink_sections,tf_dwarf_relative_addresses,tf_dwarf_only_local_labels,
  175. tf_pic_uses_got,tf_pic_default,tf_has_winlike_resources,tf_use_hlcfi,tf_supports_symbolorderfile,tf_requires_proper_alignment];
  176. cpu : cpu_i386;
  177. unit_env : 'BSDUNITS';
  178. extradefines : 'UNIX;BSD;HASUNIX;DARWIN'; // also define darwin for code compatibility
  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 : '.dylib';
  190. staticlibext : '.a';
  191. staticlibprefix : 'libp';
  192. sharedlibprefix : 'lib';
  193. sharedClibext : '.dylib';
  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_clang_asdarwin;
  203. assemextern : as_clang_asdarwin;
  204. link : ld_none;
  205. linkextern : ld_darwin;
  206. ar : ar_gnu_ar;
  207. res : res_macho;
  208. dbg : dbg_dwarf2;
  209. script : script_unix;
  210. endian : endian_little;
  211. alignment :
  212. (
  213. procalign : 16;
  214. loopalign : 8;
  215. jumpalign : 16;
  216. constalignmin : 0;
  217. constalignmax : 16;
  218. varalignmin : 0;
  219. varalignmax : 16;
  220. localalignmin : 0;
  221. localalignmax : 16;
  222. recordalignmin : 0;
  223. recordalignmax : 16;
  224. maxCrecordalign : 16
  225. );
  226. first_parm_offset : 8;
  227. stacksize : 262144;
  228. stackalign : 16;
  229. abi : abi_i386_dynalignedstack;
  230. 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:128:128-n8:16:32-S128';
  231. );
  232. system_powerpc64_darwin_info : tsysteminfo =
  233. (
  234. system : system_powerpc64_darwin;
  235. name : 'Darwin for PowerPC64';
  236. shortname : 'Darwin';
  237. flags : [tf_p_ext_support,tf_files_case_sensitive,tf_smartlink_sections,tf_dwarf_relative_addresses,tf_dwarf_only_local_labels,
  238. tf_pic_default,tf_has_winlike_resources];
  239. cpu : cpu_powerpc64;
  240. unit_env : 'BSDUNITS';
  241. extradefines : 'UNIX;BSD;HASUNIX';
  242. exeext : '';
  243. defext : '.def';
  244. scriptext : '.sh';
  245. smartext : '.sl';
  246. unitext : '.ppu';
  247. unitlibext : '.ppl';
  248. asmext : '.s';
  249. objext : '.o';
  250. resext : '.res';
  251. resobjext : '.or';
  252. sharedlibext : '.dylib';
  253. staticlibext : '.a';
  254. staticlibprefix : 'libp';
  255. sharedlibprefix : 'lib';
  256. sharedClibext : '.dylib';
  257. staticClibext : '.a';
  258. staticClibprefix : 'lib';
  259. sharedClibprefix : 'lib';
  260. importlibprefix : 'libimp';
  261. importlibext : '.a';
  262. Cprefix : '_';
  263. newline : #10;
  264. dirsep : '/';
  265. assem : as_darwin;
  266. assemextern : as_darwin;
  267. link : ld_none;
  268. linkextern : ld_darwin;
  269. ar : ar_gnu_ar;
  270. res : res_macho;
  271. dbg : dbg_dwarf2;
  272. script : script_unix;
  273. endian : endian_big;
  274. alignment :
  275. (
  276. procalign : 16;
  277. loopalign : 4;
  278. jumpalign : 0;
  279. constalignmin : 4;
  280. constalignmax : 8;
  281. varalignmin : 4;
  282. varalignmax : 8;
  283. localalignmin : 4;
  284. localalignmax : 8;
  285. recordalignmin : 0;
  286. recordalignmax : 8;
  287. maxCrecordalign : 4
  288. );
  289. first_parm_offset : 48;
  290. stacksize : 262144;
  291. stackalign : 16;
  292. abi : abi_powerpc_darwin;
  293. 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-v128:128:128-n32:64';
  294. );
  295. system_x86_64_darwin_info : tsysteminfo =
  296. (
  297. system : system_x86_64_darwin;
  298. name : 'Darwin for x86_64';
  299. shortname : 'Darwin';
  300. 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,tf_use_hlcfi
  301. {$ifdef llvm},tf_use_psabieh{$endif},tf_supports_symbolorderfile];
  302. cpu : cpu_x86_64;
  303. unit_env : 'BSDUNITS';
  304. extradefines : 'UNIX;BSD;HASUNIX';
  305. exeext : '';
  306. defext : '.def';
  307. scriptext : '.sh';
  308. smartext : '.sl';
  309. unitext : '.ppu';
  310. unitlibext : '.ppl';
  311. asmext : '.s';
  312. objext : '.o';
  313. resext : '.res';
  314. resobjext : '.or';
  315. sharedlibext : '.dylib';
  316. staticlibext : '.a';
  317. staticlibprefix : 'libp';
  318. sharedlibprefix : 'lib';
  319. sharedClibext : '.dylib';
  320. staticClibext : '.a';
  321. staticClibprefix : 'lib';
  322. sharedClibprefix : 'lib';
  323. importlibprefix : 'libimp';
  324. importlibext : '.a';
  325. Cprefix : '_';
  326. newline : #10;
  327. dirsep : '/';
  328. assem : as_clang_asdarwin;
  329. assemextern : as_clang_asdarwin;
  330. link : ld_none;
  331. linkextern : ld_darwin;
  332. ar : ar_gnu_ar;
  333. res : res_macho;
  334. dbg : dbg_dwarf2;
  335. script : script_unix;
  336. endian : endian_little;
  337. alignment :
  338. (
  339. procalign : 16;
  340. loopalign : 8;
  341. jumpalign : 16;
  342. constalignmin : 0;
  343. constalignmax : 16;
  344. varalignmin : 0;
  345. varalignmax : 16;
  346. localalignmin : 4;
  347. localalignmax : 16;
  348. recordalignmin : 0;
  349. recordalignmax : 16;
  350. maxCrecordalign : 16
  351. );
  352. first_parm_offset : 16;
  353. stacksize : 262144;
  354. stackalign : 16;
  355. abi : abi_default;
  356. 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';
  357. );
  358. system_x86_64_iphonesim_info : tsysteminfo =
  359. (
  360. system : system_x86_64_iphonesim;
  361. name : 'Darwin/iPhoneSim for x86_64';
  362. shortname : 'iPhoneSim';
  363. flags : [tf_p_ext_support,tf_files_case_sensitive,tf_smartlink_sections,tf_dwarf_relative_addresses,tf_dwarf_only_local_labels,
  364. tf_pic_default,tf_has_winlike_resources,tf_use_hlcfi,tf_supports_symbolorderfile,tf_requires_proper_alignment];
  365. cpu : cpu_x86_64;
  366. unit_env : 'BSDUNITS';
  367. extradefines : 'UNIX;BSD;HASUNIX;DARWIN'; // also define darwin for code compatibility
  368. exeext : '';
  369. defext : '.def';
  370. scriptext : '.sh';
  371. smartext : '.sl';
  372. unitext : '.ppu';
  373. unitlibext : '.ppl';
  374. asmext : '.s';
  375. objext : '.o';
  376. resext : '.res';
  377. resobjext : '.or';
  378. sharedlibext : '.dylib';
  379. staticlibext : '.a';
  380. staticlibprefix : 'libp';
  381. sharedlibprefix : 'lib';
  382. sharedClibext : '.dylib';
  383. staticClibext : '.a';
  384. staticClibprefix : 'lib';
  385. sharedClibprefix : 'lib';
  386. importlibprefix : 'libimp';
  387. importlibext : '.a';
  388. Cprefix : '_';
  389. newline : #10;
  390. dirsep : '/';
  391. assem : as_clang_asdarwin;
  392. assemextern : as_clang_asdarwin;
  393. link : ld_none;
  394. linkextern : ld_darwin;
  395. ar : ar_gnu_ar;
  396. res : res_macho;
  397. dbg : dbg_dwarf2;
  398. script : script_unix;
  399. endian : endian_little;
  400. alignment :
  401. (
  402. procalign : 16;
  403. loopalign : 8;
  404. jumpalign : 16;
  405. constalignmin : 0;
  406. constalignmax : 16;
  407. varalignmin : 0;
  408. varalignmax : 16;
  409. localalignmin : 4;
  410. localalignmax : 16;
  411. recordalignmin : 0;
  412. recordalignmax : 16;
  413. maxCrecordalign : 16
  414. );
  415. first_parm_offset : 16;
  416. stacksize : 262144;
  417. stackalign : 16;
  418. abi : abi_default;
  419. 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';
  420. );
  421. system_arm_ios_info : tsysteminfo =
  422. (
  423. system : system_arm_ios;
  424. name : 'iOS for ARM';
  425. shortname : 'iOS';
  426. flags : [tf_p_ext_support,tf_requires_proper_alignment,tf_files_case_sensitive,tf_smartlink_sections,tf_dwarf_relative_addresses,
  427. tf_dwarf_only_local_labels,tf_has_winlike_resources,tf_pic_default,tf_supports_symbolorderfile];
  428. cpu : cpu_arm;
  429. unit_env : 'BSDUNITS';
  430. extradefines : 'UNIX;BSD;HASUNIX;CPUARMEL;DARWIN';
  431. exeext : '';
  432. defext : '.def';
  433. scriptext : '.sh';
  434. smartext : '.sl';
  435. unitext : '.ppu';
  436. unitlibext : '.ppl';
  437. asmext : '.s';
  438. objext : '.o';
  439. resext : '.res';
  440. resobjext : '.or';
  441. sharedlibext : '.dylib';
  442. staticlibext : '.a';
  443. staticlibprefix : 'libp';
  444. sharedlibprefix : 'lib';
  445. sharedClibext : '.dylib';
  446. staticClibext : '.a';
  447. staticClibprefix : 'lib';
  448. sharedClibprefix : 'lib';
  449. importlibprefix : 'libimp';
  450. importlibext : '.a';
  451. Cprefix : '_';
  452. newline : #10;
  453. dirsep : '/';
  454. assem : as_clang_asdarwin;
  455. assemextern : as_clang_asdarwin;
  456. link : ld_none;
  457. linkextern : ld_darwin;
  458. ar : ar_gnu_ar;
  459. res : res_macho;
  460. dbg : dbg_dwarf2;
  461. script : script_unix;
  462. endian : endian_little;
  463. alignment :
  464. (
  465. procalign : 16;
  466. loopalign : 4;
  467. jumpalign : 0;
  468. constalignmin : 0;
  469. constalignmax : 8;
  470. varalignmin : 0;
  471. varalignmax : 8;
  472. localalignmin : 4;
  473. localalignmax : 8;
  474. recordalignmin : 0;
  475. recordalignmax : 8;
  476. maxCrecordalign : 8
  477. );
  478. first_parm_offset : 8;
  479. stacksize : 262144;
  480. stackalign : 4;
  481. abi : abi_default;
  482. { note: default LLVM stack alignment is 8 bytes for this target }
  483. 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-v64:64:64-v128:64:128-a0:0:64-n32-S32';
  484. );
  485. system_aarch64_ios_info : tsysteminfo =
  486. (
  487. system : system_aarch64_ios;
  488. name : 'iOS for AArch64';
  489. shortname : 'iOS';
  490. flags : [tf_p_ext_support,tf_requires_proper_alignment,tf_files_case_sensitive,tf_smartlink_sections,tf_dwarf_relative_addresses,
  491. tf_dwarf_only_local_labels,tf_pic_default,tf_has_winlike_resources,tf_supports_symbolorderfile];
  492. cpu : cpu_aarch64;
  493. unit_env : 'BSDUNITS';
  494. extradefines : 'UNIX;BSD;HASUNIX;DARWIN';
  495. exeext : '';
  496. defext : '.def';
  497. scriptext : '.sh';
  498. smartext : '.sl';
  499. unitext : '.ppu';
  500. unitlibext : '.ppl';
  501. asmext : '.s';
  502. objext : '.o';
  503. resext : '.res';
  504. resobjext : '.or';
  505. sharedlibext : '.dylib';
  506. staticlibext : '.a';
  507. staticlibprefix : 'libp';
  508. sharedlibprefix : 'lib';
  509. sharedClibext : '.dylib';
  510. staticClibext : '.a';
  511. staticClibprefix : 'lib';
  512. sharedClibprefix : 'lib';
  513. importlibprefix : 'libimp';
  514. importlibext : '.a';
  515. Cprefix : '_';
  516. newline : #10;
  517. dirsep : '/';
  518. assem : as_clang_asdarwin;
  519. assemextern : as_clang_asdarwin;
  520. link : ld_none;
  521. linkextern : ld_darwin;
  522. ar : ar_gnu_ar;
  523. res : res_macho;
  524. dbg : dbg_dwarf2;
  525. script : script_unix;
  526. endian : endian_little;
  527. alignment :
  528. (
  529. procalign : 16;
  530. loopalign : 4;
  531. jumpalign : 0;
  532. constalignmin : 0;
  533. constalignmax : 16;
  534. varalignmin : 0;
  535. varalignmax : 16;
  536. localalignmin : 4;
  537. localalignmax : 16;
  538. recordalignmin : 0;
  539. recordalignmax : 16;
  540. maxCrecordalign : 16
  541. );
  542. first_parm_offset : 16;
  543. stacksize : 8*1024*1024;
  544. stackalign : 16;
  545. abi : abi_aarch64_darwin;
  546. 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-n32:64-S128'
  547. );
  548. system_aarch64_darwin_info : tsysteminfo =
  549. (
  550. system : system_aarch64_darwin;
  551. name : 'Darwin for AArch64';
  552. shortname : 'Darwin';
  553. flags : [tf_p_ext_support,tf_requires_proper_alignment,tf_files_case_sensitive,tf_smartlink_sections,tf_dwarf_relative_addresses,
  554. tf_dwarf_only_local_labels,tf_pic_default,tf_has_winlike_resources,tf_supports_symbolorderfile
  555. {$ifdef llvm},tf_use_psabieh{$endif}];
  556. cpu : cpu_aarch64;
  557. unit_env : 'BSDUNITS';
  558. extradefines : 'UNIX;BSD;HASUNIX';
  559. exeext : '';
  560. defext : '.def';
  561. scriptext : '.sh';
  562. smartext : '.sl';
  563. unitext : '.ppu';
  564. unitlibext : '.ppl';
  565. asmext : '.s';
  566. objext : '.o';
  567. resext : '.res';
  568. resobjext : '.or';
  569. sharedlibext : '.dylib';
  570. staticlibext : '.a';
  571. staticlibprefix : 'libp';
  572. sharedlibprefix : 'lib';
  573. sharedClibext : '.dylib';
  574. staticClibext : '.a';
  575. staticClibprefix : 'lib';
  576. sharedClibprefix : 'lib';
  577. importlibprefix : 'libimp';
  578. importlibext : '.a';
  579. Cprefix : '_';
  580. newline : #10;
  581. dirsep : '/';
  582. assem : as_clang_asdarwin;
  583. assemextern : as_clang_asdarwin;
  584. link : ld_none;
  585. linkextern : ld_darwin;
  586. ar : ar_gnu_ar;
  587. res : res_macho;
  588. dbg : dbg_dwarf2;
  589. script : script_unix;
  590. endian : endian_little;
  591. alignment :
  592. (
  593. procalign : 16;
  594. loopalign : 4;
  595. jumpalign : 0;
  596. constalignmin : 0;
  597. constalignmax : 16;
  598. varalignmin : 0;
  599. varalignmax : 16;
  600. localalignmin : 4;
  601. localalignmax : 16;
  602. recordalignmin : 0;
  603. recordalignmax : 16;
  604. maxCrecordalign : 16
  605. );
  606. first_parm_offset : 16;
  607. stacksize : 8*1024*1024;
  608. stackalign : 16;
  609. abi : abi_aarch64_darwin;
  610. 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-n32:64-S128'
  611. );
  612. implementation
  613. initialization
  614. {$ifdef cpui386}
  615. {$ifdef Darwin}
  616. set_source_info(system_i386_Darwin_info);
  617. {$endif Darwin}
  618. {$endif cpui386}
  619. {$ifdef cpux86_64}
  620. {$ifdef Darwin}
  621. set_source_info(system_x86_64_darwin_info);
  622. {$endif}
  623. {$endif cpux86_64}
  624. {$ifdef cpupowerpc32}
  625. {$ifdef Darwin}
  626. set_source_info(system_powerpc_darwin_info);
  627. {$endif Darwin}
  628. {$endif cpupowerpc32}
  629. {$ifdef cpupowerpc64}
  630. {$ifdef Darwin}
  631. set_source_info(system_powerpc64_darwin_info);
  632. {$endif Darwin}
  633. {$endif powerpc64}
  634. {$ifdef cpuarm}
  635. {$ifdef Darwin}
  636. set_source_info(system_arm_ios_info);
  637. {$endif Darwin}
  638. {$endif cpuarm}
  639. {$ifdef cpuaarch64}
  640. {$ifdef Darwin}
  641. {$ifdef ios}
  642. set_source_info(system_aarch64_ios_info);
  643. {$else}
  644. set_source_info(system_aarch64_darwin_info);
  645. {$endif}
  646. {$endif Darwin}
  647. {$endif cpuaarch64}
  648. end.