intel / intel-npu-acceleration-library

Intel® NPU Acceleration Library
Apache License 2.0
490 stars 52 forks source link

Not able to install the library on windows 11 #133

Open guckuck opened 6 days ago

guckuck commented 6 days ago

I tried to install the library as described: pip install "intel-npu-acceleration-library @ git+https://github.com/intel/intel-npu-acceleration-library.git"

I get the following output from pip/compiler: output.txt

I installed MSYS2 as descriped here: https://code.visualstudio.com/docs/cpp/config-mingw#_installing-the-mingww64-toolchain

I also installed the Visual Studio Build Tools (version 2022 not version 2019). I didn't found the old version.

Best regards Kay

alessandropalla commented 5 days ago

It looks like you are getting some issues during compilation. From the error trace, it appears there’s an issue with the Visual Studio C++ compiler configuration.

The main cause seems to be that cl.exe can't compile a simple test program. A few things to try:

Verify Visual Studio Build Tools: Ensure that the C++ build tools are installed for Visual Studio 2022, and confirm that you’re using the correct MSVC version. Check that all dependencies for C++ compilation are properly configured in the environment.

Permissions on Temp Directories: Some of the file tracking errors are coming from the temporary directory paths (C:\Users\kaypa\AppData\Local\Temp). Sometimes build tools struggle with write permissions in the temp folders. Try clearing the temp folder or redirecting the build process to a non-temp directory with full write access.

CMake and Python Environment: Make sure you’re using a compatible CMake version (>=3.15) and a compatible Python environment. Running cmake --version and python --version will confirm.

Let me know if any of these steps help or if you need further assistance debugging this!

guckuck commented 4 days ago

Thanks for your answer. Sorry, it is long ago that I developed with C++. And it is not long ago that I switched from MacOS to Windows.

The first time I installed everything for "Build desktop with c++" or simular (german: "Desktopentwicklung mit C++"). Same problem. Then I installed only two components: winget install Microsoft.VisualStudio.2022.BuildTools --force --override "--wait --passive --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add Microsoft.VisualStudio.Component.Windows11SDK.22621"

Now I installed C++/CLI-Unterstützung für v143-Buildtools (v14.41-17.11). Same problem.

I use the PowerShell. A simple "helloworld"-app compiles perfect.

I added C:\msys64\ucrt64\bin to path. Do I have to use a Microsoft Compiler?

cmake version is 3.30.5

I also found this: https://stackoverflow.com/questions/53633705/cmake-the-c-compiler-is-not-able-to-compile-a-simple-test-program?newreg=12fa3861577d4e24815af309d66f03b1

There are several hints but I'm not sure what can I do. How to shorten the path?

Thanks again for your help.