4

I am stuck with a problem in Visual 2008 SP1.

The compiler yields:

'/fp:fast' and '/Za' are not compatible

The problem is that i did NOT use /Za in the properties.. so I don't get why there should be a conflict when the option isn't set.

here is the generated command line in my project properties :

/Od /I "..\..\..\..\..\tools\gsoap-soapcpp-2.7.6\src" /I "..\..\..\..\..\platform\vs2008\win32\gsoap-soapcpp-2.7.6\src"   
/D "WIN32" /D "_DEBUG" /D   
"_CONSOLE" /D "YY_NO_UNISTD_H" /D "_WIN32_WCE=0x700" /D "UNDER_CE" /D "WINCE" /D   
"DEBUG" /D "ARM" /D "_ARM_" /D "_UNICODE" /D "UNICODE" /Gm /EHsc /MTd /fp:fast /GR-   
/Fo"Freescale i.MX53 QSB - WEC7 (ARMv4I)\Debug IMX53/" /Fd"Freescale i.MX53 QSB - WEC7   
(ARMv4I)\Debug IMX53/vc80.pdb" /W3 /nologo /c /TP /wd4996  

As you can see, /fp:fast is set but not /Za.

Is there another option that might indirectly refer to /Za ?

After digging a bit more, i realised that the BuildLog.htm file was saying :

Creating temporary file "(...)\Freescale i.MX53 QSB - WEC7 (ARMv4I)\Debug IMX53\RSP00000341365424.rsp" with content  

[{CORRECT COMMAND LINE}

{list of source files paths}
]  

Creating command line "cl.exe @"(...)\Freescale i.MX53 QSB - WEC7 (ARMv4I)\Debug IMX53\RSP00000341365424.rsp" /nologo"
Creating temporary file "(...)\Freescale i.MX53 QSB - WEC7 (ARMv4I)\Debug IMX53\RSP00000441365424.rsp" with content
[  
{WRONG COMMAND LINE containing /Za}  
{list of source files paths}
]
Creating command line "cl.exe @"(...)\Freescale i.MX53 QSB - WEC7 (ARMv4I)\Debug IMX53\RSP00000441365424.rsp"/nologo"

Do you have any idea why this second temporary file might be created ? Is there a property I have to fix in my project ?

[EDIT] Thanks to Hans I figured out the problem. One of my files in the project had a different compiler option that I was unaware of which caused the problem. I found which one it was thanks to the buildlog.htm file

djfoxmccloud
  • 571
  • 1
  • 9
  • 23

3 Answers3

4

Seeing the compiler getting started more than once is a strong hint to the source of the problem. You probably have some source code files in the project that have /Za turned on individually. A quick fix is to select all the files in the project with Shift+Click and resetting the option.

Hans Passant
  • 922,412
  • 146
  • 1,693
  • 2,536
1

In Visual Studio 2008, Project -> Properties -> Configuration Properties -> C/C++ -> Language, change "Disable Language Extensions" from "Yes(/Za)" to "No".

Xuezhong
  • 81
  • 1
  • 5
0

My guess is that you are using the wrong version of WinCE for VS2008 - you appear to be compiling for ARM here, yes? My suspicions are aroused by the reference to vc80.pdb which is on the face of it a VS2005 vintage symbol file. Maybe this is a VS2005 project that you are porting across?

The question here indicates you should not manually define _WIN32_WCE, you could try the suggestion it provides for correlating this to the correct Platform SDK definition.

Community
  • 1
  • 1
Steve Townsend
  • 53,498
  • 9
  • 91
  • 140
  • Well, i don't define it manually. It is set to WIN32_WCE=$(CEVER) which is then processed as "_WIN32_WCE=0x700". Concerning the vc80.pdb, yes my project is a project that was upgraded from 2005 to 2008. – djfoxmccloud May 07 '12 at 12:11
  • I am afraid my input was a bit of a shot in the dark but seemed too big for a comment. Have you tried importing the code as a new project instead of upgrading? perhaps the upgrade process for this variant has one or more bugs. Is there any setting in the GUI project properties (or in the .vcproj file) that looks like it might be VS2005-y? eg. if you see 80 anywhere try changing it to 90 (after backing up the original). I wonder if you are somehow picking up a VS2005 library that is binary-incompatible with VS2008. – Steve Townsend May 07 '12 at 13:10
  • Well it seems it is not what was the problem but I might have to change it thought. Thanks – djfoxmccloud May 07 '12 at 13:26