diff options
Diffstat (limited to 'meta/classes-global/sstate.bbclass')
-rw-r--r-- | meta/classes-global/sstate.bbclass | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/meta/classes-global/sstate.bbclass b/meta/classes-global/sstate.bbclass index 95d5803f17..9330433bb2 100644 --- a/meta/classes-global/sstate.bbclass +++ b/meta/classes-global/sstate.bbclass | |||
@@ -703,7 +703,7 @@ def sstate_package(ss, d): | |||
703 | if d.getVar('SSTATE_SKIP_CREATION') == '1': | 703 | if d.getVar('SSTATE_SKIP_CREATION') == '1': |
704 | return | 704 | return |
705 | 705 | ||
706 | sstate_create_package = ['sstate_report_unihash', 'sstate_create_package'] | 706 | sstate_create_package = ['sstate_report_unihash', 'sstate_create_pkgdirs', 'sstate_create_package'] |
707 | if d.getVar('SSTATE_SIG_KEY'): | 707 | if d.getVar('SSTATE_SIG_KEY'): |
708 | sstate_create_package.append('sstate_sign_package') | 708 | sstate_create_package.append('sstate_sign_package') |
709 | 709 | ||
@@ -810,6 +810,12 @@ python sstate_task_postfunc () { | |||
810 | } | 810 | } |
811 | sstate_task_postfunc[dirs] = "${WORKDIR}" | 811 | sstate_task_postfunc[dirs] = "${WORKDIR}" |
812 | 812 | ||
813 | python sstate_create_pkgdirs () { | ||
814 | # report_unihash can change SSTATE_PKG and mkdir -p in shell doesn't own intermediate directories | ||
815 | # correctly so do this in an intermediate python task | ||
816 | with bb.utils.umask(0o002): | ||
817 | bb.utils.mkdirhier(os.path.dirname(d.getVar('SSTATE_PKG'))) | ||
818 | } | ||
813 | 819 | ||
814 | # | 820 | # |
815 | # Shell function to generate a sstate package from a directory | 821 | # Shell function to generate a sstate package from a directory |
@@ -822,7 +828,6 @@ sstate_create_package () { | |||
822 | return | 828 | return |
823 | fi | 829 | fi |
824 | 830 | ||
825 | mkdir --mode=0775 -p `dirname ${SSTATE_PKG}` | ||
826 | TFILE=`mktemp ${SSTATE_PKG}.XXXXXXXX` | 831 | TFILE=`mktemp ${SSTATE_PKG}.XXXXXXXX` |
827 | 832 | ||
828 | OPT="-cS" | 833 | OPT="-cS" |