* [gentoo-portage-dev] [PATCH] Revert "unpack: avoid useless chmods to improve speed"
@ 2015-09-27 13:24 Mike Gilbert
2015-09-28 18:52 ` Zac Medico
0 siblings, 1 reply; 3+ messages in thread
From: Mike Gilbert @ 2015-09-27 13:24 UTC (permalink / raw
To: gentoo-portage-dev
This reverts commit 0dc7b2a3923508896cf217f325b8339d73353553.
The "optimized" chmod is no longer recursive, which causes files to be
missed.
X-Gentoo-Bug: 561368
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=561368
---
bin/phase-helpers.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/bin/phase-helpers.sh b/bin/phase-helpers.sh
index b446060..efd2cfa 100644
--- a/bin/phase-helpers.sh
+++ b/bin/phase-helpers.sh
@@ -531,8 +531,8 @@ unpack() {
done
# Do not chmod '.' since it's probably ${WORKDIR} and PORTAGE_WORKDIR_MODE
# should be preserved.
- find . -mindepth 1 '!' -type l '!' -perm /a+rX,u+w,g-w,o-w \
- -exec chmod -f a+rX,u+w,g-w,o-w '{}' +
+ find . -mindepth 1 -maxdepth 1 ! -type l -print0 | \
+ ${XARGS} -0 chmod -fR a+rX,u+w,g-w,o-w
}
econf() {
--
2.5.3
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [gentoo-portage-dev] [PATCH] Revert "unpack: avoid useless chmods to improve speed"
2015-09-27 13:24 [gentoo-portage-dev] [PATCH] Revert "unpack: avoid useless chmods to improve speed" Mike Gilbert
@ 2015-09-28 18:52 ` Zac Medico
2015-09-28 19:11 ` Brian Dolbec
0 siblings, 1 reply; 3+ messages in thread
From: Zac Medico @ 2015-09-28 18:52 UTC (permalink / raw
To: gentoo-portage-dev
On 09/27/2015 06:24 AM, Mike Gilbert wrote:
> This reverts commit 0dc7b2a3923508896cf217f325b8339d73353553.
>
> The "optimized" chmod is no longer recursive, which causes files to be
> missed.
>
> X-Gentoo-Bug: 561368
> X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=561368
> ---
> bin/phase-helpers.sh | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/bin/phase-helpers.sh b/bin/phase-helpers.sh
> index b446060..efd2cfa 100644
> --- a/bin/phase-helpers.sh
> +++ b/bin/phase-helpers.sh
> @@ -531,8 +531,8 @@ unpack() {
> done
> # Do not chmod '.' since it's probably ${WORKDIR} and PORTAGE_WORKDIR_MODE
> # should be preserved.
> - find . -mindepth 1 '!' -type l '!' -perm /a+rX,u+w,g-w,o-w \
> - -exec chmod -f a+rX,u+w,g-w,o-w '{}' +
> + find . -mindepth 1 -maxdepth 1 ! -type l -print0 | \
> + ${XARGS} -0 chmod -fR a+rX,u+w,g-w,o-w
> }
>
> econf() {
>
LGTM.
Unfortunately, the find call in the 'optimized' version is useless,
because it fails like this:
$ find . -mindepth 1 '!' -type l '!' -perm /a+rX,u+w,g-w,o-w
find: `./mod_auth_token': Permission denied
Meanwhile, chmod -R works fine.
--
Thanks,
Zac
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [gentoo-portage-dev] [PATCH] Revert "unpack: avoid useless chmods to improve speed"
2015-09-28 18:52 ` Zac Medico
@ 2015-09-28 19:11 ` Brian Dolbec
0 siblings, 0 replies; 3+ messages in thread
From: Brian Dolbec @ 2015-09-28 19:11 UTC (permalink / raw
To: gentoo-portage-dev
On Mon, 28 Sep 2015 11:52:52 -0700
Zac Medico <zmedico@gentoo.org> wrote:
> On 09/27/2015 06:24 AM, Mike Gilbert wrote:
> > This reverts commit 0dc7b2a3923508896cf217f325b8339d73353553.
> >
> > The "optimized" chmod is no longer recursive, which causes files to
> > be missed.
> >
> > X-Gentoo-Bug: 561368
> > X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=561368
> > ---
> > bin/phase-helpers.sh | 4 ++--
> > 1 file changed, 2 insertions(+), 2 deletions(-)
> >
> > diff --git a/bin/phase-helpers.sh b/bin/phase-helpers.sh
> > index b446060..efd2cfa 100644
> > --- a/bin/phase-helpers.sh
> > +++ b/bin/phase-helpers.sh
> > @@ -531,8 +531,8 @@ unpack() {
> > done
> > # Do not chmod '.' since it's probably ${WORKDIR} and
> > PORTAGE_WORKDIR_MODE # should be preserved.
> > - find . -mindepth 1 '!' -type l '!' -perm /a+rX,u+w,g-w,o-w
> > \
> > - -exec chmod -f a+rX,u+w,g-w,o-w '{}' +
> > + find . -mindepth 1 -maxdepth 1 ! -type l -print0 | \
> > + ${XARGS} -0 chmod -fR a+rX,u+w,g-w,o-w
> > }
> >
> > econf() {
> >
>
> LGTM.
>
> Unfortunately, the find call in the 'optimized' version is useless,
> because it fails like this:
>
> $ find . -mindepth 1 '!' -type l '!' -perm /a+rX,u+w,g-w,o-w
> find: `./mod_auth_token': Permission denied
>
> Meanwhile, chmod -R works fine.
Applied and pushed,
Thanks
--
Brian Dolbec <dolsen>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-09-28 19:12 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-09-27 13:24 [gentoo-portage-dev] [PATCH] Revert "unpack: avoid useless chmods to improve speed" Mike Gilbert
2015-09-28 18:52 ` Zac Medico
2015-09-28 19:11 ` Brian Dolbec
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox