Skip to content

Commit c9765ae

Browse files
committed
abs fix
1 parent 8b1eb31 commit c9765ae

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

.ci/buildbot/worker.py

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -243,11 +243,9 @@ def run(
243243
Always clobber the build artifacts, i.e. disable incremental builds.
244244
"""
245245

246-
assert os.path.isabs(scriptpath)
247-
assert os.path.isabs(llvmsrcroot)
248246

249-
250-
scriptpath = os.path.normpath(scriptpath)
247+
scriptpath = os.path.abspath(scriptpath)
248+
llvmsrcroot = os.path.abspath(llvmsrcroot)
251249
stem = pathlib.Path(scriptpath).stem
252250
workdir_default = f"{stem}.workdir"
253251

@@ -295,7 +293,7 @@ def run(
295293
)
296294
args = parser.parse_args()
297295

298-
workdir = args.workdir
296+
workdir = os.path.abspath( args.workdir)
299297
clean = args.clean
300298
clobber = args.clobber
301299
cachefile = os.path.join(llvmsrcroot, args.cachefile)
@@ -315,7 +313,7 @@ def run(
315313
while True:
316314
if os.path.samefile(parentdir, workdir):
317315
raise Exception(
318-
f"Cannot use {workdir} as workdir; a '--clean' build would rmtree the llvm-project source in {parentdir} as well"
316+
f"Cannot use {args.workdir} as workdir; a '--clean' build would rmtree the llvm-project source in {parentdir} as well"
319317
)
320318
newparentdir = os.path.dirname(parentdir)
321319
if newparentdir == parentdir:

0 commit comments

Comments
 (0)