[oe] Subject: [PATCH] bitbake/fetch2: Fix refetch of local files when they are read only

Martin Jansa martin.jansa at gmail.com
Wed May 7 16:56:10 UTC 2014


On Wed, May 07, 2014 at 02:16:04PM +0100, Lewis, Nick wrote:
> From 280ff24f597e5cf663c76fa90250cce229c6aac9 Mon Sep 17 00:00:00 2001
> From: Nick Lewis <nick.lewis at usa.g4s.com>
> Date: Wed, 7 May 2014 14:02:25 +0100
> Subject: [PATCH] Fix refetch of local files when they are read only

This belong to bitbake-devel ML

> 
> Signed-off-by: Nick Lewis <nick.lewis at usa.g4s.com>
> ---
>  bitbake/lib/bb/fetch2/__init__.py | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/bitbake/lib/bb/fetch2/__init__.py b/bitbake/lib/bb/fetch2/__init__.py
> index 5a9c72f..f571fc4 100644
> --- a/bitbake/lib/bb/fetch2/__init__.py
> +++ b/bitbake/lib/bb/fetch2/__init__.py
> @@ -1251,7 +1251,7 @@ class FetchMethod(object):
>                          destdir = destdir.strip('/')
>                      if destdir != "." and not os.access("%s/%s" % (rootdir, destdir), os.F_OK):
>                          os.makedirs("%s/%s" % (rootdir, destdir))
> -                    cmd = 'cp -pPR %s %s/%s/' % (file, rootdir, destdir)
> +                    cmd = 'cp -fpPR %s %s/%s/' % (file, rootdir, destdir)
>                      #cmd = 'tar -cf - -C "%d" -ps . | tar -xf - -C "%s/%s/"' % (file, rootdir, destdir)
>                  else:
>                      # The "destdir" handling was specifically done for FILESPATH
> @@ -1261,7 +1261,7 @@ class FetchMethod(object):
>                      else:
>                         destdir = "."
>                      bb.utils.mkdirhier("%s/%s" % (rootdir, destdir))
> -                    cmd = 'cp %s %s/%s/' % (file, rootdir, destdir)
> +                    cmd = 'cp -f %s %s/%s/' % (file, rootdir, destdir)
> 
>          if not cmd:
>              return
> --
> 1.9.1
> 
> 
> Nick Lewis
> nick.lewis at usa.g4s.com
> +44 1684 277137
> www.g4stechnology.com
> New Challenge House, International Drive, Tewkesbury, Gloucestershire, GL20 8UQ, UK
> 
>  Please consider the environment before printing this email
> 
> 
> The details of this company are as follows:
> G4S Technology Limited, Registered Office: Challenge House, International Drive, Tewkesbury, Gloucestershire GL20 8UQ, Registered in England No. 2382338.
> 
> This communication may contain information which is confidential, personal and/or privileged.
> 
> It is for the exclusive use of the intended recipient(s).
> If you are not the intended recipient(s), please note that any distribution, forwarding, copying or use of this communication or the information in it is strictly prohibited.
> 
> Any personal views expressed in this e-mail are those of the individual sender and the company does not endorse or accept responsibility for them.
> 
> Prior to taking any action based upon this e-mail message, you should seek appropriate confirmation of its authenticity.
> 
> This e-mail has been scanned for all viruses by MessageLabs.
> -- 
> _______________________________________________
> Openembedded-devel mailing list
> Openembedded-devel at lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-devel

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa at gmail.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.openembedded.org/pipermail/openembedded-devel/attachments/20140507/fafcc18d/attachment-0002.sig>


More information about the Openembedded-devel mailing list