compiling error with scons

Compiling, libraries, modules, coding guidelines and porting

Moderators: jesterKing, stiv

Post Reply
jamestw
Posts: 0
Joined: Fri Jul 29, 2005 12:15 pm

compiling error with scons

Post by jamestw »

Code: Select all

C:\bf-blender\blender>scons
scons: Reading SConscript files ...
Using config file: config.opts
scons: done reading SConscript files.
scons: Building targets ...
cl /nologo /EHsc /J /W3 /Gd /MT /Og /Ot /Ob1 /Op /G6 /DWIN32 /D_CONSOLE /DWITH_Q
UICKTIME /D_LIB /DUSE_OPENAL /DFTGL_LIBRARY_STATIC /DGAMEBLENDER=1 /DUSE_SUMO_SO
LID /DNDEBUG /DNAN_BUILDINFO /DBUILD_DATE /I\usr\include /c source\creator\build
info.c /FoC:\bf-blender\build\win32\source\creator\player_buildinfo.obj
buildinfo.c
cl "-DBASE_HEADER="\"source/blender/makesdna/\"" " /EHsc /J /W3 /Gd /MT /Og /Ot
/Ob1 /Op /G6 /MT /W3 /GX /Og /Ot /Ob1 /Op /G6 /DWIN32 /D_CONSOLE /DWITH_QUICKTIM
E /D_LIB /DUSE_OPENAL /DFTGL_LIBRARY_STATIC /DGAMEBLENDER=1 /DUSE_SUMO_SOLID /DN
DEBUG /Iintern\guardedalloc /IC:\bf-blender\build\win32\source\blender\makesdna
/Isource\blender\makesdna /Isource\blender\makesdna /c source\blender\makesdna\i
ntern\makesdna.c /FoC:\bf-blender\build\win32\source\blender\makesdna\intern\mak
esdna.obj
'cl' is not recognized as an internal or external command,
operable program or batch file.
scons: *** [C:\bf-blender\build\win32\source\blender\makesdna\intern\makesdna.ob
j] Error 1
scons: building terminated because of errors.
C:\bf-blender\blender>
How do i make scons find cl.exe

mchs3d
Posts: 0
Joined: Thu Feb 03, 2005 6:05 am
Location: Loveland, CO

Post by mchs3d »

Are you sure you are running this under Cygwin. That's of the UTMOST importance for Windows users using scons. It simply won't work with the normal Windows prompt. If you aren't using Cygwin, install it (especially all of the development tools) and then try again. If that's not the case, just ask, we're always here to help! :D

guitargeek
Posts: 0
Joined: Thu Apr 24, 2003 12:54 am
Location: Greenville,IL USA

Post by guitargeek »

mchs3d, I'm sorry, that is just not the case. I have not compiled with cygwin since scons was introduced into the tree. I use the MSVC free command line tools and have had a lot of success with compiling from the DOS command line.

jamestw, have you followed the instructions here:

http://www.blender3d.org/cms/Microsoft_ ... 276.0.html

z3r0_d
Posts: 289
Joined: Wed Oct 16, 2002 2:38 am
Contact:

Post by z3r0_d »

cl ought to be in your path if you're using cygwin... msvc has a batch file to start a command prompt with the paths setup

looks like this:

Code: Select all

@SET VSINSTALLDIR=C:\Program Files\Microsoft Visual Studio .NET 2003\Common7\IDE
@SET VCINSTALLDIR=C:\Program Files\Microsoft Visual Studio .NET 2003
@SET FrameworkDir=C:\WINDOWS\Microsoft.NET\Framework
@SET FrameworkVersion=v1.1.4322
@SET FrameworkSDKDir=C:\Program Files\Microsoft Visual Studio .NET 2003\SDK\v1.1
@rem Root of Visual Studio common files.

@if "%VSINSTALLDIR%"=="" goto Usage
@if "%VCINSTALLDIR%"=="" set VCINSTALLDIR=%VSINSTALLDIR%

@rem
@rem Root of Visual Studio ide installed files.
@rem
@set DevEnvDir=%VSINSTALLDIR%

@rem
@rem Root of Visual C++ installed files.
@rem
@set MSVCDir=%VCINSTALLDIR%\VC7

@rem
@echo Setting environment for using Microsoft Visual Studio .NET 2003 tools.
@echo (If you have another version of Visual Studio or Visual C++ installed and wish
@echo to use its tools from the command line, run vcvars32.bat for that version.)
@rem

@REM %VCINSTALLDIR%\Common7\Tools dir is added only for real setup.

@set PATH=%DevEnvDir%;%MSVCDir%\BIN;%VCINSTALLDIR%\Common7\Tools;%VCINSTALLDIR%\Common7\Tools\bin\prerelease;%VCINSTALLDIR%\Common7\Tools\bin;%FrameworkSDKDir%\bin;%FrameworkDir%\%FrameworkVersion%;%PATH%;
@set INCLUDE=%MSVCDir%\ATLMFC\INCLUDE;%MSVCDir%\INCLUDE;%MSVCDir%\PlatformSDK\include\prerelease;%MSVCDir%\PlatformSDK\include;%FrameworkSDKDir%\include;%INCLUDE%
@set LIB=%MSVCDir%\ATLMFC\LIB;%MSVCDir%\LIB;%MSVCDir%\PlatformSDK\lib\prerelease;%MSVCDir%\PlatformSDK\lib;%FrameworkSDKDir%\lib;%LIB%

@goto end

:Usage

@echo. VSINSTALLDIR variable is not set. 
@echo.
@echo SYNTAX: %0

@goto end

:end
most of that isn't important though

Blendorphin
Posts: 0
Joined: Sat Nov 15, 2003 12:21 am

Post by Blendorphin »

Hi. The problem is that you need to set FREE_WINDOWS=TRUE in your user-def.mk file. I've had this happen to me lots of times when checking out into a new folder. Just to this at the Cygwin (bash) prompt:

Code: Select all

cd C:/bf-blender/blender
echo 'export FREE_WINDOWS=true' > user-def.mk
That should do the trick!

mchs3d
Posts: 0
Joined: Thu Feb 03, 2005 6:05 am
Location: Loveland, CO

Post by mchs3d »

mchs3d, I'm sorry, that is just not the case. I have not compiled with cygwin since scons was introduced into the tree. I use the MSVC free command line tools and have had a lot of success with compiling from the DOS command line.
Yes, I'm sorry. I guess I have more things to learn about SCons and such. :oops:

guitargeek
Posts: 0
Joined: Thu Apr 24, 2003 12:54 am
Location: Greenville,IL USA

Post by guitargeek »

So jamestw, are you trying to compile under Cygwin/Scons or MSVC Command Line/Scons?

So far in this thread, you have information for both :)

jamestw
Posts: 0
Joined: Fri Jul 29, 2005 12:15 pm

Post by jamestw »

Hey i followed the instructions on the free vc toolkit how every the bit that says to enter ENV = os.environ in the brackets dosn't work when i do it for the sconscript file in blender\source\blender\makesdna\intern\Sconscript
where abouts in the sconscript file do i actually put it.

guitargeek
Posts: 0
Joined: Thu Apr 24, 2003 12:54 am
Location: Greenville,IL USA

Post by guitargeek »

Ack, that part of the instructions are no longer needed. JesterKing added those changes to the CVS.

Make sure of the following:

Add to your enviromental vars in windows to include the

INCLUDE = Path to the MVSC Toolkit INLUCDE, Path to Directx include, Path to C++ toolkit include

LIB = Path to the aboves lib folders

PATH = path to the aboves bin folders

Post Reply