Gentoo Archives: gentoo-portage-dev

From: Zac Medico <zmedico@g.o>
To: gentoo-portage-dev@l.g.o
Subject: Re: [gentoo-portage-dev] repos.conf location w.r.t PORTAGE_CONFIGROOT
Date: Wed, 06 May 2015 22:16:43
Message-Id: 554A92C4.3000809@gentoo.org
In Reply to: Re: [gentoo-portage-dev] repos.conf location w.r.t PORTAGE_CONFIGROOT by Joakim Tjernlund
1 On 05/06/15 14:57, Joakim Tjernlund wrote:
2 > On Wed, 2015-05-06 at 14:36 -0700, Zac Medico wrote:
3 >> On 05/06/15 14:30, Joakim Tjernlund wrote:
4 >>> On Wed, 2015-05-06 at 13:30 -0700, Zac Medico wrote:
5 >>>> On 05/06/15 13:22, Joakim Tjernlund wrote:
6 >>>>> On Wed, 2015-05-06 at 12:54 -0700, Zac Medico wrote:
7 >>>>>> On 05/06/15 12:41, Joakim Tjernlund wrote:
8 >>>>>>> On Wed, 2015-05-06 at 19:13 +0000, Joakim Tjernlund wrote:
9 >>>>>>>> On Wed, 2015-05-06 at 11:37 -0700, Zac Medico wrote:
10 >>>>>>>>> On 05/06/15 09:54, Joakim Tjernlund wrote:
11 >>>>>>>>>> I am trying to rebuild an old cross sysroot and I got problems.
12 >>>>>>>>>> I cannot make emerge to select my old ebuilds in an overlay over those
13 >>>>>>>>>> in /usr/portage.
14 >>>>>>>>>>
15 >>>>>>>>>> What new is since last time I did this is /etc/portage/repos.conf/
16 >>>>>>>>>> I suspect emerge always reads /etc/portage/repos.conf/ no matter
17 >>>>>>>>>> what I set PORTAGE_CONFIGROOT / ROOT to ?
18 >>>>>>>>>>
19 >>>>>>>>>> Jocke
20 >>>>>>>>>>
21 >>>>>>>>>
22 >>>>>>>>> It instantiates 2 config instances, one using /etc/portage/repos.conf
23 >>>>>>>>> (for build time DEPEND) and another one using
24 >>>>>>>>> $PORTAGE_CONFIGROOT/etc/portage/repos.conf (for run time {P,R}DEPEND).
25 >>>>>>>>> You can see that it's joined with PORTAGE_CONFIGROOT in the
26 >>>>>>>>> load_repository_config function:
27 >>>>>>>>>
28 >>>>>>>>> https://gitweb.gentoo.org/proj/portage.git/tree/pym/portage/repository/config.py?id=0f191113cc
29 >>>>>>>>> cd04
30 >>>>>>>>> 9e11
31 >>>>>>>>> fdbe
32 >>>>>>>>> 73
33 >>>>>>>>> 493eb1efbf4bf89e#n971
34 >>>>>>>>
35 >>>>>>>> I see, doesn't this prevent exactly what I want to do?
36 >>>>>>>>
37 >>>>>>>> I can't see why this should be needed, it only creates a mess, another example:
38 >>>>>>>> I tried to specify exact version of my old binutils and while that worked, portage wanted
39 >>>>>>>> to pull in a newer binutils-config from the hosts master gentoo repo and
40 >>>>>>>> thus the build failed.
41 >>>>>>>>
42 >>>>>>>> If a someone really wants this behaviour, he can just add the hosts master repo
43 >>>>>>>> in his PORTAGE_CONFIGROOT IMHO
44 >>>>>>>>
45 >>>>>>
46 >>>>>> Maybe emerge --root-deps=rdeps is what you are looking for. This will
47 >>>>>> cause it to ignore DEPEND.
48 >>>>>
49 >>>>> That is not the same is it? if I "emerge ncurses" it will build ncurses but still
50 >>>>> take the ebuild from the hosts master since it is newer version.
51 >>>>>
52 >>>>> I realize now that I can change what repos are searched by using
53 >>>>> PORTAGE_REPOSITORIES=/my/own/repos.conf/
54 >>>>> but I still find the default behaviour very confusing and I don't see that it is useful.
55 >>>>
56 >>>> The idea is that you have separate repositories configured for each
57 >>>> ROOT. If it's satisfying a build-time DEPEND that will be installed into
58 >>>> ROOT=/, then it's supposed to use the repositories configured for ROOT=/.
59 >>>
60 >>> I see, but in my case I only install into my sysroot so I don't want this behaviour.
61 >>
62 >> So, why don't you use the --root-deps option?
63 >
64 > Just did(and --root-deps=rdeps too) and it didn't work, still wants to use
65 > my newer hosts pkgs. :(
66
67 It shouldn't do that. It sounds like maybe the [gentoo] config
68 from/usr/share/portage/config/repos.conf is the source of your problems,
69 since you $PORTAGE_CONFIGROOT config will always inherit that. Would
70 that be consistent with your observations?
71 --
72 Thanks,
73 Zac

Replies

Subject Author
Re: [gentoo-portage-dev] repos.conf location w.r.t PORTAGE_CONFIGROOT Joakim Tjernlund <joakim.tjernlund@×××××××××.se>
Re: [gentoo-portage-dev] repos.conf location w.r.t PORTAGE_CONFIGROOT Joakim Tjernlund <joakim.tjernlund@×××××××××.se>