diff options
author | Jim Meyering <jim@meyering.net> | 2007-08-23 10:47:16 +0200 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2007-08-23 13:59:40 +0200 |
commit | 22ed81c410c197003782ba379cb3148306b0cd8a (patch) | |
tree | 3faddb492038c4eed405090a032c7312d072aa7e /src/Makefile.am | |
parent | 173524ed7d0bb5f458251b796f23a2dfc49a4b24 (diff) | |
download | coreutils-22ed81c410c197003782ba379cb3148306b0cd8a.tar.xz |
Move functions from copy.c into new modules, since ln needs them, too.
* bootstrap.conf (gnulib_modules): Add file-set.
* gl/lib/file-set.c (record_file, seen_file): Functions from copy.c.
* gl/lib/file-set.h: Add prototypes.
* gl/lib/hash-triple.c (triple_hash, triple_hash_no_name):
(triple_compare, triple_free): Functions from copy.c.
* gl/lib/hash-triple.h (struct F_triple): Define. From copy.c.
Add prototypes.
* gl/modules/file-set: New module.
* gl/modules/hash-triple: New module.
* src/Makefile.am (copy_sources): New variable.
(ginstall_SOURCES, cp_SOURCES, mv_SOURCES): Use it.
* src/copy.c: Include hash-triple.h.
No longer include hash-pjw.h.
(copy_internal): Don't pass a NULL third argument to record_file,
since that function no longer accepts that.
(record_file): Move this function to file-set.c.
Along the way, remove the code to allow a NULL stat-buffer pointer.
Adjust sole caller.
(seen_file): Move this function to file-set.c.
(struct F_triple): Move declaration to hash-triple.h.
(triple_compare, triple_free, triple_hash, triple_hash_no_name):
Move these functions to hash-triple.c.
Signed-off-by: Jim Meyering <jim@meyering.net>
Diffstat (limited to 'src/Makefile.am')
-rw-r--r-- | src/Makefile.am | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/Makefile.am b/src/Makefile.am index 7e481adef..43f138c04 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -200,24 +200,27 @@ uninstall-local: rm -f $(installed_su); \ else :; fi +copy_sources = copy.c cp-hash.c + # Use `ginstall' in the definition of PROGRAMS and in dependencies to avoid # confusion with the `install' target. The install rule transforms `ginstall' # to install before applying any user-specified name transformations. transform = s/ginstall/install/; @program_transform_name@ -ginstall_SOURCES = install.c copy.c cp-hash.c +ginstall_SOURCES = install.c $(copy_sources) # This is for the '[' program. Automake transliterates '[' to '_'. __SOURCES = lbracket.c -cp_SOURCES = cp.c copy.c cp-hash.c +cp_SOURCES = cp.c $(copy_sources) dir_SOURCES = ls.c ls-dir.c vdir_SOURCES = ls.c ls-vdir.c +ln_SOURCES = ln.c ls_SOURCES = ls.c ls-ls.c chown_SOURCES = chown.c chown-core.c chgrp_SOURCES = chgrp.c chown-core.c -mv_SOURCES = mv.c copy.c cp-hash.c remove.c +mv_SOURCES = mv.c remove.c $(copy_sources) rm_SOURCES = rm.c remove.c uname_SOURCES = uname.c uname-uname.c |