0

I'm trying to build exe file from Python 2.7 source on Windows using Cython and MSVC Microsoft Visual C++ Compiler Package for Python 2.7.

I using following tutorial: https://github.com/cython/cython/wiki/CythonExtensionsOnWindows

I follow all steps. I not get any error, but there are no exe file. What is bad? Why msvc do not generate exe file or error?

All command are executed from Visual C++ 2008 32-bit Command Prompt. Generated test.c file has 67 kB.

c:\Users\martin\PycharmProjects\untitled>type test.py
print "Hello World!"

c:\Users\martin\PycharmProjects\untitled>python test.py
Hello World!

c:\Users\martin\PycharmProjects\untitled>cython test.py

c:\Users\martin\PycharmProjects\untitled>SET DISTUTILS_USE_SDK=1

c:\Users\martin\PycharmProjects\untitled>SET MSSdk=1

c:\Users\martin\PycharmProjects\untitled>type setup.py
try:
    from setuptools import setup
    from setuptools import Extension
except ImportError:
    from distutils.core import setup
    from distutils.extension import Extension
c:\Users\martin\PycharmProjects\untitled>
c:\Users\martin\PycharmProjects\untitled>python setup.py build_ext --inplace --compiler=msvc

c:\Users\martin\PycharmProjects\untitled>
martin
  • 1,707
  • 6
  • 34
  • 62
  • Possible duplicate of [Making an executable in Cython](http://stackoverflow.com/questions/22507592/making-an-executable-in-cython) Have you tried the --embed option? – sytech Oct 06 '16 at 22:47
  • Yes. With `--embed` result is the same. – martin Oct 06 '16 at 23:32
  • 1) Is anything produced in the directory after you run setup.py? 2) Do you not need something in setup.py in addition to the imports? – DavidW Oct 07 '16 at 12:46
  • e.g. https://docs.python.org/2.7/extending/building.html – DavidW Oct 07 '16 at 12:48

0 Answers0