1 |
On Tue, Nov 27, 2012 at 11:22 AM, Sergei Trofimovich <slyfox@g.o> wrote: |
2 |
> Before the patch I had to move subdir(not very reliable): |
3 |
> EGIT_REPO_URI="git://github.com/UU-ComputerScience/uhc.git" |
4 |
> src_prepare() { |
5 |
> mv EHC/* ./ || die |
6 |
> } |
7 |
> |
8 |
> After the patch i can define it the usual way: |
9 |
> EGIT_REPO_URI="git://github.com/UU-ComputerScience/uhc.git" |
10 |
> S="${WORKDIR}/${P}/EHC |
11 |
> |
12 |
> Original ebuild: https://github.com/gentoo-haskell/gentoo-haskell/blob/master/dev-lang/uhc/uhc-9999.ebuild#L27 |
13 |
> |
14 |
> Signed-off-by: Sergei Trofimovich <slyfox@g.o> |
15 |
> --- |
16 |
> git-2.eclass | 4 ++-- |
17 |
> 1 file changed, 2 insertions(+), 2 deletions(-) |
18 |
> |
19 |
> diff --git a/git-2.eclass b/git-2.eclass |
20 |
> index 1ecc633..1a96978 100644 |
21 |
> --- a/git-2.eclass |
22 |
> +++ b/git-2.eclass |
23 |
> @@ -21,7 +21,7 @@ DEPEND="dev-vcs/git" |
24 |
> # This variable specifies destination where the cloned |
25 |
> # data are copied to. |
26 |
> # |
27 |
> -# EGIT_SOURCEDIR="${S}" |
28 |
> +# EGIT_SOURCEDIR="${WORKDIR}/${P}" |
29 |
> |
30 |
> # @ECLASS-VARIABLE: EGIT_STORE_DIR |
31 |
> # @DESCRIPTION: |
32 |
> @@ -132,7 +132,7 @@ git-2_init_variables() { |
33 |
> local esc_pn liverepo livebranch livecommit |
34 |
> esc_pn=${PN//[-+]/_} |
35 |
> |
36 |
> - : ${EGIT_SOURCEDIR="${S}"} |
37 |
> + : ${EGIT_SOURCEDIR="${WORKDIR}/${P}"} |
38 |
> |
39 |
> : ${EGIT_STORE_DIR:="${PORTAGE_ACTUAL_DISTDIR-${DISTDIR}}/egit-src"} |
40 |
> |
41 |
> -- |
42 |
> 1.8.0 |
43 |
> |
44 |
> |
45 |
|
46 |
While in theory this makes sense, it also has the potential to break |
47 |
ebuilds setting S="${WORKDIR}/foo" and then expecting the sources to |
48 |
be inside "foo". IOW it's not backward compatible, is it? |
49 |
|
50 |
Thanks, |
51 |
|
52 |
Davide Pesavento (pesa) |