Skip to content

Commit 17f10ab

Browse files
committed
gn build: Copy file permissions from input file in configure_file() emulation.
Most significantly, this makes bin/llvm-lit executable so that it can be run in the usual way. Differential Revision: https://reviews.llvm.org/D56423 llvm-svn: 350688
1 parent 2fa8e2d commit 17f10ab

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

llvm/utils/gn/build/write_cmake_config.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,7 @@ def repl(m):
101101

102102
if not os.path.exists(args.output) or open(args.output).read() != output:
103103
open(args.output, 'w').write(output)
104+
os.chmod(args.output, os.stat(args.input).st_mode & 0777)
104105

105106

106107
if __name__ == '__main__':

0 commit comments

Comments
 (0)