Bug 13579 - wafsamba/samba_abi: always hide ABI symbols which must be local
Summary: wafsamba/samba_abi: always hide ABI symbols which must be local
Status: RESOLVED FIXED
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: Build (show other bugs)
Version: 4.9.0rc3
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Karolin Seeger
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-08-17 10:12 UTC by Alexander Bokovoy
Modified: 2018-08-24 09:58 UTC (History)
1 user (show)

See Also:


Attachments
propsed patch forv v4.9 (2.89 KB, patch)
2018-08-17 10:15 UTC, Alexander Bokovoy
asn: review+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Bokovoy 2018-08-17 10:12:44 UTC
binutils 2.31 is going to change how shared libraries are linked, such that they always provide their own local definitions of the _end, _edata and _bss_start symbols.  This would all be fine, except for shared libraries that export all symbols be default.  (Rather than just exporting those symbols that form part of their API).
    
According to binutils developers, we should only export the symbols we explicitly want to be used. We don't use this principle for all our libraries and deliberately don't want to have ABI versioning control for all of them, so the change I introduce here is to explicitly mark those symbols that will always be added by default linker configuration with binutils 2.31 as local. Right now these are '_end', '_edata', and '__bss_start' symbols.

This was pushed to git master as

commit 4e123c46820e737968fa3d1c594aa016cca39637
Author: Alexander Bokovoy <ab@samba.org>
Date:   Thu Jul 12 10:19:41 2018 +0300

    wafsamba/samba_abi: always hide ABI symbols which must be local
    
    binutils 2.31 is going to change how shared libraries are linked, such
    that they always provide their own local definitions of the _end, _edata
    and _bss_start symbols.  This would all be fine, except for shared
    libraries that export all symbols be default.  (Rather than just
    exporting those symbols that form part of their API).
    
    According to binutils developers, we should only export the symbols we
    explicitly want to be used. We don't use this principle for all our
    libraries and deliberately don't want to have ABI versioning control for
    all of them, so the change I introduce here is to explicitly mark those
    symbols that will always be added by default linker configuration with
    binutils 2.31 as local. Right now these are '_end', '_edata', and
    '__bss_start' symbols.
    
    Signed-off-by: Alexander Bokovoy <ab@samba.org>
    Reviewed-by: Andrew Bartlett <abartlet@samba.org>
    
    Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
    Autobuild-Date(master): Fri Jul 13 17:45:36 CEST 2018 on sn-devel-144
Comment 1 Alexander Bokovoy 2018-08-17 10:15:41 UTC
Created attachment 14428 [details]
propsed patch forv  v4.9
Comment 2 Andreas Schneider 2018-08-17 10:18:42 UTC
Karolin, please add the patch to 4.9. Thanks.
Comment 3 Karolin Seeger 2018-08-23 08:12:10 UTC
(In reply to Andreas Schneider from comment #2)
Pushed to autobuild-v4-9-test.
Comment 4 Karolin Seeger 2018-08-24 09:58:47 UTC
(In reply to Karolin Seeger from comment #3)
Pushed to v4-9-test.
Closing out bug report.

Thanks!