PEP 229, Using Distutils to Build Python, Andrew Kuchling
This commit is contained in:
parent
7626095211
commit
6efa7422c1
|
@ -37,6 +37,7 @@ Index by Category
|
|||
S 222 pep-0222.txt Web Library Enhancements Kuchling
|
||||
I 226 pep-0226.txt Python 2.1 Release Schedule Hylton
|
||||
S 227 pep-0227.txt Statically Nested Scopes Hylton
|
||||
S 229 pep-0229.txt Using Distutils to Build Python Kuchling
|
||||
|
||||
Pie-in-the-sky PEPs (not ready; may become active yet)
|
||||
|
||||
|
@ -121,6 +122,7 @@ Numerical Index
|
|||
I 226 pep-0226.txt Python 2.1 Release Schedule Hylton
|
||||
S 227 pep-0227.txt Statically Nested Scopes Hylton
|
||||
S 228 pep-0228.txt Reworking Python's Numeric Model Zadka
|
||||
S 229 pep-0229.txt Using Distutils to Build Python Kuchling
|
||||
|
||||
|
||||
Key
|
||||
|
|
|
@ -0,0 +1,77 @@
|
|||
PEP: 229
|
||||
Title: Using Distutils to Build Python
|
||||
Version: $Revision$
|
||||
Author: akuchlin@mems-exchange.org (A.M. Kuchling)
|
||||
Status: Draft
|
||||
Type: Standards
|
||||
Created: 16-Nov-2000
|
||||
Post-History:
|
||||
|
||||
|
||||
Introduction
|
||||
|
||||
The Modules/Setup mechanism has some flaws:
|
||||
|
||||
* People have to remember to uncomment bits of Modules/Setup in
|
||||
order to get all the possible modules.
|
||||
|
||||
* Moving Setup to a new version of Python is tedious; new modules
|
||||
have been added, so you can't just copy the older version, but
|
||||
have to reconcile the two versions.
|
||||
|
||||
* Users have to figure out where the needed libraries, such as
|
||||
zlib, are installed.
|
||||
|
||||
|
||||
Proposal
|
||||
|
||||
Use the Distutils to build the modules that come with Python.
|
||||
|
||||
The changes can be broken up into several pieces:
|
||||
|
||||
1. The Distutils needs some Python modules to be able to build
|
||||
modules. Currently I believe the minimal list is posix, _sre,
|
||||
and string.
|
||||
|
||||
These modules will have to be built before the Distutils can be
|
||||
used, so they'll simply be hardwired into Modules/Makefile and
|
||||
be automatically built.
|
||||
|
||||
2. A top-level setup.py script will be written that checks the
|
||||
libraries installed on the system and compiles as many modules
|
||||
as possible.
|
||||
|
||||
3. Modules/Setup will be kept and settings in it will override
|
||||
setup.py's usual behavior, so you can disable a module known
|
||||
to be buggy, or specify particular compilation or linker flags.
|
||||
However, in the common case where setup.py works correctly,
|
||||
everything in Setup will remain commented out. The other
|
||||
Setup.* become unnecessary, since nothing will be generating
|
||||
Setup automatically.
|
||||
|
||||
|
||||
Unresolved Issues
|
||||
|
||||
Do we need to make it possible to disable the 3 hard-wired modules
|
||||
without manually hacking the Makefiles? If yes, perhaps a
|
||||
configure switch is sufficient.
|
||||
|
||||
The Distutils always compile modules as shared libraries. How do
|
||||
we support compiling them statically into the resulting Python
|
||||
binary?
|
||||
|
||||
makesetup and the other contents of $(LIBPL)/config need to be
|
||||
preserved for compatibility with existing modules; for how many
|
||||
versions do we need to keep them around?
|
||||
|
||||
|
||||
Copyright
|
||||
|
||||
This document has been placed in the public domain.
|
||||
|
||||
|
||||
|
||||
Local Variables:
|
||||
mode: indented-text
|
||||
indent-tabs-mode: nil
|
||||
End:
|
Loading…
Reference in New Issue