Summary: | -fvisibility, with some GCC's causes problems with STL pools due to missing visibility push/pop pragmas in STL includes | ||
---|---|---|---|
Product: | [Unmaintained] arts | Reporter: | Iskren Stoyanov <i.stoyanov> |
Component: | general | Assignee: | Stefan Westerfeld <stefan> |
Status: | RESOLVED FIXED | ||
Severity: | grave | CC: | alexandergleich, anthony, belred, bjorn, bugskde, caleb, ciocile, dehaven-radio, firelight951, fpitt_83, geekboy, hephooey_dev, i.stoyanov, ibc, ivo, kdebugsystem, madman, maksim, marcelo, mschiff, mueller, nilsarne, nitro.120, pbernstein, post, raphink, rauge, raul.redondo, sdkovacs, sjnovick, stefan.asserhall, stefan.vunckx, steveahart, tdfischer, Timorgenius, vesa.hytonen |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Compiled Sources | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: | |||
Attachments: | testcase sources + makefile |
Description
Iskren Stoyanov
2005-08-19 20:25:27 UTC
I forgot to mention arts version it is 1.5 from svn Try with a sane gcc version, that is 3.x. *** Bug 113365 has been marked as a duplicate of this bug. *** *** Bug 114650 has been marked as a duplicate of this bug. *** *** Bug 113364 has been marked as a duplicate of this bug. *** *** Bug 114706 has been marked as a duplicate of this bug. *** mpyne and uga both confirmed it. I think this one is a showstopper, will try to get a test for this on the weekend *** Bug 114802 has been marked as a duplicate of this bug. *** which distribution do you use? please make your distribution vendor apply the patch from http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19664 which adds visibility support to libstdc++. without that your toolchain is broken. Dirk: kubuntu is one of the affected distros. Created attachment 13110 [details]
testcase sources + makefile
Here is a testcase for the problem. It is a bit brittle, as it relies on
non-public problems, but if someone can find a static inline function in the
STL that's spec-mandated, that can be fixed. I haven't fully confirmed this on
a patched system, though, posting it for a wider dessimination..
I guess std::numeric_limits<short>::epsilon will do. *** Bug 114916 has been marked as a duplicate of this bug. *** I'd filed <a href="http://bugs.kde.org/show_bug.cgi?id=114916"><s>Bug 14196<s></a> which was apparantly a duplicate of this, however 10 minutes of searching failed to get me here, hence the duplicate But I digress... There's supposed to be a workaround here? What is it? Sorry, thought it was here. Please see http://bugs.kde.org/show_bug.cgi?id=114650#c7 *** Bug 115083 has been marked as a duplicate of this bug. *** SVN commit 474432 by mueller: disable -fvisibility=hidden for all those broken distro's out there CCBUG: 111115 M +20 -1 acinclude.m4.in --- branches/KDE/3.4/kde-common/admin/acinclude.m4.in #474431:474432 @@ -3286,7 +3286,26 @@ [ AC_BEFORE([AC_PATH_QT_1_3], [KDE_ENABLE_HIDDEN_VISIBILITY]) + AC_MSG_CHECKING([grepping for visibility push/pop in headers]) + if test "x$GXX" = "xyes"; then + AC_LANG_SAVE + AC_LANG_CPLUSPLUS + AC_EGREP_CPP( + [GCC visibility push], + [ #include <cassert> + ], + [ + AC_MSG_RESULT(yes) + kde_stdc_visibility_patched=yes ], + [ + AC_MSG_RESULT(no) + AC_MSG_WARN([Your libstdc++ doesn't appear to be patched for + visibility support. Disabling -fvisibility=hidden]) + + kde_stdc_visibility_patched=no ]) + AC_LANG_RESTORE + kde_have_gcc_visibility=no KDE_CHECK_COMPILER_FLAG(fvisibility=hidden, [ @@ -3314,7 +3333,7 @@ ] ) - if test x$kde_cv_val_qt_gcc_visibility_patched = "xyes"; then + if test x$kde_stdc_visibility_patched = "xyes" && test x$kde_cv_val_qt_gcc_visibility_patched = "xyes"; then CXXFLAGS="$CXXFLAGS -fvisibility=hidden" KDE_CHECK_VISIBILITY_GCC_BUG HAVE_GCC_VISIBILITY=1 SVN commit 474433 by mueller: disable -fvisibility=hidden for all broken distro's out there CCBUG: 111115 M +20 -1 acinclude.m4.in --- branches/KDE/3.5/kde-common/admin/acinclude.m4.in #474432:474433 @@ -3353,7 +3353,26 @@ [ AC_BEFORE([AC_PATH_QT_1_3], [KDE_ENABLE_HIDDEN_VISIBILITY]) + AC_MSG_CHECKING([grepping for visibility push/pop in headers]) + if test "x$GXX" = "xyes"; then + AC_LANG_SAVE + AC_LANG_CPLUSPLUS + AC_EGREP_CPP( + [GCC visibility push], + [ #include <cassert> + ], + [ + AC_MSG_RESULT(yes) + kde_stdc_visibility_patched=yes ], + [ + AC_MSG_RESULT(no) + AC_MSG_WARN([Your libstdc++ doesn't appear to be patched for + visibility support. Disabling -fvisibility=hidden]) + + kde_stdc_visibility_patched=no ]) + AC_LANG_RESTORE + kde_have_gcc_visibility=no KDE_CHECK_COMPILER_FLAG(fvisibility=hidden, [ @@ -3381,7 +3400,7 @@ ] ) - if test x$kde_cv_val_qt_gcc_visibility_patched = "xyes"; then + if test x$kde_stdc_visibility_patched = "xyes" && test x$kde_cv_val_qt_gcc_visibility_patched = "xyes"; then CXXFLAGS="$CXXFLAGS -fvisibility=hidden" KDE_CHECK_VISIBILITY_GCC_BUG HAVE_GCC_VISIBILITY=1 SVN commit 474434 by mueller: disable -fvisibility=hidden if distribution is broken BUG: 111115 M +30 -8 acinclude.m4.in --- trunk/KDE/kde-common/admin/acinclude.m4.in #474433:474434 @@ -2997,16 +2997,38 @@ [ AC_REQUIRE([AC_PATH_QT]) + AC_MSG_CHECKING([grepping for visibility push/pop in headers]) + if test "x$GXX" = "xyes"; then + AC_LANG_SAVE + AC_LANG_CPLUSPLUS + AC_EGREP_CPP( + [GCC visibility push], + [ #include <cassert> + ], + [ + AC_MSG_RESULT(yes) + kde_stdc_visibility_patched=yes ], + [ + AC_MSG_RESULT(no) + AC_MSG_WARN([Your libstdc++ doesn't appear to be patched for + visibility support. Disabling -fvisibility=hidden]) + + kde_stdc_visibility_patched=no ]) + AC_LANG_RESTORE + kde_have_gcc_visibility=no - KDE_CHECK_COMPILER_FLAG(fvisibility=hidden, - [ - kde_have_gcc_visibility=yes - CXXFLAGS="$CXXFLAGS -fvisibility=hidden" - KDE_CHECK_VISIBILITY_GCC_BUG - HAVE_GCC_VISIBILITY=1 - AC_DEFINE_UNQUOTED(__KDE_HAVE_GCC_VISIBILITY, "$HAVE_GCC_VISIBILITY", [define to 1 if -fvisibility is supported]) - ]) + + if test x$kde_stdc_visibility_patched = xyes ; then + KDE_CHECK_COMPILER_FLAG(fvisibility=hidden, + [ + kde_have_gcc_visibility=yes + CXXFLAGS="$CXXFLAGS -fvisibility=hidden" + KDE_CHECK_VISIBILITY_GCC_BUG + HAVE_GCC_VISIBILITY=1 + AC_DEFINE_UNQUOTED(__KDE_HAVE_GCC_VISIBILITY, "$HAVE_GCC_VISIBILITY", [define to 1 if -fvisibility is supported]) + ]) + fi fi ]) this is the upstream bug: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21243 *** Bug 115299 has been marked as a duplicate of this bug. *** *** Bug 115422 has been marked as a duplicate of this bug. *** *** Bug 115430 has been marked as a duplicate of this bug. *** I have patch gcc for pr19664, but amarok still crash when startup, and the backtrack says: Using host libthread_db library "/lib/libthread_db.so.1". `system-supplied DSO at 0xffffe000' has disappeared; keeping its symbols. [Thread debugging using libthread_db enabled] [New Thread -1243863344 (LWP 27618)] [KCrash handler] #4 0x081baf40 in __gnu_cxx::__mt_alloc<PluginManager::StoreItem, __gnu_cxx::__common_pool_policy<__gnu_cxx::__pool, true> >::allocate () #5 0x081bb44a in std::vector<PluginManager::StoreItem, std::allocator<PluginManager::StoreItem> >::_M_insert_aux () #6 0x081b9cf1 in PluginManager::createFromService () #7 0x0811edda in EngineController::loadEngine () #8 0x0811fab5 in EngineController::loadEngine () #9 0x0808d055 in App::applySettings () #10 0x0808fad8 in App::App () #11 0x082246c4 in main () Is this because a vector<mytype> bug which the export patch may introduced? *** Bug 115648 has been marked as a duplicate of this bug. *** *** Bug 115655 has been marked as a duplicate of this bug. *** *** Bug 115797 has been marked as a duplicate of this bug. *** *** Bug 115825 has been marked as a duplicate of this bug. *** *** Bug 115881 has been marked as a duplicate of this bug. *** *** Bug 115961 has been marked as a duplicate of this bug. *** *** Bug 116041 has been marked as a duplicate of this bug. *** *** Bug 114582 has been marked as a duplicate of this bug. *** *** Bug 116221 has been marked as a duplicate of this bug. *** *** Bug 116283 has been marked as a duplicate of this bug. *** *** Bug 116352 has been marked as a duplicate of this bug. *** *** Bug 116373 has been marked as a duplicate of this bug. *** *** Bug 116307 has been marked as a duplicate of this bug. *** *** Bug 116515 has been marked as a duplicate of this bug. *** *** Bug 116348 has been marked as a duplicate of this bug. *** *** Bug 116459 has been marked as a duplicate of this bug. *** *** Bug 116943 has been marked as a duplicate of this bug. *** *** Bug 117058 has been marked as a duplicate of this bug. *** *** Bug 117058 has been marked as a duplicate of this bug. *** *** Bug 117235 has been marked as a duplicate of this bug. *** *** Bug 117318 has been marked as a duplicate of this bug. *** *** Bug 117350 has been marked as a duplicate of this bug. *** *** Bug 117417 has been marked as a duplicate of this bug. *** *** Bug 117606 has been marked as a duplicate of this bug. *** *** Bug 118137 has been marked as a duplicate of this bug. *** *** Bug 118607 has been marked as a duplicate of this bug. *** *** Bug 118613 has been marked as a duplicate of this bug. *** *** Bug 118685 has been marked as a duplicate of this bug. *** *** Bug 120905 has been marked as a duplicate of this bug. *** *** Bug 120541 has been marked as a duplicate of this bug. *** *** Bug 122563 has been marked as a duplicate of this bug. *** *** Bug 117972 has been marked as a duplicate of this bug. *** *** Bug 117972 has been marked as a duplicate of this bug. *** |