summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJürg Billeter <j@bitron.ch>2020-01-23 15:59:29 +0100
committerJürg Billeter <j@bitron.ch>2020-02-11 17:04:17 +0100
commit86c8294e90dfd0e0a810c03a34452170129cb206 (patch)
tree33c37497bb4e7e4853124d05406d4b766991795d
parent16b98a8c24dd8c8aa5a43cba8bf3aa09d98251cd (diff)
downloadbuildstream-86c8294e90dfd0e0a810c03a34452170129cb206.tar.gz
element.py: Cache buildtrees by default for workspace builds
The buildtree of the previous build is required for incremental workspace builds.
-rw-r--r--src/buildstream/element.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/buildstream/element.py b/src/buildstream/element.py
index cb4dc5450..af50c230d 100644
--- a/src/buildstream/element.py
+++ b/src/buildstream/element.py
@@ -1701,7 +1701,7 @@ class Element(Plugin):
# with an empty buildtreedir regardless of this configuration.
if cache_buildtrees == _CacheBuildTrees.ALWAYS or (
- cache_buildtrees == _CacheBuildTrees.AUTO and not build_success
+ cache_buildtrees == _CacheBuildTrees.AUTO and (not build_success or self._get_workspace())
):
try:
sandbox_build_dir = sandbox_vroot.descend(