mirror of
				https://gitlab.com/freepascal.org/fpc/source.git
				synced 2025-11-04 16:39:24 +01:00 
			
		
		
		
	* static linking fixes
This commit is contained in:
		
							parent
							
								
									3c6d74c4d9
								
							
						
					
					
						commit
						f57803d67a
					
				@ -138,7 +138,8 @@ begin
 | 
			
		||||
  if not StaticLibFiles.Empty then
 | 
			
		||||
   begin
 | 
			
		||||
    { vlink doesn't need, and doesn't support GROUP }
 | 
			
		||||
     if (cs_link_on_target in aktglobalswitches) then begin
 | 
			
		||||
    if (cs_link_on_target in aktglobalswitches) then 
 | 
			
		||||
     begin
 | 
			
		||||
      LinkRes.Add(')');
 | 
			
		||||
      LinkRes.Add('GROUP(');
 | 
			
		||||
     end;
 | 
			
		||||
@ -148,6 +149,9 @@ begin
 | 
			
		||||
      LinkRes.AddFileName(maybequoted(s));
 | 
			
		||||
     end;
 | 
			
		||||
   end;
 | 
			
		||||
  
 | 
			
		||||
  if (cs_link_on_target in aktglobalswitches) then 
 | 
			
		||||
   begin
 | 
			
		||||
    LinkRes.Add(')');
 | 
			
		||||
 | 
			
		||||
    { Write sharedlibraries like -l<lib>, also add the needed dynamic linker
 | 
			
		||||
@ -175,6 +179,17 @@ begin
 | 
			
		||||
      LinkRes.Add('-lc');
 | 
			
		||||
      LinkRes.Add('-lgcc');
 | 
			
		||||
     end;
 | 
			
		||||
   end
 | 
			
		||||
  else
 | 
			
		||||
   begin
 | 
			
		||||
    while not SharedLibFiles.Empty do
 | 
			
		||||
     begin
 | 
			
		||||
      S:=SharedLibFiles.GetFirst;
 | 
			
		||||
      LinkRes.Add('lib'+s+target_info.staticlibext);
 | 
			
		||||
     end;
 | 
			
		||||
    LinkRes.Add(')');    
 | 
			
		||||
   end;
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
{ Write and Close response }
 | 
			
		||||
  linkres.writetodisk;
 | 
			
		||||
@ -255,7 +270,10 @@ initialization
 | 
			
		||||
end.
 | 
			
		||||
{
 | 
			
		||||
  $Log$
 | 
			
		||||
  Revision 1.13  2005-02-14 17:13:10  peter
 | 
			
		||||
  Revision 1.14  2005-04-25 15:58:59  karoly
 | 
			
		||||
    * static linking fixes
 | 
			
		||||
 | 
			
		||||
  Revision 1.13  2005/02/14 17:13:10  peter
 | 
			
		||||
    * truncate log
 | 
			
		||||
 | 
			
		||||
  Revision 1.12  2005/02/11 07:23:22  karoly
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user