diff options
author | Roman Khimov <khimov@altell.ru> | 2010-04-18 22:41:40 +0000 |
---|---|---|
committer | Roman I Khimov <khimov@altell.ru> | 2010-04-25 17:13:15 +0400 |
commit | 23e874a12711ee156bba5f1bbcd9fa8dd3f2ef83 (patch) | |
tree | 54e0523244d3710850111f6c95b1a1c62923ad14 /classes | |
parent | dd7c2be839a8db7d4afaab6e700b4f81c24fb489 (diff) |
change INHIBIT_PACKAGE_STRIP to PACKAGE_STRIP with more options
Originally approached with "package.bbclass: introduce KEEP_GNU_DEBUGLINK":
http://patchwork.openembedded.org/patch/886/
Redone with a change from INHIBIT_PACKAGE_STRIP to PACKAGE_STRIP which
allows more options. By default it does exactly the same thing as is done
today, strips the binary, but keeps the gnu.debuglink section. When set to
"no", stripping is not done at all, when set to "full" the gnu.debuglink
section is not re-added to the binary.
Signed-off-by: Roman I Khimov <khimov@altell.ru>
Acked-by: Chris Larson <chris_larson@mentor.com>
Diffstat (limited to 'classes')
-rw-r--r-- | classes/package.bbclass | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/classes/package.bbclass b/classes/package.bbclass index 062f782129..910d282a01 100644 --- a/classes/package.bbclass +++ b/classes/package.bbclass @@ -197,7 +197,8 @@ def runstrip(file, d): os.system("%s'%s' --only-keep-debug '%s' '%s'" % (pathprefix, objcopy, file, debugfile)) ret = os.system("%s%s" % (pathprefix, stripcmd)) - os.system("%s'%s' --add-gnu-debuglink='%s' '%s'" % (pathprefix, objcopy, debugfile, file)) + if (bb.data.getVar('PACKAGE_STRIP', d, True) != 'full'): + os.system("%s'%s' --add-gnu-debuglink='%s' '%s'" % (pathprefix, objcopy, debugfile, file)) if newmode: os.chmod(file, origmode) @@ -389,7 +390,7 @@ python populate_packages () { package_list.append(pkg) - if (bb.data.getVar('INHIBIT_PACKAGE_STRIP', d, True) != '1'): + if (bb.data.getVar('PACKAGE_STRIP', d, True) != 'no'): for f in (bb.data.getVar('PACKAGESTRIPFUNCS', d, True) or '').split(): bb.build.exec_func(f, d) |