Python Series Question Set 01-Python 2.7.15 Installation of Alibaba Cloud Product Datahub SDK Problem Solving

Background: An error occurred when installing the SDK of Alibaba Cloud product datahub in python2.7.15.

The source code installation error is as follows: error: Unable to find vcvarsall.bat file
Insert image description here

Asking Baidu for help, the query can be solved by installing the mingw-get-setup.exe file, but the installation requires an Internet connection.

Insert image description here
Insert image description here
Custom installation location
Insert image description here
Insert image description here

In order for GCC to support compiling C language and C++ at the same time, you need to right-click the mouse to mark the two items marked in the diagram. After checking, click the "X" in the upper right corner, and the following dialog box will pop up:
Insert image description here

Click "Apply" to start the installation, which takes a little time.
Insert image description here
After the installation is completed, the environment variables of the bin directory under the MinGW installation path are configured,
but the problem is still not solved. Trying to install pip, the same error occurs, and the error message is as follows:
Insert image description here
python2.7 will search for the installed Visual Studio 2008, that is, VS90 (which uses the environment variable VS90COMNTOOLS), so after searching and downloading VCForPython7.msi through Baidu for installation, execute pip install packagename still reports an error.
So according to the error message Microsoft visual c++ 9.0, go to Baidu to search and download the vcredist_x86.exe installation package. You need to install it online, as follows:
Insert image description here

The error message changed after installation. The error message is as follows:
The stdint.h file cannot be found.
Insert image description here
According to the error message, Baidu search downloaded the file.
Insert image description here

Save its content and name it as the stdint.h file, and place the file in the vcredist_x86.exe installation path. For example, I placed it in the following path:
Insert image description here
Then execute the source package installation, and the pip setup.py install command succeeds.
Insert image description here
Insert image description here

Guess you like

Origin blog.csdn.net/weixin_40012925/article/details/126317198