[oe-commits] Roman Khimov : package.bbclass: introduce KEEP_GNU_DEBUGLINK
git version control
git at git.openembedded.org
Sun Jan 24 10:39:19 UTC 2010
Module: openembedded.git
Branch: holger/staging-branch
Commit: 392528d91659ab3272c7609ed4b421c6014907fe
URL: http://gitweb.openembedded.net/?p=openembedded.git&a=commit;h=392528d91659ab3272c7609ed4b421c6014907fe
Author: Roman Khimov <khimov at altell.ru>
Date: Fri Jul 17 10:20:12 2009 +0000
package.bbclass: introduce KEEP_GNU_DEBUGLINK
Currently we're keeping .gnu_debuglink section in files after stripping them.
It makes binaries from successive builds a bit different, which is not good
in situations where you want them to be exactly the same (identical checksums).
So, introducing KEEP_GNU_DEBUGLINK which can be set to zero to disable this
behavior and get identical result on successive builds for most of the
packages.
---
classes/package.bbclass | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/classes/package.bbclass b/classes/package.bbclass
index 062f782..831ef63 100644
--- a/classes/package.bbclass
+++ b/classes/package.bbclass
@@ -197,7 +197,9 @@ 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))
+ debuglink = bb.data.getVar('KEEP_GNU_DEBUGLINK', d, 1) or '1'
+ if debuglink != '0':
+ os.system("%s'%s' --add-gnu-debuglink='%s' '%s'" % (pathprefix, objcopy, debugfile, file))
if newmode:
os.chmod(file, origmode)
More information about the Openembedded-commits
mailing list