mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-11 15:26:04 +02:00
* A package now always has a filename, to fix PAckageRemoteArchive
git-svn-id: trunk@32759 -
This commit is contained in:
parent
d44100448c
commit
3f3c8197fb
@ -358,6 +358,8 @@ begin
|
|||||||
begin
|
begin
|
||||||
URI:=ParseURI(DownloadURL);
|
URI:=ParseURI(DownloadURL);
|
||||||
Result:=URI.Document;
|
Result:=URI.Document;
|
||||||
|
if Result='' then
|
||||||
|
Result:=ChangeFileExt(Name,'.zip');
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
Result:=FFileName;
|
Result:=FFileName;
|
||||||
|
@ -159,22 +159,13 @@ end;
|
|||||||
|
|
||||||
|
|
||||||
function PackageLocalArchive(APackage:TFPPackage): String;
|
function PackageLocalArchive(APackage:TFPPackage): String;
|
||||||
var
|
|
||||||
S: String;
|
|
||||||
begin
|
begin
|
||||||
if APackage.Name=CurrentDirPackageName then
|
if APackage.Name=CurrentDirPackageName then
|
||||||
Error(SErrNoPackageSpecified)
|
Error(SErrNoPackageSpecified)
|
||||||
else if APackage.Name=CmdLinePackageName then
|
else if APackage.Name=CmdLinePackageName then
|
||||||
Result:=APackage.LocalFileName
|
Result:=APackage.LocalFileName
|
||||||
else
|
else
|
||||||
begin
|
Result:=GlobalOptions.ArchivesDir+APackage.FileName;
|
||||||
S:=APackage.FileName;
|
|
||||||
if S='' then
|
|
||||||
begin
|
|
||||||
S:=ChangeFileExt(APackage.Name,'.zip');
|
|
||||||
end;
|
|
||||||
Result:=GlobalOptions.ArchivesDir+S;
|
|
||||||
end;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user