Skip to content

Commit

Permalink
[AMDGPU] Fix CMake cache builder (#369)
Browse files Browse the repository at this point in the history
We need to clean the build directory to take changes to the CMake cache
file have any effect for the actual build config.
  • Loading branch information
jplehr authored Jan 29, 2025
1 parent 76e9aa7 commit 377784a
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions zorg/buildbot/builders/annotated/amdgpu-offload-cmake.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@ def main(argv):
offload_base_dir = os.path.join(source_dir, "offload")
of_cmake_cache_base_dir = os.path.join(offload_base_dir, "cmake/caches")

with step("clean build", halt_on_fail=True):
# We have to "hard clean" the build directory, since we use a CMake cache
# If we do not do this, the resident config will take precedence and changes
# to the cache file are ignored.
run_command("rm -r *")

with step("cmake", halt_on_fail=True):
# TODO make the name of the cache file an argument to the script.
cmake_cache_file = os.path.join(of_cmake_cache_base_dir, "AMDGPUBot.cmake")
Expand Down

0 comments on commit 377784a

Please sign in to comment.