On Tue, Nov 27, 2012 at 11:22 AM, Sergei Trofimovich <sly...@gentoo.org> wrote:
> Before the patch I had to move subdir(not very reliable):
>     EGIT_REPO_URI="git://github.com/UU-ComputerScience/uhc.git"
>     src_prepare() {
>         mv EHC/* ./ || die
>     }
>
> After the patch i can define it the usual way:
>     EGIT_REPO_URI="git://github.com/UU-ComputerScience/uhc.git"
>     S="${WORKDIR}/${P}/EHC
>
> Original ebuild: 
> https://github.com/gentoo-haskell/gentoo-haskell/blob/master/dev-lang/uhc/uhc-9999.ebuild#L27
>
> Signed-off-by: Sergei Trofimovich <sly...@gentoo.org>
> ---
>  git-2.eclass | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/git-2.eclass b/git-2.eclass
> index 1ecc633..1a96978 100644
> --- a/git-2.eclass
> +++ b/git-2.eclass
> @@ -21,7 +21,7 @@ DEPEND="dev-vcs/git"
>  # This variable specifies destination where the cloned
>  # data are copied to.
>  #
> -# EGIT_SOURCEDIR="${S}"
> +# EGIT_SOURCEDIR="${WORKDIR}/${P}"
>
>  # @ECLASS-VARIABLE: EGIT_STORE_DIR
>  # @DESCRIPTION:
> @@ -132,7 +132,7 @@ git-2_init_variables() {
>         local esc_pn liverepo livebranch livecommit
>         esc_pn=${PN//[-+]/_}
>
> -       : ${EGIT_SOURCEDIR="${S}"}
> +       : ${EGIT_SOURCEDIR="${WORKDIR}/${P}"}
>
>         : ${EGIT_STORE_DIR:="${PORTAGE_ACTUAL_DISTDIR-${DISTDIR}}/egit-src"}
>
> --
> 1.8.0
>
>

While in theory this makes sense, it also has the potential to break
ebuilds setting S="${WORKDIR}/foo" and then expecting the sources to
be inside "foo". IOW it's not backward compatible, is it?

Thanks,

Davide Pesavento (pesa)

Reply via email to