Fail to compile with windows 10

Try deleting all the source files, clone a new copy of the source code and compile it.


D:\APP\Blender\lib\win64_vc15\dpcpp\include\sycl/detail/property_list_base.hpp(123,12): error C2039: "iter_swap": 不是 "std" 的成员 [D:\APP\Blender\build_windows_Release_x64_vc17_Release\intern\cycles\device\cycles_device.vcxproj] C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.37.32822\include\bitset(22,1): message : 参见“std”的声明 [D:\APP\Blender\build_windows_Release_x64_vc17_Release\intern\cycles\device\cycles_device.vcxproj] D:\APP\Blender\lib\win64_vc15\dpcpp\include\sycl/detail/property_list_base.hpp(123,12): error C3861: “iter_swap”: 找不到标识符 [D:\APP\Blender\build_windows_Release_x64_vc17_Release\intern\cycles\device\cycles_device.vcxproj] Alignment of class vec is not in accordance with SYCL specification requirements, a limitation of the MSVC compiler(Error C2719).Requested alignment applied, limited at 64.

Which branch are you trying to build? The main branch compiles fine with that compiler so I’m guessing you’re trying to build 3.6 maybe?

This issue is fixed in main by aefc9835f8f47ea1c993460d5b8b4478155daae5 which hasn’t been back ported to 3.6.

Compile version 4.0
And after checking the source file, this file has been fixed, but it just won’t compile!

version 4.0, main branch

what is the output of make showhash in the blender source folder?

Turn off oneAPI option in cmake, use make release can compile it

D:\APP\Blender\blender>make showhash
Libs_URL=bf-blender - Revision 63484: /trunk/lib/win64_vc15

Ah, there’s 2 places that include sycl.hpp:

intern\cycles\device\oneapi\device_impl.h:7:#  include <sycl/sycl.hpp>
intern\cycles\kernel\device\oneapi\kernel.cpp:14:#  include <sycl/sycl.hpp>

Only intern\cycles\kernel\device\oneapi\kernel.cpp was updated with the fix, but looks like the current failure is coming from the other project: [... cycles_device.vcxproj]

Adding #include <algorithm> to the top of intern\cycles\device\oneapi\device_impl.h would be a good thing to check. Can you try that @LXJ?

Adding # include <algorithm> and make release
error message

D:\APP\Blender\lib\win64_vc15\dpcpp\include\sycl/detail/property_list_base.hpp(123,12): error C2039: "iter_swap": 不是 "std" 的成员 [D:\APP\Blender\build_windows_Release_x64_vc17_Release\intern\cycles\device\cycles_device.vcxproj] D:\APP\Blender\lib\win64_vc15\dpcpp\include\sycl/detail/property_list_base.hpp(123,12): error C3861: “iter_swap”: 找不到标识符 [D:\APP\Blender\build_windows_Release_x64_vc17_Release\intern\cycles\device\cycles_device.vcxproj]

diff --git a/intern/cycles/device/oneapi/device_impl.cpp b/intern/cycles/device/oneapi/device_impl.cpp
index 4928b1124fc..f3bcc1248ee 100644
--- a/intern/cycles/device/oneapi/device_impl.cpp
+++ b/intern/cycles/device/oneapi/device_impl.cpp
@@ -3,7 +3,7 @@
  * SPDX-License-Identifier: Apache-2.0 */

+#  include <algorithm>
 #  include "device/oneapi/device_impl.h"

 #  include "util/debug.h"

seems to make it build for me

I give up and wait for the daily version.
When will the Windows version of the daily build be available for download? It’s been a week since there was a build.

1 Like

there’s issues with the codesign certificate, will be a couple of days, if you don’t have an intel discrete GPU you can just turn off WITH_CYCLES_DEVICE_ONEAPI in your CMakeCache.txt in your build folder to sidestep the issue.

Adding #include <algorithm> to the top of lib\win64_vc15\dpcpp\include\sycl\detail\property_list_base.hpp can be build for me.