Skip to content

Commit a2c4b91

Browse files
committed
python-utils-r1.eclass: Replace python_export with getters
Signed-off-by: Michał Górny <[email protected]>
1 parent 1718e9c commit a2c4b91

File tree

1 file changed

+6
-11
lines changed

1 file changed

+6
-11
lines changed

eclass/python-utils-r1.eclass

+6-11
Original file line numberDiff line numberDiff line change
@@ -774,9 +774,8 @@ python_newexe() {
774774
local f=${1}
775775
local newfn=${2}
776776

777-
local PYTHON_SCRIPTDIR d
778-
python_export PYTHON_SCRIPTDIR
779-
d=${PYTHON_SCRIPTDIR#${EPREFIX}}
777+
local scriptdir=$(python_get_scriptdir)
778+
local d=${scriptdir#${EPREFIX}}
780779

781780
(
782781
dodir "${wrapd}"
@@ -902,10 +901,8 @@ python_domodule() {
902901
d=${python_moduleroot}
903902
else
904903
# relative to site-packages
905-
local PYTHON_SITEDIR=${PYTHON_SITEDIR}
906-
[[ ${PYTHON_SITEDIR} ]] || python_export PYTHON_SITEDIR
907-
908-
d=${PYTHON_SITEDIR#${EPREFIX}}/${python_moduleroot//.//}
904+
local sitedir=$(python_get_sitedir)
905+
d=${sitedir#${EPREFIX}}/${python_moduleroot//.//}
909906
fi
910907

911908
(
@@ -935,10 +932,8 @@ python_doheader() {
935932

936933
[[ ${EPYTHON} ]] || die 'No Python implementation set (EPYTHON is null).'
937934

938-
local d PYTHON_INCLUDEDIR=${PYTHON_INCLUDEDIR}
939-
[[ ${PYTHON_INCLUDEDIR} ]] || python_export PYTHON_INCLUDEDIR
940-
941-
d=${PYTHON_INCLUDEDIR#${EPREFIX}}
935+
local includedir=$(python_get_includedir)
936+
local d=${includedir#${EPREFIX}}
942937

943938
(
944939
insopts -m 0644

0 commit comments

Comments
 (0)