aboutsummaryrefslogtreecommitdiff
path: root/coreutils/cp.c
diff options
context:
space:
mode:
Diffstat (limited to 'coreutils/cp.c')
-rw-r--r--coreutils/cp.c23
1 files changed, 13 insertions, 10 deletions
diff --git a/coreutils/cp.c b/coreutils/cp.c
index 092e39583..5b34c27e7 100644
--- a/coreutils/cp.c
+++ b/coreutils/cp.c
@@ -73,15 +73,17 @@ int cp_main(int argc, char **argv)
73#endif 73#endif
74 }; 74 };
75 75
76 // Need at least two arguments
77 // Soft- and hardlinking doesn't mix
78 // -P and -d are the same (-P is POSIX, -d is GNU)
79 // -r and -R are the same
80 // -R (and therefore -r) turns on -d (coreutils does this)
81 // -a = -pdR
82 opt_complementary = "-2:l--s:s--l:Pd:rRd:Rd:apdR";
83#if ENABLE_FEATURE_CP_LONG_OPTIONS 76#if ENABLE_FEATURE_CP_LONG_OPTIONS
84 applet_long_options = 77 flags = getopt32long(argv, "^"
78 FILEUTILS_CP_OPTSTR
79 "\0"
80 // Need at least two arguments
81 // Soft- and hardlinking doesn't mix
82 // -P and -d are the same (-P is POSIX, -d is GNU)
83 // -r and -R are the same
84 // -R (and therefore -r) turns on -d (coreutils does this)
85 // -a = -pdR
86 "-2:l--s:s--l:Pd:rRd:Rd:apdR",
85 "archive\0" No_argument "a" 87 "archive\0" No_argument "a"
86 "force\0" No_argument "f" 88 "force\0" No_argument "f"
87 "interactive\0" No_argument "i" 89 "interactive\0" No_argument "i"
@@ -94,9 +96,10 @@ int cp_main(int argc, char **argv)
94 "update\0" No_argument "u" 96 "update\0" No_argument "u"
95 "remove-destination\0" No_argument "\xff" 97 "remove-destination\0" No_argument "\xff"
96 "parents\0" No_argument "\xfe" 98 "parents\0" No_argument "\xfe"
97 ; 99 );
98#endif 100#else
99 flags = getopt32(argv, FILEUTILS_CP_OPTSTR); 101 flags = getopt32(argv, FILEUTILS_CP_OPTSTR);
102#endif
100 /* Options of cp from GNU coreutils 6.10: 103 /* Options of cp from GNU coreutils 6.10:
101 * -a, --archive 104 * -a, --archive
102 * -f, --force 105 * -f, --force