Closed Bug 578540 Opened 10 years ago Closed 9 years ago
_TR1 macro redefinition warning spam when building with MSVC10
In the IPC code, the following warning is spammed repeatedly: c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\INCLUDE\yvals.h(21) : warning C4005: '_HAS_TR1' : macro redefinition command-line arguments : see previous definition of '_HAS_TR1'
_HAS_TR1=0 is definied in http://mxr.mozilla.org/mozilla1.9.2/source/ipc/chromium/chromium-config.mk#85 there is also a chromium bug about that (http://code.google.com/p/chromium/issues/detail?id=27238), saying that there is an issue with VS2010 in googletest.
Chris, any chance this can get any love? It makes it very hard to look for other warnings because this and bug 578546 are so overwhelmingly spammed to the console.
Sorry, was on PTO. I think there was another bug on this; I remember it being discussed anyway. The conclusion was that _HAS_TR1=0 isn't supported by VC10, so we should stop trying to build like that. I won't be able to look at this until next week at the earliest.
OK, so yvals.h defines it to 1. Chromium sets it to 0 due to their issues with googletest that they're not in a hurry to fix. Do we care about those issues with the Chromium code we use? If yes, seems that we should be using an ifdef/undef before the _HAS_TR1 define. (Conditional on MSC_VER as well?) If no, we should just remove the define. Let me know and I'll happily make the patch. The warning spam from this issue is ridiculous.
We don't care about googletest. If things are clean in VS9 and VS10, let's just drop the _HAS_TR1 bit.
Builds fine with VC10 and removes the warning. I don't see any difference in browser behavior (IPC seems to be working OK).
Assignee: nobody → ryanvm
Status: NEW → ASSIGNED
Attachment #487792 - Flags: review?(jones.chris.g)
Attachment #487792 - Flags: review?(jones.chris.g) → review+
Passes try with only the usual random orange suspects. Who can a2.0+ this patch?
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla2.0b8
You need to log in before you can comment on or make changes to this bug.