diff options
author | Michael Olbrich <m.olbrich@pengutronix.de> | 2012-02-02 23:55:00 +0100 |
---|---|---|
committer | Michael Olbrich <m.olbrich@pengutronix.de> | 2012-02-02 23:55:38 +0100 |
commit | 073012371e458a85444aea71b614d8f6f9761c7c (patch) | |
tree | 85b619441c9075889606d78b2f2ba3df18bb50c5 | |
parent | 5ad31a73a0800e3739be815d9cf1482d4b2768e2 (diff) | |
download | ptxdist-073012371e458a85444aea71b614d8f6f9761c7c.tar.gz ptxdist-073012371e458a85444aea71b614d8f6f9761c7c.tar.xz |
ptxd_make_world_install_pack: fix removing empty directories
Use "find -depth ..." instead of "rmdir -p". Otherwise too many
directories may be removed if nothing is installed.
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
-rw-r--r-- | scripts/lib/ptxd_make_world_install.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/lib/ptxd_make_world_install.sh b/scripts/lib/ptxd_make_world_install.sh index 174fa5937..da23f7fed 100644 --- a/scripts/lib/ptxd_make_world_install.sh +++ b/scripts/lib/ptxd_make_world_install.sh @@ -110,8 +110,8 @@ ptxd_make_world_install_pack() { # remove empty dirs test \! -e "${pkg_pkg_dir}" || \ - find "${pkg_pkg_dir}" -type d -print0 | xargs -r -0 -- \ - rmdir --ignore-fail-on-non-empty -p -- && + find "${pkg_pkg_dir}" -depth -type d -print0 | xargs -r -0 -- \ + rmdir --ignore-fail-on-non-empty -- && check_pipe_status && if [ \! -e "${pkg_pkg_dir}" ]; then |