Commit Graph

86 Commits

Author SHA1 Message Date
Marc-André Lemburg b339b2aa6f Issue #2562: Fix distutils PKG-INFO writing logic to allow having
non-ascii characters and Unicode in setup.py meta-data.
2008-09-03 11:13:56 +00:00
Georg Brandl 392c6fc02d ConfigParser renaming reversal part 3: move module into place and adapt imports. 2008-05-25 07:25:25 +00:00
Alexandre Vassalotti eb8cef2664 Fixed import of configparser in the distutils module.
If configparser is unavailable, try to import configparser using its
old name. This is required for backward-compatibility with older
Python versions.
2008-05-16 02:06:59 +00:00
Alexandre Vassalotti 7663f9e4ff Revert distutils changes done in r63248.
As explained by Marc-Andre Lemburg, distutils needs to stay
backward-compatible. Therefore, it should use the old ConfigParser
module name.
2008-05-15 00:33:57 +00:00
Alexandre Vassalotti e2514c6f10 Updated import statements to use the new `configparser` module name.
Updated the documentation to use the new name.
Revert addition of the stub entry for the old name.

Georg, I am reverting your changes since this commit should propagate
to py3k.
2008-05-14 22:44:22 +00:00
Andrew M. Kuchling aac5c8669f #1858: re-apply patch for this, adding the missing files 2008-05-11 14:00:00 +00:00
Brett Cannon 10f5db6424 Revert r62998 as it broke the build (seems distutils.config is missing). 2008-05-10 20:52:01 +00:00
Andrew M. Kuchling cd8001c8ed #1858 from Tarek Ziade:
Allow multiple repositories in .pypirc; see http://wiki.python.org/moin/EnhancedPyPI
for discussion.

The patch is slightly revised from Tarek's last patch: I've simplified
the PyPIRCCommand.finalize_options() method to not look at sys.argv.
Tests still pass.
2008-05-10 19:51:55 +00:00
Guido van Rossum 8bc0965adf Removed uses of dict.has_key() from distutils, and uses of
callable() from copy_reg.py, so the interpreter now starts up
without warnings when '-3' is given.  More work like this needs to
be done in the rest of the stdlib.
2008-02-21 18:18:37 +00:00
Martin v. Löwis 98da562600 Make dist_files a triple, with the Python target version included,
so that bdist_wininst can specify 'any'.
2005-03-23 18:54:36 +00:00
Martin v. Löwis 55f1bb8bfa Add the upload command. Make all dist commands register their
outputs with the distribution object.
2005-03-21 20:56:35 +00:00
Fred Drake 227e8ffa20 - rename check_provision() to split_revision()
- fix indentation to conform to the Python style guide
- add more tests and documentation
2005-03-21 06:36:32 +00:00
Fred Drake db7b0027dc PEP 314 implementation (client side):
added support for the provides, requires, and obsoletes metadata fields
2005-03-20 22:19:47 +00:00
Martin v. Löwis 8ed338ab44 Patch #1104111: Alter setup.py --help and --help-commands. 2005-03-03 08:12:27 +00:00
Martin v. Löwis 5a6601cfc6 Update compatibility comments to 2.1, corresponding to PEP 291 1.13. 2004-11-10 22:23:15 +00:00
Anthony Baxter 73cc8479f0 oops. how did _that_ happen? 2004-10-13 13:22:34 +00:00
Anthony Baxter f2113f0c6e Backing out the basic dependency checking (from pycon sprint).
This support was only a first cut, and doesn't deserve to be in
a released version (where we have to support it in an ongoing
manner)
2004-10-13 12:35:28 +00:00
Fred Drake d04573fef0 This allows additional commands to be provided for existing setup.py
scripts without modifying either the distutils installation or the
setup.py scripts of packages with which the new commands will be used.

Specifically, an option is added to distutils that allows additional
packages to be searched for command implementations in addition to
distutils.command.  The additional packages can be specified on the
command line or via the installation or personal configuration files
already loaded by distutils.

For discussion, see the thread starting with:

http://mail.python.org/pipermail/distutils-sig/2004-August/004112.html

This closes SF patch #102241.
2004-08-03 16:37:40 +00:00
Tim Peters 182b5aca27 Whitespace normalization, via reindent.py. 2004-07-18 06:16:08 +00:00
Fred Drake 0eb32a65b0 Add support for package data.
This is basically the support for package data from Phillip Eby's
setuptools package.  I've changed it only to fit it into the core
implementation rather than to live in subclasses, and added
documentation.
2004-06-11 21:50:33 +00:00
Anthony Baxter 05f842bae2 Basic dependency checking. setup() has two new optional arguments
requires and provides. requires is a sequence of strings, of the
form 'packagename-version'. The dependency checking so far merely
does an '__import__(packagename)' and checks for packagename.__version__
You can also leave off the version, and any version of the package
will be installed.
There's a special case for the package 'python' - sys.version_info
is used, so
requires= ( 'python-2.3', )
just works.

Provides is of the same format as requires - but if it's not supplied,
a provides is generated by adding the version to each entry in packages,
or modules if packages isn't there.
Provides is currently only used in the PKG-INFO file. Shortly, PyPI
will grow the ability to accept these lines, and register will be
updated to send them.

There's a new command 'checkdep' command that runs these checks.
For this version, only greater-than-or-equal checking is done. We'll
add the ability to specify an optional operator later.
2004-03-22 22:22:05 +00:00
Fred Drake f06116dcab commentary about how bad ConfigParser is doesn't help here, and the
suggested approach to dealing with it isn't a good one; we need a
better general purpose config reader, not a distutils-specific reader
2004-02-17 22:35:19 +00:00
Walter Dörwald 70a6b49821 Replace backticks with repr() or "%r"
From SF patch #852334.
2004-02-12 17:35:32 +00:00
Andrew M. Kuchling a52b85262a [Bug #693470] 'licence' as an alias for 'license' doesn't work.
This patch makes it work again.
2003-03-03 20:07:27 +00:00
Andrew M. Kuchling 188d85f475 [Patch #683939] Add download_url field to metadata 2003-02-19 14:16:01 +00:00
Andrew M. Kuchling 282e2c36ba [Patch #658094] PEP 301 implementation
Add 'classifiers' keyword to DistributionMetadata
2003-01-03 15:24:36 +00:00
Andrew M. Kuchling d448f66317 Add comment to Distutil files about requiring 1.5.2 compatibility, as
suggested by PEP 291.
2002-11-19 13:12:28 +00:00
Andrew M. Kuchling a6483d2e9a Remove 'created by' lines; people can use CVS for this, and the information is often out of date 2002-11-14 02:25:42 +00:00
Andrew M. Kuchling ccf4e421b8 Catch only ImportError 2002-10-31 13:39:33 +00:00
Andrew M. Kuchling ff4ad9a1ce Make the Distribution() constructor forgiving of unknown keyword
arguments, triggering a warning instead of raising an exception.  (In
1.5.2/2.0, it will print to stderr.)

Bugfix candidate for all previous versions.  This changes behaviour,
but the old behaviour wasn't very useful.  If Distutils version X+1
adds a new keyword argument, using the new keyword means your setup.py
file won't work with Distutils version X any more.
2002-10-31 13:22:41 +00:00
Jeremy Hylton fcd7353863 Use distutils.debug.DEBUG instead of distutils.core.DEBUG.
Note that distutils.core.DEBUG still works if client code uses it, but
the core code avoids circular references by using distutils.debug.
2002-09-11 16:31:53 +00:00
Jeremy Hylton 7146073850 Use module-level import of DEBUG instead of many function-level imports. 2002-06-04 21:02:26 +00:00
Jeremy Hylton cd8a1148e1 Make setup.py less chatty by default.
This is a conservative version of SF patch 504889.  It uses the log
module instead of calling print in various places, and it ignores the
verbose argument passed to many functions and set as an attribute on
some objects.  Instead, it uses the verbosity set on the logger via
the command line.

The log module is now preferred over announce() and warn() methods
that exist only for backwards compatibility.

XXX This checkin changes a lot of modules that have no test suite and
aren't exercised by the Python build process.  It will need
substantial testing.
2002-06-04 20:14:43 +00:00
Fred Drake b94b849d65 Whitespace normalization. 2001-12-06 20:51:35 +00:00
Thomas Heller bcd8975740 Use a version number of 0.0.0 instead of ???. The latter leads to
invalid filenames on Windows when building without specifying a
version number in the setup script.

See also
http://mail.python.org/pipermail/distutils-sig/2001-November/002656.html

Bugfix candidate.
2001-12-06 20:44:19 +00:00
Andrew M. Kuchling d303b61eb4 [Bug #459270] Fix incorrect docstring 2001-12-06 16:32:05 +00:00
Neil Schemenauer a8aefe535c Don't use dir() to find instance attribute names. 2001-09-03 15:47:21 +00:00
Fred Drake 981a1787b7 Wrap a comment to fit in 80 columns.
Use construction-syntax for an exception to make the argument easier
to read.
2001-08-10 18:59:30 +00:00
Andrew M. Kuchling fa7dc57d6c [Bug #412271, bug #449009] Use 'license' as the attribute name,
though 'licence' is still supported for backward-compatibility
   (Should I add a warning to get_licence(), or not bother?)

Also fixes an UnboundLocalError noticed by PyChecker
2001-08-10 18:49:23 +00:00
Andrew M. Kuchling f89d993e07 Back out the requirement to supply a version number 2001-03-31 02:41:01 +00:00
Andrew M. Kuchling ffb963c7f6 Use the get_contact*() accessors instead of get_maintainer*() 2001-03-22 15:32:23 +00:00
Andrew M. Kuchling a7210ed272 Add 'platforms' and 'keywords' attributes to the DistributionMetadata class,
along with options to print them.
Add a finalize_options() method to Distribution to do final processing
    on the platform and keyword attributes
Add DistributionMetadata.write_pkg_info() method to write a PKG-INFO file
    into the release tree.
2001-03-22 03:06:52 +00:00
Andrew M. Kuchling 898f099dc6 Bug #409403: Signal an error if the distribution's metadata has no version 2001-03-17 19:59:26 +00:00
Andrew M. Kuchling 3f819ec2ed Fix from Jack Jansen for the Mac and the Metrowerks compiler, posted
to the Distutils-SIG and archived at
http://mail.python.org/pipermail/distutils-sig/2000-November/001755.html
2001-01-15 16:09:35 +00:00
Greg Ward f6fc875831 Jack Jansen: added 'get_command_list()' method, and Mac-specific code to
use it to generate a dialog for users to specify the command-line (because
providing a command-line with MacPython is so awkward).
2000-11-11 02:47:11 +00:00
Greg Ward fa9ff76aae Untabified. 2000-10-14 04:06:40 +00:00
Greg Ward 2c08cf0ffa Fix '_set_command_options()' so it only calls 'strtobool()' on strings
(was crashing on any boolean command-line option!).
2000-09-27 00:15:37 +00:00
Greg Ward fd7b91eff9 Standardize whitespace in function calls and docstrings. 2000-09-26 01:52:25 +00:00
Greg Ward 2f2b6c62ba Change to use the new 'translate_longopt()' function from fancy_getopt, rather
than rolling our own with fancy_getopt's 'longopt_xlate' global.
2000-09-25 01:58:07 +00:00
Greg Ward ceb9e226a6 Fixed some bugs and mis-features in handling config files:
* options can now be spelled "foo-bar" or "foo_bar" (handled in
    'parse_config_files()', just after we parse a file)
  * added a "[global]" section so there's a place to set global
    options like verbose/quiet and dry-run
  * respect the "negative alias" dictionary so (eg.) "quiet=1" is
    the same as "verbose=0" (this had to be done twice: once in
    'parse_config_file()' for global options, and once in
    '_set_command_options()' for per-command options)
  * the other half of handling boolean options correctly: allow
    commands to list their boolean options in a 'boolean_options'
    class attribute, and use it to translate strings (like "yes", "1",
    "no", "0", etc) to true or false
2000-09-25 01:23:52 +00:00