summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2019-12-11 11:59:14 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2020-01-11 11:06:21 +0000
commitbe02afefc529b1d9a3b7291f15066ac7427fb440 (patch)
tree3bdf6e9e62a5bd542a4a266e3680e085e1448cd1 /meta
parent17e3fcab7ad4c066ca11fa0a942033e5877f7b54 (diff)
downloadpoky-be02afefc529b1d9a3b7291f15066ac7427fb440.tar.gz
sstate: Ensure mkdir happens before mktemp
This avoids a directory not present error. Fix a comment typo whilst here. (From OE-Core rev: c5f285f83ea1e322d5124847904adf488d3e790a) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 1360d8d7d99b70a80c8cdbc1fc6d9e6752483139) Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/classes/sstate.bbclass5
1 files changed, 2 insertions, 3 deletions
diff --git a/meta/classes/sstate.bbclass b/meta/classes/sstate.bbclass
index 79ae392116..b5267f00be 100644
--- a/meta/classes/sstate.bbclass
+++ b/meta/classes/sstate.bbclass
@@ -747,14 +747,13 @@ sstate_task_postfunc[dirs] = "${WORKDIR}"
747# set as SSTATE_BUILDDIR. Will be run from within SSTATE_BUILDDIR. 747# set as SSTATE_BUILDDIR. Will be run from within SSTATE_BUILDDIR.
748# 748#
749sstate_create_package () { 749sstate_create_package () {
750 TFILE=`mktemp ${SSTATE_PKG}.XXXXXXXX` 750 # Exit early if it already exists
751
752 # Exit earlu if it already exists
753 if [ -e ${SSTATE_PKG} ]; then 751 if [ -e ${SSTATE_PKG} ]; then
754 return 752 return
755 fi 753 fi
756 754
757 mkdir -p `dirname ${SSTATE_PKG}` 755 mkdir -p `dirname ${SSTATE_PKG}`
756 TFILE=`mktemp ${SSTATE_PKG}.XXXXXXXX`
758 757
759 # Use pigz if available 758 # Use pigz if available
760 OPT="-czS" 759 OPT="-czS"