Commit Graph

35 Commits

Author SHA1 Message Date
Michael W. Hudson
82d3c7da8b Backport theller's checkin of revision 1.35:
package_dir must be converted from the distutils path conventions to
local conventions before being used by build_py.

Fixes SF bug #509288, probably a candidate for 2.2.1
2002-02-19 14:15:40 +00:00
Fred Drake
21d45356b8 Whitespace normalization. 2001-12-06 21:01:19 +00:00
Greg Ward
73a6c942cd Added the ability to do byte-compilation at build time, currently off
by default (since compiling at install time works just fine).  Details:
  - added 'compile' and 'optimize' options
  - added 'byte_compile()' method
  - changed 'get_outputs()' so it includes bytecode files
A lot of the code added is very similar to code in install_lib.py;
would be nice to factor it out further.
2000-10-02 02:19:04 +00:00
Greg Ward
cb1f4c4d33 Standardized whitespace around function calls. 2000-09-30 18:27:54 +00:00
Greg Ward
3a5a2bd486 Changed 'build_module()' so it returns the result of 'copy_file()'
on the module file -- could be useful for subclasses overriding it.
2000-09-30 17:33:05 +00:00
Greg Ward
99b032eaf2 Added 'boolean_options' list to support config file parsing. 2000-09-25 01:41:15 +00:00
Greg Ward
6a2035d76b Typo fix. 2000-09-06 02:06:27 +00:00
Greg Ward
9821bf4e62 Added 'script_name' and 'script_args' instance attributes to Distribution.
Changed 'core.setup()' so it sets them to reasonable defaults.
Tweaked how the "usage" string is generated: 'core' now provides
  'gen_usage()', which is used instead of 'USAGE'.
Modified "build_py" and "sdist" commands to refer to
  'self.distribution.script_name' rather than 'sys.argv[0]'.
2000-08-29 01:15:18 +00:00
Greg Ward
c0fe82ca26 Fix long-hidden inconsistency in internal interface: 'find_modules()' now
represents packages as strings, not tuples.  This allowed a simplification
in 'get_package_dir()', too -- can now assume that 'package' is a string.
2000-08-15 13:01:25 +00:00
Greg Ward
6f980b5936 Renamed 'modules' option to 'py_modules', for consistency with Distribution
(and in order to generate a more sensible error message cleanly).
2000-06-04 13:42:52 +00:00
Greg Ward
8bbba17d38 Fixed a couple of long-hidden bugs (amazing what you find when you
attempt to verify the bold assertions in the documentation):
  * entries for the "root package" in 'package_dir' didn't work --
    fixed by improving the fall-through code in 'get_package_dir()'
  * __init__.py files weren't installed when modules-in-packages
    were listed individually (ie. in 'py_modules' in the setup script);
    fixed by making 'check_package()' return the name of the __init__
    file if it exists, and making 'find_modules()' add an entry to
    the module list for __init__ if applicable
2000-05-26 00:44:06 +00:00
Greg Ward
fcd974efbb Normalized all the end-of-class lines. 2000-05-25 01:10:04 +00:00
Greg Ward
7aff6f34fe Delete some debugging print statements. 2000-04-10 01:31:58 +00:00
Greg Ward
c41d6b35a9 Added '--force' option -- very clear what it means for building (ignore
timestamps), so every build_* command has 'self.force', which follows the
'build' command if not set by the user.
2000-04-10 00:19:42 +00:00
Greg Ward
8b2e95edd6 Deleted some crufty comments and code.
A host of improvements in preparation for the 'bdist' command:
  - added 'get_outputs()' method (all the other improvements were to support
    this addition)
  - made 'find_package_modules()' and 'find_modules()' return similar
    values (list of (package, module, module_filename) tuples)
  - factored 'find_all_modules()' out of 'get_source_files()' (needed
    by 'get_outputs()')
  - factored 'get_module_outfile()' out of 'build_module()' (also needed
    by 'get_outputs()')
  - various little tweaks, improvements, comment/doc updates
2000-03-29 02:10:51 +00:00
Greg Ward
56359f591b Typo fix. 2000-03-03 03:00:27 +00:00
Greg Ward
3ce77fd05e Changed '__rcsid__' to '__revision__'. 2000-03-02 01:49:45 +00:00
Greg Ward
e691651682 Build reorg: change 'build_dir' option to 'build_lib'. 2000-03-01 01:19:37 +00:00
Greg Ward
e01149cbe8 Renamed 'set_default_options()' to 'initialize_options()', and
'set_final_options()' to 'finalize_options()'.
2000-02-18 00:35:22 +00:00
Greg Ward
bbeceeaf9a Renamed all 'options' class attributes to 'user_options'. 2000-02-18 00:25:39 +00:00
Greg Ward
1993f9ad0e Renamed all command classes so they're exactly the same as the name of the
command itself: no more of this "FooBar class for foo_bar command"
silliness.
2000-02-18 00:13:53 +00:00
Greg Ward
113e70efa2 Patch from Joe Van Andel: fix arg to % operator in warning. 2000-02-02 00:07:14 +00:00
Greg Ward
37bc815053 Added 'description' class attribute to every command class (to help the
'--help-commands' option).
Shuffled imports around in a few command modules to avoid expensive
  up-front import of sysconfig (and resulting delays in generating list
  of all commands).
2000-01-30 18:34:15 +00:00
Greg Ward
7c463ef362 Ditch unneeded imports. 2000-01-17 16:25:17 +00:00
Greg Ward
9b45443c1b Fixed 'find_package_modules()' to ensure that we never build (and thus
install) the setup script itself.
Fixed 'build_module()' so we do *not* preserve file mode (which means
  we can install read-only files, which makes the next installation
  of this distribution fail -- at least under Unix); added a comment
  explaining this.
1999-12-12 17:03:59 +00:00