$ python freeze.py hello.py
/usr/lib/python2.3/parsesetup.py:3: DeprecationWarning: the regex module is depr
ecated; please use the re module
  import regex

  Name                      File
  ----                      ----
m BaseHTTPServer            /usr/lib/python2.3/BaseHTTPServer.py
m FixTk                     /usr/lib/python2.3/lib-tk/FixTk.py
m SocketServer              /usr/lib/python2.3/SocketServer.py
m StringIO                  /usr/lib/python2.3/StringIO.py
m Tkconstants               /usr/lib/python2.3/lib-tk/Tkconstants.py
m Tkinter                   /usr/lib/python2.3/lib-tk/Tkinter.py
m UserDict                  /usr/lib/python2.3/UserDict.py
m __builtin__
m __main__                  hello.py
m _codecs
m _locale                   /usr/lib/python2.3/lib-dynload/_locale.dll
m _random                   /usr/lib/python2.3/lib-dynload/_random.dll
m _socket                   /usr/lib/python2.3/lib-dynload/_socket.dll
m _sre
m _ssl                      /usr/lib/python2.3/lib-dynload/_ssl.dll
m _tkinter                  /usr/lib/python2.3/lib-dynload/_tkinter.dll
m array                     /usr/lib/python2.3/lib-dynload/array.dll
m atexit                    /usr/lib/python2.3/atexit.py
m base64                    /usr/lib/python2.3/base64.py
m binascii                  /usr/lib/python2.3/lib-dynload/binascii.dll
m cStringIO                 /usr/lib/python2.3/lib-dynload/cStringIO.dll
m codecs                    /usr/lib/python2.3/codecs.py
m copy                      /usr/lib/python2.3/copy.py
m copy_reg                  /usr/lib/python2.3/copy_reg.py
m dis                       /usr/lib/python2.3/dis.py
P distutils                 /usr/lib/python2.3/distutils/__init__.py
m distutils.dep_util        /usr/lib/python2.3/distutils/dep_util.py
m distutils.errors          /usr/lib/python2.3/distutils/errors.py
m distutils.log             /usr/lib/python2.3/distutils/log.py
m distutils.spawn           /usr/lib/python2.3/distutils/spawn.py
m distutils.util            /usr/lib/python2.3/distutils/util.py
m dummy_thread              /usr/lib/python2.3/dummy_thread.py
P encodings                 /usr/lib/python2.3/encodings/__init__.py
m encodings.aliases         /usr/lib/python2.3/encodings/aliases.py
m errno
m exceptions
m fcntl                     /usr/lib/python2.3/lib-dynload/fcntl.dll
m fnmatch                   /usr/lib/python2.3/fnmatch.py
m formatter                 /usr/lib/python2.3/formatter.py
m ftplib                    /usr/lib/python2.3/ftplib.py
m getopt                    /usr/lib/python2.3/getopt.py
m getpass                   /usr/lib/python2.3/getpass.py
m glob                      /usr/lib/python2.3/glob.py
m gopherlib                 /usr/lib/python2.3/gopherlib.py
m htmlentitydefs            /usr/lib/python2.3/htmlentitydefs.py
m htmllib                   /usr/lib/python2.3/htmllib.py
m httplib                   /usr/lib/python2.3/httplib.py
m imp
m inspect                   /usr/lib/python2.3/inspect.py
m linecache                 /usr/lib/python2.3/linecache.py
m locale                    /usr/lib/python2.3/locale.py
m macpath                   /usr/lib/python2.3/macpath.py
m macurl2path               /usr/lib/python2.3/macurl2path.py
m markupbase                /usr/lib/python2.3/markupbase.py
m marshal
m math                      /usr/lib/python2.3/lib-dynload/math.dll
m mimetools                 /usr/lib/python2.3/mimetools.py
m mimetypes                 /usr/lib/python2.3/mimetypes.py
m ntpath                    /usr/lib/python2.3/ntpath.py
m nturl2path                /usr/lib/python2.3/nturl2path.py
m opcode                    /usr/lib/python2.3/opcode.py
m os                        /usr/lib/python2.3/os.py
m os2emxpath                /usr/lib/python2.3/os2emxpath.py
m popen2                    /usr/lib/python2.3/popen2.py
m posix
m posixpath                 /usr/lib/python2.3/posixpath.py
m pwd                       /usr/lib/python2.3/lib-dynload/pwd.dll
m py_compile                /usr/lib/python2.3/py_compile.py
m pydoc                     /usr/lib/python2.3/pydoc.py
m quopri                    /usr/lib/python2.3/quopri.py
m random                    /usr/lib/python2.3/random.py
m re                        /usr/lib/python2.3/re.py
m repr                      /usr/lib/python2.3/repr.py
m rfc822                    /usr/lib/python2.3/rfc822.py
m select                    /usr/lib/python2.3/lib-dynload/select.dll
m sgmllib                   /usr/lib/python2.3/sgmllib.py
m site                      /usr/lib/python2.3/site.py
m socket                    /usr/lib/python2.3/socket.py
m sre                       /usr/lib/python2.3/sre.py
m sre_compile               /usr/lib/python2.3/sre_compile.py
m sre_constants             /usr/lib/python2.3/sre_constants.py
m sre_parse                 /usr/lib/python2.3/sre_parse.py
m stat                      /usr/lib/python2.3/stat.py
m string                    /usr/lib/python2.3/string.py
m strop                     /usr/lib/python2.3/lib-dynload/strop.dll
m sys
m tempfile                  /usr/lib/python2.3/tempfile.py
m termios                   /usr/lib/python2.3/lib-dynload/termios.dll
m thread
m threading                 /usr/lib/python2.3/threading.py
m time                      /usr/lib/python2.3/lib-dynload/time.dll
m token                     /usr/lib/python2.3/token.py
m tokenize                  /usr/lib/python2.3/tokenize.py
m traceback                 /usr/lib/python2.3/traceback.py
m tty                       /usr/lib/python2.3/tty.py
m types                     /usr/lib/python2.3/types.py
m urllib                    /usr/lib/python2.3/urllib.py
m urlparse                  /usr/lib/python2.3/urlparse.py
m uu                        /usr/lib/python2.3/uu.py
m warnings                  /usr/lib/python2.3/warnings.py
m webbrowser                /usr/lib/python2.3/webbrowser.py

