diff options
| -rw-r--r-- | meta/classes/rm_work.bbclass | 32 | ||||
| -rw-r--r-- | meta/recipes-devtools/qemu/qemu-helper-native_1.0.bb | 1 | ||||
| -rw-r--r-- | meta/recipes-kernel/systemtap/systemtap-native_git.bb | 1 |
3 files changed, 20 insertions, 14 deletions
diff --git a/meta/classes/rm_work.bbclass b/meta/classes/rm_work.bbclass index badeaeba07..2a4e808b88 100644 --- a/meta/classes/rm_work.bbclass +++ b/meta/classes/rm_work.bbclass | |||
| @@ -35,22 +35,12 @@ do_rm_work () { | |||
| 35 | fi | 35 | fi |
| 36 | done | 36 | done |
| 37 | 37 | ||
| 38 | cd ${WORKDIR} | ||
| 39 | for dir in * | ||
| 40 | do | ||
| 41 | # Retain only logs and other files in temp, safely ignore | ||
| 42 | # failures of removing pseudo folers on NFS2/3 server. | ||
| 43 | if [ $dir = 'pseudo' ]; then | ||
| 44 | rm -rf $dir 2> /dev/null || true | ||
| 45 | elif ! echo '${RM_WORK_EXCLUDE_ITEMS}' | grep -q -w "$dir"; then | ||
| 46 | rm -rf $dir | ||
| 47 | fi | ||
| 48 | done | ||
| 49 | |||
| 50 | # Need to add pseudo back or subsqeuent work in this workdir | 38 | # Need to add pseudo back or subsqeuent work in this workdir |
| 51 | # might fail since setscene may not rerun to recreate it | 39 | # might fail since setscene may not rerun to recreate it |
| 52 | mkdir -p ${WORKDIR}/pseudo/ | 40 | mkdir -p ${WORKDIR}/pseudo/ |
| 53 | 41 | ||
| 42 | excludes='${RM_WORK_EXCLUDE_ITEMS}' | ||
| 43 | |||
| 54 | # Change normal stamps into setscene stamps as they better reflect the | 44 | # Change normal stamps into setscene stamps as they better reflect the |
| 55 | # fact WORKDIR is now empty | 45 | # fact WORKDIR is now empty |
| 56 | # Also leave noexec stamps since setscene stamps don't cover them | 46 | # Also leave noexec stamps since setscene stamps don't cover them |
| @@ -79,6 +69,12 @@ do_rm_work () { | |||
| 79 | i=dummy | 69 | i=dummy |
| 80 | break | 70 | break |
| 81 | ;; | 71 | ;; |
| 72 | *do_addto_recipe_sysroot*) | ||
| 73 | # Preserve recipe-sysroot-native if do_addto_recipe_sysroot has been used | ||
| 74 | excludes="$excludes recipe-sysroot-native" | ||
| 75 | i=dummy | ||
| 76 | break | ||
| 77 | ;; | ||
| 82 | # We remove do_package entirely, including any | 78 | # We remove do_package entirely, including any |
| 83 | # sstate version since otherwise we'd need to leave 'plaindirs' around | 79 | # sstate version since otherwise we'd need to leave 'plaindirs' around |
| 84 | # such as 'packages' and 'packages-split' and these can be large. No end | 80 | # such as 'packages' and 'packages-split' and these can be large. No end |
| @@ -101,6 +97,18 @@ do_rm_work () { | |||
| 101 | done | 97 | done |
| 102 | rm -f $i | 98 | rm -f $i |
| 103 | done | 99 | done |
| 100 | |||
| 101 | cd ${WORKDIR} | ||
| 102 | for dir in * | ||
| 103 | do | ||
| 104 | # Retain only logs and other files in temp, safely ignore | ||
| 105 | # failures of removing pseudo folers on NFS2/3 server. | ||
| 106 | if [ $dir = 'pseudo' ]; then | ||
| 107 | rm -rf $dir 2> /dev/null || true | ||
| 108 | elif ! echo "$excludes" | grep -q -w "$dir"; then | ||
| 109 | rm -rf $dir | ||
| 110 | fi | ||
| 111 | done | ||
| 104 | } | 112 | } |
| 105 | do_rm_work_all () { | 113 | do_rm_work_all () { |
| 106 | : | 114 | : |
diff --git a/meta/recipes-devtools/qemu/qemu-helper-native_1.0.bb b/meta/recipes-devtools/qemu/qemu-helper-native_1.0.bb index 27d53157db..d86b155176 100644 --- a/meta/recipes-devtools/qemu/qemu-helper-native_1.0.bb +++ b/meta/recipes-devtools/qemu/qemu-helper-native_1.0.bb | |||
| @@ -20,6 +20,5 @@ do_install() { | |||
| 20 | install tunctl ${D}${bindir}/ | 20 | install tunctl ${D}${bindir}/ |
| 21 | } | 21 | } |
| 22 | 22 | ||
| 23 | RM_WORK_EXCLUDE_ITEMS += "recipe-sysroot-native" | ||
| 24 | DEPENDS += "qemu-native" | 23 | DEPENDS += "qemu-native" |
| 25 | addtask addto_recipe_sysroot after do_populate_sysroot before do_build | 24 | addtask addto_recipe_sysroot after do_populate_sysroot before do_build |
diff --git a/meta/recipes-kernel/systemtap/systemtap-native_git.bb b/meta/recipes-kernel/systemtap/systemtap-native_git.bb index c3da77c831..19cc1cf0f0 100644 --- a/meta/recipes-kernel/systemtap/systemtap-native_git.bb +++ b/meta/recipes-kernel/systemtap/systemtap-native_git.bb | |||
| @@ -3,5 +3,4 @@ require systemtap_git.bb | |||
| 3 | 3 | ||
| 4 | inherit native | 4 | inherit native |
| 5 | 5 | ||
| 6 | RM_WORK_EXCLUDE_ITEMS += "recipe-sysroot-native" | ||
| 7 | addtask addto_recipe_sysroot after do_populate_sysroot before do_build | 6 | addtask addto_recipe_sysroot after do_populate_sysroot before do_build |
