[OE-core] [oe-core][PATCH 2/6] kernel.bbclass: use symlinks for modutils files

Richard Purdie richard.purdie at linuxfoundation.org
Mon Mar 26 22:05:29 UTC 2012


On Mon, 2012-03-26 at 11:46 -0700, Darren Hart wrote:
> What is the motivation?
> 
> On 03/23/2012 05:56 AM, Martin Jansa wrote:
> > Signed-off-by: Martin Jansa <Martin.Jansa at gmail.com>
> > ---
> >  meta/classes/kernel.bbclass |    8 +++-----
> >  1 files changed, 3 insertions(+), 5 deletions(-)
> > 
> > diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass
> > index 975ae13..54ed7f7 100644
> > --- a/meta/classes/kernel.bbclass
> > +++ b/meta/classes/kernel.bbclass
> > @@ -407,16 +407,14 @@ python populate_packages_prepend () {
> >  		# appropriate modprobe commands to the postinst
> >  		autoload = d.getVar('module_autoload_%s' % basename, True)
> >  		if autoload:
> > -			name = '%s/etc/modutils/%s' % (dvar, basename)
> > -			f = open(name, 'w')
> > -			for m in autoload.split():
> > -				f.write('%s\n' % m)
> > -			f.close()
> >  			name = '%s/etc/modules-load.d/%s.conf' % (dvar, basename)
> >  			f = open(name, 'w')
> >  			for m in autoload.split():
> >  				f.write('%s\n' % m)
> >  			f.close()
> > +			modutils_name = '%s/etc/modutils/%s' % (dvar, basename)
> > +			modutils_target = '../modules-load.d/%s.conf' % (basename)
> > +			os.symlink(modutils_target, modutils_name)
> 
> This basically undoes what was added in 1/2 and replaces it with
> symblinks right?
> 
> If so, just do it as symlinks in the first place.

This is one patch set its best to read in totality as the symlinks get
removed later. I thought about squashing the series but decided to leave
it for history.

Cheers,

Richard






More information about the Openembedded-core mailing list