FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.

» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Gentoo > Gentoo Development

LinkBack Thread Tools
Old 12-15-2010, 01:31 PM
Arfrever Frehtes Taifersar Arahesis
Default Patches for python.eclass and distutils.eclass

Patch for python.eclass is divided into 3 subpatches.
Subpatch #1 adds/improves/updates support for Jython in many functions and fixes some minor
bugs in python_generate_wrapper_scripts().
Subpatch #2 adds python_merge_intermediate_installation_images() function. This function will
provide improved and more generic version of a functionality of distutils_src_install().
This function automatically performs the following actions:
- Renaming of versioned Python scripts.
- Conversion of shebangs in Python scripts.
- Merging of intermediate installation images into installation image.
- Generation of Python wrapper scripts.
Example usage:
src_install() {
installation() {
emake DESTDIR="${T}/images/${PYTHON_ABI}" install
python_execute_function installation
python_merge_intermediate_installation_images "${T}/images"
Python scripts in /usr/bin and /usr/sbin are versioned by default.
are used to control, which files should be versioned.
PYTHON_VERSIONED_EXECUTABLES is useful e.g. for dev-util/eric, which installs shell scripts.
Subpatch #3 renames some private arrays for consistency with other arrays.
E.g. _PYTHON_GLOBALLY_SUPPORTED_ABIS will contain Python ABIs generally supported by
python.eclass, while _PYTHON_LOCALLY_SUPPORTED_ABIS will contain Python ABIs supported by
current package.

Patch for distutils.eclass is divided into 2 subpatches.
Subpatch #1 ports distutils_src_install() to use python_merge_intermediate_installation_images()
and deprecates DISTUTILS_DISABLE_VERSIONING_OF_PYTHON_SCRIPTS variable, which is used only in
2 packages in the tree.
Subpatch #2 adds optional deprecation warnings for some cases. Deprecation warnings are
printed only when PYTHON_DEPRECATION_WARNINGS variable is set (e.g. in /etc/make.conf).
It might be useful for Gentoo developers to set this variable to avoid committing ebuilds
using deprecated functionality. This subpatch does NOT introduce any deprecation, because
the corresponding functionality has been already deprecated since 2010-08-03 (without
deprecation warnings).

I'm planning to commit these patches in 1 week.

Arfrever Frehtes Taifersar Arahesis
Old 12-15-2010, 01:56 PM
Ulrich Mueller
Default Patches for python.eclass and distutils.eclass

>>>>> On Wed, 15 Dec 2010, Arfrever Frehtes Taifersar Arahesis wrote:

>+ sed -e "1s:^#![[:space:]]*([^[:space:]]*/usr/bin/env[[:space:]])?[[:space:]]*([^[:space:]]*/)?(jython|python)([[:digit:]]+(.[[:digit:]]+)?)?($|[[:space:]].*):#!12${python_interpreter}6:" -i "${file}" || die "Conversion of shebang in '${file}' failed"
>+ echo ${_BOLD}"$(PYTHON)" "${setup_file}" "${DISTUTILS_GLOBAL_OPTIONS[@]}" $([[ -z "${DISTUTILS_USE_SEPARATE_SOURCE_DIRECTORIES}" ]] && echo build -b "$(_distutils_get_build_dir)") install --no-compile --root="${T}/images/${PYTHON_ABI}" "$@"${_NORMAL}

This is unreadable. Could you please use a reasonable line length
below 80 characters? In your mail message and (more important) in the


Thread Tools

All times are GMT. The time now is 01:24 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org