]> git.ipfire.org Git - thirdparty/coreutils.git/commit
cp,mv,install: modularize targetdir
authorPaul Eggert <eggert@cs.ucla.edu>
Wed, 13 Apr 2022 06:56:41 +0000 (23:56 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Wed, 13 Apr 2022 06:57:15 +0000 (23:57 -0700)
commit30c932a3098146128acfd839589f308ec1bb116d
tree1a97d2f26bbb5f1a00ae827a5da65167d5c6b5cb
parent52139fd69034446695af60c8064a38e5e795227c
cp,mv,install: modularize targetdir

Move target directory code out of system.h to a new targetdir module.
This doesn’t change functionality.
* bootstrap.conf (gnulib_modules): Add targetdir.
* src/cp.c, src/install.c, src/mv.c: Include targetdir.h.
* src/system.h (must_be_working_directory, target_directory_operand)
(targetdir_dirfd_valid): Move from here ...
* gl/lib/targetdir.c, gl/lib/targetdir.h, gl/modules/targetdir:
... to these new files.
bootstrap.conf
gl/lib/targetdir.c [new file with mode: 0644]
gl/lib/targetdir.h [new file with mode: 0644]
gl/modules/targetdir [new file with mode: 0644]
src/cp.c
src/install.c
src/mv.c
src/system.h