git: binutils221: revisit start/stop label generation

John Marino marino at crater.dragonflybsd.org
Wed Apr 6 23:35:34 PDT 2011


commit f070647cc5317c4924be4dd60563fc39c18094cf
Author: John Marino <draco at marino.st>
Date:   Thu Apr 7 08:28:22 2011 +0200

    binutils221: revisit start/stop label generation
    
    In commit b133d3fde203bbf8e2c359d2be9f09c20ce732b5 (3 April), ld's
    lang_insert_orphan function was modified to include all symbols, which
    matches the behavior of binutils 2.17 and allowed kernel modules
    utilizing previously unreferenced __start_* and __stop_* sections to
    load properly.
    
    For at least 4 years, the ld developed by binutils has the policy to
    discard all unreference symbols, considering them "clutter".  This
    commit will revert back ld back to its default behavior unless the
    options -shared or -Bshareable are passed in the command line.  In those
    cases, the linked file will include all symbols, referenced or not.
    
    In the future, we may consider modifying an .em file to define a flag
    that will revert to 2.17 on a per-target basis rather than forcing all
    shared objects to carry extraneous symbols.  I'd have to identify all
    kernel modules requiring this flag before implementing that change.

Summary of changes:
 contrib/binutils-2.21/README.DRAGONFLY |    1 +
 contrib/binutils-2.21/ld/ldlang.c      |   21 ++++++++++++++++-----
 2 files changed, 17 insertions(+), 5 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/f070647cc5317c4924be4dd60563fc39c18094cf


-- 
DragonFly BSD source repository





More information about the Commits mailing list