This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: freeze tool broken in Python 3.x
Type: behavior Stage:
Components: Demos and Tools Versions: Python 3.1
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: georg.brandl, hagen, jcsalterego, loewis
Priority: normal Keywords: patch

Created on 2009-06-29 03:15 by hagen, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
freeze.patch hagen, 2009-07-15 20:24 review
Messages (7)
msg89808 - (view) Author: Hagen Fürstenau (hagen) Date: 2009-06-29 03:15
The freeze tool seems to be severely broken in Python 3.x. Applying it
to a "hello world" script produces:

Warning: unknown modules remain: _bisect _collections _ctypes _hashlib
_heapq _multiprocessing _pickle _random _socket _ssl _struct _tkinter
array atexit binascii datetime fcntl itertools math mmap operator
pyexpat readline select termios time

and a subsequent make results in

config.o:(.data+0x8): undefined reference to `init_codecs'
config.o:(.data+0x18): undefined reference to `init_functools'
config.o:(.data+0x28): undefined reference to `init_io'
config.o:(.data+0x38): undefined reference to `init_locale'
config.o:(.data+0x48): undefined reference to `init_sre'
config.o:(.data+0x58): undefined reference to `init_thread'
config.o:(.data+0x68): undefined reference to `init_weakref'
config.o:(.data+0x78): undefined reference to `initerrno'
config.o:(.data+0x88): undefined reference to `initgc'
config.o:(.data+0x98): undefined reference to `initimp'
config.o:(.data+0xa8): undefined reference to `initposix'
config.o:(.data+0xb8): undefined reference to `initpwd'
config.o:(.data+0xc8): undefined reference to `initsignal'
config.o:(.data+0xd8): undefined reference to `initzipimport'
msg89810 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2009-06-29 05:40
Would you like to provide a patch?
msg89811 - (view) Author: Hagen Fürstenau (hagen) Date: 2009-06-29 05:45
> Would you like to provide a patch?

I wouldn't mind if someone beat me to it. But if that doesn't happen,
I'll look into it when I have some time to spare.
msg89831 - (view) Author: Jerry Chen (jcsalterego) Date: 2009-06-29 12:58
I am unable to reproduce with py3k latest r73676 after making and
installing, and running

$ python3.2 freeze.py hello.py

# on OS X 10.5.7
$ uname -a
Darwin 9.7.0 Darwin Kernel Version 9.7.0: Tue Mar 31 22:52:17 PDT 2009;
root:xnu-1228.12.14~1/RELEASE_I386 i386
msg89894 - (view) Author: Hagen Fürstenau (hagen) Date: 2009-06-30 00:02
I get the same error as before with a fresh install of r73676 on Linux.

$ uname -a
Linux zhuangzi 2.6.28-13-generic #44-Ubuntu SMP Tue Jun 2 07:55:09 UTC
2009 x86_64 GNU/Linux
msg90542 - (view) Author: Hagen Fürstenau (hagen) Date: 2009-07-15 20:24
I'm attaching a patch with the minimal changes I had to make to get a
"hello world" script frozen under 3.x. They all have to do with changes
between 2.x and 3.x.
msg119286 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2010-10-21 13:01
An equivalent patch had already been committed in r83606.
History
Date User Action Args
2022-04-11 14:56:50adminsetgithub: 50613
2010-10-21 13:01:50georg.brandlsetstatus: open -> closed

nosy: + georg.brandl
messages: + msg119286

resolution: fixed
2009-07-15 20:24:11hagensetfiles: + freeze.patch
keywords: + patch
messages: + msg90542
2009-06-30 00:02:15hagensetmessages: + msg89894
2009-06-29 12:58:17jcsalteregosetnosy: + jcsalterego
messages: + msg89831
2009-06-29 05:45:50hagensetmessages: + msg89811
2009-06-29 05:40:09loewissetnosy: + loewis
messages: + msg89810
2009-06-29 03:15:48hagencreate