cp: add support for --parents and long option synonyms of short opts

By Ian Wienand (ianw AT vmware.com)

function                                             old     new   delta
cp_main                                              257     369    +112
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 1/0 up/down: 112/0)             Total: 112 bytes
   text    data     bss     dec     hex filename
 823000     458    6948  830406   cabc6 busybox_old
 823283     458    6948  830689   cace1 busybox_unstripped

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Denys Vlasenko
2009-09-26 14:31:04 +02:00
parent 67f7186403
commit 48f116198d
3 changed files with 68 additions and 17 deletions

5
testsuite/cp/cp-parents Normal file
View File

@@ -0,0 +1,5 @@
mkdir -p foo/bar/baz
touch foo/bar/baz/file
mkdir dir
busybox cp --parents foo/bar/baz/file dir
test -f dir/foo/bar/baz/file