[python-win32] Compiling Python as a static .exe

Russell Wallace russell.wallace at gmail.com
Tue Jan 21 13:07:01 CET 2014


The '...' is the long list of source files I got from pythoncore.vcproj,
plus getbuildinfo.c, and the required include directives. You would think a
missing main function would be the explanation, but the absence of a
leading _ in the error message is a key indicator. To make sure, I tried
adding a main function by hand, and also wmain just in case, and the error
still occurs.


On Mon, Jan 20, 2014 at 11:47 PM, Mark Hammond <skippy.hammond at gmail.com>wrote:

> [oops - resending with CC to python-win32 list]
>
>
> On 21/01/2014 12:12 AM, Russell Wallace wrote:
>
>> Hi,
>>
>> I'm trying to compile Python 2.7.6 as a statically linked 64-bit Windows
>> executable, and I'm getting a weird error message. As per
>> http://stackoverflow.com/questions/21231439/unresolved-
>> external-symbol-main-no-underscore I
>> have a command line that looks like:
>>
>> cl /DPy_BUILD_CORE ... /link Advapi32.lib Shell32.lib User32.lib
>>
>
> What exactly is in the "..." - it looks to me that you simply don't have a
> main defined (and neither does the code that builds pythonxx.dll - only
> python.exe has a main)
>
> Mark
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-win32/attachments/20140121/6e85a488/attachment.html>


More information about the python-win32 mailing list