[Buildroot] [PATCH v2 06/13] package/skeleton-init-openrc: add support to remount rootfs as rw

michal.lyszczek at bofc.pl michal.lyszczek at bofc.pl
Sun May 19 08:32:27 UTC 2019


Hello Thomas
On 2019-05-18 23:22:40, Thomas Petazzoni wrote:
> Hello,
> 
> On Sun, 12 May 2019 21:55:43 +0200
> Michał Łyszczek <michal.lyszczek at bofc.pl> wrote:
> 
> > diff --git a/package/skeleton-init-openrc/skeleton-init-sysv.mk b/package/skeleton-init-openrc/skeleton-init-sysv.mk
> > index 5ee2192093..bbe80071ae 100644
> > --- a/package/skeleton-init-openrc/skeleton-init-sysv.mk
> > +++ b/package/skeleton-init-openrc/skeleton-init-sysv.mk
> > @@ -15,8 +15,23 @@ SKELETON_INIT_OPENRC_DEPENDENCIES = skeleton-init-common
> >  
> >  SKELETON_INIT_OPENRC_PROVIDES = skeleton
> >  
> > +ifeq ($(BR2_TARGET_GENERIC_REMOUNT_ROOTFS_RW),y)
> > +# Comment /dev/root entry in fstab. When openrc does not find fstab entry for
> > +# "/", it will try to remount "/" as "rw".
> > +define SKELETON_INIT_OPENRC_ROOT_RO_OR_RW
> > +	$(SED) '/^ *\/dev\/root.*$$/s~^~#~' $(TARGET_DIR)/etc/fstab
> > +endef
> > +else
> > +# Uncomment /dev/root entry in fstab which has "ro" option so openrc notices
> > +# it and doesn't remount root to rw.
> > +define SKELETON_INIT_OPENRC_ROOT_RO_OR_RW
> > +	$(SED) '/^# *\/dev\/root.*$$/s~^#\+~~' $(TARGET_DIR)/etc/fstab
> > +endef
> > +endif # BR2_TARGET_GENERIC_REMOUNT_ROOTFS_RW
> 
> Why are you handling the ro/rw rootfs topic from skeleton-init-sysv.mk,
> but the getty topic is handled from openrc.mk (in PATCH 04/13). It
> doesn't seem very consistent.

I just followed already established rules here (based on systemd package).
BR2_TARGET_GENERIC_GETTY is in systemd.mk, and
BR2_TARGET_GENERIC_REMOUNT_ROOTFS_RW is in skeleton-init-systemd.mk
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20190519/c8b8a8b6/attachment.asc>


More information about the buildroot mailing list