From: Andre McCurdy <armccurdy@gmail.com>
To: openembedded-core@lists.openembedded.org
Subject: [PATCH] sstate.bbclass: remove redundant cd and mkdir commands
Date: Tue, 14 Jul 2015 17:54:42 -0700 [thread overview]
Message-ID: <1436921682-5965-1-git-send-email-armccurdy@gmail.com> (raw)
Update sstate_create_package and sstate_unpack_package to remove
redundant initial mkdir and cd commands. The working directory is
now setup correctly before the shell functions are called.
Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
---
meta/classes/sstate.bbclass | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/meta/classes/sstate.bbclass b/meta/classes/sstate.bbclass
index 5b64b49..2a050dc 100644
--- a/meta/classes/sstate.bbclass
+++ b/meta/classes/sstate.bbclass
@@ -646,10 +646,9 @@ python sstate_task_postfunc () {
#
# Shell function to generate a sstate package from a directory
-# set as SSTATE_BUILDDIR
+# set as SSTATE_BUILDDIR. Will be run from within SSTATE_BUILDDIR.
#
sstate_create_package () {
- cd ${SSTATE_BUILDDIR}
TFILE=`mktemp ${SSTATE_PKG}.XXXXXXXX`
# Need to handle empty directories
if [ "$(ls -A)" ]; then
@@ -672,10 +671,9 @@ sstate_create_package () {
#
# Shell function to decompress and prepare a package for installation
+# Will be run from within SSTATE_INSTDIR.
#
sstate_unpack_package () {
- mkdir -p ${SSTATE_INSTDIR}
- cd ${SSTATE_INSTDIR}
tar -xmvzf ${SSTATE_PKG}
# Use "! -w ||" to return true for read only files
[ ! -w ${SSTATE_PKG} ] || touch --no-dereference ${SSTATE_PKG}
--
1.9.1
reply other threads:[~2015-07-15 0:55 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1436921682-5965-1-git-send-email-armccurdy@gmail.com \
--to=armccurdy@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