From bb4b5c3c00c8d5ac05cb419e3b4a1015f14dd148 Mon Sep 17 00:00:00 2001 From: Pierre Labastie Date: Fri, 8 Nov 2013 22:10:11 +0000 Subject: [PATCH] Permission problem again --- common/libs/func_download_pkgs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/common/libs/func_download_pkgs b/common/libs/func_download_pkgs index 10661db..d441005 100644 --- a/common/libs/func_download_pkgs +++ b/common/libs/func_download_pkgs @@ -26,9 +26,11 @@ get_sources() { # Download file, write name to MISSING_FILES.DMP if # Housekeeping [[ ! -d $BUILDDIR/sources ]] && mkdir $BUILDDIR/sources cd $BUILDDIR/sources - [[ -f MD5SUMS ]] && rm MD5SUMS - [[ -f MISSING_FILES.DMP ]] && rm MISSING_FILES.DMP - [[ -f urls.lst ]] && rm urls.lst + # If using CLFS, /sources is writable by all, but with sticky bit, + # and user does not hold MD5SUMS nor the other files, so use sudo + [[ -f MD5SUMS ]] && sudo rm MD5SUMS + [[ -f MISSING_FILES.DMP ]] && sudo rm MISSING_FILES.DMP + [[ -f urls.lst ]] && sudo rm urls.lst # Generate URLs file create_urls