Skip to content

Instantly share code, notes, and snippets.

@bendtherules
Last active September 16, 2020 20:01
Show Gist options
  • Save bendtherules/2fdb3d46ff0c0ca22980 to your computer and use it in GitHub Desktop.
Save bendtherules/2fdb3d46ff0c0ca22980 to your computer and use it in GitHub Desktop.
How to install C compiler for python ( compile c+python modules from pip and also from cython)
install Microsoft Visual C++ Compiler for Python 2.7
create this fake folder "C:\Users\ab\AppData\Local\Programs\Common\Microsoft\Visual C++ for Python\9.0\fake1\fake2"
set env var VS90COMNTOOLS= that fake folder
now goto C:\Users\ab\AppData\Local\Programs\Common\Microsoft\Visual C++ for Python\9.0
youll find there is vcvarsall.bat, but it is not searched for here
copy it and paste in the VC folder
open for editing:
[in 3 places youll find this type of statement, replace them with these]
set VCINSTALLDIR=%~dp0
set WindowsSdkDir=%~dp0\..\WinSDK\
thank god, hoping everything will work :)
@bendtherules
Copy link
Author

Please put your own user path instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment