Gentoo Archives: gentoo-portage-dev

From: Zac Medico <zmedico@g.o>
To: gentoo-portage-dev@l.g.o
Subject: Re: [gentoo-portage-dev] running ebuild in src tree
Date: Wed, 11 Mar 2015 19:19:45
Message-Id: 5500954C.3010308@gentoo.org
In Reply to: Re: [gentoo-portage-dev] running ebuild in src tree by Joakim Tjernlund
1 On 03/11/2015 12:08 PM, Joakim Tjernlund wrote:
2 > On Wed, 2015-03-11 at 12:03 -0700, Zac Medico wrote:
3 >> On 03/11/2015 11:56 AM, Joakim Tjernlund wrote:
4 >>> On Wed, 2015-03-11 at 11:34 -0700, Zac Medico wrote:
5 >>>> On 03/11/2015 09:03 AM, Joakim Tjernlund wrote:
6 >>>>> When developing code it would be really nice if one could run your ebuild
7 >>>>> on that src tree as is(no fetch, unpack etc.)
8 >>>>
9 >>>> The existing convention is to create an ebuild with version 9999 and use one of the live vcs eclasses
10 >>>> such
11 >>>> as git-r3 to pull the live sources in the src_unpack function. In a future EAPI, we plan to add some
12 >>>> features related to this [1].
13 >>>
14 >>> I think you misunderstand, [1] is not what I want to do(I think):
15 >>>
16 >>> Got my src working copy and made a few modds, not commitet yet. Now I just want build/test etc. before
17 >>> committing and to do that I just run mytree/overlay/dev-util/myapp/myapp.ebuild compile and voila, my
18 >>> code is
19 >>> built which I already have in mytree.
20 >>
21 >> Well, you can create a -9999 ebuild that copies your sources from $directory to $WORKDIR. Maybe use an
22 >> environment to configure whether it pulls from a local directory or a vcs repository.
23 >
24 > No copy, just use the current sources. I realize this is not supported ATM but I think
25 > it would be a very useful extension. It could just be an extra option or two to ebuild
26
27 You can already write the code to do this in the ebuild. Maybe have it
28 create a symlink to your source directory. You can use environment
29 variables, so there's no need to special options for this. It's really
30 none of portage's business where your source code comes from.
31 --
32 Thanks,
33 Zac