POV-Ray : Newsgroups : povray.windows : povray compilation with msvc 2008 problem Server Time
29 Mar 2024 03:39:07 EDT (-0400)
  povray compilation with msvc 2008 problem (Message 1 to 2 of 2)  
From: Urban
Subject: povray compilation with msvc 2008 problem
Date: 13 Sep 2008 16:30:00
Message: <web.48cc217d6351ca73829187ed0@news.povray.org>
Dear All,
I am trying to compile povray on my windows xp sp3, using msvc 2008 v9 nmake. I
continously endup with the following error:

//********************************************************************************
D:\Devel\povwin-3.6>nmake -f windows\makefiles\makefile.vc USE_GUI=0

Microsoft (R) Program Maintenance Utility Version 9.00.21022.08
Copyright (C) Microsoft Corporation.  All rights reserved.

        cl /c /nologo /TP /Fovc_con_debug\povray_textstream.obj /MDd /DWIN32 /Iw
indows\console  /Isource /Isource\patches /Isource\base /Isource\frontend /Ilibr
aries\jpeg  /Ilibraries\png /Ilibraries\zlib /Ilibraries\tiff\libtiff /Zi  /Fdvc
_con_debug\povray.pdb /D_DEBUG /D_CONSOLE /GR /GX    .\source\base\textstream.cp
p
cl : Command line warning D9035 : option 'GX' has been deprecated and will be re
moved in a future release
cl : Command line warning D9036 : use 'EHsc' instead of 'GX'
textstream.cpp
...\source\base\textstream.cpp(211) : error C3861: 'min': identifier not found
NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN
\cl.EXE"' : return code '0x2'
Stop.
//********************************************************************************

I am aware, that msvc uses specific min/max macros that may interfere with
povray source code during compilation. I know the NOMINMAX preprocessor
definition and was trying to apply it in the makefile, but it didn't change
much - still the same error. I was trying to use #undef min, max macros in the
original source code, but it seems little elegant, and doesn't work.
Do You have any suggestions, maybe there is something I am doing wrong or
something that I am missing.
Best,
Lukasz


Post a reply to this message

From: Chris Cason
Subject: Re: povray compilation with msvc 2008 problem
Date: 15 Sep 2008 03:01:36
Message: <48ce0850@news.povray.org>
> I am aware, that msvc uses specific min/max macros that may interfere with
> povray source code during compilation. I know the NOMINMAX preprocessor
> definition and was trying to apply it in the makefile, but it didn't change
> much - still the same error. I was trying to use #undef min, max macros in the
> original source code, but it seems little elegant, and doesn't work.
> Do You have any suggestions, maybe there is something I am doing wrong o

I haven't tried to build the 3.6 source with VC9, however at a guess
try redefining min to be std::min and max to be std::max (or make sure
'using namespace std' is visible where min and max are used).

Of course this may have nothing to do with the problem but without the
source in front of me at the moment it's the first thing that comes to
mind.

-- Chris


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.