From 9a4d59e54117522163d020b949b6c9e98a6ca8fd Mon Sep 17 00:00:00 2001 From: Bertrand Jacquin Date: Sun, 19 Mar 2006 15:56:21 +0100 Subject: e.eclass: fetch mirror tar in unpack and download them if server file is newer --- eclass/enlightenment.eclass | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'eclass') diff --git a/eclass/enlightenment.eclass b/eclass/enlightenment.eclass index 8c96d363..67c620cc 100644 --- a/eclass/enlightenment.eclass +++ b/eclass/enlightenment.eclass @@ -58,8 +58,7 @@ HOMEPAGE="http://www.enlightenment.org/" case ${EURI_STATE:-${ECVS_STATE}} in release) SRC_URI="http://enlightenment.freedesktop.org/files/${P}.tar.gz mirror://sourceforge/enlightenment/${P}.tar.gz";; snap) SRC_URI="mirror://gentoo/${P}.tar.bz2";; - mirror) SRC_URI="${ECVS_MIRROR}/${ECVS_MODULE}.tar.bz2" - RESTRICT="nomirror";; + mirror) SRC_URI="";; live) SRC_URI="";; esac @@ -116,7 +115,13 @@ gettext_modify() { } enlightenment_src_unpack() { - if [[ ${ECVS_STATE} == "live" ]] ; then + if [[ ${ECVS_STATE} == "mirror" ]] ; then + B="${PN}.tar.bz2" + cp -p /usr/portage/distfiles/${B} ${DISTDIR} 2> /dev/null + wget -t 5 --passive-ftp ${ECVS_MIRROR}/${ECVS_MODULE}.tar.bz2 --progress=bar:force -N -P ${DISTDIR} + cp -p ${DISTDIR}/${B} /usr/portage/distfiles 2> /dev/null + unpack ${B} + elif [[ ${ECVS_STATE} == "live" ]] ; then cvs_src_unpack else unpack ${A} -- cgit v1.2.3