summaryrefslogtreecommitdiff
path: root/gnulib-tool.py
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2022-08-03 11:27:21 +0200
committerBruno Haible <bruno@clisp.org>2022-08-03 11:27:21 +0200
commitdbc9a4b304185e2cb0d9f425866f71161c9a1255 (patch)
tree3ea1526794114be5ee54c00ed8305f18fc969e6f /gnulib-tool.py
parentf88aeeb42a4926bc2f7bcb7758ca511e75404593 (diff)
downloadgnulib-dbc9a4b304185e2cb0d9f425866f71161c9a1255.tar.gz
gnulib-tool.py: Avoid errors when writing to a VFAT file system.
* pygnulib/constants.py (copyfile, copyfile2): New functions. * gnulib-tool.py: Use them instead of shutil. * pygnulib/*.py: Likewise.
Diffstat (limited to 'gnulib-tool.py')
-rwxr-xr-xgnulib-tool.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/gnulib-tool.py b/gnulib-tool.py
index 302aaf3405..2ac522aa05 100755
--- a/gnulib-tool.py
+++ b/gnulib-tool.py
@@ -54,6 +54,7 @@ MODES = constants.MODES
TESTS = constants.TESTS
compiler = constants.compiler
joinpath = constants.joinpath
+copyfile = constants.copyfile
isabs = os.path.isabs
isdir = os.path.isdir
isfile = os.path.isfile
@@ -959,7 +960,7 @@ def main():
# Copy the file.
assistant = classes.GLFileAssistant(config)
tmpfile = assistant.tmpfilename(destpath)
- shutil.copy(lookedup, tmpfile)
+ copyfile(lookedup, tmpfile)
assistant.setOriginal(srcpath)
assistant.config.setDestDir(destdir)
assistant.setRewritten(destpath)