Wireshark-dev: Re: [Wireshark-dev] [Wireshark-commits] rev 20609: /trunk/ /trunk/:config.h.win3
From: Ulf Lamping <ulf.lamping@xxxxxx>
Date: Tue, 30 Jan 2007 14:37:17 +0100
Douglas Pratley wrote:
The logic of this looks wrong to me in one sense - the message tells you
that your compiler is 14.00 when it is not (I'm still using 12.00). I
would have thought it should be reversed, so that given a compiler
number, it checks that the variant is one of the accepted values.

More importantly, I tried adding these lines:

#define WS_TO_STRING2(x) #x
#define WS_TO_STRING(x) WS_TO_STRING2(x)
#pragma message( "_MSC_VER: " WS_TO_STRING(_MSC_VER))
#pragma message( "MSVC_VARIANT: " WS_TO_STRING(MSVC_VARIANT) )

I then get:

_MSC_VER: 1200
MSVC_VARIANT: MSVC_VARIANT

I don't think that MSVC_VARIANT, or any of the constants it's being
compared against, are actually getting defined.

I can't see anything in config.nmake that would actually cause them to
be passed to the preprocessor. Am I missing something?
Could you check 20614 instead? At least I've fixed the check logic in config.h here.

As you point it out, I don't know why the config.h lines:
#elseif _MSC_VER == 1200 && (MSVC_VARIANT != MSVC6)
#error Your MSVC_VARIANT setting in config.nmake and the C compiler version 12.00 (V6.0) don't match!

don't trigger an error now (it doesn't do in the builtbot) - as MSVC_VARIANT isn't defined at all, it shouldn't be MSVC6 ?!?

We might need to add something like: -DMSVC_VARIANT=$(MSVC_VARIANT) (I don't have the right syntax at hand) to the Makefile.nmake CFLAGS.

I currently don't really know why it currently doesn't throw a compiler error - but it obviously don't do it now (seems I'm missing something here?!?) ...

Regards, ULFL