[PATCH] D75426: [LTO] onfig::addSaveTemps: clear ResolutionFile upon an error

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 3 14:24:42 PST 2020


MaskRay marked an inline comment as done.
MaskRay added inline comments.


================
Comment at: lld/test/ELF/lto/resolution-err.ll:5
+; RUN: touch %t.resolution.txt
+; RUN: chmod -w %t.resolution.txt
+; RUN: not ld.lld -save-temps %t.bc -o %t 2>&1 | FileCheck %s
----------------
MaskRay wrote:
> hoyFB wrote:
> > The chmod is an issue when the test is run on a server without root access. Do you have an suggestion how to make it work? Thanks.
> Quote https://pubs.opengroup.org/onlinepubs/9699919799/utilities/chmod.html
> 
> > Only a process whose effective user ID matches the user ID of the file, or a process with appropriate privileges, shall be permitted to change the file mode bits of a file.
> 
> The user ID of `%t.resolution.txt` is the current effective user ID. The current effective user ID can `chmod -w` the file. See `llvm/test/tools/llvm-objcopy/ELF/mirror-permissions-unix.test` for another example.
> 
> Is that not the case on your system?
Or do you mean **with** root access?

This is so uncommon that I think maybe you should just disable the test internally.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D75426/new/

https://reviews.llvm.org/D75426





More information about the llvm-commits mailing list