diff options
-rw-r--r-- | meta/classes/sstate.bbclass | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/meta/classes/sstate.bbclass b/meta/classes/sstate.bbclass index 15706541ae..20e66e2742 100644 --- a/meta/classes/sstate.bbclass +++ b/meta/classes/sstate.bbclass | |||
@@ -455,12 +455,14 @@ python sstate_task_postfunc () { | |||
455 | # | 455 | # |
456 | sstate_create_package () { | 456 | sstate_create_package () { |
457 | cd ${SSTATE_BUILDDIR} | 457 | cd ${SSTATE_BUILDDIR} |
458 | TFILE=`mktemp ${SSTATE_PKG}.XXXXXXXX` | ||
458 | # Need to handle empty directories | 459 | # Need to handle empty directories |
459 | if [ "$(ls -A)" ]; then | 460 | if [ "$(ls -A)" ]; then |
460 | tar -czf ${SSTATE_PKG} * | 461 | tar -czf $TFILE * |
461 | else | 462 | else |
462 | tar -cz --file=${SSTATE_PKG} --files-from=/dev/null | 463 | tar -cz --file=$TFILE --files-from=/dev/null |
463 | fi | 464 | fi |
465 | mv $TFILE ${SSTATE_PKG} | ||
464 | 466 | ||
465 | cd ${WORKDIR} | 467 | cd ${WORKDIR} |
466 | rm -rf ${SSTATE_BUILDDIR} | 468 | rm -rf ${SSTATE_BUILDDIR} |