Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: Patches and discussions about the oe-core layer
	<openembedded-core@lists.openembedded.org>
Cc: "Rifenbark, Scott M" <scott.m.rifenbark@intel.com>
Subject: Re: [CONSOLIDATED PULL 29/43] package.bbclass: Ensure kernel modules get stripped
Date: Tue, 24 Apr 2012 11:40:53 +0100	[thread overview]
Message-ID: <1335264053.12692.117.camel@ted> (raw)
In-Reply-To: <4F957991.8090800@linux.intel.com>

On Mon, 2012-04-23 at 08:47 -0700, Darren Hart wrote:
> 
> On 04/20/2012 09:45 AM, Saul Wold wrote:
> > From: Richard Purdie <richard.purdie@linuxfoundation.org>
> > 
> > Kernel modules are not marked as executable but we do expect to strip them.
> > This patch adds in missing code to ensure we do this. Without this images
> > are getting sigificantly bloated in size.
> > 
> > Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
> > ---
> >  meta/classes/package.bbclass |    8 ++++++++
> >  1 files changed, 8 insertions(+), 0 deletions(-)
> > 
> > diff --git a/meta/classes/package.bbclass b/meta/classes/package.bbclass
> > index 99c945d..71bd3a6 100644
> > --- a/meta/classes/package.bbclass
> > +++ b/meta/classes/package.bbclass
> > @@ -870,6 +870,14 @@ python split_and_strip_files () {
> >  				elf_file = int(file_list[file][5:])
> >  				#bb.note("Strip %s" % file)
> >  				runstrip(file, elf_file, d)
> > +
> > +
> > +	if (d.getVar('INHIBIT_PACKAGE_STRIP', True) != '1'):	<- white space at end
> 
> Note: Whitespace at end of line.
> 
> I understand it's common practice with bitbake recipes to compare to '1'
> as a string. However, this isn't documented in the usae of
> INHIBIT_PACKAGE_STRIP, and it seems reasonable that someone might try
> setting "True" or "yes" or some other common affirmative label.
> 
> Scott, can we update the ref manual glossary to indicate that assigning
> to the string "1" is the way to set this to true?

I think we need to go over all these "1" tests that change them to be
conditional on the variable set/unset. I did just copy this some another
location within package.bbclass which is fine for 1.2 but needs
revisiting.

> > +		for root, dirs, files in os.walk(dvar):
> > +			for f in files:
> > +				if not f.endswith(".ko"):
> > +					continue
> > +				runstrip(os.path.join(root, f), None, d)
> 
> Not a big deal, but you can drop the "not" and the "continue" and only
> runtstrip if the file ends with ".ko" since there isn't anything else
> done in the loop.

I just have a dislike of functions that look like a set of steps :). I
also suspect the conditions might change here in the future.

Cheers,

Richard




  reply	other threads:[~2012-04-24 10:50 UTC|newest]

Thread overview: 52+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-20 16:44 [CONSOLIDATED PULL 00/43] Post 1.2 Catch Up Saul Wold
2012-04-20 16:44 ` [CONSOLIDATED PULL 01/43] augeas: Add libxml2 dependency Saul Wold
2012-07-17 20:50   ` McClintock Matthew-B29882
2012-04-20 16:44 ` [CONSOLIDATED PULL 02/43] rt-tests: fix dependency on eglibc, clean LDFLAGS passing Saul Wold
2012-04-20 20:04   ` Denys Dmytriyenko
2012-04-20 20:10     ` Saul Wold
2012-04-20 16:44 ` [CONSOLIDATED PULL 03/43] connman: Fix linking with gold linker Saul Wold
2012-04-20 16:44 ` [CONSOLIDATED PULL 04/43] connman: backport test script fixes Saul Wold
2012-04-20 16:44 ` [CONSOLIDATED PULL 05/43] python: use PKGSUFFIX for libpython2 Saul Wold
2012-04-20 16:44 ` [CONSOLIDATED PULL 06/43] wpa-supplicant: remove unused files Saul Wold
2012-04-20 16:44 ` [CONSOLIDATED PULL 07/43] wpa-supplicant: move wpa_passphrase to bindir Saul Wold
2012-04-20 16:44 ` [CONSOLIDATED PULL 08/43] update-alternatives.bbclass: Ensure alternatives end up in per file deps Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 09/43] coreutils_*.bb: Use update alternatives and add missing manual alt links Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 10/43] coreutils_*.bb: Sync up file path with busybox and minor cleanup Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 11/43] grep: Use update-alternatives Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 12/43] openssh: " Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 13/43] hdparm: " Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 14/43] iputils: " Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 15/43] net-tools: " Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 16/43] shadow: " Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 17/43] findutils: " Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 18/43] gzip: Use update-alternatives class Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 19/43] module-init-tools: Update to use " Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 20/43] kbd: Use update-alternatives Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 21/43] console-tools: " Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 22/43] sysvinit: Use update-alternatives in a different way Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 23/43] lrzsz: Use update-alternatives to set provides Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 24/43] cpio: use update-alternatives class Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 25/43] dropbear: Use " Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 26/43] ncurses: Use update-alternatives Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 27/43] gthumb: Disable parallel make for gthumb install Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 28/43] qt4-x11-free: enable -accessibility and -sm Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 29/43] package.bbclass: Ensure kernel modules get stripped Saul Wold
2012-04-23 15:47   ` Darren Hart
2012-04-24 10:40     ` Richard Purdie [this message]
2012-05-08 12:43   ` Dominik
2012-04-20 16:45 ` [CONSOLIDATED PULL 30/43] qemu: Backport a patch to solve SSE2 instruction emulation issues Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 31/43] bdwgc: Set ARM_INSTRUCTION_SET to "arm" Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 32/43] bluez4: make alsa support conditional upon DISTRO_FEATURES Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 33/43] gettext.bbclass: Ensure we don't overwrite other DEPENDS_GETTEXT values Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 34/43] binutils: add embedspu for ppc builds Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 35/43] libgcc: Package additional *crt*.o files for PPC Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 36/43] xserver-kdrive: Add xkb to existing docs list Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 37/43] gcc: Add plugins package for ARM, fix /usr/incude packaging Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 38/43] quilt: move empty quiltrc to native sysconfdir Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 39/43] sysstat: Upgrade to 10.0.3 Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 40/43] lame: Upgrade to 3.99.5 Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 41/43] sqlite3: Upgrade to 3.7.11 Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 42/43] distro_tracking: Update Manual Check Saul Wold
2012-04-20 16:45 ` [CONSOLIDATED PULL 43/43] kernel: Fix packaging issue Saul Wold
2012-04-23 15:39   ` Darren Hart
2012-04-24 10:43 ` [CONSOLIDATED PULL 00/43] Post 1.2 Catch Up Richard Purdie

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=1335264053.12692.117.camel@ted \
    --to=richard.purdie@linuxfoundation.org \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=scott.m.rifenbark@intel.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox