I am trying to install the Python wrapper for my camera from here. My install command is
python setup.py install
and I am getting the following error
"C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Tools\MSVC\14.35.32215\bin\HostX86\x64\cl.exe" /c /nologo /O2 /W3 /GL /DNDEBUG /MD "-IC:\Users\mesoSPIM Workstation\AppData\Roaming\Python\Python39\site-packages\numpy\core\include" "-IC:\Program Files\Photometrics\PVCamSDK\/inc/" -IC:\Users\Public\Anaconda3\include -IC:\Users\Public\Anaconda3\Include "-IC:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Tools\MSVC\14.35.32215\include" "-IC:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Tools\MSVC\14.35.32215\ATLMFC\include" "-IC:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\VS\include" /EHsc /Tpsrc/pyvcam/pvcmodule.cpp /Fobuild\temp.win-amd64-cpython-39\Release\src/pyvcam/pvcmodule.obj
pvcmodule.cpp
C:\Users\Public\Anaconda3\include\pyconfig.h(59): fatal error C1083: Cannot open include file: 'io.h': No such file or directory
error: command 'C:\\Program Files\\Microsoft Visual Studio\\2022\\Enterprise\\VC\\Tools\\MSVC\\14.35.32215\\bin\\HostX86\\x64\\cl.exe' failed with exit code 2
The installation requires the latest version of C++ build tools which I have installed using the Visual Studio Installer. I have tried to implement the different solutions detailed here: [1], [2] [3]
These solutions in general have to do reinstalling VC++ or installing Win 10/11 SDK. After manually adding environment variables as mentioned here, I get a similar error where the code cannot open the 'basestd.h' file:
fatal error C1083: Cannot open include file: 'basetsd.h': No such file or directory
Also to note: I am not able to reproduce these errors on another PC with the same configuration. The installation works fine there.
I am using Anaconda3 and a Win 11 PC.