assemble.pas 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755
  1. {
  2. $Id$
  3. Copyright (c) 1998 by the FPC development team
  4. This unit handles the assemblerfile write and assembler calls of FPC
  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. unit assemble;
  18. interface
  19. uses
  20. {$ifdef Delphi}
  21. dmisc,
  22. {$endif Delphi}
  23. dos,cobjects,globtype,globals,aasm;
  24. const
  25. {$ifdef tp}
  26. AsmOutSize=1024;
  27. {$else}
  28. AsmOutSize=32768;
  29. {$endif}
  30. type
  31. PAsmList=^TAsmList;
  32. TAsmList=object
  33. {filenames}
  34. path : pathstr;
  35. name : namestr;
  36. asmfile, { current .s and .o file }
  37. objfile,
  38. as_bin : string;
  39. IsEndFile : boolean; { special 'end' file for import dir ? }
  40. {outfile}
  41. AsmSize,
  42. AsmStartSize,
  43. outcnt : longint;
  44. outbuf : array[0..AsmOutSize-1] of char;
  45. outfile : file;
  46. Constructor Init;
  47. Destructor Done;
  48. Function FindAssembler:string;
  49. Function CallAssembler(const command,para:string):Boolean;
  50. Function DoAssemble:boolean;
  51. Procedure RemoveAsm;
  52. procedure NextSmartName;
  53. Procedure AsmFlush;
  54. Procedure AsmClear;
  55. Procedure AsmWrite(const s:string);
  56. Procedure AsmWritePChar(p:pchar);
  57. Procedure AsmWriteLn(const s:string);
  58. Procedure AsmLn;
  59. procedure AsmCreate;
  60. procedure AsmClose;
  61. procedure Synchronize;
  62. procedure WriteTree(p:paasmoutput);virtual;
  63. procedure WriteAsmList;virtual;
  64. end;
  65. Procedure GenerateAsm;
  66. Procedure OnlyAsm;
  67. var
  68. SmartLinkFilesCnt : longint;
  69. Implementation
  70. uses
  71. script,files,systems,verbose
  72. {$ifdef linux}
  73. ,linux
  74. {$endif}
  75. ,strings
  76. {$ifdef i386}
  77. {$ifndef NoAg386Bin}
  78. ,ag386bin
  79. {$endif}
  80. {$ifndef NoAg386Att}
  81. ,ag386att
  82. {$endif NoAg386Att}
  83. {$ifndef NoAg386Nsm}
  84. ,ag386nsm
  85. {$endif NoAg386Nsm}
  86. {$ifndef NoAg386Int}
  87. ,ag386int
  88. {$endif NoAg386Int}
  89. {$ifdef Ag386Cof}
  90. ,ag386cof
  91. {$endif Ag386Cof}
  92. {$endif}
  93. {$ifdef m68k}
  94. {$ifndef NoAg68kGas}
  95. ,ag68kgas
  96. {$endif NoAg68kGas}
  97. {$ifndef NoAg68kMot}
  98. ,ag68kmot
  99. {$endif NoAg68kMot}
  100. {$ifndef NoAg68kMit}
  101. ,ag68kmit
  102. {$endif NoAg68kMit}
  103. {$ifndef NoAg68kMpw}
  104. ,ag68kmpw
  105. {$endif NoAg68kMpw}
  106. {$endif}
  107. ;
  108. {*****************************************************************************
  109. TAsmList
  110. *****************************************************************************}
  111. Function DoPipe:boolean;
  112. begin
  113. DoPipe:=(cs_asm_pipe in aktglobalswitches) and
  114. not(cs_asm_leave in aktglobalswitches)
  115. {$ifdef i386}
  116. and (aktoutputformat=as_i386_as)
  117. {$endif i386}
  118. {$ifdef m68k}
  119. and (aktoutputformat=as_m68k_as);
  120. {$endif m68k}
  121. end;
  122. const
  123. lastas : byte=255;
  124. var
  125. LastASBin : string;
  126. Function TAsmList.FindAssembler:string;
  127. var
  128. asfound : boolean;
  129. begin
  130. if lastas<>ord(target_asm.id) then
  131. begin
  132. lastas:=ord(target_asm.id);
  133. { is an assembler passed ? }
  134. if utilsdirectory<>'' then
  135. LastASBin:=Search(target_asm.asmbin+source_os.exeext,utilsdirectory,asfound)+
  136. target_asm.asmbin+source_os.exeext;
  137. if LastASBin='' then
  138. LastASBin:=FindExe(target_asm.asmbin,asfound);
  139. if (not asfound) and not(cs_asm_extern in aktglobalswitches) then
  140. begin
  141. Message1(exec_w_assembler_not_found,LastASBin);
  142. aktglobalswitches:=aktglobalswitches+[cs_asm_extern];
  143. end;
  144. if asfound then
  145. Message1(exec_t_using_assembler,LastASBin);
  146. end;
  147. FindAssembler:=LastASBin;
  148. end;
  149. Function TAsmList.CallAssembler(const command,para:string):Boolean;
  150. begin
  151. callassembler:=true;
  152. if not(cs_asm_extern in aktglobalswitches) then
  153. begin
  154. swapvectors;
  155. exec(command,para);
  156. swapvectors;
  157. if (doserror<>0) then
  158. begin
  159. Message1(exec_w_cant_call_assembler,tostr(doserror));
  160. aktglobalswitches:=aktglobalswitches+[cs_asm_extern];
  161. callassembler:=false;
  162. end
  163. else
  164. if (dosexitcode<>0) then
  165. begin
  166. Message1(exec_w_error_while_assembling,tostr(dosexitcode));
  167. callassembler:=false;
  168. end;
  169. end
  170. else
  171. AsmRes.AddAsmCommand(command,para,name);
  172. end;
  173. procedure TAsmList.RemoveAsm;
  174. var
  175. g : file;
  176. i : word;
  177. begin
  178. if cs_asm_leave in aktglobalswitches then
  179. exit;
  180. if cs_asm_extern in aktglobalswitches then
  181. AsmRes.AddDeleteCommand(AsmFile)
  182. else
  183. begin
  184. assign(g,AsmFile);
  185. {$I-}
  186. erase(g);
  187. {$I+}
  188. i:=ioresult;
  189. end;
  190. end;
  191. Function TAsmList.DoAssemble:boolean;
  192. var
  193. s : string;
  194. begin
  195. DoAssemble:=true;
  196. if DoPipe then
  197. exit;
  198. if (SmartLinkFilesCnt<=1) and not(cs_asm_extern in aktglobalswitches) then
  199. Message1(exec_i_assembling,name);
  200. s:=target_asm.asmcmd;
  201. Replace(s,'$ASM',AsmFile);
  202. Replace(s,'$OBJ',ObjFile);
  203. if CallAssembler(FindAssembler,s) then
  204. RemoveAsm
  205. else
  206. begin
  207. DoAssemble:=false;
  208. GenerateError;
  209. end;
  210. end;
  211. procedure TAsmList.NextSmartName;
  212. var
  213. s : string;
  214. begin
  215. inc(SmartLinkFilesCnt);
  216. if SmartLinkFilesCnt>999999 then
  217. Message(asmw_f_too_many_asm_files);
  218. if IsEndFile then
  219. begin
  220. s:=current_module^.asmprefix^+'e';
  221. IsEndFile:=false;
  222. end
  223. else
  224. s:=current_module^.asmprefix^;
  225. AsmFile:=Path+FixFileName(s+tostr(SmartLinkFilesCnt)+target_info.asmext);
  226. ObjFile:=Path+FixFileName(s+tostr(SmartLinkFilesCnt)+target_info.objext);
  227. end;
  228. {*****************************************************************************
  229. TAsmList AsmFile Writing
  230. *****************************************************************************}
  231. Procedure TAsmList.AsmFlush;
  232. begin
  233. if outcnt>0 then
  234. begin
  235. BlockWrite(outfile,outbuf,outcnt);
  236. outcnt:=0;
  237. end;
  238. end;
  239. Procedure TAsmList.AsmClear;
  240. begin
  241. outcnt:=0;
  242. end;
  243. Procedure TAsmList.AsmWrite(const s:string);
  244. begin
  245. if OutCnt+length(s)>=AsmOutSize then
  246. AsmFlush;
  247. Move(s[1],OutBuf[OutCnt],length(s));
  248. inc(OutCnt,length(s));
  249. inc(AsmSize,length(s));
  250. end;
  251. Procedure TAsmList.AsmWriteLn(const s:string);
  252. begin
  253. AsmWrite(s);
  254. AsmLn;
  255. end;
  256. Procedure TAsmList.AsmWritePChar(p:pchar);
  257. var
  258. i,j : longint;
  259. begin
  260. i:=StrLen(p);
  261. j:=i;
  262. while j>0 do
  263. begin
  264. i:=min(j,AsmOutSize);
  265. if OutCnt+i>=AsmOutSize then
  266. AsmFlush;
  267. Move(p[0],OutBuf[OutCnt],i);
  268. inc(OutCnt,i);
  269. inc(AsmSize,i);
  270. dec(j,i);
  271. p:=pchar(@p[i]);
  272. end;
  273. end;
  274. Procedure TAsmList.AsmLn;
  275. begin
  276. if OutCnt>=AsmOutSize-2 then
  277. AsmFlush;
  278. OutBuf[OutCnt]:=target_os.newline[1];
  279. inc(OutCnt);
  280. inc(AsmSize);
  281. if length(target_os.newline)>1 then
  282. begin
  283. OutBuf[OutCnt]:=target_os.newline[2];
  284. inc(OutCnt);
  285. inc(AsmSize);
  286. end;
  287. end;
  288. procedure TAsmList.AsmCreate;
  289. begin
  290. if (cs_smartlink in aktmoduleswitches) then
  291. NextSmartName;
  292. {$ifdef linux}
  293. if DoPipe then
  294. begin
  295. Message1(exec_i_assembling_pipe,asmfile);
  296. POpen(outfile,'as -o '+objfile,'W');
  297. end
  298. else
  299. {$endif}
  300. begin
  301. Assign(outfile,asmfile);
  302. {$I-}
  303. Rewrite(outfile,1);
  304. {$I+}
  305. if ioresult<>0 then
  306. Message1(exec_d_cant_create_asmfile,asmfile);
  307. end;
  308. outcnt:=0;
  309. AsmSize:=0;
  310. AsmStartSize:=0;
  311. end;
  312. procedure TAsmList.AsmClose;
  313. var
  314. f : file;
  315. l : longint;
  316. begin
  317. AsmFlush;
  318. {$ifdef linux}
  319. if DoPipe then
  320. Close(outfile)
  321. else
  322. {$endif}
  323. begin
  324. {Touch Assembler time to ppu time is there is a ppufilename}
  325. if Assigned(current_module^.ppufilename) then
  326. begin
  327. Assign(f,current_module^.ppufilename^);
  328. {$I-}
  329. reset(f,1);
  330. {$I+}
  331. if ioresult=0 then
  332. begin
  333. getftime(f,l);
  334. close(f);
  335. reset(outfile,1);
  336. setftime(outfile,l);
  337. end;
  338. end;
  339. close(outfile);
  340. end;
  341. end;
  342. {Touch Assembler and object time to ppu time is there is a ppufilename}
  343. procedure TAsmList.Synchronize;
  344. begin
  345. {Touch Assembler time to ppu time is there is a ppufilename}
  346. if Assigned(current_module^.ppufilename) then
  347. begin
  348. SynchronizeFileTime(current_module^.ppufilename^,asmfile);
  349. if not(cs_asm_extern in aktglobalswitches) then
  350. SynchronizeFileTime(current_module^.ppufilename^,objfile);
  351. end;
  352. end;
  353. procedure TAsmList.WriteTree(p:paasmoutput);
  354. begin
  355. end;
  356. procedure TAsmList.WriteAsmList;
  357. begin
  358. end;
  359. Constructor TAsmList.Init;
  360. var
  361. i : word;
  362. begin
  363. { load start values }
  364. asmfile:=current_module^.asmfilename^;
  365. objfile:=current_module^.objfilename^;
  366. name:=FixFileName(current_module^.modulename^);
  367. OutCnt:=0;
  368. SmartLinkFilesCnt:=0;
  369. IsEndFile:=false;
  370. { Which path will be used ? }
  371. if (cs_smartlink in aktmoduleswitches) then
  372. begin
  373. path:=current_module^.path^+FixFileName(current_module^.modulename^)+target_info.smartext;
  374. {$I-}
  375. mkdir(path);
  376. {$I+}
  377. i:=ioresult;
  378. path:=FixPath(path,false);
  379. end
  380. else
  381. path:=current_module^.path^;
  382. end;
  383. Destructor TAsmList.Done;
  384. begin
  385. end;
  386. {*****************************************************************************
  387. Generate Assembler Files Main Procedure
  388. *****************************************************************************}
  389. Procedure GenerateAsm;
  390. var
  391. a : PAsmList;
  392. {$ifdef i386}
  393. {$ifndef NoAg386Bin}
  394. b : Pi386binasmlist;
  395. {$endif}
  396. {$endif}
  397. begin
  398. case aktoutputformat of
  399. as_none : ;
  400. {$ifdef i386}
  401. {$ifndef NoAg386Bin}
  402. as_i386_dbg,
  403. as_i386_coff,
  404. as_i386_pecoff :
  405. begin
  406. case aktoutputformat of
  407. as_i386_dbg :
  408. b:=new(pi386binasmlist,Init(og_dbg));
  409. as_i386_coff :
  410. b:=new(pi386binasmlist,Init(og_coff));
  411. as_i386_pecoff :
  412. b:=new(pi386binasmlist,Init(og_pecoff));
  413. end;
  414. b^.WriteBin;
  415. dispose(b,done);
  416. if assigned(current_module^.ppufilename) then
  417. begin
  418. if (cs_smartlink in aktmoduleswitches) then
  419. SynchronizeFileTime(current_module^.ppufilename^,current_module^.staticlibfilename^)
  420. else
  421. SynchronizeFileTime(current_module^.ppufilename^,current_module^.objfilename^);
  422. end;
  423. if assigned(current_module^.ppufilename) then
  424. SynchronizeFileTime(current_module^.ppufilename^,current_module^.objfilename^);
  425. exit;
  426. end;
  427. {$endif NoAg386Bin}
  428. {$ifndef NoAg386Att}
  429. as_i386_as,
  430. as_i386_as_aout,
  431. as_i386_asw :
  432. a:=new(pi386attasmlist,Init);
  433. {$endif NoAg386Att}
  434. {$ifndef NoAg386Nsm}
  435. as_i386_nasmcoff,
  436. as_i386_nasmelf,
  437. as_i386_nasmobj :
  438. a:=new(pi386nasmasmlist,Init);
  439. {$endif NoAg386Nsm}
  440. {$ifndef NoAg386Int}
  441. as_i386_tasm :
  442. a:=new(pi386intasmlist,Init);
  443. {$endif NoAg386Int}
  444. {$endif}
  445. {$ifdef m68k}
  446. {$ifndef NoAg68kGas}
  447. as_m68k_as,
  448. as_m68k_gas :
  449. a:=new(pm68kgasasmlist,Init);
  450. {$endif NoAg86KGas}
  451. {$ifndef NoAg68kMot}
  452. as_m68k_mot :
  453. a:=new(pm68kmotasmlist,Init);
  454. {$endif NoAg86kMot}
  455. {$ifndef NoAg68kMit}
  456. as_m68k_mit :
  457. a:=new(pm68kmitasmlist,Init);
  458. {$endif NoAg86KMot}
  459. {$ifndef NoAg68kMpw}
  460. as_m68k_mpw :
  461. a:=new(pm68kmpwasmlist,Init);
  462. {$endif NoAg68kMpw}
  463. {$endif}
  464. else
  465. {$ifdef TP}
  466. exit;
  467. {$else}
  468. Message(asmw_f_assembler_output_not_supported);
  469. {$endif}
  470. end;
  471. a^.AsmCreate;
  472. a^.WriteAsmList;
  473. a^.AsmClose;
  474. a^.DoAssemble;
  475. a^.synchronize;
  476. dispose(a,Done);
  477. end;
  478. Procedure OnlyAsm;
  479. var
  480. a : PAsmList;
  481. begin
  482. a:=new(pasmlist,Init);
  483. a^.DoAssemble;
  484. dispose(a,Done);
  485. end;
  486. end.
  487. {
  488. $Log$
  489. Revision 1.49 1999-06-28 16:02:29 peter
  490. * merged
  491. Revision 1.48.2.1 1999/06/28 15:55:39 peter
  492. * also search path if not found in utilsdirectory
  493. Revision 1.48 1999/05/27 19:44:03 peter
  494. * removed oldasm
  495. * plabel -> pasmlabel
  496. * -a switches to source writing automaticly
  497. * assembler readers OOPed
  498. * asmsymbol automaticly external
  499. * jumptables and other label fixes for asm readers
  500. Revision 1.47 1999/05/13 21:59:19 peter
  501. * removed oldppu code
  502. * warning if objpas is loaded from uses
  503. * first things for new deref writing
  504. Revision 1.46 1999/05/05 22:21:48 peter
  505. * updated messages
  506. Revision 1.45 1999/05/04 21:44:33 florian
  507. * changes to compile it with Delphi 4.0
  508. Revision 1.44 1999/05/02 23:28:42 peter
  509. * don't include ag386bin for oldasm
  510. Revision 1.43 1999/05/02 22:41:51 peter
  511. * moved section names to systems
  512. * fixed nasm,intel writer
  513. Revision 1.42 1999/05/01 13:24:00 peter
  514. * merged nasm compiler
  515. * old asm moved to oldasm/
  516. Revision 1.41 1999/03/24 23:16:42 peter
  517. * fixed bugs 212,222,225,227,229,231,233
  518. Revision 1.40 1999/03/18 20:30:44 peter
  519. + .a writer
  520. Revision 1.39 1999/03/01 15:43:48 peter
  521. * synchronize also the objfile for ag386bin
  522. Revision 1.38 1999/02/26 00:48:15 peter
  523. * assembler writers fixed for ag386bin
  524. Revision 1.37 1999/02/24 00:59:11 peter
  525. * small updates for ag386bin
  526. Revision 1.36 1999/02/22 02:15:01 peter
  527. * updates for ag386bin
  528. Revision 1.35 1999/02/17 10:16:26 peter
  529. * small fixes for the binary writer
  530. Revision 1.34 1999/01/10 15:37:52 peter
  531. * moved some tables from ra386*.pas -> i386.pas
  532. + start of coff writer
  533. * renamed asmutils unit to rautils
  534. Revision 1.33 1998/12/11 00:02:45 peter
  535. + globtype,tokens,version unit splitted from globals
  536. Revision 1.32 1998/11/06 09:46:46 pierre
  537. * assemble failure increments status errorcount again !!
  538. Revision 1.31 1998/10/26 22:23:28 peter
  539. + fixpath() has an extra option to allow a ./ as path
  540. Revision 1.30 1998/10/16 13:37:14 florian
  541. + switch -FD added to specify the path for utilities
  542. Revision 1.29 1998/10/15 16:19:42 peter
  543. * fixed asmsynchronize
  544. Revision 1.28 1998/10/14 15:56:43 pierre
  545. * all references to comp suppressed for m68k
  546. Revision 1.27 1998/10/13 16:50:01 pierre
  547. * undid some changes of Peter that made the compiler wrong
  548. for m68k (I had to reinsert some ifdefs)
  549. * removed several memory leaks under m68k
  550. * removed the meory leaks for assembler readers
  551. * cross compiling shoud work again better
  552. ( crosscompiling sysamiga works
  553. but as68k still complain about some code !)
  554. Revision 1.26 1998/10/13 13:10:11 peter
  555. * new style for m68k/i386 infos and enums
  556. Revision 1.25 1998/10/13 08:19:24 pierre
  557. + source_os is now set correctly for cross-processor compilers
  558. (tos contains all target_infos and
  559. we use CPU86 and CPU68 conditionnals to
  560. get the source operating system
  561. this only works if you do not undefine
  562. the source target !!)
  563. * several cg68k memory leaks fixed
  564. + started to change the code so that it should be possible to have
  565. a complete compiler (both for m68k and i386 !!)
  566. Revision 1.24 1998/10/08 23:28:50 peter
  567. * -vu shows unit info, -vt shows tried/used files
  568. Revision 1.23 1998/10/07 04:27:37 carl
  569. + MPW support
  570. Revision 1.22 1998/09/16 16:41:39 peter
  571. * merged fixes
  572. Revision 1.21.2.1 1998/09/16 16:11:38 peter
  573. * missing isendfile reset in .init
  574. Revision 1.21 1998/09/07 18:33:32 peter
  575. + smartlinking for win95 imports
  576. Revision 1.20 1998/09/04 17:34:20 pierre
  577. * bug with datalabel corrected
  578. + assembler errors better commented
  579. * one nested record crash removed
  580. Revision 1.19 1998/08/26 10:06:34 peter
  581. * reduce amount of asmfiles generated
  582. * no stabs are written in writefilelineinfo when debuginfo is off
  583. Revision 1.18 1998/08/21 14:08:39 pierre
  584. + TEST_FUNCRET now default (old code removed)
  585. works also for m68k (at least compiles)
  586. Revision 1.17 1998/08/17 09:17:43 peter
  587. * static/shared linking updates
  588. Revision 1.16 1998/08/14 21:56:30 peter
  589. * setting the outputfile using -o works now to create static libs
  590. Revision 1.15 1998/08/14 18:16:09 peter
  591. * return after a failed call will now add it to ppas
  592. Revision 1.14 1998/08/10 14:49:41 peter
  593. + localswitches, moduleswitches, globalswitches splitting
  594. Revision 1.13 1998/07/14 21:46:40 peter
  595. * updated messages file
  596. Revision 1.12 1998/07/08 14:58:34 daniel
  597. * First check if call to assembler is succesfull, then check it's exit code.
  598. This is more logical than first checking the exit code. For some mysterious
  599. reason this did not give problems on DOS & Linux. On OS/2 it did.
  600. Revision 1.11 1998/06/08 22:59:43 peter
  601. * smartlinking works for win32
  602. * some defines to exclude some compiler parts
  603. Revision 1.10 1998/06/04 23:51:33 peter
  604. * m68k compiles
  605. + .def file creation moved to gendef.pas so it could also be used
  606. for win32
  607. Revision 1.9 1998/05/23 01:21:01 peter
  608. + aktasmmode, aktoptprocessor, aktoutputformat
  609. + smartlink per module $SMARTLINK-/+ (like MMX) and moved to aktswitches
  610. + $LIBNAME to set the library name where the unit will be put in
  611. * splitted cgi386 a bit (codeseg to large for bp7)
  612. * nasm, tasm works again. nasm moved to ag386nsm.pas
  613. Revision 1.8 1998/05/11 13:07:53 peter
  614. + $ifdef NEWPPU for the new ppuformat
  615. + $define GDB not longer required
  616. * removed all warnings and stripped some log comments
  617. * no findfirst/findnext anymore to remove smartlink *.o files
  618. Revision 1.7 1998/05/07 00:17:00 peter
  619. * smartlinking for sets
  620. + consts labels are now concated/generated in hcodegen
  621. * moved some cpu code to cga and some none cpu depended code from cga
  622. to tree and hcodegen and cleanup of hcodegen
  623. * assembling .. output reduced for smartlinking ;)
  624. Revision 1.6 1998/05/04 17:54:24 peter
  625. + smartlinking works (only case jumptable left todo)
  626. * redesign of systems.pas to support assemblers and linkers
  627. + Unitname is now also in the PPU-file, increased version to 14
  628. Revision 1.5 1998/04/29 10:33:44 pierre
  629. + added some code for ansistring (not complete nor working yet)
  630. * corrected operator overloading
  631. * corrected nasm output
  632. + started inline procedures
  633. + added starstarn : use ** for exponentiation (^ gave problems)
  634. + started UseTokenInfo cond to get accurate positions
  635. Revision 1.4 1998/04/27 23:10:27 peter
  636. + new scanner
  637. * $makelib -> if smartlink
  638. * small filename fixes pmodule.setfilename
  639. * moved import from files.pas -> import.pas
  640. Revision 1.3 1998/04/10 14:41:43 peter
  641. * removed some Hints
  642. * small speed optimization for AsmLn
  643. Revision 1.2 1998/04/08 11:34:18 peter
  644. * nasm works (linux only tested)
  645. }