Missing modules:
? Carbon.File imported from macpath
? Carbon.Folder imported from tempfile
? Carbon.Folders imported from tempfile
? EasyDialogs imported from getpass
? MacOS imported from Tkinter, py_compile
? SOCKS imported from ftplib
? _winreg imported from urllib
? ce imported from os
? ic imported from pydoc, urllib, webbrowser
? mac imported from os
? msvcrt imported from getpass
? nt imported from ntpath, os
? org.python.core imported from copy
? os.path imported from os
? os2 imported from os
? riscos imported from os
? riscosenviron imported from os
? riscospath imported from os
? rourl2path imported from urllib
? sitecustomize imported from site

freezing BaseHTTPServer ...
freezing FixTk ...
freezing SocketServer ...
freezing StringIO ...
freezing Tkconstants ...
freezing Tkinter ...
freezing UserDict ...
freezing __main__ ...
freezing atexit ...
freezing base64 ...
freezing codecs ...
freezing copy ...
freezing copy_reg ...
freezing dis ...
freezing distutils ...
freezing distutils.dep_util ...
freezing distutils.errors ...
freezing distutils.log ...
freezing distutils.spawn ...
freezing distutils.util ...
freezing dummy_thread ...
freezing encodings ...
freezing encodings.aliases ...
freezing fnmatch ...
freezing formatter ...
freezing ftplib ...
freezing getopt ...
freezing getpass ...
freezing glob ...
freezing gopherlib ...
freezing htmlentitydefs ...
freezing htmllib ...
freezing httplib ...
freezing inspect ...
freezing linecache ...
freezing locale ...
freezing macpath ...
freezing macurl2path ...
freezing markupbase ...
freezing mimetools ...
freezing mimetypes ...
freezing ntpath ...
freezing nturl2path ...
freezing opcode ...
freezing os ...
freezing os2emxpath ...
freezing popen2 ...
freezing posixpath ...
freezing py_compile ...
freezing pydoc ...
freezing quopri ...
freezing random ...
freezing re ...
freezing repr ...
freezing rfc822 ...
freezing sgmllib ...
freezing site ...
freezing socket ...
freezing sre ...
freezing sre_compile ...
freezing sre_constants ...
freezing sre_parse ...
freezing stat ...
freezing string ...
freezing tempfile ...
freezing threading ...
freezing token ...
freezing tokenize ...
freezing traceback ...
freezing tty ...
freezing types ...
freezing urllib ...
freezing urlparse ...
freezing uu ...
freezing warnings ...
freezing webbrowser ...
generating table of frozen modules
Warning: unknown modules remain: _locale _random _socket _ssl _tkinter array bin
ascii cStringIO fcntl math pwd select strop termios time
Now run "make" to build the target: hello

$ make
gcc -I/usr/include/python2.3 -I/usr/include/python2.3  -c config.c
gcc -I/usr/include/python2.3 -I/usr/include/python2.3  -c frozen.c
gcc   config.o frozen.o /usr/lib/python2.3/config/libpython2.3.a   -lm  -o hello

config.o(.data+0x4):config.c: undefined reference to `_init_codecs'
config.o(.data+0xc):config.c: undefined reference to `_init_sre'
config.o(.data+0x14):config.c: undefined reference to `_initerrno'
config.o(.data+0x1c):config.c: undefined reference to `_initexceptions'
config.o(.data+0x24):config.c: undefined reference to `_initimp'
config.o(.data+0x2c):config.c: undefined reference to `_initposix'
config.o(.data+0x34):config.c: undefined reference to `_initthread'
config.o(.data+0x3c):config.c: undefined reference to `_PyMarshal_Init'
config.o(.data+0x44):config.c: undefined reference to `_initimp'
config.o(.data+0x6c):config.c: undefined reference to `_initgc'
frozen.o(.text+0x1f):frozen.c: undefined reference to `__imp__PyImport_FrozenModules'
frozen.o(.text+0x37):frozen.c: undefined reference to `_Py_FrozenMain'
collect2: ld returned 1 exit status
make: *** [hello] Error 1