mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-20 07:19:27 +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
|
||||
URI:=ParseURI(DownloadURL);
|
||||
Result:=URI.Document;
|
||||
if Result='' then
|
||||
Result:=ChangeFileExt(Name,'.zip');
|
||||
end
|
||||
else
|
||||
Result:=FFileName;
|
||||
|
@ -159,22 +159,13 @@ end;
|
||||
|
||||
|
||||
function PackageLocalArchive(APackage:TFPPackage): String;
|
||||
var
|
||||
S: String;
|
||||
begin
|
||||
if APackage.Name=CurrentDirPackageName then
|
||||
Error(SErrNoPackageSpecified)
|
||||
else if APackage.Name=CmdLinePackageName then
|
||||
Result:=APackage.LocalFileName
|
||||
else
|
||||
begin
|
||||
S:=APackage.FileName;
|
||||
if S='' then
|
||||
begin
|
||||
S:=ChangeFileExt(APackage.Name,'.zip');
|
||||
end;
|
||||
Result:=GlobalOptions.ArchivesDir+S;
|
||||
end;
|
||||
Result:=GlobalOptions.ArchivesDir+APackage.FileName;
|
||||
end;
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user