This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PATCH: Define __GXX_WEAK__ to 0 when using -fno-weak



On May 1, 2005, at 4:35 PM, Mark Mitchell wrote:



On a system in which weak symbols are supported (and, hence, SUPPORTS_WEAK is defined), but when -fno-weak is being used, we still define __GXX_WEAK__ to 1, which results in libsupc++ using pointer-comparison to determine typeinfo identity, rather than string-comparison. Fixed with the attached patch. I also added documentation for a few predefined preprocessor symbols which were not otherwise documented.

Tested on x86_64-unknown-linux-gnu, applied on the mainline.

(Personally, I'd be happy to remove -fno-weak entirely, and just say
that wehther or not you get weak/COMDAT symbols depends purely on
whether or not your system supports that.  But, that's another
debate...)

This was PR 14391.


I had messed up the logic when I write a patch for this, oh well.

-- Pinski


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]