Bug 31459 - No #pragma GCC visibility {push/pop} (default) in <stdexcept> and <string>
No #pragma GCC visibility {push/pop} (default) in <stdexcept> and <string>
Status: RESOLVED DUPLICATE of bug 19664
Product: gcc
Classification: Unclassified
Component: c++
4.1.1
: P3 minor
: ---
Assigned To: Not yet assigned to anyone
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2007-04-03 15:14 UTC by Roger Jarrett
Modified: 2007-04-03 17:37 UTC (History)
30 users (show)

See Also:
Host: x86_64-unknown-linux-gnu
Target: x86_64-unknown-linux-gnu
Build: x86_64-unknown-linux-gnu
Known to work:
Known to fail:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Roger Jarrett 2007-04-03 15:14:03 UTC
Generic header defect observed on both x86 and x86_64
 
Missing  "#pragma GCC visibility push(default)" and "#pragma GCC visibility pop" directives wrapped around the versions of <stdexcept> and <string> that ship with GCC 4.0 - 4.2.  See for example <new> or <exception>, which are properly encased.

Add #pragma GCC visibility push(default) and 
#pragma GCC visibility pop(default) to string and stdexcept

From new
...
#pragma GCC visibility push(default)

extern "C++" {
...
} // extern "C++"

#pragma GCC visibility pop
....


Workaround:
create a include directory with files 'string' and 'stdexcept' and alter your include path to ssearch this directory first.

string:

#pragma GCC system_header
#pragma GCC visibility push(default)
#include_next <string>
#pragma GCC visibility pop
Comment 1 Andrew Pinski 2007-04-03 17:37:00 UTC
Actually this is fixed in 4.2.0, see PR 19664.

*** This bug has been marked as a duplicate of 19664 ***