[Bug libc/23145] _init/_fini aren't marked as hidden

cvs-commit at gcc dot gnu.org sourceware-bugzilla@sourceware.org
Fri Jun 8 17:58:00 GMT 2018


https://sourceware.org/bugzilla/show_bug.cgi?id=23145

--- Comment #2 from cvs-commit at gcc dot gnu.org <cvs-commit at gcc dot gnu.org> ---
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, master has been updated
       via  67c0579669ba1fc265d770252fab31babf887329 (commit)
      from  1c09524e4db3efd797ebcfcd8241bdb78f0b06f0 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=67c0579669ba1fc265d770252fab31babf887329

commit 67c0579669ba1fc265d770252fab31babf887329
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Jun 8 10:28:38 2018 -0700

    Mark _init and _fini as hidden [BZ #23145]

    _init and _fini are special functions provided by glibc for linker to
    define DT_INIT and DT_FINI in executable and shared library.  They
    should never be put in dynamic symbol table.  This patch marks them as
    hidden to remove them from dynamic symbol table.

    Tested with build-many-glibcs.py.

        [BZ #23145]
        * elf/Makefile (tests-special): Add $(objpfx)check-initfini.out.
        ($(all-built-dso:=.dynsym): New target.
        (common-generated): Add $(all-built-dso:$(common-objpfx)%=%.dynsym).
        ($(objpfx)check-initfini.out): New target.
        (generated): Add check-initfini.out.
        * scripts/check-initfini.awk: New file.
        * sysdeps/aarch64/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/alpha/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/arm/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/hppa/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/i386/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/ia64/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/m68k/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/microblaze/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/mips/mips32/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/mips/mips64/n32/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/mips/mips64/n64/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/nios2/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/powerpc/powerpc32/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/powerpc/powerpc64/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/s390/s390-32/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/s390/s390-64/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/sh/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/sparc/crti.S (_init): Mark as hidden.
        (_fini): Likewise.
        * sysdeps/x86_64/crti.S (_init): Mark as hidden.
        (_fini): Likewise.

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog                        |   48 +++++++++++++++++++++++++++++
 elf/Makefile                     |   15 ++++++++-
 scripts/check-initfini.awk       |   63 ++++++++++++++++++++++++++++++++++++++
 sysdeps/aarch64/crti.S           |    2 +
 sysdeps/alpha/crti.S             |    2 +
 sysdeps/arm/crti.S               |    2 +
 sysdeps/hppa/crti.S              |    2 +
 sysdeps/i386/crti.S              |    2 +
 sysdeps/ia64/crti.S              |    2 +
 sysdeps/m68k/crti.S              |    2 +
 sysdeps/microblaze/crti.S        |    2 +
 sysdeps/mips/mips32/crti.S       |    2 +
 sysdeps/mips/mips64/n32/crti.S   |    2 +
 sysdeps/mips/mips64/n64/crti.S   |    2 +
 sysdeps/nios2/crti.S             |    2 +
 sysdeps/powerpc/powerpc32/crti.S |    2 +
 sysdeps/powerpc/powerpc64/crti.S |    2 +
 sysdeps/s390/s390-32/crti.S      |    2 +
 sysdeps/s390/s390-64/crti.S      |    2 +
 sysdeps/sh/crti.S                |    2 +
 sysdeps/sparc/crti.S             |    2 +
 sysdeps/x86_64/crti.S            |    2 +
 22 files changed, 163 insertions(+), 1 deletions(-)
 create mode 100644 scripts/check-initfini.awk

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Glibc-bugs mailing list