From: "François-Xavier Carton" <fx.carton@yahoo.fr>
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] Building packages in different prefix without rebuilding system packages
Date: Thu, 14 May 2020 10:37:12 +0200 [thread overview]
Message-ID: <20200514083712.GA20188@pc-fx> (raw)
In-Reply-To: <3049712.aeNJFYEL58@lenovo.localdomain>
On Thu, May 14, 2020 at 09:07:43AM +0100, Michael wrote:
> On Thursday, 14 May 2020 06:13:33 BST Dale wrote:
> > François-Xavier Carton wrote:
> > > Hi,
> > >
> > > Is there a way of installing packages in a different prefix while still
> > > using system packages? I've tried setting EPREFIX, however doing that
> > > will install all dependencies in the prefix, even if there are already
> > > installed in the system.
> > >
> > > I was hoping to install some packages in user directories, but I also
> > > don't want to duplicate the packages installed globally. For example,
> > > most packages eventually depend on gcc, which I definitely don't want to
> > > compile twice. So ideally, only dependencies that are not installed
> > > globally should be pulled in.
> > >
> > > I was not able to find a way of doing that, but I feel like it shouldn't
> > > be too hard, because EPREFIX almost does what I want. Does someone know
> > > if it's possible without too much tweaking?
> > >
> > > Thanks,
> > > -François-Xavier
> >
> > I'm clueless on EPREFIX but if you want to avoid compiling a package
> > twice, would the -k option help? If you have portage set to save the
> > binaries you compiled before, it would install from that instead of
> > compiling things twice.
> >
> > Just thought I'd mention just in case it would help.
> >
> > Dale
> >
> > :-) :-)
>
> The whole concept of EPREFIX is predicated on installing a Gentoo system
> within a different path/filesystem than the / of the host installation and
> being able to run it as a non-root user. As I understand it, using libraries
> from the main system and potentially altering them in the process is not going
> to work without changing Gentoo's eprefix intended design.
>
> It should be possible to change the prefix paths selectively, in particular
> the LD_LIBRARY_PATH to link binaries from within the prefix to libraries in
> the host system, but I'm not sure what privileges are needed to install/run
> such a hybrid linkage and how an update of the host system will break
> installed packages within the EPREFIX and vice versa. We're talking of a
> Frankenstein build here with the potential of install operations on one system
> would be breaking the other, including portage itself.
>
> With containerisation of applications there may be easier ways to achieve what
> François-Xavier is looking for. I am thinking of running sandboxed
> applications in the likes of flatpack, snap, zero-install, appimage and
> whatever else may have been devised lately. However, with these systems you
> end up using what's already been developed and any static libraries their devs
> considered desirable. If you want a bespoke installation optimised for your
> hardware and chosen compilation flags, then you are probably looking to
> develop a containerised application for your own use.
>
> Someone more knowledgeable in both Gentoo's EPREFIX project and containerised
> apps should chime in soon to offer more helpful advice.
I wouldn't try to install different versions of the same package, just
add new packages to the base system. But I can see your point about
updates; since the base system is not aware of the prefixed one, it
cannot rebuild the packages in the prefix automatically when needed.
It's indeed more complex than what I hoped :(
next prev parent reply other threads:[~2020-05-14 8:37 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20200514050205.GA15477.ref@pc-fx>
2020-05-14 5:02 ` [gentoo-user] Building packages in different prefix without rebuilding system packages François-Xavier Carton
2020-05-14 5:13 ` Dale
2020-05-14 8:07 ` Michael
2020-05-14 8:37 ` François-Xavier Carton [this message]
2020-05-14 8:46 ` Pengcheng Xu
2020-05-14 10:07 ` Neil Bothwick
2020-05-14 10:17 ` Pengcheng Xu
2020-05-14 11:55 ` Neil Bothwick
2020-05-14 13:09 ` Pengcheng Xu
2020-05-14 13:26 ` Michael Orlitzky
2020-05-14 22:32 ` François-Xavier Carton
2020-05-15 10:53 ` [gentoo-user] " Michael Haubenwallner
2020-05-15 21:44 ` François-Xavier Carton
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=20200514083712.GA20188@pc-fx \
--to=fx.carton@yahoo.fr \
--cc=gentoo-user@lists.gentoo.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox