link.pas 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696
  1. {
  2. $Id$
  3. Copyright (c) 1998 by the FPC development team
  4. This unit handles the linker and binder calls for programs and
  5. libraries
  6. This program is free software; you can redistribute it and/or modify
  7. it under the terms of the GNU General Public License as published by
  8. the Free Software Foundation; either version 2 of the License, or
  9. (at your option) any later version.
  10. This program is distributed in the hope that it will be useful,
  11. but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. GNU General Public License for more details.
  14. You should have received a copy of the GNU General Public License
  15. along with this program; if not, write to the Free Software
  16. Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  17. ****************************************************************************
  18. }
  19. Unit link;
  20. Interface
  21. uses cobjects,files;
  22. Type
  23. TLinker = Object
  24. Glibc2,
  25. LinkToC, { Should we link to the C libs? }
  26. Strip : Boolean; { Strip symbols ? }
  27. ObjectFiles,
  28. SharedLibFiles,
  29. StaticLibFiles : TStringContainer;
  30. LibrarySearchPath, { Search path for libraries }
  31. LinkOptions : string; { Additional options to the linker }
  32. DynamicLinker : String[80]; { What Dynamic linker ? }
  33. LinkResName : String[32]; { Name of response file }
  34. { Methods }
  35. Constructor Init;
  36. Destructor Done;
  37. procedure AddModuleFiles(hp:pmodule);
  38. function FindObjectFile(s : string) : string;
  39. function FindLibraryFile(s:string;const ext:string) : string;
  40. Procedure AddObject(const S : String);
  41. Procedure AddStaticLibrary(const S : String);
  42. Procedure AddSharedLibrary(S : String);
  43. Function FindLinker:String; { Find linker, sets Name }
  44. Function DoExec(const command,para:string;info,useshell:boolean):boolean;
  45. Function WriteResponseFile:Boolean;
  46. Function MakeExecutable:boolean;
  47. Procedure MakeStaticLibrary(filescnt:longint);
  48. Procedure MakeSharedLibrary;
  49. end;
  50. PLinker=^TLinker;
  51. Var
  52. Linker : TLinker;
  53. Implementation
  54. uses
  55. globtype,systems,
  56. script,globals,verbose
  57. {$ifdef i386}
  58. ,win_targ
  59. {$endif}
  60. {$ifdef linux}
  61. ,linux
  62. {$endif}
  63. ,dos
  64. ;
  65. {$ifndef linux}
  66. Procedure Shell(command:string);
  67. { This is already defined in the linux.ppu for linux, need for the *
  68. expansion under linux }
  69. var
  70. comspec : string;
  71. begin
  72. comspec:=getenv('COMSPEC');
  73. Exec(comspec,' /C '+command);
  74. end;
  75. {$endif}
  76. Constructor TLinker.Init;
  77. begin
  78. ObjectFiles.Init_no_double;
  79. SharedLibFiles.Init_no_double;
  80. StaticLibFiles.Init_no_double;
  81. LinkToC:=False;
  82. Glibc2:=false;
  83. Strip:=false;
  84. LinkOptions:='';
  85. {$ifdef linux}
  86. { first try glibc2 }
  87. DynamicLinker:='/lib/ld-linux.so.2';
  88. if FileExists(DynamicLinker) then
  89. Glibc2:=true
  90. else
  91. DynamicLinker:='/lib/ld-linux.so.1';
  92. LibrarySearchPath:='/lib;/usr/lib';
  93. {$else}
  94. DynamicLinker:='';
  95. LibrarySearchPath:='';
  96. {$endif}
  97. LinkResName:='link.res';
  98. end;
  99. Destructor TLinker.Done;
  100. begin
  101. ObjectFiles.Done;
  102. SharedLibFiles.Done;
  103. StaticLibFiles.Done;
  104. end;
  105. procedure TLinker.AddModuleFiles(hp:pmodule);
  106. begin
  107. with hp^ do
  108. begin
  109. while not linkofiles.empty do
  110. AddObject(linkofiles.Get);
  111. while not linksharedlibs.empty do
  112. AddSharedLibrary(linksharedlibs.Get);
  113. while not linkstaticlibs.empty do
  114. AddStaticLibrary(linkstaticlibs.Get);
  115. end;
  116. end;
  117. var
  118. LastLDBin : string;
  119. Function TLinker.FindLinker:string;
  120. var
  121. ldfound : boolean;
  122. begin
  123. if LastLDBin='' then
  124. begin
  125. if utilsdirectory<>'' then
  126. begin
  127. LastLDBin:=Search(target_link.linkbin+source_os.exeext,
  128. utilsdirectory,ldfound)+target_link.linkbin+source_os.exeext;
  129. end
  130. else
  131. LastLDBin:=FindExe(target_link.linkbin,ldfound);
  132. if (not ldfound) and not(cs_link_extern in aktglobalswitches) then
  133. begin
  134. Message1(exec_w_linker_not_found,LastLDBin);
  135. aktglobalswitches:=aktglobalswitches+[cs_link_extern];
  136. end;
  137. if ldfound then
  138. Message1(exec_t_using_linker,LastLDBin);
  139. end;
  140. FindLinker:=LastLDBin;
  141. end;
  142. { searches an object file }
  143. function TLinker.FindObjectFile(s:string) : string;
  144. var
  145. found : boolean;
  146. begin
  147. if pos('.',s)=0 then
  148. s:=s+target_info.objext;
  149. s:=FixFileName(s);
  150. if FileExists(s) then
  151. begin
  152. Findobjectfile:=s;
  153. exit;
  154. end;
  155. findobjectfile:=search(s,'.;'+unitsearchpath+';'+exepath,found)+s;
  156. if not(cs_link_extern in aktglobalswitches) and (not found) then
  157. Message1(exec_w_objfile_not_found,s);
  158. end;
  159. { searches an library file }
  160. function TLinker.FindLibraryFile(s:string;const ext:string) : string;
  161. var
  162. found : boolean;
  163. begin
  164. if pos('.',s)=0 then
  165. s:=s+ext;
  166. if FileExists(s) then
  167. begin
  168. FindLibraryFile:=s;
  169. exit;
  170. end;
  171. findlibraryfile:=search(s,'.;'+librarysearchpath+';'+exepath,found)+s;
  172. if not(cs_link_extern in aktglobalswitches) and (not found) then
  173. Message1(exec_w_libfile_not_found,s);
  174. end;
  175. Procedure TLinker.AddObject(const S : String);
  176. begin
  177. ObjectFiles.Insert(FindObjectFile(s));
  178. end;
  179. Procedure TLinker.AddSharedLibrary(S:String);
  180. begin
  181. { remove prefix 'lib' }
  182. if Copy(s,1,length(target_os.libprefix))=target_os.libprefix then
  183. Delete(s,1,length(target_os.libprefix));
  184. { remove extension if any }
  185. if Copy(s,length(s)-length(target_os.sharedlibext)+1,length(target_os.sharedlibext))=target_os.sharedlibext then
  186. Delete(s,length(s)-length(target_os.sharedlibext)+1,length(target_os.sharedlibext)+1);
  187. { ready to be inserted }
  188. SharedLibFiles.Insert (S);
  189. end;
  190. Procedure TLinker.AddStaticLibrary(const S:String);
  191. begin
  192. StaticLibFiles.Insert(FindLibraryFile(s,target_os.staticlibext));
  193. end;
  194. Function TLinker.DoExec(const command,para:string;info,useshell:boolean):boolean;
  195. begin
  196. DoExec:=true;
  197. if not(cs_link_extern in aktglobalswitches) then
  198. begin
  199. swapvectors;
  200. if useshell then
  201. shell(command+' '+para)
  202. else
  203. exec(command,para);
  204. swapvectors;
  205. if (doserror<>0) then
  206. begin
  207. Message(exec_w_cant_call_linker);
  208. aktglobalswitches:=aktglobalswitches+[cs_link_extern];
  209. DoExec:=false;
  210. end
  211. else
  212. if (dosexitcode<>0) then
  213. begin
  214. Message(exec_w_error_while_linking);
  215. aktglobalswitches:=aktglobalswitches+[cs_link_extern];
  216. DoExec:=false;
  217. end;
  218. end;
  219. { Update asmres when externmode is set }
  220. if cs_link_extern in aktglobalswitches then
  221. begin
  222. if info then
  223. AsmRes.AddLinkCommand(Command,Para,current_module^.exefilename^)
  224. else
  225. AsmRes.AddLinkCommand(Command,Para,'');
  226. end;
  227. end;
  228. Function TLinker.WriteResponseFile : Boolean;
  229. Var
  230. LinkResponse : Text;
  231. i : longint;
  232. prtobj,s,s2 : string;
  233. found,
  234. linklibc : boolean;
  235. procedure WriteRes(const s:string);
  236. begin
  237. if s<>'' then
  238. WriteLn(Linkresponse,s);
  239. end;
  240. begin
  241. WriteResponseFile:=False;
  242. { set special options for some targets }
  243. linklibc:=SharedLibFiles.Find('c');
  244. prtobj:='prt0';
  245. case target_info.target of
  246. target_m68k_Palmos,
  247. target_i386_Win32 :
  248. begin
  249. if DLLsource then
  250. prtobj:='wdllprt0'
  251. else
  252. prtobj:='wprt0';
  253. end;
  254. target_m68k_linux,
  255. target_i386_linux :
  256. begin
  257. if cs_profile in aktmoduleswitches then
  258. begin
  259. prtobj:='gprt0';
  260. if not glibc2 then
  261. AddSharedLibrary('gmon');
  262. AddSharedLibrary('c');
  263. linklibc:=true;
  264. end
  265. else
  266. begin
  267. if linklibc then
  268. prtobj:='cprt0';
  269. end;
  270. end;
  271. end;
  272. { Fix command line options }
  273. If not SharedLibFiles.Empty then
  274. LinkOptions:='-dynamic-linker='+DynamicLinker+' '+LinkOptions;
  275. if Strip and not(cs_debuginfo in aktmoduleswitches) then
  276. LinkOptions:=LinkOptions+target_link.stripopt;
  277. { Open linkresponse and write header }
  278. assign(linkresponse,current_module^.outpath^+LinkResName);
  279. {$I-}
  280. rewrite(linkresponse);
  281. {$I+}
  282. if ioresult<>0 then
  283. exit;
  284. { Write library searchpath }
  285. S2:=LibrarySearchPath;
  286. Repeat
  287. i:=Pos(';',S2);
  288. If i=0 then
  289. i:=255;
  290. S:=Copy(S2,1,i-1);
  291. If S<>'' then
  292. WriteRes(target_link.libpathprefix+s+target_link.libpathsuffix);
  293. Delete (S2,1,i);
  294. until S2='';
  295. WriteRes(target_link.inputstart);
  296. { add objectfiles, start with prt0 always }
  297. if prtobj<>'' then
  298. WriteRes(FindObjectFile(prtobj));
  299. if linklibc then
  300. begin
  301. WriteRes(search('crti.o',librarysearchpath,found)+'crti.o');
  302. WriteRes(search('crtbegin.o',librarysearchpath,found)+'crtbegin.o');
  303. end;
  304. while not ObjectFiles.Empty do
  305. begin
  306. s:=ObjectFiles.Get;
  307. if s<>'' then
  308. WriteRes(s);
  309. end;
  310. if linklibc then
  311. begin
  312. WriteRes(search('crtend.o',librarysearchpath,found)+'crtend.o');
  313. WriteRes(search('crtn.o',librarysearchpath,found)+'crtn.o');
  314. end;
  315. { Write sharedlibraries like -l<lib> }
  316. While not SharedLibFiles.Empty do
  317. begin
  318. S:=SharedLibFiles.Get;
  319. if s<>'c' then
  320. begin
  321. i:=Pos(target_os.sharedlibext,S);
  322. if i>0 then
  323. Delete(S,i,255);
  324. WriteRes(target_link.libprefix+s);
  325. end
  326. else
  327. linklibc:=true;
  328. end;
  329. { be sure that libc is the last lib }
  330. if linklibc then
  331. WriteRes(target_link.libprefix+'c');
  332. WriteRes(target_link.inputend);
  333. { Write staticlibraries }
  334. if not StaticLibFiles.Empty then
  335. begin
  336. WriteRes(target_link.GroupStart);
  337. While not StaticLibFiles.Empty do
  338. begin
  339. S:=StaticLibFiles.Get;
  340. WriteRes(s)
  341. end;
  342. WriteRes(target_link.GroupEnd);
  343. end;
  344. { Close response }
  345. close(linkresponse);
  346. WriteResponseFile:=True;
  347. end;
  348. function TLinker.MakeExecutable:boolean;
  349. var
  350. bindbin : string[80];
  351. bindfound : boolean;
  352. s : string;
  353. success : boolean;
  354. ii : longint;
  355. begin
  356. {$ifdef linux}
  357. if LinkToC then
  358. begin
  359. AddObject('/usr/lib/crt0.o');
  360. AddObject('lprt');
  361. AddStaticLibrary('libc.a');
  362. AddStaticLibrary('libgcc.a');
  363. end;
  364. {$endif Linux}
  365. { Write used files and libraries }
  366. WriteResponseFile;
  367. { Call linker }
  368. if not(cs_link_extern in aktglobalswitches) then
  369. Message1(exec_i_linking,current_module^.exefilename^);
  370. s:=target_link.linkcmd;
  371. if DLLsource then
  372. Replace(s,'$EXE',current_module^.sharedlibfilename^)
  373. else
  374. Replace(s,'$EXE',current_module^.exefilename^);
  375. Replace(s,'$OPT',LinkOptions);
  376. Replace(s,'$RES',current_module^.outpath^+LinkResName);
  377. success:=DoExec(FindLinker,s,true,false);
  378. {Bind}
  379. if (target_link.bindbin[1]<>'') and
  380. ((target_info.target<>target_i386_win32) or bind_win32_dll) then
  381. for ii:=1 to target_link.binders do
  382. begin
  383. s:=target_link.bindcmd[ii];
  384. Replace(s,'$OPT',LinkOptions);
  385. Replace(s,'$RES',current_module^.outpath^+LinkResName);
  386. if DLLsource then
  387. Replace(s,'$EXE',current_module^.sharedlibfilename^)
  388. else
  389. Replace(s,'$EXE',current_module^.exefilename^);
  390. {Size of the heap when an EMX program runs in OS/2.}
  391. Replace(s,'$HEAPMB',tostr((maxheapsize+1048575) shr 20));
  392. {Size of the stack when an EMX program runs in OS/2.}
  393. Replace(s,'$STACKKB',tostr((stacksize+1023) shr 10));
  394. {When an EMX program runs in DOS, the heap and stack share the
  395. same memory pool. The heap grows upwards, the stack grows downwards.}
  396. Replace(s,'$DOSHEAPKB',tostr((stacksize+maxheapsize+1023) shr 10));
  397. if utilsdirectory<>'' then
  398. begin
  399. bindbin:=Search(target_link.bindbin[ii]+source_os.exeext,
  400. utilsdirectory,bindfound)+target_link.bindbin[ii]+source_os.exeext;
  401. end
  402. else
  403. bindbin:=FindExe(target_link.bindbin[ii],bindfound);
  404. if (not bindfound) and not (cs_link_extern in aktglobalswitches) then
  405. begin
  406. Message1(exec_w_binder_not_found,bindbin);
  407. aktglobalswitches:=aktglobalswitches+[cs_link_extern];
  408. end;
  409. DoExec(bindbin,s,false,false);
  410. end;
  411. { Post processor executable }
  412. {$ifdef i386}
  413. if (target_info.target=target_i386_Win32) and success and
  414. not(cs_link_extern in aktglobalswitches) then
  415. if DLLsource then
  416. win_targ.postprocessexecutable(current_module^.sharedlibfilename^)
  417. else
  418. win_targ.postprocessexecutable(current_module^.exefilename^);
  419. {$endif}
  420. {Remove ReponseFile}
  421. if (success) and not(cs_link_extern in aktglobalswitches) then
  422. RemoveFile(current_module^.outpath^+LinkResName);
  423. MakeExecutable:=success; { otherwise a recursive call to link method }
  424. end;
  425. Procedure TLinker.MakeStaticLibrary(filescnt:longint);
  426. {
  427. FilesCnt holds the amount of .o files created, if filescnt=0 then
  428. no smartlinking is used
  429. }
  430. var
  431. smartpath,
  432. s,
  433. arbin : string;
  434. arfound : boolean;
  435. cnt : longint;
  436. begin
  437. smartpath:=current_module^.path^+FixPath(FixFileName(current_module^.modulename^)+target_info.smartext,false);
  438. { find ar binary }
  439. if utilsdirectory<>'' then
  440. begin
  441. arbin:=Search(target_ar.arbin+source_os.exeext,
  442. utilsdirectory,arfound)+target_ar.arbin+source_os.exeext;
  443. end
  444. else
  445. arbin:=FindExe(target_ar.arbin,arfound);
  446. if (not arfound) and not(cs_link_extern in aktglobalswitches) then
  447. begin
  448. Message(exec_w_ar_not_found);
  449. aktglobalswitches:=aktglobalswitches+[cs_link_extern];
  450. end;
  451. s:=target_ar.arcmd;
  452. Replace(s,'$LIB',current_module^.staticlibfilename^);
  453. if filescnt=0 then
  454. Replace(s,'$FILES',current_module^.objfilename^)
  455. else
  456. Replace(s,'$FILES',FixFileName(smartpath+current_module^.asmprefix^+'*'+target_info.objext));
  457. DoExec(arbin,s,false,true);
  458. { Clean up }
  459. if not(cs_asm_leave in aktglobalswitches) and not(cs_link_extern in aktglobalswitches) then
  460. begin
  461. if filescnt=0 then
  462. RemoveFile(current_module^.objfilename^)
  463. else
  464. begin
  465. for cnt:=1 to filescnt do
  466. if not RemoveFile(FixFileName(smartpath+current_module^.asmprefix^+tostr(cnt)+target_info.objext)) then
  467. RemoveFile(FixFileName(smartpath+current_module^.asmprefix^+'e'+tostr(cnt)+target_info.objext));
  468. RemoveDir(smartpath);
  469. end;
  470. end;
  471. end;
  472. Procedure TLinker.MakeSharedLibrary;
  473. var
  474. s : string;
  475. begin
  476. s:=' -shared -o $LIB $FILES';
  477. Replace(s,'$LIB',current_module^.sharedlibfilename^);
  478. Replace(s,'$FILES',current_module^.objfilename^);
  479. if DoExec(FindLinker,s,false,false) then
  480. RemoveFile(current_module^.objfilename^);
  481. end;
  482. end.
  483. {
  484. $Log$
  485. Revision 1.43 1999-01-25 15:02:13 peter
  486. * link libc always as last
  487. Revision 1.42 1998/12/11 00:03:19 peter
  488. + globtype,tokens,version unit splitted from globals
  489. Revision 1.41 1998/12/01 23:39:46 pierre
  490. * postprocessexec for win32 changed
  491. Revision 1.40 1998/12/01 12:51:20 peter
  492. * fixed placing of ppas.sh and link.res when using -FE
  493. Revision 1.39 1998/11/30 13:26:23 pierre
  494. * the code for ordering the exported procs/vars was buggy
  495. + added -WB to force binding (Ozerski way of creating DLL)
  496. this is off by default as direct writing of .edata section seems
  497. OK
  498. Revision 1.38 1998/11/30 09:43:13 pierre
  499. * some range check bugs fixed (still not working !)
  500. + added DLL writing support for win32 (also accepts variables)
  501. + TempAnsi for code that could be used for Temporary ansi strings
  502. handling
  503. Revision 1.37 1998/10/26 22:23:31 peter
  504. + fixpath() has an extra option to allow a ./ as path
  505. Revision 1.36 1998/10/22 15:18:44 florian
  506. + switch -vx for win32 added
  507. Revision 1.35 1998/10/19 18:06:23 peter
  508. * use no_double
  509. Revision 1.34 1998/10/16 13:37:18 florian
  510. + switch -FD added to specify the path for utilities
  511. Revision 1.33 1998/10/14 13:38:22 peter
  512. * fixed path with staticlib/objects in ppufiles
  513. Revision 1.32 1998/10/14 11:03:55 daniel
  514. * Forgot to dereference a pointer.
  515. Revision 1.31 1998/10/14 11:01:21 daniel
  516. * Staticlibfilename no longer not include a path. Correction when calling
  517. ar.
  518. Revision 1.30 1998/10/13 13:10:18 peter
  519. * new style for m68k/i386 infos and enums
  520. Revision 1.29 1998/10/13 08:19:34 pierre
  521. + source_os is now set correctly for cross-processor compilers
  522. (tos contains all target_infos and
  523. we use CPU86 and CPU68 conditionnals to
  524. get the source operating system
  525. this only works if you do not undefine
  526. the source target !!)
  527. * several cg68k memory leaks fixed
  528. + started to change the code so that it should be possible to have
  529. a complete compiler (both for m68k and i386 !!)
  530. Revision 1.28 1998/10/08 23:28:56 peter
  531. * -vu shows unit info, -vt shows tried/used files
  532. Revision 1.27 1998/10/06 17:16:52 pierre
  533. * some memory leaks fixed (thanks to Peter for heaptrc !)
  534. Revision 1.26 1998/09/29 15:23:05 peter
  535. * remove also the end files for smartlinking
  536. Revision 1.25 1998/09/10 15:25:31 daniel
  537. + Added maxheapsize.
  538. * Corrected semi-bug in calling the assembler and the linker
  539. Revision 1.24 1998/09/07 18:32:45 peter
  540. * fixed for m68k
  541. Revision 1.23 1998/09/03 17:39:04 florian
  542. + better code for type conversation longint/dword to real type
  543. Revision 1.22 1998/09/01 09:01:00 peter
  544. + glibc2 support
  545. Revision 1.21 1998/08/31 12:26:26 peter
  546. * m68k and palmos updates from surebugfixes
  547. Revision 1.20 1998/08/19 10:06:14 peter
  548. * fixed filenames and removedir which supports slash at the end
  549. Revision 1.19 1998/08/17 09:17:47 peter
  550. * static/shared linking updates
  551. Revision 1.18 1998/08/14 21:56:34 peter
  552. * setting the outputfile using -o works now to create static libs
  553. Revision 1.17 1998/08/14 18:16:08 peter
  554. * return after a failed call will now add it to ppas
  555. Revision 1.16 1998/08/12 19:28:15 peter
  556. * better libc support
  557. Revision 1.15 1998/08/10 14:50:02 peter
  558. + localswitches, moduleswitches, globalswitches splitting
  559. Revision 1.14 1998/06/17 14:10:13 peter
  560. * small os2 fixes
  561. * fixed interdependent units with newppu (remake3 under linux works now)
  562. Revision 1.13 1998/06/08 22:59:46 peter
  563. * smartlinking works for win32
  564. * some defines to exclude some compiler parts
  565. Revision 1.12 1998/06/04 23:51:44 peter
  566. * m68k compiles
  567. + .def file creation moved to gendef.pas so it could also be used
  568. for win32
  569. Revision 1.11 1998/05/27 00:20:31 peter
  570. * some scanner optimizes
  571. * automaticly aout2exe for go32v1
  572. * fixed dynamiclinker option which was added at the wrong place
  573. Revision 1.10 1998/05/22 12:32:47 peter
  574. * fixed -L on the commandline, Dos commandline is only 128 bytes
  575. Revision 1.9 1998/05/12 10:46:59 peter
  576. * moved printstatus to verb_def
  577. + V_Normal which is between V_Error and V_Warning and doesn't have a
  578. prefix like error: warning: and is included in V_Default
  579. * fixed some messages
  580. * first time parameter scan is only for -v and -T
  581. - removed old style messages
  582. Revision 1.8 1998/05/11 13:07:54 peter
  583. + $ifdef NEWPPU for the new ppuformat
  584. + $define GDB not longer required
  585. * removed all warnings and stripped some log comments
  586. * no findfirst/findnext anymore to remove smartlink *.o files
  587. Revision 1.7 1998/05/08 09:21:20 michael
  588. * Added missing -Fl message to messages file.
  589. * Corrected mangling of file names when doing Linklib
  590. * -Fl now actually WORKS.
  591. * Librarysearchpath is now a field in linker object.
  592. Revision 1.6 1998/05/06 09:26:49 peter
  593. * fixed ld call with shell
  594. Revision 1.4 1998/05/04 17:54:25 peter
  595. + smartlinking works (only case jumptable left todo)
  596. * redesign of systems.pas to support assemblers and linkers
  597. + Unitname is now also in the PPU-file, increased version to 14
  598. Revision 1.3 1998/04/16 10:54:30 daniel
  599. * Fixed linking for OS/2.
  600. }