Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<blockquote> <p>to avoid further answers like jwp's one, note that, for this project, I absolutely need my program being a standalone executable because it is absolutely impossible to have a python VM on the target platform where the executable will run. I have exactly the same hw available for compiling, so luckly I don't need to cross-compile (but I'd do the development on a more friendly Linux).</p> <p>I'd also like to test if my code compile in Cython from the beginning, not to premature optimize, but just to be sure that I'm not going too far with the use of incompatible features, which would require a painful refactoring if Cython would be seriously needed.</p> </blockquote> <p>If all you're looking for is to have a stand-alone executable, you don't need to run Cython. There are a few good libraries for doing this:</p> <ul> <li><a href="http://www.py2exe.org/" rel="nofollow noreferrer">py2exe</a></li> <li><a href="http://svn.pythonmac.org/py2app/py2app/trunk/doc/index.html" rel="nofollow noreferrer">py2app</a></li> </ul> <p>However, to run Python code, you're simply going to <em>have to</em> install an interpreter or virtual machine on the target machine in some form or fashion. The solutions I presented involve merely embedding the interpreter to make it easier to install. In fact, I'm pretty sure (but could be wrong) that Cython won't allow you to build a stand-alone executables. It's mainly meant for creating extensions to the Python interpreter.</p> <p>However, there are a couple of other alternatives. If you have a Java interpreter on the target machine, you can run <a href="http://www.jython.org/Project/" rel="nofollow noreferrer">Jython</a>. There's also a <a href="http://www.codeplex.com/Wiki/View.aspx?ProjectName=IronPython" rel="nofollow noreferrer">IronPython</a> for .net. However, you will still have to distribute the runtimes for these languages with your project.</p> <p>In short, if you want a stand-alone executable with no dependencies, your only option is pretty much to go with straight C or C++.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload