Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2015-07-23 10:53:23 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2015-07-23 10:53:23 +0300
commit6ee2f79f33589e86795b95a523d6f6e63262c728 (patch)
tree3888393ffbb945ad8ef4f52991d9957b8f3129b5
parent1788293a0125e178cf7cbea60113ae7d81749cbe (diff)
Cycles: Previous commit broke compilation on Windows
Apparently MSVC doesn't have setenv() function.
-rw-r--r--intern/cycles/blender/blender_python.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/intern/cycles/blender/blender_python.cpp b/intern/cycles/blender/blender_python.cpp
index 5da018ea36e..52b284e03b8 100644
--- a/intern/cycles/blender/blender_python.cpp
+++ b/intern/cycles/blender/blender_python.cpp
@@ -491,7 +491,11 @@ static PyObject *system_info_func(PyObject * /*self*/, PyObject * /*value*/)
static PyObject *opencl_disable_func(PyObject * /*self*/, PyObject * /*value*/)
{
VLOG(2) << "Disabling OpenCL platform.";
+#ifdef _MSC_VER
+ putenv("CYCLES_OPENCL_TEST=NONE");
+#else
setenv("CYCLES_OPENCL_TEST", "NONE", 1);
+#endif
Py_RETURN_NONE;
}
#endif