mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-14 17:21:20 +02:00
* always surround ld link.res SEARCH_DIR() arguments with double quotes,
rather than with single/double quotes depending on the target platform (ld only supports double quotes), and rather than only quoting when necessary (wastes time since quotes are always allowed, and double quotes inside a directory name cannot be escaped for ld; they are simply not supported by the program) (mantis #22059, follow-up to r21069 and r21208) git-svn-id: trunk@21343 -
This commit is contained in:
parent
ccf895af5a
commit
c27f9da1b2
@ -163,7 +163,7 @@ begin
|
||||
while assigned(HPath) do
|
||||
begin
|
||||
if assumebinutils then
|
||||
Add('SEARCH_DIR('+maybequoted(HPath.Str)+')')
|
||||
Add('SEARCH_DIR("'+HPath.Str+'")')
|
||||
else
|
||||
Add('-L'+HPath.Str);
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
@ -172,7 +172,7 @@ begin
|
||||
while assigned(HPath) do
|
||||
begin
|
||||
if assumebinutils then
|
||||
Add('SEARCH_DIR('+maybequoted(HPath.Str)+')')
|
||||
Add('SEARCH_DIR("'+HPath.Str+'")')
|
||||
else
|
||||
Add('-L'+HPath.Str);
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
|
@ -118,7 +118,7 @@ begin
|
||||
begin
|
||||
s:=HPath.Str;
|
||||
if s<>'' then
|
||||
LinkRes.Add('SEARCH_DIR('+Unix2AmigaPath(maybequoted(s))+')');
|
||||
LinkRes.Add('SEARCH_DIR("'+Unix2AmigaPath(s)+'")');
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
end;
|
||||
|
||||
|
@ -424,7 +424,7 @@ begin
|
||||
if LdSupportsNoResponseFile then
|
||||
LinkRes.Add('-L'+HPath.Str)
|
||||
else
|
||||
LinkRes.Add('SEARCH_DIR('+maybequoted(HPath.Str)+')');
|
||||
LinkRes.Add('SEARCH_DIR("'+HPath.Str+'")');
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
end;
|
||||
HPath:=TCmdStrListItem(LibrarySearchPath.First);
|
||||
@ -433,7 +433,7 @@ begin
|
||||
if LdSupportsNoResponseFile then
|
||||
LinkRes.Add('-L'+HPath.Str)
|
||||
else
|
||||
LinkRes.Add('SEARCH_DIR('+maybequoted(HPath.Str)+')');
|
||||
LinkRes.Add('SEARCH_DIR("'+HPath.Str+'")');
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
end;
|
||||
|
||||
|
@ -113,7 +113,7 @@ begin
|
||||
begin
|
||||
s:=HPath.Str;
|
||||
if s<>'' then
|
||||
LinkRes.Add('SEARCH_DIR('+(maybequoted(s))+')');
|
||||
LinkRes.Add('SEARCH_DIR("'+s+'")');
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
end;
|
||||
|
||||
|
@ -107,7 +107,7 @@ begin
|
||||
begin
|
||||
s:=HPath.Str;
|
||||
if s<>'' then
|
||||
LinkRes.Add('SEARCH_DIR('+(maybequoted(s))+')');
|
||||
LinkRes.Add('SEARCH_DIR("'+s+'")');
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
end;
|
||||
|
||||
|
@ -353,13 +353,13 @@ begin
|
||||
HPath:=TCmdStrListItem(current_module.locallibrarysearchpath.First);
|
||||
while assigned(HPath) do
|
||||
begin
|
||||
Add('SEARCH_DIR('+maybequoted(HPath.Str)+')');
|
||||
Add('SEARCH_DIR("'+HPath.Str+'")');
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
end;
|
||||
HPath:=TCmdStrListItem(LibrarySearchPath.First);
|
||||
while assigned(HPath) do
|
||||
begin
|
||||
Add('SEARCH_DIR('+maybequoted(HPath.Str)+')');
|
||||
Add('SEARCH_DIR("'+HPath.Str+'")');
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
end;
|
||||
|
||||
|
@ -104,7 +104,7 @@ begin
|
||||
begin
|
||||
s:=HPath.Str;
|
||||
if s<>'' then
|
||||
LinkRes.Add('SEARCH_DIR('+Unix2AmigaPath(maybequoted(s))+')');
|
||||
LinkRes.Add('SEARCH_DIR("'+Unix2AmigaPath(s)+'")');
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
end;
|
||||
|
||||
|
@ -122,7 +122,7 @@ begin
|
||||
begin
|
||||
s:=HPath.Str;
|
||||
if s<>'' then
|
||||
LinkRes.Add('SEARCH_DIR('+(maybequoted(s))+')');
|
||||
LinkRes.Add('SEARCH_DIR("'+s+'")');
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
end;
|
||||
|
||||
|
@ -224,13 +224,13 @@ begin
|
||||
HPath:=TCmdStrListItem(current_module.locallibrarysearchpath.First);
|
||||
while assigned(HPath) do
|
||||
begin
|
||||
LinkRes.Add('SEARCH_DIR('+maybequoted(HPath.Str)+')');
|
||||
LinkRes.Add('SEARCH_DIR("'+HPath.Str+'")');
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
end;
|
||||
HPath:=TCmdStrListItem(LibrarySearchPath.First);
|
||||
while assigned(HPath) do
|
||||
begin
|
||||
LinkRes.Add('SEARCH_DIR('+maybequoted(HPath.Str)+')');
|
||||
LinkRes.Add('SEARCH_DIR("'+HPath.Str+'")');
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
end;
|
||||
|
||||
|
@ -99,7 +99,7 @@ begin
|
||||
begin
|
||||
s:=HPath.Str;
|
||||
if s<>'' then
|
||||
LinkRes.Add('SEARCH_DIR('+(maybequoted(s))+')');
|
||||
LinkRes.Add('SEARCH_DIR("'+s+'")');
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
end;
|
||||
|
||||
|
@ -1200,13 +1200,13 @@ implementation
|
||||
HPath:=TCmdStrListItem(current_module.locallibrarysearchpath.First);
|
||||
while assigned(HPath) do
|
||||
begin
|
||||
Add('SEARCH_DIR('+MaybeQuoted(HPath.Str)+')');
|
||||
Add('SEARCH_DIR("'+HPath.Str+'")');
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
end;
|
||||
HPath:=TCmdStrListItem(LibrarySearchPath.First);
|
||||
while assigned(HPath) do
|
||||
begin
|
||||
Add('SEARCH_DIR('+MaybeQuoted(HPath.Str)+')');
|
||||
Add('SEARCH_DIR("'+HPath.Str+'")');
|
||||
HPath:=TCmdStrListItem(HPath.Next);
|
||||
end;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user