unable to install dlib for python windows 10 (cmake installed) - python-3.x

Trying to install dlib for python on Windows 10 by building it from source for quite a while now and have searched a lot to find a good solution. I tried to follow the following steps.
I first installed VS 16 2019 with all the required c++ dev tools(check attached screenshot) and then installed cmake.
Then pip installed cmake.
Now when I write "pip install dlib". It collapses by showing the
following output(check attached screenshot):
-- Building for: Visual Studio 14 2015
-- Selecting Windows SDK version to target Windows 10.0.19042.
CMake Error at CMakeLists.txt:14 (project):
Failed to run MSBuild command:
MSBuild.exe
to get the value of VCTargetsPath:
The system cannot find the file specified
-- Configuring incomplete, errors occurred!
I think the problem here is that cmake is using "VS 14 2015" by default when I run "pip install dlib". Is there a way to change this default to use "vs 16 2019" in cmake.

Related

How can i add visual studio build tools in a pyinstaller run?

I'm trying to develop a minimization alghorithm for master thesis task. I used cvxpy and i'd like to make an installer, since it would be very interesting for remaining research group that do not use python. As described in the installation documentation, cvxpy need visual studio build tools for python 3.
This complicate the stuff: how can i use pyinstaller and create a directory in which are already embedded also all visual studio dependencies needed for cvxpy? If this is not possible, how can i setup Inno setup in order to install visual studio build tools for python 3 before installing my application, taking only the necessary package from visual studio build tools?
Build a bootloader for PyInstaller
Download Build Tools for Visual Studio 2019 from Microsoft.
Run the vs_BuildTools.exe downloaded in the previous step.
Select “C++ build tools”
Install/upgrade setuptools: $ pip install setuptools --upgrade.

How to install Visual Studio 2015 PlatformSDK now?

When I ran something (such as pip install scrapy) with python 3.7, I got a trouble with
error: [WinError 3] The system cannot find the path specified: 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\PlatformSDK\\lib'
and I found there is no PlatformSDK in my VS 14.0 at all.
(Update on 24 Jul 2018: I got another error [WinError 3] The system cannot find the path specified: 'C:\\Program Files (x86)\\Microsoft SDKs\\Windows\\v8.1\\lib' when I ran pip install scrapy on another laptop, also Win 10 OS. I'm not sure whether my case is similar to this question's)
Then I got a vs_community.exe source from here and installed Web Developer Tools and Visual Studio Extensibility Tools Update 3 successfully, but still no PlatformSDK.
So how can I get this missing folder and its packages inside it?
Once I had a problem installing another Python program (QARK) that required Windows Visual C++. In fact in cmd / PowerShell I was told that a required version was missing.
So I followed what was written on THIS site, so I didn't have this problem anymore (I also rebooted, for safety):
Install using any ONE of these choices:
Microsoft Build Tools for Visual Studio
Alternative link to Microsoft Build Tools for Visual Studio.
Offline installer: vs_buildtools.exe
Select: Workloads → C++ build tools.
Install options: select only the “Windows 10 SDK” (assuming the computer is Windows 10). Optionally, if you want to use MSVC cl.exe C/C++ compiler from the command line, additionally select the C++ build tools, which takes an additional 2 GB disk space.
After that I didn't have any problems running it.
I hope I have been helpful! 🤞

Error installing Fasttext on Windows 10 Python 3

I am trying to install fastText using pip install fastText on Windows 10. I have Python 3 installed in Anaconda.
I tried reading several posts but they do not give a clear idea about what exact changes should I make to install. I am getting the following error:
The error shown below reads:
raise ValueError("Unknown MS Compiler version %s " % msc_ver)
ValueError: Unknown MS Compiler version 1900
Can anybody help in this?
It appears this is a know bug currently in open status according to Python Bug Tracker
I am just successful install fasttext on windows 10 using pip with Visual Studio Build Tools(MS Compiler) for Visual Studio 2017.
You can download MS Build Tools for Visual Studio 2017 here: http://landinghub.visualstudio.com/visual-cpp-build-tools

MicrosoftVisual C++ 2015 Redistributable installation failed 0x80240017

When I try to install Microsoft Visual C++ 2015 Redistributable, I get this error
0x80240017, I need it to solve the api-ms-win-crt-runtime-l1-1-0.dll problem
I had the same problem recently, I needed to use XAMPP and when initializing the Apache module I received this error. I tried many things:
Install all windows updates.
Install Visual C ++ 2015 Redistributable that installs this DLL (I get this error 0x80240017 and could not install).
Install the KBKB2999226 and KB2919355 package that contains this DLL.
Clear TEMP folder and rename directories.
I could not by any means. What solved my problem was to install Visual Studio 2015 itself, I had to push the envelope, I had to push it, that solved my problem, and XAMPP becomes to run, unfortunately.

Can't get qwt_designer_plugin to load in Qt Creator

My setup is:
Visual Studio 2012
Qt 5.2.0 from
http://download.qt-project.org/official_releases/qt/5.2/5.2.0/qt-windows-opensource-5.2.0-msvc2012-x86_64-offline.exe
Unzip Qwt from http://sourceforge.net/projects/qwt/files/qwt/6.1.0/qwt-6.1.0.zip/download to C:\qwt-6.1.0
Opened Qt 5.2.0 64-bit for Desktop (MSVC 2012) and ran "qmake qwt.pro"
Opened VS2012 x64 Native Tools Command Prompt and ran "nmake" and "nmake install"
Set QWT_ROOT = C:\qwt-6.1.0
Added C:\qwt-6.1.0\lib to PATH
Copied C:\qwt-6.1.0\plugins\designer\qwt_designer_plugin.dll to C:\Qt\Qt5.2.0\Tools\QtCreator\bin\plugins\designer
When I open Qt Creator and edit the UI then go to Tools->Form Editor->About Qt Designer Plugins I see "Cannot load library qwt_designer_plugin.dll:" but no error or reason.
I used Dependency Walker to check the Dll, and QtCreator.exe and all its dependencies are 32-bit whereas my build of qwt_designer_plugin.dll is 64-bit. I wondered if this was causing the problem so I:
Downloaded Qt5.2.0 from http://download.qt-project.org/official_releases/qt/5.2/5.2.0/qt-windows-opensource-5.2.0-msvc2012-x86-offline.exe and install into C:\Qt\Qt5.2.0-32
Unzipped Qwt into C:\qwt-6.1.0-32bit to create a fresh copy.
Opened Qt 5.2.0 32-bit for Desktop (MSVC 2012), cd into C:\qwt-6.1.0-32bit and "qmake qwt.pro"
Opened VS2012 x86 Native Tools Command Prompt and ran "nmake" and "nmake install"
Copied C:\qwt-6.1.0-32bit\designer\plugins\designer\qwt_designer_plugin.dll to C:\Qt\Qt5.2.0\Tools\QtCreator\bin\plugins\designer
This works fine and I can now see the plugin loaded correctly and add Qwt widgets in the UI designer.
This worked for me:
Step 1
I check what MSVC version the QtCreator in my Qt framework version was built with. E.g. QtCreator that comes with Qt_5.6.2 MSVC2015 (qt-opensource-windows-x86-msvc2015-5.6.2.exe) was built with MSVC 2013 (qt-opensource-windows-x86-msvc2013-5.6.2.exe).
Step 2
I install qt-opensource-windows-x86-msvc2013-5.6.2.exe and build Qwt(plugin) with that Qt version.
For comparison here is what happens when Qwt is built with Qt_5.6.2 MSVC2013 and Qt_5.6.2 MSVC2015:
Also here:
https://stackoverflow.com/a/20156419/3096593

Resources