mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-14 22:09:32 +02:00
* fixed -L on the commandline, Dos commandline is only 128 bytes
This commit is contained in:
parent
19a1443d6e
commit
cfa06433c6
@ -255,7 +255,7 @@ Function TLinker.WriteResponseFile : Boolean;
|
|||||||
Var
|
Var
|
||||||
LinkResponse : Text;
|
LinkResponse : Text;
|
||||||
i : longint;
|
i : longint;
|
||||||
prtobj,s : string;
|
prtobj,s,s2 : string;
|
||||||
begin
|
begin
|
||||||
{ Open linkresponse and write header }
|
{ Open linkresponse and write header }
|
||||||
assign(linkresponse,inputdir+LinkResName);
|
assign(linkresponse,inputdir+LinkResName);
|
||||||
@ -275,8 +275,19 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
writeln(linkresponse,target_link.inputstart);
|
{ Add library searchpath }
|
||||||
|
S2:=LibrarySearchPath;
|
||||||
|
Repeat
|
||||||
|
i:=Pos(';',S2);
|
||||||
|
If i=0 then
|
||||||
|
i:=255;
|
||||||
|
S:=Copy(S2,1,i-1);
|
||||||
|
If S<>'' then
|
||||||
|
WriteLn(linkresponse,target_link.libpathprefix+s+target_link.libpathsuffix);
|
||||||
|
Delete (S2,1,i);
|
||||||
|
until S2='';
|
||||||
|
|
||||||
|
writeln(linkresponse,target_link.inputstart);
|
||||||
{ add objectfiles, start with prt0 always }
|
{ add objectfiles, start with prt0 always }
|
||||||
if prtobj<>'' then
|
if prtobj<>'' then
|
||||||
Writeln(linkresponse,FindObjectFile(prtobj));
|
Writeln(linkresponse,FindObjectFile(prtobj));
|
||||||
@ -286,7 +297,6 @@ begin
|
|||||||
if s<>'' then
|
if s<>'' then
|
||||||
Writeln(linkresponse,s);
|
Writeln(linkresponse,s);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{ Write sharedlibraries like -l<lib> }
|
{ Write sharedlibraries like -l<lib> }
|
||||||
While not SharedLibFiles.Empty do
|
While not SharedLibFiles.Empty do
|
||||||
begin
|
begin
|
||||||
@ -296,7 +306,6 @@ begin
|
|||||||
Delete(S,i,255);
|
Delete(S,i,255);
|
||||||
writeln(linkresponse,target_link.libprefix+s);
|
writeln(linkresponse,target_link.libprefix+s);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
writeln(linkresponse,target_link.inputend);
|
writeln(linkresponse,target_link.inputend);
|
||||||
|
|
||||||
{ Write staticlibraries }
|
{ Write staticlibraries }
|
||||||
@ -342,20 +351,6 @@ begin
|
|||||||
if Strip then
|
if Strip then
|
||||||
LinkOptions:=LinkOptions+target_link.stripopt;
|
LinkOptions:=LinkOptions+target_link.stripopt;
|
||||||
|
|
||||||
{ Add library searchpath to the commandline }
|
|
||||||
|
|
||||||
S2:=LibrarySearchPath;
|
|
||||||
Repeat
|
|
||||||
i:=Pos(';',S2);
|
|
||||||
If i=0 then
|
|
||||||
i:=255;
|
|
||||||
S:=Copy(S2,1,i-1);
|
|
||||||
If S<>'' then
|
|
||||||
LinkOptions:=LinkOptions+' -L'+s;
|
|
||||||
Delete (S2,1,i);
|
|
||||||
until S2='';
|
|
||||||
|
|
||||||
|
|
||||||
{ Write used files and libraries }
|
{ Write used files and libraries }
|
||||||
WriteResponseFile;
|
WriteResponseFile;
|
||||||
|
|
||||||
@ -443,7 +438,10 @@ end;
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.9 1998-05-12 10:46:59 peter
|
Revision 1.10 1998-05-22 12:32:47 peter
|
||||||
|
* fixed -L on the commandline, Dos commandline is only 128 bytes
|
||||||
|
|
||||||
|
Revision 1.9 1998/05/12 10:46:59 peter
|
||||||
* moved printstatus to verb_def
|
* moved printstatus to verb_def
|
||||||
+ V_Normal which is between V_Error and V_Warning and doesn't have a
|
+ V_Normal which is between V_Error and V_Warning and doesn't have a
|
||||||
prefix like error: warning: and is included in V_Default
|
prefix like error: warning: and is included in V_Default
|
||||||
|
@ -78,10 +78,12 @@ unit systems;
|
|||||||
linkbin : string[8];
|
linkbin : string[8];
|
||||||
linkcmd : string[50];
|
linkcmd : string[50];
|
||||||
stripopt : string[2];
|
stripopt : string[2];
|
||||||
groupstart,
|
libpathprefix : string[12];
|
||||||
groupend,
|
libpathsuffix : string[2];
|
||||||
inputstart,
|
groupstart : string[8];
|
||||||
inputend : string[8];
|
groupend : string[2];
|
||||||
|
inputstart : string[8];
|
||||||
|
inputend : string[2];
|
||||||
libprefix : string[2];
|
libprefix : string[2];
|
||||||
end;
|
end;
|
||||||
|
|
||||||
@ -279,6 +281,8 @@ unit systems;
|
|||||||
linkbin : 'ld';
|
linkbin : 'ld';
|
||||||
linkcmd : '$OPT -o $EXE $RES';
|
linkcmd : '$OPT -o $EXE $RES';
|
||||||
stripopt : '-s';
|
stripopt : '-s';
|
||||||
|
libpathprefix : 'SEARCH_DIR(';
|
||||||
|
libpathsuffix : ')';
|
||||||
groupstart : 'GROUP(';
|
groupstart : 'GROUP(';
|
||||||
groupend : ')';
|
groupend : ')';
|
||||||
inputstart : 'INPUT(';
|
inputstart : 'INPUT(';
|
||||||
@ -290,6 +294,8 @@ unit systems;
|
|||||||
linkbin : 'ld';
|
linkbin : 'ld';
|
||||||
linkcmd : '-oformat coff-go32 $OPT -o $EXE @$RES';
|
linkcmd : '-oformat coff-go32 $OPT -o $EXE @$RES';
|
||||||
stripopt : '-s';
|
stripopt : '-s';
|
||||||
|
libpathprefix : '-L';
|
||||||
|
libpathsuffix : '';
|
||||||
groupstart : '-(';
|
groupstart : '-(';
|
||||||
groupend : '-)';
|
groupend : '-)';
|
||||||
inputstart : '';
|
inputstart : '';
|
||||||
@ -300,6 +306,8 @@ unit systems;
|
|||||||
linkbin : 'ld';
|
linkbin : 'ld';
|
||||||
linkcmd : '-oformat coff-go32-exe $OPT -o $EXE @$RES';
|
linkcmd : '-oformat coff-go32-exe $OPT -o $EXE @$RES';
|
||||||
stripopt : '-s';
|
stripopt : '-s';
|
||||||
|
libpathprefix : '-L';
|
||||||
|
libpathsuffix : '';
|
||||||
groupstart : '-(';
|
groupstart : '-(';
|
||||||
groupend : '-)';
|
groupend : '-)';
|
||||||
inputstart : '';
|
inputstart : '';
|
||||||
@ -310,6 +318,8 @@ unit systems;
|
|||||||
linkbin : 'ldw';
|
linkbin : 'ldw';
|
||||||
linkcmd : '$OPT -o $EXE $RES';
|
linkcmd : '$OPT -o $EXE $RES';
|
||||||
stripopt : '-s';
|
stripopt : '-s';
|
||||||
|
libpathprefix : 'SEARCH_DIR(';
|
||||||
|
libpathsuffix : ')';
|
||||||
groupstart : 'GROUP(';
|
groupstart : 'GROUP(';
|
||||||
groupend : ')';
|
groupend : ')';
|
||||||
inputstart : 'INPUT(';
|
inputstart : 'INPUT(';
|
||||||
@ -320,6 +330,8 @@ unit systems;
|
|||||||
linkbin : 'ld';
|
linkbin : 'ld';
|
||||||
linkcmd : '-o $EXE @$RES';
|
linkcmd : '-o $EXE @$RES';
|
||||||
stripopt : '-s';
|
stripopt : '-s';
|
||||||
|
libpathprefix : '-L';
|
||||||
|
libpathsuffix : '';
|
||||||
groupstart : '-(';
|
groupstart : '-(';
|
||||||
groupend : '-)';
|
groupend : '-)';
|
||||||
inputstart : '';
|
inputstart : '';
|
||||||
@ -519,7 +531,10 @@ begin
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.10 1998-05-11 13:07:58 peter
|
Revision 1.11 1998-05-22 12:32:49 peter
|
||||||
|
* fixed -L on the commandline, Dos commandline is only 128 bytes
|
||||||
|
|
||||||
|
Revision 1.10 1998/05/11 13:07:58 peter
|
||||||
+ $ifdef NEWPPU for the new ppuformat
|
+ $ifdef NEWPPU for the new ppuformat
|
||||||
+ $define GDB not longer required
|
+ $define GDB not longer required
|
||||||
* removed all warnings and stripped some log comments
|
* removed all warnings and stripped some log comments
|
||||||
|
Loading…
Reference in New Issue
Block a user