All of lore.kernel.org
 help / color / mirror / Atom feed
From: Yann E. MORIN <yann.morin.1998@free.fr>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] Config.in: add BR2_DL_DIR_OPTS
Date: Thu, 1 Nov 2018 18:04:28 +0100	[thread overview]
Message-ID: <20181101170428.GV28575@scaer> (raw)
In-Reply-To: <CAGt4E5vUJGDUnO1vhzkMqdP86Li05Ae+eMmSNN1h8g85MsXK7g@mail.gmail.com>

Markus, All,

On 2018-11-01 08:16 -0700, Markus Mayer spake thusly:
> On Thu, 1 Nov 2018 at 05:23, Yann E. MORIN <yann.morin.1998@free.fr> wrote:
> > On 2018-11-01 13:19 +0100, Arnout Vandecappelle spake thusly:
> > > On 31/10/18 22:39, Markus Mayer wrote:
> > > > Provide a simple mechanism to pass extra arguments to "mkdir" when
> > > > creating download directories. This can be helpful if one needs the
> > > > download directories to be writable multiple users ("shared download
> > > > cache").
> > >
> > >  I think having a Config.in option for this is way overkill. You can just make
> > > the directory before calling Buildroot, right? And if it is a shared directory,
> > > it should be created only once anyway.
> >
> > Yes for the top-level BR2_DL_DIR. But Buildroot does create sub-dirs,
> > one per package, and Bbuildroot also enforces the umask to 0022, which
> > means sub-dirs will not have the group-writable bit set.
> 
> Yep. That's exactly the problem we are running into. There was no
> issue when buildroot wasn't creating sub-dirs per package. But now,
> with a sub-dir per package, those sub-directories end up being
> non-writable by group, which means that a different user building
> buildroot at a time when there is a new source tar-ball to download,
> will receive a permission error.
> 
> BTW, the whole exercise of using a shared "dl" directory is to
> conserve disk space on build machines.

Note: I'm all in favour of fixing this use-case, but I have a few other
suggestion in addition to fixing the issue:

0. one may use newgrp to switch to the grou that owns the download
   directory:
    - first, prepare the directory:
        $ mkdir /some/place/dl-dir
        $ chown some-group /some/place/dl-dir
        $ chmod g+rwxs /some/place/dl-dir
    - now, each user uses newgrp:
        $ export BR2_DL_DIR=/some/place/dl-dir
        $ newgrp some-group
        $ make source

1. one could also use a de-duplicating filesystem, like btrfs for example.

But as I said, I'd like we also fix your use-case, and I have a series
locally that gets rid of the umask altogether. But even that will
require that participating users use an appropriate umask of course.

Regards,
Yann E. MORIN.

> Thanks,
> -Markus
> 
> > Regards,
> > Yann E. MORIN.
> >
> > >  Regards,
> > >  Arnout
> > >
> > > [snip]
> > > _______________________________________________
> > > buildroot mailing list
> > > buildroot at busybox.net
> > > http://lists.busybox.net/mailman/listinfo/buildroot
> >
> > --
> > .-----------------.--------------------.------------------.--------------------.
> > |  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
> > | +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
> > | +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
> > | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
> > '------------------------------^-------^------------------^--------------------'

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'

  reply	other threads:[~2018-11-01 17:04 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-31 21:39 [Buildroot] [PATCH] Config.in: add BR2_DL_DIR_OPTS Markus Mayer
2018-11-01  1:54 ` Carlos Santos
2018-11-01  5:18   ` Markus Mayer
2018-11-01  9:06 ` Yann E. MORIN
2018-11-01 11:01   ` Thomas Petazzoni
2018-11-01 11:18     ` Yann E. MORIN
2018-11-01 12:19 ` Arnout Vandecappelle
2018-11-01 12:23   ` Yann E. MORIN
2018-11-01 15:16     ` Markus Mayer
2018-11-01 17:04       ` Yann E. MORIN [this message]
2019-03-17 12:51 ` Yann E. MORIN

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20181101170428.GV28575@scaer \
    --to=yann.morin.1998@free.fr \
    --cc=buildroot@busybox.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.