Skip to content

Commit e230589

Browse files
committed
python-utils-r1.eclass: Mark python_export private
Signed-off-by: Michał Górny <[email protected]>
1 parent a2c4b91 commit e230589

File tree

6 files changed

+44
-142
lines changed

6 files changed

+44
-142
lines changed

eclass/python-any-r1.eclass

+6-6
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ _python_any_set_globals() {
151151
_python_set_impls
152152

153153
for i in "${_PYTHON_SUPPORTED_IMPLS[@]}"; do
154-
python_export "${i}" PYTHON_PKG_DEP
154+
_python_export "${i}" PYTHON_PKG_DEP
155155

156156
# note: need to strip '=' slot operator for || deps
157157
deps="${PYTHON_PKG_DEP/:0=/:0} ${deps}"
@@ -232,7 +232,7 @@ python_gen_any_dep() {
232232
local i PYTHON_PKG_DEP out=
233233
for i in "${_PYTHON_SUPPORTED_IMPLS[@]}"; do
234234
local PYTHON_USEDEP="python_targets_${i}(-),python_single_target_${i}(+)"
235-
python_export "${i}" PYTHON_PKG_DEP
235+
_python_export "${i}" PYTHON_PKG_DEP
236236

237237
local i_depstr=${depstr//\$\{PYTHON_USEDEP\}/${PYTHON_USEDEP}}
238238
# note: need to strip '=' slot operator for || deps
@@ -299,7 +299,7 @@ python_setup() {
299299
ewarn
300300
ewarn "Dependencies won't be satisfied, and EPYTHON/eselect-python will be ignored."
301301

302-
python_export "${impls[0]}" EPYTHON PYTHON
302+
_python_export "${impls[0]}" EPYTHON PYTHON
303303
_python_wrapper_setup
304304
einfo "Using ${EPYTHON} to build"
305305
return
@@ -308,7 +308,7 @@ python_setup() {
308308
# first, try ${EPYTHON}... maybe it's good enough for us.
309309
if [[ ${EPYTHON} ]]; then
310310
if _python_EPYTHON_supported "${EPYTHON}"; then
311-
python_export EPYTHON PYTHON
311+
_python_export EPYTHON PYTHON
312312
_python_wrapper_setup
313313
einfo "Using ${EPYTHON} to build"
314314
return
@@ -324,7 +324,7 @@ python_setup() {
324324
# no eselect-python?
325325
break
326326
elif _python_EPYTHON_supported "${i}"; then
327-
python_export "${i}" EPYTHON PYTHON
327+
_python_export "${i}" EPYTHON PYTHON
328328
_python_wrapper_setup
329329
einfo "Using ${EPYTHON} to build"
330330
return
@@ -334,7 +334,7 @@ python_setup() {
334334
# fallback to best installed impl.
335335
# (reverse iteration over _PYTHON_SUPPORTED_IMPLS)
336336
for (( i = ${#_PYTHON_SUPPORTED_IMPLS[@]} - 1; i >= 0; i-- )); do
337-
python_export "${_PYTHON_SUPPORTED_IMPLS[i]}" EPYTHON PYTHON
337+
_python_export "${_PYTHON_SUPPORTED_IMPLS[i]}" EPYTHON PYTHON
338338
if _python_EPYTHON_supported "${EPYTHON}"; then
339339
_python_wrapper_setup
340340
einfo "Using ${EPYTHON} to build"

eclass/python-r1.eclass

+6-6
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ _python_set_globals() {
173173
_python_set_impls
174174

175175
for i in "${_PYTHON_SUPPORTED_IMPLS[@]}"; do
176-
python_export "${i}" PYTHON_PKG_DEP
176+
_python_export "${i}" PYTHON_PKG_DEP
177177
deps+="python_targets_${i}? ( ${PYTHON_PKG_DEP} ) "
178178
done
179179

@@ -485,7 +485,7 @@ python_gen_impl_dep() {
485485
for impl in "${_PYTHON_SUPPORTED_IMPLS[@]}"; do
486486
if _python_impl_matches "${impl}" "${@}"; then
487487
local PYTHON_PKG_DEP
488-
python_export "${impl}" PYTHON_PKG_DEP
488+
_python_export "${impl}" PYTHON_PKG_DEP
489489
matches+=( "python_targets_${impl}? ( ${PYTHON_PKG_DEP} )" )
490490
fi
491491
done
@@ -563,7 +563,7 @@ python_gen_any_dep() {
563563
for i in "${_PYTHON_SUPPORTED_IMPLS[@]}"; do
564564
if _python_impl_matches "${i}" "${@}"; then
565565
local PYTHON_USEDEP="python_targets_${i}(-),python_single_target_${i}(+)"
566-
python_export "${i}" PYTHON_PKG_DEP
566+
_python_export "${i}" PYTHON_PKG_DEP
567567

568568
local i_depstr=${depstr//\$\{PYTHON_USEDEP\}/${PYTHON_USEDEP}}
569569
# note: need to strip '=' slot operator for || deps
@@ -637,7 +637,7 @@ _python_multibuild_wrapper() {
637637

638638
local -x EPYTHON PYTHON
639639
local -x PATH=${PATH} PKG_CONFIG_PATH=${PKG_CONFIG_PATH}
640-
python_export "${MULTIBUILD_VARIANT}" EPYTHON PYTHON
640+
_python_export "${MULTIBUILD_VARIANT}" EPYTHON PYTHON
641641
_python_wrapper_setup
642642

643643
"${@}"
@@ -760,7 +760,7 @@ python_setup() {
760760
# check patterns
761761
_python_impl_matches "${impl}" "${@}" || continue
762762

763-
python_export "${impl}" EPYTHON PYTHON
763+
_python_export "${impl}" EPYTHON PYTHON
764764

765765
# if python_check_deps() is declared, switch into any-of mode
766766
if [[ ${has_check_deps} ]]; then
@@ -803,7 +803,7 @@ python_replicate_script() {
803803
local _PYTHON_FIX_SHEBANG_QUIET=1
804804

805805
local PYTHON_SCRIPTDIR
806-
python_export PYTHON_SCRIPTDIR
806+
_python_export PYTHON_SCRIPTDIR
807807

808808
(
809809
exeopts -m 0755

eclass/python-single-r1.eclass

+4-4
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ _python_single_set_globals() {
213213

214214
local deps= i PYTHON_PKG_DEP
215215
for i in "${_PYTHON_SUPPORTED_IMPLS[@]}"; do
216-
python_export "${i}" PYTHON_PKG_DEP
216+
_python_export "${i}" PYTHON_PKG_DEP
217217
# 1) well, python-exec would suffice as an RDEP
218218
# but no point in making this overcomplex, BDEP doesn't hurt anyone
219219
# 2) python-exec should be built with all targets forced anyway
@@ -436,7 +436,7 @@ python_gen_impl_dep() {
436436
for impl in "${_PYTHON_SUPPORTED_IMPLS[@]}"; do
437437
if _python_impl_matches "${impl}" "${@}"; then
438438
local PYTHON_PKG_DEP
439-
python_export "${impl}" PYTHON_PKG_DEP
439+
_python_export "${impl}" PYTHON_PKG_DEP
440440
matches+=( "python_single_target_${impl}? ( ${PYTHON_PKG_DEP} )" )
441441
fi
442442
done
@@ -465,7 +465,7 @@ python_setup() {
465465
ewarn
466466
ewarn "Dependencies won't be satisfied, and PYTHON_SINGLE_TARGET flags will be ignored."
467467

468-
python_export "${impls[0]}" EPYTHON PYTHON
468+
_python_export "${impls[0]}" EPYTHON PYTHON
469469
_python_wrapper_setup
470470
einfo "Using ${EPYTHON} to build"
471471
return
@@ -483,7 +483,7 @@ python_setup() {
483483
die "More than one implementation in PYTHON_SINGLE_TARGET."
484484
fi
485485

486-
python_export "${impl}" EPYTHON PYTHON
486+
_python_export "${impl}" EPYTHON PYTHON
487487
_python_wrapper_setup
488488
einfo "Using ${EPYTHON} to build"
489489
fi

0 commit comments

Comments
 (0)