[Patches] [ python-Patches-454041 ] Setup and distutils changes.
noreply@sourceforge.net
noreply@sourceforge.net
Wed, 05 Sep 2001 12:20:08 -0700
Patches item #454041, was opened at 2001-08-21 18:01
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=305470&aid=454041&group_id=5470
Category: distutils
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Billy G. Allie (ballie01)
>Assigned to: A.M. Kuchling (akuchling)
Summary: Setup and distutils changes.
Initial Comment:
The attached patches change setup.py and the distutils
compiler modules to allow dynamically loaded modules
that are built against shared libraries to be built
with the appropriate runtime library search directories
set as needed. The attached patches and a description
of what they do follows:
1. uw7_setup.patch
This patch modifies setup.py to:
* have find_library_file() search for the
directory where a given library file is lo-
cated, and returns a tuple '(dirs, rt_dirs)'
where 'dirs' is a possibly-empty list of
additional directories and 'rt_dirs' is a
possibly-empty list of directories to be
searched at runtime. If the file couldn't be
found at all, None is returned.
* use the modified find_library_file() to set the
runtime_library_dirs parameter to Extension()
method so that the appropriate linker option to
embed the runtime library directory search path
in the dynamically load module will be gener-
ated. Whether or not the option is generated
is controlled by the distutils compiler class.
* add the curses and terminfo library to the
libraries searched when the readline module is
built.
2. uw7_ccompiler.patch
This patch modifies Lib/distutils/ccompiler.py as
follows:
* The runtime_library_dir_option() method was
change so that it returns an empty list instead
of raising the NotImplemented exception. This
was done so that a reasonable default will be
used for those systems that do not need to
specify a runtime search path for libraries.
It is possible that setup.py will determine
that a directory will be needed to be searched
at runtime, even if a particular system or
compiler do not support or need to have a
runtime directory search patch defined. In
this case, the compiler class should return an
empty list when runtime_library_dir_option() is
called.
* Changed how runtime_library_dir_option() is
called. Instead of calling it once for each
directory in the runtime_library_dirs list, it
is called once, passing it the entire list of
directories to be searched at runtime. This
pushes the decision of how to format the option
to the system specific compiler class. Some
systems (UnixWare, for example) only allow a
single -R option to be specified, followed by a
colon (:) separated list of directories to
search.
* Added support for a new compiler class,
USLCcompiler. This compiler class supports
Unix System Labs style C compilers. UnixWare
uses this compiler class. Sun's native
compiler for Solaris use to be based on the
Unix System Lab's C compiler. I don't know if
this is still the case.
3. uw7_unixccompiler.patch
This patch modifies Lib/distutils/unixccompier.py
so that is no longer defines it's own version of
runtime_library_dir_option(). Most system's that
used this compiler do not need to specify a runtime
directory search path via an ld option.
4. uw7_msvccompiler.patch and uw7_mwerkscompiler.patch
These patches update Lib/distutils/msvccompiler.py
and Lib/distutils/mwerkscompiler.py so that being
passed something in runtime_library_dirs does not
raise an exception. They will now print a warning
message if runtime_library_dirs is not empty or
None. They will return an empty list if
runtime_library_dir_option() is called.
5. uw7_uslccompiler.patch
This patch adds the USLCCompiler class.
----------------------------------------------------------------------
Comment By: Billy G. Allie (ballie01)
Date: 2001-08-22 21:46
Message:
Logged In: YES
user_id=8500
A new version of the setup.py patch, uw7_setup_2.patch has
been uploaded. This takes info account the recent change to
setup.py in regards to the bsddb module. Please use this
patch in place of uw7_setup_2.patch.
----------------------------------------------------------------------
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=305470&aid=454041&group_id=5470