Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[workaround] how to move portage-related stuff?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
avx
Advocate
Advocate


Joined: 21 Jun 2004
Posts: 2152

PostPosted: Mon Aug 03, 2009 9:00 am    Post subject: [workaround] how to move portage-related stuff? Reply with quote

Despite being somewhat chaotic in real life, I like my pc-stuff as organised as possible, mainly to be easily maintainable. So for me, the next step is bringing up a usefull (in my eyes) system for portage and the stuff related.

Currently, I've got a setup like this:
Code:

/portage
/portage/binpkg
/portage/distfiles
/portage/overlay
/portage/tmp
/portage/tree


I'd also like to have /etc/portage in /portage, BUT at best not via symlinks. Same goes for /var/cache/edb /var/lib/portage, etc. So, the question is, have I overread some variables I can define and if not, would this be acceptable to include in portage's features or am I supposed to hack portage's src or live with symlinks?


Last edited by avx on Mon Aug 03, 2009 5:15 pm; edited 1 time in total
Back to top
View user's profile Send private message
Veldrin
Veteran
Veteran


Joined: 27 Jul 2004
Posts: 1945
Location: Zurich, Switzerland

PostPosted: Mon Aug 03, 2009 11:46 am    Post subject: Reply with quote

You can always use mount -o bind... I personally don't use it in the portage case, but I've heard from other gentoo users to do it exactly like this.

e.g.
Code:
# mount /portage/distfiles /usr/portage/disrfiles -o bind


The Syntex is the same, as with mount i.e mount <device> <mount-point>.

cheers
V.

PS. ask, if I should elaborate more.
Back to top
View user's profile Send private message
d2_racing
Bodhisattva
Bodhisattva


Joined: 25 Apr 2005
Posts: 13047
Location: Ste-Foy,Canada

PostPosted: Mon Aug 03, 2009 12:08 pm    Post subject: Reply with quote

In fact, I saw that one a couple of times actually.
Back to top
View user's profile Send private message
Mike Hunt
Watchman
Watchman


Joined: 19 Jul 2009
Posts: 5287

PostPosted: Mon Aug 03, 2009 12:47 pm    Post subject: Reply with quote

But, just be careful that you don't hose your box next time you sync. Emerge --sync will completely overwrite your PORTDIR. :P
Back to top
View user's profile Send private message
avx
Advocate
Advocate


Joined: 21 Jun 2004
Posts: 2152

PostPosted: Mon Aug 03, 2009 4:21 pm    Post subject: Reply with quote

@Veldrin, interesting idea, haven't thought of that, yet. Thanks. The "problem" I see with this would be, that `mount` could/would get somewhat messy and confusing.
@Mike Hunt, want do you mean? All ebuilds, etc are stored in /portage/tree/.


Last edited by avx on Mon Aug 03, 2009 5:12 pm; edited 1 time in total
Back to top
View user's profile Send private message
Mike Hunt
Watchman
Watchman


Joined: 19 Jul 2009
Posts: 5287

PostPosted: Mon Aug 03, 2009 4:55 pm    Post subject: Reply with quote

ph030 wrote:
@Mike Hunt, want do you mean? All ebuilds, etc are storen in /portage/tree/.


Perhaps I misunderstood what you want to do. I thought you want to move all the portage related stuff into the root of your PORTDIR. my mistake. :)
Back to top
View user's profile Send private message
avx
Advocate
Advocate


Joined: 21 Jun 2004
Posts: 2152

PostPosted: Mon Aug 03, 2009 5:14 pm    Post subject: Reply with quote

No problem :)

Tested the `mount --bind`, technically works, but as told, `mount` is of course cluttered, so is /etc - guess I have to live with it. Marking as [workaround].
Back to top
View user's profile Send private message
dreadlorde
Apprentice
Apprentice


Joined: 16 Dec 2008
Posts: 243
Location: /adm/timezone/US_Michigan

PostPosted: Mon Aug 03, 2009 11:27 pm    Post subject: Reply with quote

Have you looked at aufs2?
_________________
Ludwig von Mises Institute
Quote:
I am not to be a shepherd, I am not to be a grave-digger. No longer will I speak to the people; for the last time I have spoken to the dead.
Back to top
View user's profile Send private message
avx
Advocate
Advocate


Joined: 21 Jun 2004
Posts: 2152

PostPosted: Tue Aug 04, 2009 9:24 am    Post subject: Reply with quote

Does this build against 2.6.30.x now? Besides, where exactly do you see a benefit for using it in this case?
Back to top
View user's profile Send private message
yngwin
Retired Dev
Retired Dev


Joined: 19 Dec 2002
Posts: 4572
Location: Suzhou, China

PostPosted: Tue Aug 04, 2009 2:01 pm    Post subject: Reply with quote

There are some variables you can define. See man make.conf.
_________________
"Those who deny freedom to others deserve it not for themselves." - Abraham Lincoln
Free Culture | Defective by Design | EFF
Back to top
View user's profile Send private message
avx
Advocate
Advocate


Joined: 21 Jun 2004
Posts: 2152

PostPosted: Tue Aug 04, 2009 2:54 pm    Post subject: Reply with quote

Yep, but not for /etc/portage which currently is my main concern.
Back to top
View user's profile Send private message
i92guboj
Bodhisattva
Bodhisattva


Joined: 30 Nov 2004
Posts: 10315
Location: Córdoba (Spain)

PostPosted: Tue Aug 04, 2009 5:19 pm    Post subject: Reply with quote

I don't think you can change that without hacking into portage itself. These paths are the first thing you see on the emerge man page, and they appear as something that's hardcoded. However, what's the point? Don't misunderstand me, I am not going to fight over who's right here, I just feel curious, I will not argue just want to hear the reasoning behind it and after that I will not answer back (I don't want to spoil the thread more than necessary).

Following the same logic, nothing under /etc would make sense, we could also move the apache configs to /apache, and so on... /etc is for config files, that's why there's /etc/portage: config files for portage.
Back to top
View user's profile Send private message
avx
Advocate
Advocate


Joined: 21 Jun 2004
Posts: 2152

PostPosted: Tue Aug 04, 2009 6:01 pm    Post subject: Reply with quote

Quote:
However, what's the point?


1. it's all about choice[tm]
2. easier to deploy on a set of similar setups, i.e. no symlink+nfs-hell
3. all gentoo-relevant (or the most) gentoo-stuff in one single location, i.e. easy to turn $distro->gentoo/funtoo/...
4. no problems with i.e. backups caused by some files being on another partition
5. nearly everything else related to portage can be placed where you want it to be
6. easy to keep multiple portage's around

I'm sure there are even more things one can think of.

Edit
Quote:
following the same logic, nothing under /etc would make sense
Well, there's some weird stuff in there, i.e. asound.state. Besides, imho /etc is a bad name anyway, something like /set(tings) would be more logical, imho, but that's another topic.
Quote:
/etc is for config files
Well, if that's the case, why not do it right and have something like /etc/sys, /etc/root, /etc/$user? /etc/skel is imho not the right thing. XDG came up with ~/.config, ~/.cache, etc, but how many apps are using this? Not even GNOME/KDE make use of it, that's why we have at least dozens of files cluttering our ~/.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum