All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [pull request] Pull request for branch yem/patchwork
@ 2013-11-11 17:45 Yann E. MORIN
  2013-11-11 17:45 ` [Buildroot] [PATCH 1/2] target: ensure target/ dir is writable Yann E. MORIN
  2013-11-11 17:45 ` [Buildroot] [PATCH 2/2] busybox: ensure $(BUSYBOX_BUILD_CONFIG) " Yann E. MORIN
  0 siblings, 2 replies; 7+ messages in thread
From: Yann E. MORIN @ 2013-11-11 17:45 UTC (permalink / raw)
  To: buildroot

From: "Yann E. MORIN" <yann.morin.1998@free.fr>

Hello All!

This series ensures that taregt/ and our copy of busybox .config are
writeable.

In case the Buildroot tree is RO (eg. shared via a read-only NFS mount),
target/ would end-up read-only, which is a bit awkward, since we won't be
able to add files in there. Ditto for the busybox' .config file, since we
need to tweak it with sed.

I've had this locally for some time now, grabbed from some patches in
patchwork. A previous submission of this series has been marked as
"Changes Requested", but there's no trace of it in the ML, so I'm just
re-spinning them as-is for further comments.

Regards,
Yann E. MORIN.


The following changes since commit 6d93f061eccad3b81a27e8cf02cb8b29e9dba44e:

  ethtool: bump version to 3.12.1 (2013-11-11 15:06:57 +0100)

are available in the git repository at:

  git://gitorious.org/buildroot/buildroot.git yem/patchwork

for you to fetch changes up to 0b4acecdd3e9fb7d9510c206338ebbdfa483ca9e:

  busybox: ensure $(BUSYBOX_BUILD_CONFIG) is writable (2013-11-11 16:23:04 +0100)

----------------------------------------------------------------
Nathan Lynch (2):
      target: ensure target/ dir is writable
      busybox: ensure $(BUSYBOX_BUILD_CONFIG) is writable

 Makefile                   | 4 ++--
 package/busybox/busybox.mk | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

-- 
.-----------------.--------------------.------------------.--------------------.
|  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.  |
'------------------------------^-------^------------------^--------------------'

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

* [Buildroot] [PATCH 1/2] target: ensure target/ dir is writable
  2013-11-11 17:45 [Buildroot] [pull request] Pull request for branch yem/patchwork Yann E. MORIN
@ 2013-11-11 17:45 ` Yann E. MORIN
  2013-11-11 17:45 ` [Buildroot] [PATCH 2/2] busybox: ensure $(BUSYBOX_BUILD_CONFIG) " Yann E. MORIN
  1 sibling, 0 replies; 7+ messages in thread
From: Yann E. MORIN @ 2013-11-11 17:45 UTC (permalink / raw)
  To: buildroot

From: Nathan Lynch <ntl@pobox.com>

If the source target skeleton is read-only (eg. because Buildroot's
source dir is), modifications to the output target (such as creating
/etc/hostname and /etc/issue) fail.

(This can happen if the Buildroot source dir is NFS-mounted read-only
to be shared between different machines, for example).

Signed-off-by: Nathan Lynch <ntl@pobox.com>
[yann.morin.1998 at free.fr: we use rsync now, not cp; --chmod=Du+w
 suggested by Arnout; clarify commit log]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Arnout Vandecappelle <arnout@mind.be>
---
 Makefile | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/Makefile b/Makefile
index 2f7db59..b821b2e 100644
--- a/Makefile
+++ b/Makefile
@@ -433,7 +433,7 @@ RSYNC_VCS_EXCLUSIONS = \
 $(BUILD_DIR)/.root:
 	mkdir -p $(TARGET_DIR)
 	rsync -a $(RSYNC_VCS_EXCLUSIONS) \
-		--exclude .empty --exclude '*~' \
+		--chmod=Du+w --exclude .empty --exclude '*~' \
 		$(TARGET_SKELETON)/ $(TARGET_DIR)/
 	cp support/misc/target-dir-warning.txt $(TARGET_DIR_WARNING_FILE)
 	@ln -snf lib $(TARGET_DIR)/$(LIB_SYMLINK)
@@ -508,7 +508,7 @@ endif
 	@$(foreach d, $(call qstrip,$(BR2_ROOTFS_OVERLAY)), \
 		$(call MESSAGE,"Copying overlay $(d)"); \
 		rsync -a $(RSYNC_VCS_EXCLUSIONS) \
-			--exclude .empty --exclude '*~' \
+			--chmod=Du+w --exclude .empty --exclude '*~' \
 			$(d)/ $(TARGET_DIR)$(sep))
 
 	@$(foreach s, $(call qstrip,$(BR2_ROOTFS_POST_BUILD_SCRIPT)), \
-- 
1.8.1.2

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

* [Buildroot] [PATCH 2/2] busybox: ensure $(BUSYBOX_BUILD_CONFIG) is writable
  2013-11-11 17:45 [Buildroot] [pull request] Pull request for branch yem/patchwork Yann E. MORIN
  2013-11-11 17:45 ` [Buildroot] [PATCH 1/2] target: ensure target/ dir is writable Yann E. MORIN
@ 2013-11-11 17:45 ` Yann E. MORIN
  2013-11-11 20:22   ` Danomi Manchego
  1 sibling, 1 reply; 7+ messages in thread
From: Yann E. MORIN @ 2013-11-11 17:45 UTC (permalink / raw)
  To: buildroot

From: Nathan Lynch <ntl@pobox.com>

If $(BUSYBOX_CONFIG_FILE) is read-only (eg. because Buildroot's
source dir is), the sed fixups to $(BUSYBOX_BUILD_CONFIG) fail.

Signed-off-by: Nathan Lynch <ntl@pobox.com>
[yann.morin.1998 at free.fr: use $(INSTALL) instead of cp]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Arnout Vandecappelle <arnout@mind.be>
---
 package/busybox/busybox.mk | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/package/busybox/busybox.mk b/package/busybox/busybox.mk
index ad8bdaf..8d40bca 100644
--- a/package/busybox/busybox.mk
+++ b/package/busybox/busybox.mk
@@ -135,7 +135,7 @@ endef
 endif
 
 define BUSYBOX_COPY_CONFIG
-	cp -f $(BUSYBOX_CONFIG_FILE) $(BUSYBOX_BUILD_CONFIG)
+	$(INSTALL) -D -m 0644 $(BUSYBOX_CONFIG_FILE) $(BUSYBOX_BUILD_CONFIG)
 endef
 
 # Disable shadow passwords support if unsupported by the C library
-- 
1.8.1.2

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

* [Buildroot] [PATCH 2/2] busybox: ensure $(BUSYBOX_BUILD_CONFIG) is writable
  2013-11-11 17:45 ` [Buildroot] [PATCH 2/2] busybox: ensure $(BUSYBOX_BUILD_CONFIG) " Yann E. MORIN
@ 2013-11-11 20:22   ` Danomi Manchego
  2013-11-12 17:42     ` Yann E. MORIN
  0 siblings, 1 reply; 7+ messages in thread
From: Danomi Manchego @ 2013-11-11 20:22 UTC (permalink / raw)
  To: buildroot

On Mon, Nov 11, 2013 at 12:45 PM, Yann E. MORIN <yann.morin.1998@free.fr> wrote:
> From: Nathan Lynch <ntl@pobox.com>
>
> If $(BUSYBOX_CONFIG_FILE) is read-only (eg. because Buildroot's
> source dir is), the sed fixups to $(BUSYBOX_BUILD_CONFIG) fail.

These share the same issue:

- linux.mk:  $(KERNEL_ARCH_PATH)/configs/buildroot_defconfig
- uclibc,mk:  $(UCLIBC_DIR)/.oldconfig

Danomi -

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

* [Buildroot] [PATCH 2/2] busybox: ensure $(BUSYBOX_BUILD_CONFIG) is writable
  2013-11-11 20:22   ` Danomi Manchego
@ 2013-11-12 17:42     ` Yann E. MORIN
  2013-11-12 17:54       ` Danomi Manchego
  0 siblings, 1 reply; 7+ messages in thread
From: Yann E. MORIN @ 2013-11-12 17:42 UTC (permalink / raw)
  To: buildroot

Danomi, All,

On 2013-11-11 15:22 -0500, Danomi Manchego spake thusly:
> On Mon, Nov 11, 2013 at 12:45 PM, Yann E. MORIN <yann.morin.1998@free.fr> wrote:
> > From: Nathan Lynch <ntl@pobox.com>
> >
> > If $(BUSYBOX_CONFIG_FILE) is read-only (eg. because Buildroot's
> > source dir is), the sed fixups to $(BUSYBOX_BUILD_CONFIG) fail.
> 
> These share the same issue:
> 
> - linux.mk:  $(KERNEL_ARCH_PATH)/configs/buildroot_defconfig
> - uclibc,mk:  $(UCLIBC_DIR)/.oldconfig

Indeed, I'll add them to the series. Thanks! :-)

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  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.  |
'------------------------------^-------^------------------^--------------------'

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

* [Buildroot] [PATCH 2/2] busybox: ensure $(BUSYBOX_BUILD_CONFIG) is writable
  2013-11-12 17:42     ` Yann E. MORIN
@ 2013-11-12 17:54       ` Danomi Manchego
  2013-11-12 18:26         ` Yann E. MORIN
  0 siblings, 1 reply; 7+ messages in thread
From: Danomi Manchego @ 2013-11-12 17:54 UTC (permalink / raw)
  To: buildroot

On Tue, Nov 12, 2013 at 12:42 PM, Yann E. MORIN <yann.morin.1998@free.fr> wrote:
> Danomi, All,
>
> On 2013-11-11 15:22 -0500, Danomi Manchego spake thusly:
>> On Mon, Nov 11, 2013 at 12:45 PM, Yann E. MORIN <yann.morin.1998@free.fr> wrote:
>> > From: Nathan Lynch <ntl@pobox.com>
>> >
>> > If $(BUSYBOX_CONFIG_FILE) is read-only (eg. because Buildroot's
>> > source dir is), the sed fixups to $(BUSYBOX_BUILD_CONFIG) fail.
>>
>> These share the same issue:
>>
>> - linux.mk:  $(KERNEL_ARCH_PATH)/configs/buildroot_defconfig
>> - uclibc,mk:  $(UCLIBC_DIR)/.oldconfig
>
> Indeed, I'll add them to the series. Thanks! :-)

I was going to say that the TARGET_DIR_WARNING_FILE copy in Makefile
and fs/common.mk might need the same treatment as well, but I think we
only ran into that issue once, when a coworker did something silly
like deleting output/build to force a rebuild rather than doing a
"make clean" or deleting all of output.  So that's probably not a real
problem.

Danomi -

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

* [Buildroot] [PATCH 2/2] busybox: ensure $(BUSYBOX_BUILD_CONFIG) is writable
  2013-11-12 17:54       ` Danomi Manchego
@ 2013-11-12 18:26         ` Yann E. MORIN
  0 siblings, 0 replies; 7+ messages in thread
From: Yann E. MORIN @ 2013-11-12 18:26 UTC (permalink / raw)
  To: buildroot

Danomi, All,

On 2013-11-12 12:54 -0500, Danomi Manchego spake thusly:
> On Tue, Nov 12, 2013 at 12:42 PM, Yann E. MORIN <yann.morin.1998@free.fr> wrote:
> > Danomi, All,
> >
> > On 2013-11-11 15:22 -0500, Danomi Manchego spake thusly:
> >> On Mon, Nov 11, 2013 at 12:45 PM, Yann E. MORIN <yann.morin.1998@free.fr> wrote:
> >> > From: Nathan Lynch <ntl@pobox.com>
> >> >
> >> > If $(BUSYBOX_CONFIG_FILE) is read-only (eg. because Buildroot's
> >> > source dir is), the sed fixups to $(BUSYBOX_BUILD_CONFIG) fail.
> >>
> >> These share the same issue:
> >>
> >> - linux.mk:  $(KERNEL_ARCH_PATH)/configs/buildroot_defconfig
> >> - uclibc,mk:  $(UCLIBC_DIR)/.oldconfig
> >
> > Indeed, I'll add them to the series. Thanks! :-)
> 
> I was going to say that the TARGET_DIR_WARNING_FILE copy in Makefile
> and fs/common.mk might need the same treatment as well, but I think we
> only ran into that issue once, when a coworker did something silly
> like deleting output/build to force a rebuild rather than doing a
> "make clean" or deleting all of output.  So that's probably not a real
> problem.

Well, the problem seems to exist today, since that file is copied with a
plain 'cp' and removed with 'rm -f'.

I don't know how it currently work if the skeletton is R/O. But since
this series ensures target/ is R/W, the 'rm -f' will succeed.

But for good measure, I'll fix that as well. Thanks.

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  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.  |
'------------------------------^-------^------------------^--------------------'

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

end of thread, other threads:[~2013-11-12 18:26 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-11-11 17:45 [Buildroot] [pull request] Pull request for branch yem/patchwork Yann E. MORIN
2013-11-11 17:45 ` [Buildroot] [PATCH 1/2] target: ensure target/ dir is writable Yann E. MORIN
2013-11-11 17:45 ` [Buildroot] [PATCH 2/2] busybox: ensure $(BUSYBOX_BUILD_CONFIG) " Yann E. MORIN
2013-11-11 20:22   ` Danomi Manchego
2013-11-12 17:42     ` Yann E. MORIN
2013-11-12 17:54       ` Danomi Manchego
2013-11-12 18:26         ` Yann E. MORIN

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.