--- perl-module.eclass.old 2010-04-22 08:06:00.000000000 -0400 +++ perl-module.eclass 2010-04-28 09:10:11.380834922 -0400 @@ -12,7 +12,7 @@ # The perl-module eclass is designed to allow easier installation of perl # modules, and their incorporation into the Gentoo Linux system. -inherit eutils base +inherit eutils base multilib toolchain-funcs [[ ${CATEGORY} == "perl-core" ]] && inherit alternatives PERL_EXPF="src_unpack src_compile src_test src_install" @@ -255,6 +255,16 @@ ${perlinfo_done} && return 0 perlinfo_done=true + if tc-is-cross-compiler ; then + # Once these 3 variables are set, + # modules use them for makefile vars, + # perlinfo gets info from $PERL_ARCHLIB + # build, and all is well... + export PERL_LIB="${ROOT}usr/$(get_libdir)/$(perl -V:privlib | cut -d \' -f 2 | cut -d / -f 4-)" + export PERL_ARCHLIB="$(ls -d ${PERL_LIB}/${CHOST%%-*}*)" + export PERL_INC="${PERL_ARCHLIB}/CORE" + fi + local f version install{{site,vendor}{arch,lib},archlib} eval "$(perl -V:{version,install{{site,vendor}{arch,lib},archlib}} )" PERL_VERSION=${version}