Lines Matching +full:binary +full:- +full:extensions
3 """Freeze a Python script into a binary.
8 -p prefix: This is the prefix used when you ran ``make install''
13 tree; then -P must point to the build tree.
15 -P exec_prefix: Like -p but this is the 'exec_prefix', used to
17 evaluates to, or the -p argument if given.
18 If -p points to the Python source tree, -P must point
21 -e extension: A directory containing additional .o files that
25 or more extensions is passed.
26 More than one -e option may be given.
28 -o dir: Directory where the output files are created; default '.'.
30 -m: Additional arguments are module names instead of filenames.
32 -a package=dir: Additional directories to be added to the package's
35 More than one -a option may be given for each package.
37 -l file: Pass the file to the linker (windows only)
39 -d: Debugging mode for the module finder.
41 -q: Make the module finder totally quiet.
43 -h: Print this help message.
45 -x module Exclude the specified module. It will still be imported
46 by the frozen binary if it exists on the host system.
48 -X module Like -x, except the module can never be imported by
49 the frozen binary.
51 -E: Freeze will fail if any modules can't be found (that
52 were not excluded using -x or -X).
54 -i filename: Include a file with additional command line options. Used
57 are read and the -i option replaced with the parsed
58 params (note - quoting args in this file is NOT supported)
60 -s subsystem: Specify the subsystem (For Windows only.);
63 -w: Toggle Windows (NT or 95) behavior.
64 (For debugging only -- on a win32 platform, win32 behavior
67 -r prefix=f: Replace path prefix.
69 contained in the resulting binary.
73 script: The Python script to be executed by the resulting binary.
76 that will be included in the resulting binary. These
77 may be .py or .pyc files. If -m is specified, these are
86 if it does, the resulting binary is not self-contained.
98 # Import the freeze-private modules
112 prefix = None # settable with -p option
113 exec_prefix = None # settable with -P option
114 extensions = []
115 exclude = [] # settable with -x option
116 addn_link = [] # settable with -l, but only honored under Windows.
122 replace_paths = [] # settable with -r option
140 # parse command line by first replacing any "-i" options with the
143 while pos < len(sys.argv)-1:
144 # last option can not be "-i", so this ensures "pos+1" is in range!
145 if sys.argv[pos] == '-i':
149 usage("File name '%s' specified with the -i option "
150 "can not be read - %s" % (sys.argv[pos+1], why) )
151 # Replace the '-i' and the filename with the read params.
153 pos = pos + len(options) - 1 # Skip the name and the included args.
164 if o == '-h':
167 if o == '-d':
169 if o == '-e':
170 extensions.append(a)
171 if o == '-m':
173 if o == '-o':
175 if o == '-p':
177 if o == '-P':
179 if o == '-q':
181 if o == '-w':
183 if o == '-s':
185 usage("-s subsystem option only on Windows")
187 if o == '-x':
189 if o == '-X':
192 if o == '-E':
194 if o == '-l':
196 if o == '-a':
198 if o == '-r':
217 # determine whether -p points to the Python source tree
246 includes = ['-I' + incldir, '-I' + config_h_dir]
252 check_dirs = check_dirs + extensions
259 files = supp_sources + extensions # extensions are files on Windows.
268 for dir in extensions:
281 if arg == '-m':
283 # if user specified -m on the command line before _any_
293 # process non-option arguments
306 # handle -o option
330 # handle -s option on Windows
348 # If a Windows service, then add the "built-in" module.
350 mod.__file__="dummy.pyd" # really built-in to the resulting EXE
355 if mod == '-m':
359 if mod[-2:] == '.*':
360 mf.import_hook(mod[:-2], None, ["*"])
399 # search for unknown modules in extensions directories (not on Windows)
406 extensions)
417 unknown, extensions, prefix)
493 print "Use ``%s -h'' for help" % sys.argv[0]