1
0
Fork 0

keep build directory

This commit is contained in:
Mikhail Goncharov 2021-06-28 15:45:53 +02:00
parent ff4e998ef4
commit 9939a0f29d
2 changed files with 8 additions and 4 deletions

View file

@ -40,7 +40,7 @@ def ninja_all_report(step: Step, _: Report):
sys.stdout.buffer.write,
sys.stderr.buffer.write,
'ninja all', cwd=build_dir)
logging.debug(f'ninja all: returned {rc}')
logging.debug(f'{build_dir}, ninja all: returned {rc}')
step.set_status_from_exit_code(rc)
@ -51,7 +51,7 @@ def ninja_check_all_report(step: Step, _: Report):
sys.stdout.buffer.write,
sys.stderr.buffer.write,
'ninja check-all', cwd=build_dir)
logging.debug(f'ninja check-all: returned {rc}')
logging.debug(f'{build_dir}, ninja check-all: returned {rc}')
step.set_status_from_exit_code(rc)

View file

@ -145,8 +145,12 @@ def run(projects: str, repo_path: str, config_file_path: str = None, *, dry_run:
script_dir = os.path.dirname(__file__)
config_file_path = os.path.join(script_dir, 'run_cmake_config.yaml')
config = Configuration(config_file_path)
build_dir = os.path.abspath(os.path.join(repo_path, 'build'))
build_dir = os.path.abspath(os.path.join(os.getenv("BUILDKITE_BUILD_PATH"), 'llvm_build'))
logging.info(f"build directory '{build_dir}'")
if os.path.isdir(build_dir):
logging.info("directory exist")
if os.getenv("ph_no_cache") is None:
return 0, build_dir, [], commands
if not dry_run:
secure_delete(build_dir)
os.makedirs(build_dir)