summaryrefslogtreecommitdiff
path: root/apt-pkg
diff options
context:
space:
mode:
Diffstat (limited to 'apt-pkg')
-rw-r--r--apt-pkg/acquire-item.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/apt-pkg/acquire-item.cc b/apt-pkg/acquire-item.cc
index bf19290c6..6227888b6 100644
--- a/apt-pkg/acquire-item.cc
+++ b/apt-pkg/acquire-item.cc
@@ -144,7 +144,10 @@ pkgAcqIndex::pkgAcqIndex(pkgAcquire *Owner,
DestFile += URItoFileName(URI);
// Create the item
- Desc.URI = URI + ".bz2";
+ if(FileExists("/usr/bin/bzip2"))
+ Desc.URI = URI + ".bz2";
+ else
+ Desc.URI = URI + ".gz";
Desc.Description = URIDesc;
Desc.Owner = this;
Desc.ShortDesc = ShortDesc;