how to fix CMake Error in CMakeLists.txt: Generator NMake Makefiles does not support platform specification, but platform x64 was specified

后端 未结 8 2343
情书的邮戳
情书的邮戳 2020-12-05 10:46

I want to install dlib using pip install dlib using cmd in windows 10 But it is showing following three errors: CMake Error in CMakeLists.txt: Generator

相关标签:
8条回答
  • 2020-12-05 11:11

    I had a similar problem when installing dlib and pqkmeans Python packages.

    1. Installing CMAKE or MinGW did not help.
    2. I solved it only after installing the Build Tools for Visual Studio from here (so installing Visual Studion IDE, which is quite huge, is not necessary). When installing, I didn't check any additional ticks - the mininal proposed set of packages was enough.
    3. When installing Visual Studio, I run into a problem from this question (traces of older versions of VS) and dealt with it following the answers to this question.
    0 讨论(0)
  • 2020-12-05 11:12

    The easiest way is to install MS Visual Studio Community Edition, and select Visual C++ (install anything else you want but they are all optional except C++). This will install CMake and the correct compiler and libs in the correct locations.

    • Download the latest Dlib.
    • CD into the Dlib folder.
    • Make sure the Dlib/build folder is empty ( rm -r -force .\build* )
    • Run: python .\setup.py install

    If you get an error, post back here. You are probably missing a dependency or ENV variable.

    0 讨论(0)
提交回复
热议问题