* [gentoo-commits] gentoo-x86 commit in eclass: ChangeLog python-any-r1.eclass python-r1.eclass python-single-r1.eclass python-utils-r1.eclass
@ 2012-12-20 23:35 Michal Gorny (mgorny)
0 siblings, 0 replies; 4+ messages in thread
From: Michal Gorny (mgorny) @ 2012-12-20 23:35 UTC (permalink / raw
To: gentoo-commits
mgorny 12/12/20 23:35:17
Modified: ChangeLog python-any-r1.eclass python-r1.eclass
python-single-r1.eclass python-utils-r1.eclass
Log:
Commonize the code for obtaining the Python interpreter dependency string.
Revision Changes Path
1.572 eclass/ChangeLog
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?rev=1.572&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?rev=1.572&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?r1=1.571&r2=1.572
Index: ChangeLog
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v
retrieving revision 1.571
retrieving revision 1.572
diff -u -r1.571 -r1.572
--- ChangeLog 20 Dec 2012 21:01:50 -0000 1.571
+++ ChangeLog 20 Dec 2012 23:35:17 -0000 1.572
@@ -1,6 +1,10 @@
# ChangeLog for eclass directory
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.571 2012/12/20 21:01:50 jlec Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.572 2012/12/20 23:35:17 mgorny Exp $
+
+ 20 Dec 2012; Michał Górny <mgorny@gentoo.org> python-any-r1.eclass,
+ python-r1.eclass, python-single-r1.eclass, python-utils-r1.eclass:
+ Commonize the code for obtaining the Python interpreter dependency string.
20 Dec 2012; Justin Lecher <jlec@gentoo.org> flag-o-matic.eclass:
Add fix for nen gnu compiler which use -x as command line arg internally,
1.3 eclass/python-any-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-any-r1.eclass?rev=1.3&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-any-r1.eclass?rev=1.3&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-any-r1.eclass?r1=1.2&r2=1.3
Index: python-any-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-any-r1.eclass,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- python-any-r1.eclass 7 Dec 2012 18:00:08 -0000 1.2
+++ python-any-r1.eclass 20 Dec 2012 23:35:17 -0000 1.3
@@ -1,6 +1,6 @@
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-any-r1.eclass,v 1.2 2012/12/07 18:00:08 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-any-r1.eclass,v 1.3 2012/12/20 23:35:17 mgorny Exp $
# @ECLASS: python-any-r1
# @MAINTAINER:
@@ -202,25 +202,13 @@
fi
done
+ local PYTHON_PKG_DEP
for i in "${rev_impls[@]}"; do
- local d
- case "${i}" in
- python*)
- d='dev-lang/python';;
- jython*)
- d='dev-java/jython';;
- pypy*)
- d='dev-python/pypy';;
- *)
- die "Invalid implementation: ${i}"
- esac
- local v=${i##*[a-z]}
-
- if has_version "${d}:${v/_/.}${usestr}"; then
- python_export "${i}" EPYTHON PYTHON
- break
- fi
+ python_export "${i}" PYTHON_PKG_DEP EPYTHON PYTHON
+ has_version "${PYTHON_PKG_DEP}" && break
done
+
+ die $EPYTHON
}
_PYTHON_ANY_R1=1
1.31 eclass/python-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-r1.eclass?rev=1.31&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-r1.eclass?rev=1.31&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-r1.eclass?r1=1.30&r2=1.31
Index: python-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-r1.eclass,v
retrieving revision 1.30
retrieving revision 1.31
diff -u -r1.30 -r1.31
--- python-r1.eclass 19 Dec 2012 09:22:17 -0000 1.30
+++ python-r1.eclass 20 Dec 2012 23:35:17 -0000 1.31
@@ -1,6 +1,6 @@
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-r1.eclass,v 1.30 2012/12/19 09:22:17 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-r1.eclass,v 1.31 2012/12/20 23:35:17 mgorny Exp $
# @ECLASS: python-r1
# @MAINTAINER:
@@ -149,30 +149,15 @@
REQUIRED_USE="|| ( ${flags[*]} )"
PYTHON_USEDEP=${optflags// /,}
- local usestr
- [[ ${PYTHON_REQ_USE} ]] && usestr="[${PYTHON_REQ_USE}]"
-
# 1) well, python-exec would suffice as an RDEP
# but no point in making this overcomplex, BDEP doesn't hurt anyone
# 2) python-exec should be built with all targets forced anyway
# but if new targets were added, we may need to force a rebuild
PYTHON_DEPS="dev-python/python-exec[${PYTHON_USEDEP}]"
- local i
+ local i PYTHON_PKG_DEP
for i in "${PYTHON_COMPAT[@]}"; do
- local d
- case ${i} in
- python*)
- d='dev-lang/python';;
- jython*)
- d='dev-java/jython';;
- pypy*)
- d='dev-python/pypy';;
- *)
- die "Invalid implementation: ${i}"
- esac
-
- local v=${i##*[a-z]}
- PYTHON_DEPS+=" python_targets_${i}? ( ${d}:${v/_/.}${usestr} )"
+ python_export "${i}" PYTHON_PKG_DEP
+ PYTHON_DEPS+=" python_targets_${i}? ( ${PYTHON_PKG_DEP} )"
done
}
_python_set_globals
1.9 eclass/python-single-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-single-r1.eclass?rev=1.9&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-single-r1.eclass?rev=1.9&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-single-r1.eclass?r1=1.8&r2=1.9
Index: python-single-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-single-r1.eclass,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- python-single-r1.eclass 17 Dec 2012 20:09:28 -0000 1.8
+++ python-single-r1.eclass 20 Dec 2012 23:35:17 -0000 1.9
@@ -1,6 +1,6 @@
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-single-r1.eclass,v 1.8 2012/12/17 20:09:28 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-single-r1.eclass,v 1.9 2012/12/20 23:35:17 mgorny Exp $
# @ECLASS: python-single-r1
# @MAINTAINER:
@@ -144,35 +144,20 @@
REQUIRED_USE="|| ( ${flags_mt[*]} ) ^^ ( ${flags[*]} )"
PYTHON_USEDEP=${optflags// /,}
- local usestr
- [[ ${PYTHON_REQ_USE} ]] && usestr="[${PYTHON_REQ_USE}]"
-
# 1) well, python-exec would suffice as an RDEP
# but no point in making this overcomplex, BDEP doesn't hurt anyone
# 2) python-exec should be built with all targets forced anyway
# but if new targets were added, we may need to force a rebuild
PYTHON_DEPS="dev-python/python-exec[${PYTHON_USEDEP}]"
- local i
+ local i PYTHON_PKG_DEP
for i in "${PYTHON_COMPAT[@]}"; do
# The chosen targets need to be in PYTHON_TARGETS as well.
# This is in order to enforce correct dependencies on packages
# supporting multiple implementations.
REQUIRED_USE+=" python_single_target_${i}? ( python_targets_${i} )"
- local d
- case ${i} in
- python*)
- d='dev-lang/python';;
- jython*)
- d='dev-java/jython';;
- pypy*)
- d='dev-python/pypy';;
- *)
- die "Invalid implementation: ${i}"
- esac
-
- local v=${i##*[a-z]}
- PYTHON_DEPS+=" python_single_target_${i}? ( ${d}:${v/_/.}${usestr} )"
+ python_export "${i}" PYTHON_PKG_DEP
+ PYTHON_DEPS+=" python_single_target_${i}? ( ${PYTHON_PKG_DEP} )"
done
}
_python_single_set_globals
1.9 eclass/python-utils-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?rev=1.9&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?rev=1.9&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?r1=1.8&r2=1.9
Index: python-utils-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- python-utils-r1.eclass 20 Dec 2012 06:05:23 -0000 1.8
+++ python-utils-r1.eclass 20 Dec 2012 23:35:17 -0000 1.9
@@ -1,6 +1,6 @@
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v 1.8 2012/12/20 06:05:23 floppym Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v 1.9 2012/12/20 23:35:17 mgorny Exp $
# @ECLASS: python-utils-r1
# @MAINTAINER:
@@ -83,6 +83,17 @@
# /usr/lib64/python2.6/site-packages
# @CODE
+# @ECLASS-VARIABLE: PYTHON_PKG_DEP
+# @DESCRIPTION:
+# The complete dependency on a particular Python package as a string.
+#
+# Set and exported on request using python_export().
+#
+# Example value:
+# @CODE
+# dev-lang/python:2.7[xml]
+# @CODE
+
# @FUNCTION: python_export
# @USAGE: [<impl>] <variables>...
# @DESCRIPTION:
@@ -150,6 +161,30 @@
export PYTHON_SITEDIR=${EPREFIX}${dir}/site-packages
debug-print "${FUNCNAME}: PYTHON_SITEDIR = ${PYTHON_SITEDIR}"
;;
+ PYTHON_PKG_DEP)
+ local d
+ case ${impl} in
+ python*)
+ PYTHON_PKG_DEP='dev-lang/python';;
+ jython*)
+ PYTHON_PKG_DEP='dev-java/jython';;
+ pypy*)
+ PYTHON_PKG_DEP='dev-python/pypy';;
+ *)
+ die "Invalid implementation: ${impl}"
+ esac
+
+ # slot
+ PYTHON_PKG_DEP+=:${impl##*[a-z-]}
+
+ # use-dep
+ if [[ ${PYTHON_REQ_USE} ]]; then
+ PYTHON_PKG_DEP+=[${PYTHON_REQ_USE}]
+ fi
+
+ export PYTHON_PKG_DEP
+ debug-print "${FUNCNAME}: PYTHON_PKG_DEP = ${PYTHON_PKG_DEP}"
+ ;;
*)
die "python_export: unknown variable ${var}"
esac
^ permalink raw reply [flat|nested] 4+ messages in thread
* [gentoo-commits] gentoo-x86 commit in eclass: ChangeLog python-any-r1.eclass python-r1.eclass python-single-r1.eclass python-utils-r1.eclass
@ 2013-01-21 19:28 Michal Gorny (mgorny)
0 siblings, 0 replies; 4+ messages in thread
From: Michal Gorny (mgorny) @ 2013-01-21 19:28 UTC (permalink / raw
To: gentoo-commits
mgorny 13/01/21 19:28:16
Modified: ChangeLog python-any-r1.eclass python-r1.eclass
python-single-r1.eclass python-utils-r1.eclass
Log:
Check PYTHON_COMPAT for validity, and support disabling implementations in the eclass.
Revision Changes Path
1.631 eclass/ChangeLog
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?rev=1.631&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?rev=1.631&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?r1=1.630&r2=1.631
Index: ChangeLog
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v
retrieving revision 1.630
retrieving revision 1.631
diff -u -r1.630 -r1.631
--- ChangeLog 21 Jan 2013 19:22:25 -0000 1.630
+++ ChangeLog 21 Jan 2013 19:28:16 -0000 1.631
@@ -1,6 +1,11 @@
# ChangeLog for eclass directory
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.630 2013/01/21 19:22:25 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.631 2013/01/21 19:28:16 mgorny Exp $
+
+ 21 Jan 2013; Michał Górny <mgorny@gentoo.org> python-any-r1.eclass,
+ python-r1.eclass, python-single-r1.eclass, python-utils-r1.eclass:
+ Check PYTHON_COMPAT for validity, and support disabling implementations in
+ the eclass.
21 Jan 2013; Michał Górny <mgorny@gentoo.org> multilib.eclass:
Set PKG_CONFIG_{LIBDIR,PATH} for multilib builds. Approved by vapier in bug
1.6 eclass/python-any-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-any-r1.eclass?rev=1.6&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-any-r1.eclass?rev=1.6&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-any-r1.eclass?r1=1.5&r2=1.6
Index: python-any-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-any-r1.eclass,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- python-any-r1.eclass 2 Jan 2013 21:12:44 -0000 1.5
+++ python-any-r1.eclass 21 Jan 2013 19:28:16 -0000 1.6
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-any-r1.eclass,v 1.5 2013/01/02 21:12:44 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-any-r1.eclass,v 1.6 2013/01/21 19:28:16 mgorny Exp $
# @ECLASS: python-any-r1
# @MAINTAINER:
@@ -134,13 +134,13 @@
}
_python_build_set_globals
-# @FUNCTION: _python_impl_supported
+# @FUNCTION: _python_EPYTHON_supported
# @USAGE: <epython>
# @INTERNAL
# @DESCRIPTION:
# Check whether the specified implementation is supported by package
# (specified in PYTHON_COMPAT).
-_python_impl_supported() {
+_python_EPYTHON_supported() {
debug-print-function ${FUNCNAME} "${@}"
local i=${1/./_}
@@ -153,6 +153,7 @@
;;
*)
ewarn "Invalid EPYTHON: ${EPYTHON}"
+ return 1
;;
esac
@@ -173,7 +174,7 @@
# first, try ${EPYTHON}... maybe it's good enough for us.
if [[ ${EPYTHON} ]]; then
- if _python_impl_supported "${EPYTHON}"; then
+ if _python_EPYTHON_supported "${EPYTHON}"; then
python_export EPYTHON PYTHON
return
fi
@@ -187,7 +188,7 @@
if [[ ! ${i} ]]; then
# no eselect-python?
break
- elif _python_impl_supported "${i}"; then
+ elif _python_EPYTHON_supported "${i}"; then
python_export "${i}" EPYTHON PYTHON
return
fi
@@ -206,8 +207,6 @@
python_export "${i}" PYTHON_PKG_DEP EPYTHON PYTHON
ROOT=/ has_version "${PYTHON_PKG_DEP}" && return
done
-
- die $EPYTHON
}
_PYTHON_ANY_R1=1
1.37 eclass/python-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-r1.eclass?rev=1.37&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-r1.eclass?rev=1.37&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-r1.eclass?r1=1.36&r2=1.37
Index: python-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-r1.eclass,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -r1.36 -r1.37
--- python-r1.eclass 8 Jan 2013 16:36:16 -0000 1.36
+++ python-r1.eclass 21 Jan 2013 19:28:16 -0000 1.37
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-r1.eclass,v 1.36 2013/01/08 16:36:16 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-r1.eclass,v 1.37 2013/01/21 19:28:16 mgorny Exp $
# @ECLASS: python-r1
# @MAINTAINER:
@@ -132,7 +132,24 @@
# @CODE
_python_set_globals() {
- local flags=( "${PYTHON_COMPAT[@]/#/python_targets_}" )
+ local impls=()
+
+ PYTHON_DEPS=
+ local i PYTHON_PKG_DEP
+ for i in "${PYTHON_COMPAT[@]}"; do
+ _python_impl_supported "${i}" || continue
+
+ python_export "${i}" PYTHON_PKG_DEP
+ PYTHON_DEPS+="python_targets_${i}? ( ${PYTHON_PKG_DEP} ) "
+
+ impls+=( "${i}" )
+ done
+
+ if [[ ${#impls[@]} -eq 0 ]]; then
+ die "No supported implementation in PYTHON_COMPAT."
+ fi
+
+ local flags=( "${impls[@]/#/python_targets_}" )
local optflags=${flags[@]/%/?}
# A nice QA trick here. Since a python-single-r1 package has to have
@@ -141,7 +158,7 @@
# it should prevent developers from mistakenly depending on packages
# not supporting multiple Python implementations.
- local flags_st=( "${PYTHON_COMPAT[@]/#/-python_single_target_}" )
+ local flags_st=( "${impls[@]/#/-python_single_target_}" )
optflags+=,${flags_st[@]/%/(-)}
IUSE=${flags[*]}
@@ -152,12 +169,7 @@
# but no point in making this overcomplex, BDEP doesn't hurt anyone
# 2) python-exec should be built with all targets forced anyway
# but if new targets were added, we may need to force a rebuild
- PYTHON_DEPS="dev-python/python-exec[${PYTHON_USEDEP}]"
- local i PYTHON_PKG_DEP
- for i in "${PYTHON_COMPAT[@]}"; do
- python_export "${i}" PYTHON_PKG_DEP
- PYTHON_DEPS+=" python_targets_${i}? ( ${PYTHON_PKG_DEP} )"
- done
+ PYTHON_DEPS+="dev-python/python-exec[${PYTHON_USEDEP}]"
}
_python_set_globals
@@ -171,6 +183,8 @@
local i
for i in "${PYTHON_COMPAT[@]}"; do
+ _python_impl_supported "${i}" || continue
+
use "python_targets_${i}" && return 0
done
@@ -210,6 +224,8 @@
local matches=()
for impl in "${PYTHON_COMPAT[@]}"; do
+ _python_impl_supported "${impl}" || continue
+
for pattern; do
if [[ ${impl} == ${pattern} ]]; then
matches+=(
@@ -249,6 +265,8 @@
local matches=()
for impl in "${PYTHON_COMPAT[@]}"; do
+ _python_impl_supported "${impl}" || continue
+
for pattern; do
if [[ ${impl} == ${pattern} ]]; then
matches+=( "python_targets_${impl}" )
@@ -292,6 +310,8 @@
shift
for impl in "${PYTHON_COMPAT[@]}"; do
+ _python_impl_supported "${impl}" || continue
+
for pattern; do
if [[ ${impl} == ${pattern} ]]; then
matches+=( "python_targets_${impl}? ( ${dep} )" )
@@ -337,6 +357,8 @@
einfo "Will copy sources from ${S}"
# the order is irrelevant here
for impl in "${PYTHON_COMPAT[@]}"; do
+ _python_impl_supported "${impl}" || continue
+
if use "python_targets_${impl}"
then
local BUILD_DIR=${bdir%%/}-${impl}
@@ -369,6 +391,8 @@
local impl py2 py3 dis_py2 dis_py3
for impl in "${PYTHON_COMPAT[@]}"; do
+ _python_impl_supported "${impl}" || continue
+
if use "python_targets_${impl}"; then
case "${impl}" in
python2_*)
@@ -480,6 +504,8 @@
local impl old=${USE_PYTHON} new=() removed=()
for impl in "${PYTHON_COMPAT[@]}"; do
+ _python_impl_supported "${impl}" || continue
+
local abi
case "${impl}" in
python*)
@@ -573,7 +599,9 @@
debug-print "${FUNCNAME}: bdir = ${bdir}"
for impl in "${_PYTHON_ALL_IMPLS[@]}"; do
- if has "${impl}" "${PYTHON_COMPAT[@]}" && use "python_targets_${impl}"
+ if has "${impl}" "${PYTHON_COMPAT[@]}" \
+ && _python_impl_supported "${impl}" \
+ && use "python_targets_${impl}"
then
local EPYTHON PYTHON
python_export "${impl}" EPYTHON PYTHON
@@ -601,7 +629,9 @@
local impl best
for impl in "${_PYTHON_ALL_IMPLS[@]}"; do
- if has "${impl}" "${PYTHON_COMPAT[@]}" && use "python_targets_${impl}"
+ if has "${impl}" "${PYTHON_COMPAT[@]}" \
+ && _python_impl_supported "${impl}" \
+ && use "python_targets_${impl}"
then
best=${impl}
fi
1.14 eclass/python-single-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-single-r1.eclass?rev=1.14&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-single-r1.eclass?rev=1.14&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-single-r1.eclass?r1=1.13&r2=1.14
Index: python-single-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-single-r1.eclass,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- python-single-r1.eclass 8 Jan 2013 20:18:38 -0000 1.13
+++ python-single-r1.eclass 21 Jan 2013 19:28:16 -0000 1.14
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-single-r1.eclass,v 1.13 2013/01/08 20:18:38 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-single-r1.eclass,v 1.14 2013/01/21 19:28:16 mgorny Exp $
# @ECLASS: python-single-r1
# @MAINTAINER:
@@ -134,8 +134,31 @@
# @CODE
_python_single_set_globals() {
- local flags_mt=( "${PYTHON_COMPAT[@]/#/python_targets_}" )
- local flags=( "${PYTHON_COMPAT[@]/#/python_single_target_}" )
+ local impls=()
+
+ PYTHON_DEPS=
+ local i PYTHON_PKG_DEP
+ for i in "${PYTHON_COMPAT[@]}"; do
+ _python_impl_supported "${i}" || continue
+
+ # The chosen targets need to be in PYTHON_TARGETS as well.
+ # This is in order to enforce correct dependencies on packages
+ # supporting multiple implementations.
+ #REQUIRED_USE+=" python_single_target_${i}? ( python_targets_${i} )"
+
+ python_export "${i}" PYTHON_PKG_DEP
+ PYTHON_DEPS+="python_single_target_${i}? ( ${PYTHON_PKG_DEP} ) "
+
+ impls+=( "${i}" )
+ done
+
+ if [[ ${#impls[@]} -eq 0 ]]; then
+ die "No supported implementation in PYTHON_COMPAT."
+ fi
+
+ local flags_mt=( "${impls[@]/#/python_targets_}" )
+ local flags=( "${impls[@]/#/python_single_target_}" )
+
local optflags=${flags_mt[@]/%/?}
optflags+=,${flags[@]/%/(+)?}
@@ -147,17 +170,7 @@
# but no point in making this overcomplex, BDEP doesn't hurt anyone
# 2) python-exec should be built with all targets forced anyway
# but if new targets were added, we may need to force a rebuild
- PYTHON_DEPS="dev-python/python-exec[${PYTHON_USEDEP}]"
- local i PYTHON_PKG_DEP
- for i in "${PYTHON_COMPAT[@]}"; do
- # The chosen targets need to be in PYTHON_TARGETS as well.
- # This is in order to enforce correct dependencies on packages
- # supporting multiple implementations.
- #REQUIRED_USE+=" python_single_target_${i}? ( python_targets_${i} )"
-
- python_export "${i}" PYTHON_PKG_DEP
- PYTHON_DEPS+=" python_single_target_${i}? ( ${PYTHON_PKG_DEP} )"
- done
+ PYTHON_DEPS+="dev-python/python-exec[${PYTHON_USEDEP}]"
}
_python_single_set_globals
1.14 eclass/python-utils-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?rev=1.14&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?rev=1.14&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?r1=1.13&r2=1.14
Index: python-utils-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- python-utils-r1.eclass 5 Jan 2013 10:01:20 -0000 1.13
+++ python-utils-r1.eclass 21 Jan 2013 19:28:16 -0000 1.14
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v 1.13 2013/01/05 10:01:20 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v 1.14 2013/01/21 19:28:16 mgorny Exp $
# @ECLASS: python-utils-r1
# @MAINTAINER:
@@ -47,6 +47,37 @@
python2_5 python2_6 python2_7
)
+# @FUNCTION: _python_impl_supported
+# @USAGE: <impl>
+# @INTERNAL
+# @DESCRIPTION:
+# Check whether the implementation <impl> (PYTHON_COMPAT-form)
+# is still supported.
+#
+# Returns 0 if the implementation is valid and supported. If it is
+# unsupported, returns 1 -- and the caller should ignore the entry.
+# If it is invalid, dies with an appopriate error messages.
+_python_impl_supported() {
+ debug-print-function ${FUNCNAME} "${@}"
+
+ [[ ${#} -eq 1 ]] || die "${FUNCNAME}: takes exactly 1 argument (impl)."
+
+ local impl=${1}
+
+ # keep in sync with _PYTHON_ALL_IMPLS!
+ # (not using that list because inline patterns shall be faster)
+ case "${impl}" in
+ python2_[567]|python3_[123]|pypy1_[89]|pypy2_0|jython2_5)
+ return 0
+ ;;
+# pypy1_8)
+# return 1
+# ;;
+ *)
+ die "Invalid implementation in PYTHON_COMPAT: ${impl}"
+ esac
+}
+
# @ECLASS-VARIABLE: PYTHON
# @DESCRIPTION:
# The absolute path to the current Python interpreter.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [gentoo-commits] gentoo-x86 commit in eclass: ChangeLog python-any-r1.eclass python-r1.eclass python-single-r1.eclass python-utils-r1.eclass
@ 2013-04-07 17:02 Michal Gorny (mgorny)
0 siblings, 0 replies; 4+ messages in thread
From: Michal Gorny (mgorny) @ 2013-04-07 17:02 UTC (permalink / raw
To: gentoo-commits
mgorny 13/04/07 17:02:52
Modified: ChangeLog python-any-r1.eclass python-r1.eclass
python-single-r1.eclass python-utils-r1.eclass
Log:
Create temporary symlinks for executables and pkg-config files, and add them to $PATH and $PKG_CONFIG_PATH respectively. This makes it easier for broken build systems to find Python, and gives us the possibility of dropping python-wrapper.
Revision Changes Path
1.770 eclass/ChangeLog
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?rev=1.770&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?rev=1.770&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?r1=1.769&r2=1.770
Index: ChangeLog
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v
retrieving revision 1.769
retrieving revision 1.770
diff -u -r1.769 -r1.770
--- ChangeLog 7 Apr 2013 16:56:14 -0000 1.769
+++ ChangeLog 7 Apr 2013 17:02:52 -0000 1.770
@@ -1,6 +1,13 @@
# ChangeLog for eclass directory
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.769 2013/04/07 16:56:14 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.770 2013/04/07 17:02:52 mgorny Exp $
+
+ 07 Apr 2013; Michał Górny <mgorny@gentoo.org> python-any-r1.eclass,
+ python-r1.eclass, python-single-r1.eclass, python-utils-r1.eclass:
+ Create temporary symlinks for executables and pkg-config files, and add them
+ to $PATH and $PKG_CONFIG_PATH respectively. This makes it easier for broken
+ build systems to find Python, and gives us the possibility of dropping
+ python-wrapper.
07 Apr 2013; Michał Górny <mgorny@gentoo.org> autotools-multilib.eclass,
multilib-build.eclass, multilib-minimal.eclass:
1.7 eclass/python-any-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-any-r1.eclass?rev=1.7&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-any-r1.eclass?rev=1.7&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-any-r1.eclass?r1=1.6&r2=1.7
Index: python-any-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-any-r1.eclass,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- python-any-r1.eclass 21 Jan 2013 19:28:16 -0000 1.6
+++ python-any-r1.eclass 7 Apr 2013 17:02:52 -0000 1.7
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-any-r1.eclass,v 1.6 2013/01/21 19:28:16 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-any-r1.eclass,v 1.7 2013/04/07 17:02:52 mgorny Exp $
# @ECLASS: python-any-r1
# @MAINTAINER:
@@ -205,7 +205,10 @@
local PYTHON_PKG_DEP
for i in "${rev_impls[@]}"; do
python_export "${i}" PYTHON_PKG_DEP EPYTHON PYTHON
- ROOT=/ has_version "${PYTHON_PKG_DEP}" && return
+ if ROOT=/ has_version "${PYTHON_PKG_DEP}"; then
+ python_wrapper_setup "${T}"
+ return
+ fi
done
}
1.53 eclass/python-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-r1.eclass?rev=1.53&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-r1.eclass?rev=1.53&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-r1.eclass?r1=1.52&r2=1.53
Index: python-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-r1.eclass,v
retrieving revision 1.52
retrieving revision 1.53
diff -u -r1.52 -r1.53
--- python-r1.eclass 30 Mar 2013 12:56:24 -0000 1.52
+++ python-r1.eclass 7 Apr 2013 17:02:52 -0000 1.53
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-r1.eclass,v 1.52 2013/03/30 12:56:24 floppym Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-r1.eclass,v 1.53 2013/04/07 17:02:52 mgorny Exp $
# @ECLASS: python-r1
# @MAINTAINER:
@@ -637,7 +637,9 @@
debug-print-function ${FUNCNAME} "${@}"
local -x EPYTHON PYTHON
+ local -x PATH=${PATH} PKG_CONFIG_PATH=${PKG_CONFIG_PATH}
python_export "${MULTIBUILD_VARIANT}" EPYTHON PYTHON
+ python_wrapper_setup "${T}/${EPYTHON}"
"${@}"
}
@@ -710,6 +712,7 @@
debug-print "${FUNCNAME}: Best implementation is: ${best}"
python_export "${best}" "${@}"
+ python_wrapper_setup "${T}"
}
# @FUNCTION: python_replicate_script
1.16 eclass/python-single-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-single-r1.eclass?rev=1.16&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-single-r1.eclass?rev=1.16&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-single-r1.eclass?r1=1.15&r2=1.16
Index: python-single-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-single-r1.eclass,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -r1.15 -r1.16
--- python-single-r1.eclass 30 Jan 2013 10:42:25 -0000 1.15
+++ python-single-r1.eclass 7 Apr 2013 17:02:52 -0000 1.16
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-single-r1.eclass,v 1.15 2013/01/30 10:42:25 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-single-r1.eclass,v 1.16 2013/04/07 17:02:52 mgorny Exp $
# @ECLASS: python-single-r1
# @MAINTAINER:
@@ -207,6 +207,7 @@
fi
python_export "${impl}" EPYTHON PYTHON
+ python_wrapper_setup "${T}"
fi
done
1.21 eclass/python-utils-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?rev=1.21&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?rev=1.21&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?r1=1.20&r2=1.21
Index: python-utils-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -r1.20 -r1.21
--- python-utils-r1.eclass 28 Mar 2013 12:21:46 -0000 1.20
+++ python-utils-r1.eclass 7 Apr 2013 17:02:52 -0000 1.21
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v 1.20 2013/03/28 12:21:46 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v 1.21 2013/04/07 17:02:52 mgorny Exp $
# @ECLASS: python-utils-r1
# @MAINTAINER:
@@ -818,5 +818,99 @@
doins -r "${@}" || die
}
+# @FUNCTION: python_wrapper_setup
+# @USAGE: <path> [<impl>]
+# @DESCRIPTION:
+# Create proper 'python' executable and pkg-config wrappers
+# (if available) in the directory named by <path>. Set up PATH
+# and PKG_CONFIG_PATH appropriately.
+#
+# The wrappers will be created for implementation named by <impl>,
+# or for one named by ${EPYTHON} if no <impl> passed.
+#
+# If the named directory contains a python symlink already, it will
+# be assumed to contain proper wrappers already and only environment
+# setup will be done. If wrapper update is requested, the directory
+# shall be removed first.
+python_wrapper_setup() {
+ debug-print-function ${FUNCNAME} "${@}"
+
+ local workdir=${1}
+ local impl=${2:-${EPYTHON}}
+
+ [[ ${workdir} ]] || die "${FUNCNAME}: no workdir specified."
+ [[ ${impl} ]] || die "${FUNCNAME}: no impl nor EPYTHON specified."
+
+ if [[ ! -x ${workdir}/bin/python ]]; then
+ mkdir -p "${workdir}"/{bin,pkgconfig} || die
+
+ # Clean up, in case we were supposed to do a cheap update.
+ rm -f "${workdir}"/bin/python{,2,3,-config}
+ rm -f "${workdir}"/bin/2to3
+ rm -f "${workdir}"/pkgconfig/python{,2,3}.pc
+
+ local EPYTHON PYTHON
+ python_export "${impl}" EPYTHON PYTHON
+
+ local pyver
+ if [[ ${EPYTHON} == python3* ]]; then
+ pyver=3
+ else # includes pypy & jython
+ pyver=2
+ fi
+
+ # Python interpreter
+ ln -s "${PYTHON}" "${workdir}"/bin/python || die
+ ln -s python "${workdir}"/bin/python${pyver} || die
+
+ local nonsupp=()
+
+ # CPython-specific
+ if [[ ${EPYTHON} == python* ]]; then
+ ln -s "${PYTHON}-config" "${workdir}"/bin/python-config || die
+
+ # Python 2.6+.
+ if [[ ${EPYTHON} != python2.5 ]]; then
+ ln -s "${PYTHON/python/2to3-}" "${workdir}"/bin/2to3 || die
+ else
+ nonsupp+=( 2to3 )
+ fi
+
+ # Python 2.7+.
+ if [[ ${EPYTHON} != python2.[56] ]]; then
+ ln -s "${EPREFIX}"/usr/$(get_libdir)/pkgconfig/${EPYTHON/n/n-}.pc \
+ "${workdir}"/pkgconfig/python.pc || die
+ else
+ # XXX?
+ ln -s /dev/null "${workdir}"/pkgconfig/python.pc || die
+ fi
+ ln -s python.pc "${workdir}"/pkgconfig/python${pyver}.pc || die
+ else
+ nonsupp+=( 2to3 python-config )
+ fi
+
+ local x
+ for x in "${nonsupp[@]}"; do
+ echo >"${workdir}"/bin/${x} <<__EOF__ || die
+#!/bin/sh
+echo "${x} is not supported by ${EPYTHON}" >&2
+exit 1
+__EOF__
+ chmod +x "${workdir}"/bin/${x} || die
+ done
+
+ # Now, set the environment.
+ # But note that ${workdir} may be shared with something else,
+ # and thus already on top of PATH.
+ if [[ ${PATH##:*} != ${workdir}/bin ]]; then
+ PATH=${workdir}/bin${PATH:+:${PATH}}
+ fi
+ if [[ ${PKG_CONFIG_PATH##:*} != ${workdir}/pkgconfig ]]; then
+ PKG_CONFIG_PATH=${workdir}/pkgconfig${PKG_CONFIG_PATH:+:${PKG_CONFIG_PATH}}
+ fi
+ export PATH PKG_CONFIG_PATH
+ fi
+}
+
_PYTHON_UTILS_R1=1
fi
^ permalink raw reply [flat|nested] 4+ messages in thread
* [gentoo-commits] gentoo-x86 commit in eclass: ChangeLog python-any-r1.eclass python-r1.eclass python-single-r1.eclass python-utils-r1.eclass
@ 2013-05-10 22:03 Michal Gorny (mgorny)
0 siblings, 0 replies; 4+ messages in thread
From: Michal Gorny (mgorny) @ 2013-05-10 22:03 UTC (permalink / raw
To: gentoo-commits
mgorny 13/05/10 22:03:31
Modified: ChangeLog python-any-r1.eclass python-r1.eclass
python-single-r1.eclass python-utils-r1.eclass
Log:
Consistently create ${EPYTHON} subdir for Python wrappers. Fixes conflict between Python & vala wrappers, bug #469312.
Revision Changes Path
1.818 eclass/ChangeLog
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?rev=1.818&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?rev=1.818&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?r1=1.817&r2=1.818
Index: ChangeLog
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v
retrieving revision 1.817
retrieving revision 1.818
diff -u -r1.817 -r1.818
--- ChangeLog 9 May 2013 03:03:02 -0000 1.817
+++ ChangeLog 10 May 2013 22:03:30 -0000 1.818
@@ -1,6 +1,11 @@
# ChangeLog for eclass directory
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.817 2013/05/09 03:03:02 dirtyepic Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.818 2013/05/10 22:03:30 mgorny Exp $
+
+ 10 May 2013; Michał Górny <mgorny@gentoo.org> python-any-r1.eclass,
+ python-r1.eclass, python-single-r1.eclass, python-utils-r1.eclass:
+ Consistently create ${EPYTHON} subdir for Python wrappers. Fixes conflict
+ between Python & vala wrappers, bug #469312.
09 May 2013; Ryan Hill <dirtyepic@gentoo.org> toolchain.eclass:
Drop support for graphite in 4.4/4.5 due to incompatibilities with newer ppl
1.11 eclass/python-any-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-any-r1.eclass?rev=1.11&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-any-r1.eclass?rev=1.11&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-any-r1.eclass?r1=1.10&r2=1.11
Index: python-any-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-any-r1.eclass,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -r1.10 -r1.11
--- python-any-r1.eclass 30 Apr 2013 05:34:33 -0000 1.10
+++ python-any-r1.eclass 10 May 2013 22:03:30 -0000 1.11
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-any-r1.eclass,v 1.10 2013/04/30 05:34:33 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-any-r1.eclass,v 1.11 2013/05/10 22:03:30 mgorny Exp $
# @ECLASS: python-any-r1
# @MAINTAINER:
@@ -216,7 +216,7 @@
if [[ ${EPYTHON} ]]; then
if _python_EPYTHON_supported "${EPYTHON}"; then
python_export EPYTHON PYTHON
- python_wrapper_setup "${T}"
+ python_wrapper_setup
return
fi
fi
@@ -231,7 +231,7 @@
break
elif _python_EPYTHON_supported "${i}"; then
python_export "${i}" EPYTHON PYTHON
- python_wrapper_setup "${T}"
+ python_wrapper_setup
return
fi
done
@@ -247,7 +247,7 @@
for i in "${rev_impls[@]}"; do
python_export "${i}" EPYTHON PYTHON
if _python_EPYTHON_supported "${EPYTHON}"; then
- python_wrapper_setup "${T}"
+ python_wrapper_setup
return
fi
done
1.54 eclass/python-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-r1.eclass?rev=1.54&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-r1.eclass?rev=1.54&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-r1.eclass?r1=1.53&r2=1.54
Index: python-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-r1.eclass,v
retrieving revision 1.53
retrieving revision 1.54
diff -u -r1.53 -r1.54
--- python-r1.eclass 7 Apr 2013 17:02:52 -0000 1.53
+++ python-r1.eclass 10 May 2013 22:03:30 -0000 1.54
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-r1.eclass,v 1.53 2013/04/07 17:02:52 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-r1.eclass,v 1.54 2013/05/10 22:03:30 mgorny Exp $
# @ECLASS: python-r1
# @MAINTAINER:
@@ -639,7 +639,7 @@
local -x EPYTHON PYTHON
local -x PATH=${PATH} PKG_CONFIG_PATH=${PKG_CONFIG_PATH}
python_export "${MULTIBUILD_VARIANT}" EPYTHON PYTHON
- python_wrapper_setup "${T}/${EPYTHON}"
+ python_wrapper_setup
"${@}"
}
@@ -712,7 +712,7 @@
debug-print "${FUNCNAME}: Best implementation is: ${best}"
python_export "${best}" "${@}"
- python_wrapper_setup "${T}"
+ python_wrapper_setup
}
# @FUNCTION: python_replicate_script
1.17 eclass/python-single-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-single-r1.eclass?rev=1.17&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-single-r1.eclass?rev=1.17&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-single-r1.eclass?r1=1.16&r2=1.17
Index: python-single-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-single-r1.eclass,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -r1.16 -r1.17
--- python-single-r1.eclass 7 Apr 2013 17:02:52 -0000 1.16
+++ python-single-r1.eclass 10 May 2013 22:03:30 -0000 1.17
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-single-r1.eclass,v 1.16 2013/04/07 17:02:52 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-single-r1.eclass,v 1.17 2013/05/10 22:03:30 mgorny Exp $
# @ECLASS: python-single-r1
# @MAINTAINER:
@@ -207,7 +207,7 @@
fi
python_export "${impl}" EPYTHON PYTHON
- python_wrapper_setup "${T}"
+ python_wrapper_setup
fi
done
1.24 eclass/python-utils-r1.eclass
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?rev=1.24&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?rev=1.24&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?r1=1.23&r2=1.24
Index: python-utils-r1.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -r1.23 -r1.24
--- python-utils-r1.eclass 30 Apr 2013 05:36:19 -0000 1.23
+++ python-utils-r1.eclass 10 May 2013 22:03:30 -0000 1.24
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v 1.23 2013/04/30 05:36:19 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v 1.24 2013/05/10 22:03:30 mgorny Exp $
# @ECLASS: python-utils-r1
# @MAINTAINER:
@@ -820,11 +820,11 @@
}
# @FUNCTION: python_wrapper_setup
-# @USAGE: <path> [<impl>]
+# @USAGE: [<path> [<impl>]]
# @DESCRIPTION:
# Create proper 'python' executable and pkg-config wrappers
# (if available) in the directory named by <path>. Set up PATH
-# and PKG_CONFIG_PATH appropriately.
+# and PKG_CONFIG_PATH appropriately. <path> defaults to ${T}/${EPYTHON}.
#
# The wrappers will be created for implementation named by <impl>,
# or for one named by ${EPYTHON} if no <impl> passed.
@@ -836,7 +836,7 @@
python_wrapper_setup() {
debug-print-function ${FUNCNAME} "${@}"
- local workdir=${1}
+ local workdir=${1:-${T}/${EPYTHON}}
local impl=${2:-${EPYTHON}}
[[ ${workdir} ]] || die "${FUNCNAME}: no workdir specified."
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-05-10 22:03 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-05-10 22:03 [gentoo-commits] gentoo-x86 commit in eclass: ChangeLog python-any-r1.eclass python-r1.eclass python-single-r1.eclass python-utils-r1.eclass Michal Gorny (mgorny)
-- strict thread matches above, loose matches on Subject: below --
2013-04-07 17:02 Michal Gorny (mgorny)
2013-01-21 19:28 Michal Gorny (mgorny)
2012-12-20 23:35 Michal Gorny (mgorny)
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox