Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [RFC/PATCH 0/4] support building from read-only source tree
@ 2012-06-18 15:02 Nathan Lynch
  2012-06-18 15:02 ` [Buildroot] [RFC/PATCH 1/4] uClibc: ensure .oldconfig is writable Nathan Lynch
                   ` (4 more replies)
  0 siblings, 5 replies; 10+ messages in thread
From: Nathan Lynch @ 2012-06-18 15:02 UTC (permalink / raw)
  To: buildroot

There are several places in Buildroot where files are copied from the
source tree to the output directory and then modified.  The most
obvious case is copying a .config or equivalent to the build
directory and then modifying it with sed, as with uClibc or busybox.

This works fine when the source file has write permissions; this is
preserved in the destination copy.  This is the behavior in the common
case of running from a git repository or a release tarball.

However, when the source file is read-only, the destination copy is
also not writable and such fixups fail.  This occurs when the the
Buildroot source tree is being hosted in a Perforce repository.
Perforce uses local file permissions to track whether a file is being
edited and checks out all regular files read-only by design.

The following changes were enough to get qemu_mips_malta_defconfig to
build and run successfully.  I submit these patches for discussion and
illustration of the effort required to support this use case.

Nathan Lynch (4):
  uClibc: ensure .oldconfig is writable
  ensure target fs is writable
  busybox: ensure $(BUSYBOX_BUILD_CONFIG) is writable
  linux: ensure buildroot_defconfig is writable

 Makefile                   |    1 +
 linux/linux.mk             |    3 ++-
 package/busybox/busybox.mk |    3 ++-
 toolchain/uClibc/uclibc.mk |    1 +
 4 files changed, 6 insertions(+), 2 deletions(-)

-- 
1.7.10.2

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2013-05-30 20:36 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-06-18 15:02 [Buildroot] [RFC/PATCH 0/4] support building from read-only source tree Nathan Lynch
2012-06-18 15:02 ` [Buildroot] [RFC/PATCH 1/4] uClibc: ensure .oldconfig is writable Nathan Lynch
2012-06-18 15:02 ` [Buildroot] [RFC/PATCH 2/4] ensure target fs " Nathan Lynch
2012-06-20 23:12   ` Arnout Vandecappelle
2012-06-18 15:02 ` [Buildroot] [RFC/PATCH 3/4] busybox: ensure $(BUSYBOX_BUILD_CONFIG) " Nathan Lynch
2012-06-20 23:13   ` Arnout Vandecappelle
2012-06-18 15:02 ` [Buildroot] [RFC/PATCH 4/4] linux: ensure buildroot_defconfig " Nathan Lynch
2013-05-26 14:45 ` [Buildroot] [RFC/PATCH 0/4] support building from read-only source tree Yann E. MORIN
2013-05-26 16:36   ` Yann E. MORIN
2013-05-30 20:36     ` Nathan Lynch

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox