All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: Chris Trobridge <christrobridge@hotmail.com>,
	"yocto@yoctoproject.org" <yocto@yoctoproject.org>
Subject: Re: Sharing a source repository
Date: Tue, 12 Jan 2016 11:27:49 +0000	[thread overview]
Message-ID: <1452598069.28375.10.camel@linuxfoundation.org> (raw)
In-Reply-To: <DUB130-W826C28E67F7AA9DF278329DACA0@phx.gbl>

On Tue, 2016-01-12 at 09:36 +0000, Chris Trobridge wrote:
> I have a source (git) repository that can build a number of targets
> that could usefully be distributed across a number of recipes to be
> applied in different circumstances.  Is there a preferred method to
> allow multiple recipes to reference the same source without it being
> unpacked etc separately for each recipe (I've not seen evidence of
> any optimisation for this by default?)
> 
> To some extent this situation can be accommodated by producing
> multiple packages from one recipe.  This isn't great, or modular but
> might be mitigated a bit with includes etc.
> 
> I could move specific source to specific recipe folders and version
> control it with the meta data but that would place it outside the
> original repository and break the meta data separation.
> 
> The most promising choice so far is the "subpath" option to the git
> fetcher.  This would appear to let me pick out portions of the
> repository into different recipes that could then be rdepended upon
> (there is one 'project' within the repository that is several GB). 
>  (There are also git sub-projects but I'm not using that.)
> 
> Would using "subpath" be the preferred method for my case?
> 
> Or is there an idiomatic way to pull in a repository in one recipe
> and then reference that from other recipes?  I can think of something
> that would work but would probably be breaking the spirit (eg sym
> -linking the git directory somewhere commonly accessible to the other
> recipes).  This would also have the disadvantage of pulling the whole
> repository in even only small part was actually required.

You could look at what we do with gcc and the gcc-source recipe. Its
works there but its not common place and requires workarounds in some
corner cases like the sstate checksum debugging code.

Cheers,

Richard


  reply	other threads:[~2016-01-12 11:28 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-12  9:36 Sharing a source repository Chris Trobridge
2016-01-12 11:27 ` Richard Purdie [this message]
2016-01-12 13:04   ` Chris Trobridge

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1452598069.28375.10.camel@linuxfoundation.org \
    --to=richard.purdie@linuxfoundation.org \
    --cc=christrobridge@hotmail.com \
    --cc=yocto@yoctoproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.