Huelse / SEAL-Python

Microsoft SEAL 4.X For Python
MIT License
321 stars 65 forks source link

Encountered problems during setup #123

Open pwl101 opened 1 month ago

pwl101 commented 1 month ago

Type problem

Descripe

D:\SEAL-Python>python setup.py build_ext -i running build_ext building 'seal' extension "D:\Visual Studio\VC\Tools\MSVC\14.41.34120\bin\HostX86\x64\cl.exe" /c /nologo /O2 /W3 /GL /DNDEBUG /MD -DVERSION_INFO=4.0.0 -IC:\Users\m1366\AppData\Local\Programs\Python\Python311\include -Ipybind11/include -ISEAL/native/src -ISEAL/build/native/src -IC:\Users\m1366\AppData\Local\Programs\Python\Python311\Lib\site-packages\pybind11\include -IC:\Users\m1366\AppData\Local\Programs\Python\Python311\include -IC:\Users\m1366\AppData\Local\Programs\Python\Python311\Include "-ID:\Visual Studio\VC\Tools\MSVC\14.41.34120\include" "-ID:\Visual Studio\VC\Tools\MSVC\14.41.34120\ATLMFC\include" "-ID:\Visual Studio\VC\Auxiliary\VS\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\cppwinrt" "-ID:\Visual Studio\VC\Tools\MSVC\14.41.34120\include" "-ID:\Visual Studio\VC\Tools\MSVC\14.41.34120\ATLMFC\include" "-ID:\Visual Studio\VC\Auxiliary\VS\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\cppwinrt" /EHsc /Tpsrc\wrapper.cpp /Fobuild\temp.win-amd64-cpython-311\Release\src\wrapper.obj /std:c++latest /EHsc /bigobj /std:c++latest wrapper.cpp D:\SEAL-Python\pybind11\include\pybind11\detail/type_caster_base.h(482): error C2027: 使用了未定义类型“_frame” C:\Users\m1366\AppData\Local\Programs\Python\Python311\include\pytypedefs.h(22): note: 参见“_frame”的声明 error: command 'D:\Visual Studio\VC\Tools\MSVC\14.41.34120\bin\HostX86\x64\cl.exe' failed with exit code 2

I encountered the above error while executing the Python setup. py build. ext - i command, and I don't know how to solve it

pwl101 commented 1 month ago
新建 BMP 图像
Huelse commented 1 month ago

delete the SEAL/build and run:

cmake -S . -B build -G "Visual Studio 17 2022" -A x64 -DSEAL_USE_MSGSL=OFF -DSEAL_USE_ZLIB=OFF -DSEAL_USE_ZSTD=OFF
cmake --build build --config Release

and copy the SEAL/build/lib/Release/seal-4.1.lib to SEAL/build/lib.