Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of problem:
Dynamic libraries are not being reinitialized properly on subsequent reloads.
Version-Release number of selected component (if applicable):
4.4.7
How reproducible:
Always
Steps to Reproduce:
See gcc bug report http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60731
Additional info:
Verified to not be a problem in RHEL 5 but is a problem in the RHEL 7 beta.
The only issue are the assumptions about dlclose behavior, dlclose is certainly not required to always unload the library, even before unique symbols often it has been unable to either temporarily (until some other libraries are dlclosed) or permanently unload certain libraries.
If some library relies on that, it is simply buggy.
This is a bug and there is nothing in the code in the reproducer that should cause dlclose() to not unload the library. clang, icpc and gcc 4.1.2 all do the right thing here, but gcc 4.4.7 does not. It generates code that is not standard compliant and this is a regression from RHEL 5.
I set the status back to new because as I stated in the previous comment, this is a regression when compared to RHEL 5 and both clang++ and icpc generate code that behaves correctly on RHEL 6.
Nevertheless, it is not a bug.
Assumption that dlclose must always unload the library is just bad assumption, there are many reasons why something can't be unloaded.
You can use -fno-gnu-unique to avoid STB_GNU_UNIQUE symbols if you don't care about violating the C++ standard requirements (which clang++ or icpc don't bother with) with new enough toolchains (e.g. Developer Toolset).
-fno-gnu-unique is only available in the newer versions of the devtoolset, so unfortunately that doesn't do anything to resolve the issue with the stock version of gcc that comes with RHEL 6.
Honestly, I LOVE that devtoolset is available and it's GREAT resource for the situations where it can be used, but the point of using RHEL is to have a stable platform and forcing users to have to constantly chase new compiler versions doesn't seem to fit into that paradigm of stability.