summaryrefslogtreecommitdiff
path: root/helpers
diff options
context:
space:
mode:
authorDaniel Baumann <daniel@debian.org>2008-06-09 10:04:44 +0200
committerDaniel Baumann <daniel@debian.org>2011-03-09 19:03:34 +0100
commit4c4e58ca20774c45b4e4d6dd42267259d25141ee (patch)
tree7afdc42abae371c3a1c18e5dc714b9eb104d6995 /helpers
parent11883b9f466244e7af0a79c4f4f73eee60ba25d4 (diff)
downloadlive-build-4c4e58ca20774c45b4e4d6dd42267259d25141ee.zip
live-build-4c4e58ca20774c45b4e4d6dd42267259d25141ee.tar.gz
Only saving source indices to indices cache if source indices are actually existing, thanks to Thanatermesis <thanatermesis.ecvs@elivecd.net>.
Diffstat (limited to 'helpers')
-rwxr-xr-xhelpers/lh_chroot_sources13
1 files changed, 11 insertions, 2 deletions
diff --git a/helpers/lh_chroot_sources b/helpers/lh_chroot_sources
index 154a224..677b50f 100755
--- a/helpers/lh_chroot_sources
+++ b/helpers/lh_chroot_sources
@@ -200,10 +200,19 @@ case "${1}" in
cp -f chroot/etc/apt/trusted.gpg* cache/indices_bootstrap
cp -f chroot/var/cache/apt/pkgcache.bin cache/indices_bootstrap
- cp -f chroot/var/cache/apt/srcpkgcache.bin cache/indices_bootstrap
+
+ if ls chroot/var/cache/apt/srcpkgcache.bin > /dev/null 2>&1
+ then
+ cp -f chroot/var/cache/apt/srcpkgcache.bin cache/indices_bootstrap
+ fi
cp -f chroot/var/lib/apt/lists/*_Packages cache/indices_bootstrap
- cp -f chroot/var/lib/apt/lists/*_Sources cache/indices_bootstrap
+
+ if ls chroot/var/lib/apt/lists/*_Sources > /dev/null 2>&1
+ then
+ cp -f chroot/var/lib/apt/lists/*_Sources cache/indices_bootstrap
+ fi
+
cp -f chroot/var/lib/apt/*_Release* cache/indices_bootstrap
fi
fi