Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
To: openembedded-core@lists.openembedded.org
Cc: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Subject: [PATCH] opkg-utils: ignore packages disapperaring filelist generation
Date: Thu, 25 Aug 2011 17:52:47 +0400	[thread overview]
Message-ID: <1314280367-22179-1-git-send-email-dbaryshkov@gmail.com> (raw)

Package files disappearing during index generation don't cause a fatal
error. Make package file disappearing during filelist generation also
a non-fatal error.

Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
---
 .../opkg-utils/no-ioerror-during-filelist.patch    |   31 ++++++++++++++++++++
 meta/recipes-devtools/opkg-utils/opkg-utils_svn.bb |    3 +-
 2 files changed, 33 insertions(+), 1 deletions(-)
 create mode 100644 meta/recipes-devtools/opkg-utils/no-ioerror-during-filelist.patch

diff --git a/meta/recipes-devtools/opkg-utils/no-ioerror-during-filelist.patch b/meta/recipes-devtools/opkg-utils/no-ioerror-during-filelist.patch
new file mode 100644
index 0000000..dc85cb6
--- /dev/null
+++ b/meta/recipes-devtools/opkg-utils/no-ioerror-during-filelist.patch
@@ -0,0 +1,31 @@
+From: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
+Subject: Ignore IOError errors while populating filelist
+Upstream-Status: Pending/Not-Applicable
+
+While populating Packages.filelist there is a possibility that the package file
+will disappear while reading. So ignore errors during filelist generation.
+
+
+Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
+
+Index: opkg-utils/opkg-make-index
+===================================================================
+--- opkg-utils.orig/opkg-make-index	2011-08-25 16:45:41.000000000 +0400
++++ opkg-utils/opkg-make-index	2011-08-25 17:38:57.000000000 +0400
+@@ -197,7 +197,15 @@
+ names = packages.packages.keys()
+ names.sort()
+ for name in names:
+-     for fn in packages[name].get_file_list():
++     try:
++          fnlist = packages[name].get_file_list()
++     except OSError, e:
++          sys.stderr.write(e)
++          continue
++     except IOError, e:
++          sys.stderr.write(e)
++          continue
++     for fn in fnlist:
+           (h,t) = os.path.split(fn)
+           if not t: continue
+           if not files.has_key(t): files[t] = name+':'+fn
diff --git a/meta/recipes-devtools/opkg-utils/opkg-utils_svn.bb b/meta/recipes-devtools/opkg-utils/opkg-utils_svn.bb
index fd2b5e6..7659465 100644
--- a/meta/recipes-devtools/opkg-utils/opkg-utils_svn.bb
+++ b/meta/recipes-devtools/opkg-utils/opkg-utils_svn.bb
@@ -8,12 +8,13 @@ RDEPENDS_${PN} = "python"
 RDEPENDS_${PN}_virtclass-native = ""
 SRCREV = "4747"
 PV = "0.1.8+svnr${SRCPV}"
-PR = "r4"
+PR = "r5"
 
 SRC_URI = "svn://svn.openmoko.org/trunk/src/host/;module=opkg-utils;proto=http \
            file://index-ignore-filenotfound.patch \
            file://mtime-int.patch \
            file://add-license-field.patch \
+           file://no-ioerror-during-filelist.patch \
            "
 
 S = "${WORKDIR}/opkg-utils"
-- 
1.7.2.5




             reply	other threads:[~2011-08-25 13:57 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-25 13:52 Dmitry Eremin-Solenikov [this message]
2011-08-26  9:26 ` [PATCH] opkg-utils: ignore packages disapperaring filelist generation Dmitry Eremin-Solenikov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1314280367-22179-1-git-send-email-dbaryshkov@gmail.com \
    --to=dbaryshkov@gmail.com \
    --cc=openembedded-core@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox