[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [43446] trunk/blender: Compilation error when using mingw+scons
Sergey Sharybin
sergey.vfx at gmail.com
Tue Jan 17 11:32:31 CET 2012
Revision: 43446
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=43446
Author: nazgul
Date: 2012-01-17 10:32:17 +0000 (Tue, 17 Jan 2012)
Log Message:
-----------
Compilation error when using mingw+scons
Error was caused by boost library (which doesn't seem to be working with Cycles too
when compiling with mingw). Switched mingw to use TR1 unordered collections. Also,
there was re-declaration of strcasecmp when mingw is used.
Additional changes are related on using own process spawning when BF_TOOLSET is set to
mingw. Seems to be working fine now (i've got too long command line error) and no
warning are supressing now (as it was told in comment for commented own process spawning).
Modified Paths:
--------------
trunk/blender/SConstruct
trunk/blender/build_files/scons/tools/btools.py
trunk/blender/extern/carve/SConscript
trunk/blender/extern/carve/include/carve/win32.h
trunk/blender/intern/boolop/SConscript
Modified: trunk/blender/SConstruct
===================================================================
--- trunk/blender/SConstruct 2012-01-17 05:46:34 UTC (rev 43445)
+++ trunk/blender/SConstruct 2012-01-17 10:32:17 UTC (rev 43446)
@@ -147,9 +147,8 @@
env.Tool('mstoolkit', [toolpath])
else:
env = BlenderEnvironment(tools=[toolset], ENV = os.environ)
- # xxx commented out, as was supressing warnings under mingw..
- #if env:
- # btools.SetupSpawn(env)
+ if env:
+ btools.SetupSpawn(env)
else:
if bitness==64 and platform=='win32':
env = BlenderEnvironment(ENV = os.environ, MSVS_ARCH='amd64')
Modified: trunk/blender/build_files/scons/tools/btools.py
===================================================================
--- trunk/blender/build_files/scons/tools/btools.py 2012-01-17 05:46:34 UTC (rev 43445)
+++ trunk/blender/build_files/scons/tools/btools.py 2012-01-17 10:32:17 UTC (rev 43446)
@@ -222,15 +222,15 @@
newargs = string.join(args[1:], ' ')
cmdline = cmd + " " + newargs
startupinfo = subprocess.STARTUPINFO()
- startupinfo.dwFlags |= subprocess.STARTF_USESHOWWINDOW
+ #startupinfo.dwFlags |= subprocess.STARTF_USESHOWWINDOW
proc = subprocess.Popen(cmdline, stdin=subprocess.PIPE, stdout=subprocess.PIPE,
stderr=subprocess.PIPE, startupinfo=startupinfo, shell = False)
data, err = proc.communicate()
rv = proc.wait()
- if rv:
- print "====="
- print err
- print "====="
+ if data:
+ print(data)
+ if err:
+ print(err)
return rv
def SetupSpawn( env ):
Modified: trunk/blender/extern/carve/SConscript
===================================================================
--- trunk/blender/extern/carve/SConscript 2012-01-17 05:46:34 UTC (rev 43445)
+++ trunk/blender/extern/carve/SConscript 2012-01-17 10:32:17 UTC (rev 43446)
@@ -14,7 +14,8 @@
if env['WITH_BF_BOOST']:
if env['OURPLATFORM'] not in ('win32-vc', 'win64-vc'):
# Boost is setting as preferred collections library in the Carve code when using MSVC compiler
- defs.append('HAVE_BOOST_UNORDERED_COLLECTIONS')
+ if env['OURPLATFORM'] != 'win32-mingw':
+ defs.append('HAVE_BOOST_UNORDERED_COLLECTIONS')
defs.append('CARVE_SYSTEM_BOOST')
incs.append(env['BF_BOOST_INC'])
Modified: trunk/blender/extern/carve/include/carve/win32.h
===================================================================
--- trunk/blender/extern/carve/include/carve/win32.h 2012-01-17 05:46:34 UTC (rev 43445)
+++ trunk/blender/extern/carve/include/carve/win32.h 2012-01-17 10:32:17 UTC (rev 43446)
@@ -8,9 +8,11 @@
#include <string.h>
#include <stdlib.h>
+#if !defined(__MINGW32__)
inline int strcasecmp(const char *a, const char *b) {
return _stricmp(a,b);
}
+#endif
inline void srandom(unsigned long input) {
srand(input);
Modified: trunk/blender/intern/boolop/SConscript
===================================================================
--- trunk/blender/intern/boolop/SConscript 2012-01-17 05:46:34 UTC (rev 43445)
+++ trunk/blender/intern/boolop/SConscript 2012-01-17 10:32:17 UTC (rev 43446)
@@ -17,7 +17,8 @@
if env['WITH_BF_BOOST']:
if env['OURPLATFORM'] not in ('win32-vc', 'win64-vc'):
# Boost is setting as preferred collections library in the Carve code when using MSVC compiler
- defs.append('HAVE_BOOST_UNORDERED_COLLECTIONS')
+ if env['OURPLATFORM'] != 'win32-mingw':
+ defs.append('HAVE_BOOST_UNORDERED_COLLECTIONS')
defs.append('CARVE_SYSTEM_BOOST')
incs += ' ' + env['BF_BOOST_INC']
More information about the Bf-blender-cvs
mailing list