Topic: scons can't find PYthon

HI there maratis users-

Trying to get scons installed so I can compile Mar., but scons can't find the python installation, and the python install is definitely
showing up . It works from the SHELL in windows and  its clearly setup in PATH, pointing directly to the python DIR, where the python .exe is.

Any idea why scons can't find it ?

I have PYthon 2.74 which is fine according to scons FAQ,and the latest stable scons version 2.3

thx
Gm

Re: scons can't find PYthon

Hi gamemaker,

why don't you just use the scons.py script provided by Maratis?
That works fine for me without installing anything additional (Windows 7 64bit, Python 2.3.7).
You can find it in

trunk/dev/scons.py

I hope this helps wink

Sponk

Re: scons can't find PYthon

I tried running python scons.py and it clearly started working just fine, but then I got this:

cl /Fobuild\win32_i386\release\3rdparty\assimp\code\LWOAnimation.obj /c "C:\Users\Gaillard Lee\Downloads\maratis-master\3rdparty\assimp\code\LWOAnimation.cpp" /TP /nologo /EHsc /nologo /GR /
FC /W1 /O2 /Ot /MD /arch:SSE2 /DWIN32 /D_MBCS /DNDEBUG /DASSIMP_BUILD_BOOST_WORKAROUND /DASSIMP_BUILD_NO_OWN_ZLIB /Ibuild\win32_i386\release\3rdparty\assimp "/IC:\Users\Gaillard Lee\Download
s\maratis-master\3rdparty\assimp" /Ibuild\win32_i386\release\3rdparty\assimp\include "/IC:\Users\Gaillard Lee\Downloads\maratis-master\3rdparty\assimp\include" /Ibuild\win32_i386\release\3rd
party\assimp\code\BoostWorkaround "/IC:\Users\Gaillard Lee\Downloads\maratis-master\3rdparty\assimp\code\BoostWorkaround" /Ibuild\win32_i386\release\3rdparty\zlib "/IC:\Users\Gaillard Lee\Do
wnloads\maratis-master\3rdparty\zlib"
LWOAnimation.cpp
c:\users\gaillard lee\downloads\maratis-master\3rdparty\assimp\code\lwoanimation.cpp(159) : error C2039: 'bind1st' : is not a member of 'std'
c:\users\gaillard lee\downloads\maratis-master\3rdparty\assimp\code\lwoanimation.cpp(159) : error C2039: 'greater' : is not a member of 'std'
c:\users\gaillard lee\downloads\maratis-master\3rdparty\assimp\code\lwoanimation.cpp(159) : error C2065: 'greater' : undeclared identifier
c:\users\gaillard lee\downloads\maratis-master\3rdparty\assimp\code\lwoanimation.cpp(159) : error C2062: type 'double' unexpected
c:\users\gaillard lee\downloads\maratis-master\3rdparty\assimp\code\lwoanimation.cpp(159) : error C3861: 'bind1st': identifier not found
c:\users\gaillard lee\downloads\maratis-master\3rdparty\assimp\code\lwoanimation.cpp(177) : error C2065: 'm' : undeclared identifier
c:\users\gaillard lee\downloads\maratis-master\3rdparty\assimp\code\lwoanimation.cpp(178) : error C2065: 'm' : undeclared identifier
c:\users\gaillard lee\downloads\maratis-master\3rdparty\assimp\code\lwoanimation.cpp(181) : error C2065: 'm' : undeclared identifier
c:\users\gaillard lee\downloads\maratis-master\3rdparty\assimp\code\lwoanimation.cpp(189) : error C2065: 'm' : undeclared identifier
c:\users\gaillard lee\downloads\maratis-master\3rdparty\assimp\code\lwoanimation.cpp(190) : error C2065: 'm' : undeclared identifier
scons: *** [build\win32_i386\release\3rdparty\assimp\code\LWOAnimation.obj] Error 2
scons: building terminated because of errors.

Also it should be noted, that few are going to understand ( as I clearly didn't ) you do NOT need scons to do this, because INSTALL reads as following:

" Make sure you have Python and scons installed, open a shell and type : "python scons.py" after the build, the final product can be found in the "prod/" directory "

But anyway, - any idea what might be up ?

ty
Gm

Re: scons can't find PYthon

Hi,

there is some recurring problems on windows which I don't fully understand,
most of it seems to be linked with Assimp and the new c++ standard (maybe).

What windows are you using ? and what compiler is installed ? (I know it works with visual studio 8, not sure about more recent versions)

Re: scons can't find PYthon

Hi Anael and thx for reply wink))

I am using Windows 8 64bit ( No doubt by now, many people are, not sure how widespread it is so far), and I have ms express 2010 and 2012 installed. I just saw no reason to go back further than 2010, but I'm willing to install it if need be I guess.

Cheers
Gm

Re: scons can't find PYthon

I don't think it's about VS 2010 because it works fine for me.

Maybe your VS 2012 installation messed around with some environment variables so you can't use the 'old' VS 2010 compiler anymore?

Sponk

Re: scons can't find PYthon

Sponk wrote:

I don't think it's about VS 2010 because it works fine for me.

Maybe your VS 2012 installation messed around with some environment variables so you can't use the 'old' VS 2010 compiler anymore?

Sponk

How would I verify that if so to avoid removing VS 2010 if indeed it's not the problem ?

All I can be sure of, is that VS10 and 11, both have their own ENV VAR as shown in my computer's ENV VAR section.

thx
Gm

Re: scons can't find PYthon

I"d like to avoid removing an entire VS app if I don't need to , as its not a quick install ( or removal). Any ideas on this before that happens ? wink Im stuck until this is resolved.

EDIT: Im going to just remove VS2010 and keep 2012 and see if that helps...i'd rather have current than old, so this just makes sense. I'll report if this change allows compilation to be successful.

thx
Gm

Re: scons can't find PYthon

I'm going to make this a new post to make sure its noticed.

I removed VS2010 and kept VS 2012 for obvious reasons, and after running python scons.py, and as note by Anael about ASSIMP issues,  I am now posting the results:

LWOAnimation.cpp
c:\users\gaillard lee\downloads\ maratis3.21\3rdparty\assimp\code\lwoanimation.cpp(159) : error C2039: 'bind1st' : is not a member of 'std'
c:\users\gaillard lee\downloads\ maratis3.21\3rdparty\assimp\code\lwoanimation.cpp(159) : error C2039: 'greater' : is not a member of 'std'
c:\users\gaillard lee\downloads\ maratis3.21\3rdparty\assimp\code\lwoanimation.cpp(159) : error C2065: 'greater' : undeclared identifier
c:\users\gaillard lee\downloads\ maratis3.21\3rdparty\assimp\code\lwoanimation.cpp(159) : error C2062: type 'double' unexpected
c:\users\gaillard lee\downloads\ maratis3.21\3rdparty\assimp\code\lwoanimation.cpp(159) : error C3861: 'bind1st': identifier not found
c:\users\gaillard lee\downloads\ maratis3.21\3rdparty\assimp\code\lwoanimation.cpp(177) : error C2065: 'm' : undeclared identifier
c:\users\gaillard lee\downloads\ maratis3.21\3rdparty\assimp\code\lwoanimation.cpp(178) : error C2065: 'm' : undeclared identifier
c:\users\gaillard lee\downloads\ maratis3.21\3rdparty\assimp\code\lwoanimation.cpp(181) : error C2065: 'm' : undeclared identifier
c:\users\gaillard lee\downloads\ maratis3.21\3rdparty\assimp\code\lwoanimation.cpp(189) : error C2065: 'm' : undeclared identifier
c:\users\gaillard lee\downloads\ maratis3.21\3rdparty\assimp\code\lwoanimation.cpp(190) : error C2065: 'm' : undeclared identifier
scons: *** [build\win32_i386\release\3rdparty\assimp\code\LWOAnimation.obj] Error 2
scons: building terminated because of errors.

Im not sure its logical that I should ( or anyone ?) have to revert to a older version of VS just to get this working, as that means Im going backwards in features ( why I'd like to keep 2012 : http://msdn.microsoft.com/en-us/library/bb386063.aspx ) and likely stability of a product and I'm just not willing to do that just yet if I can at all avoid it.

Short of that, I hope Anael can find the issues with Assimp , because at least so far I am having no other errors in compilation of other software.

Thx wink
Gm

Re: scons can't find PYthon

I did some research and it seems that Microsoft moved some std:: functions and broke the compatibility,
which would explain why it works with older versions of visual and why it works on linux and mac (gcc).

This functions (std:: bind1st, std::greater...) are used by assimp only,

try adding this line on top of "lwoanimation.cpp" and to other files having the same errors :

#include <functional>

I don't have visual studio 2012 installed so I cannot test it,
tell me how it goes and we'll update the code on svn.

(we could also put a bug report on assimp website)

Re: scons can't find PYthon

OK Anael, thx , that was really fast I must admit wink)
I'll post here with the results.

Cheers
Gm

Re: scons can't find PYthon

Thanks again Anael for that one liner inclusion, as it worked fine, giving no errors this time wink

Cheers
Gm

Re: scons can't find PYthon

good,

can you confirm me where you added the line so I can correct it on svn too,
only in lwoanimation.cpp or in other files also ?

Re: scons can't find PYthon

Only in lwoanimation.cpp wink