bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug gold/16100] New: shared lib exports definition of _ZdlPv even thoug


From: sbergman at redhat dot com
Subject: [Bug gold/16100] New: shared lib exports definition of _ZdlPv even though local per --version-script
Date: Wed, 30 Oct 2013 13:59:40 +0000

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

            Bug ID: 16100
           Summary: shared lib exports definition of _ZdlPv even though
                    local per --version-script
           Product: binutils
           Version: 2.23
            Status: NEW
          Severity: normal
          Priority: P2
         Component: gold
          Assignee: ian at airs dot com
          Reporter: sbergman at redhat dot com
                CC: ccoutant at google dot com

I can reproduce this at least on Fedora 19 (binutils-2.23.52.0.1-9.fc19.x86_64)
but it reportedly also hits "GNU gold (GNU Binutils; openSUSE 12.3 2.23.1)
1.11".

With lib1.cc containing:

  void test1(char * p) { delete p; }

and lib2.cc containing:

  void operator delete(void *) throw() {}
  extern "C" void test2() {}

and lib2.ver containing:

  {
  global:
    test2;
  local:
    *;
  };

When switching alternatives to use /usr/bin/ld.gold:

  $ g++ -shared -fPIC -o lib1.so lib1.cc
  $ g++ -shared -fPIC -o lib2.so -Wl,--version-script,lib2.ver lib2.cc -L. -l1
  $ nm lib2.so | grep _ZdlPv
  0000000000000698 T _ZdlPv

shows that the operator delete(void *) replacement function is exported from
lib2.so even though the version script demotes it to local.  Doing the above
with /usr/bin/ld.bfd results in local

  00000000000005e8 t _ZdlPv

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



reply via email to

[Prev in Thread] Current Thread [Next in Thread]