Re: [gentoo-user] Can I (partially) rebuild a package with emerge?

2009-12-17 Thread Alan Mackenzie
Hi, Neil,

On Wed, Dec 16, 2009 at 10:05:40PM +, Neil Bothwick wrote:
 On Wed, 16 Dec 2009 20:44:29 +, Alan Mackenzie wrote:

  I've just emerged xorg-x11, and noticed that I had a wrong setting
  for VIDEO_CARDS in /etc/make.conf.  Does emerge have a facility to
  rebuild only those portions of xorg-x11 dependent on that setting,
  or do I have to start again from scratch?  I've perused the emerge
  man page, but not found this situation addressed.

 VIDEO_CARDS sets USE flags, so emerge -uavDN world.

I've done that, but it failed to rebuild my xorg-x11.  I've still got
the version from last night, even though I've changed USE flags (via
setting VIDEO_CARDS) in /etc/make.conf.

/etc/make.conf has a later timestamp than /usr/bin/Xorg, yet this
doesn't trigger the -N flag.  I'm misunderstanding something significant
here.  The emerge man page is not explicit in how it determines new
USE flags.

If I wanted just to remove Xorg, together with the 188 other packages
installed with it, would it be correct to run these commands:

emerge --unmerge xorg-x11
emerge --depclean

?

TVM!

 -- 
 Neil Bothwick

-- 
Alan Mackenzie (Nuremberg, Germany).



Re: [gentoo-user] Can I (partially) rebuild a package with emerge?

2009-12-17 Thread Jesús Guerrero
On Thu, 17 Dec 2009 15:14:48 +, Alan Mackenzie a...@muc.de wrote:
 Hi, Neil,
 
 On Wed, Dec 16, 2009 at 10:05:40PM +, Neil Bothwick wrote:
 On Wed, 16 Dec 2009 20:44:29 +, Alan Mackenzie wrote:
 
  I've just emerged xorg-x11, and noticed that I had a wrong setting
  for VIDEO_CARDS in /etc/make.conf.  Does emerge have a facility to
  rebuild only those portions of xorg-x11 dependent on that setting,
  or do I have to start again from scratch?  I've perused the emerge
  man page, but not found this situation addressed.
 
 VIDEO_CARDS sets USE flags, so emerge -uavDN world.
 
 I've done that, but it failed to rebuild my xorg-x11.  I've still got
 the version from last night, even though I've changed USE flags (via
 setting VIDEO_CARDS) in /etc/make.conf.

First, as I said in my other mail, the only relevant package that needs to
be rebuilt is xorg-server, nothing else. The drivers you add will be built
afresh as well as dependencies for xorg-server. 

Second, xorg-x11 is *nothing*. It's just a meta package that pulls
dependencies, it doesn't actually install a single file on your hard disk,
and it doesn't compile anything at all. So, re-emerging it will do nothing.

 /etc/make.conf has a later timestamp than /usr/bin/Xorg, yet this
 doesn't trigger the -N flag.

-N flag is not triggered based on time stamps. Each time a package is
merged, the USE flags you used the last time you merged it are stored under
/var/db/pkg. All -N does is to check if these flags that are stored match
the current ones, and if not, the offending package is re-emerged.

 If I wanted just to remove Xorg, together with the 188 other packages
 installed with it, would it be correct to run these commands:
 
 emerge --unmerge xorg-x11
 emerge --depclean

As long as you didn't emerge any single X package by hand, yes. But it
will do nothing to help you, it will not solve your problem. And it's not
related to your problem either. You'd just be wasting time.

-- 
Jesús Guerrero



Re: [gentoo-user] Can I (partially) rebuild a package with emerge?

2009-12-16 Thread Xavier Parizet
Le mercredi 16 décembre 2009 21:44:29, Alan Mackenzie a écrit :
 Hi, gentoo,
 
 I've just emerged xorg-x11, and noticed that I had a wrong setting for
 VIDEO_CARDS in /etc/make.conf.  Does emerge have a facility to rebuild
 only those portions of xorg-x11 dependent on that setting, or do I have
 to start again from scratch?  I've perused the emerge man page, but not
 found this situation addressed.
 
 Thanks for the help!
 

Actually it's not possible because when a package is merged with success, the 
build tree is deleted from /var/tmp/portage.
The only choice you have is to rebuild the whole package using emerge --
oneshot package. 
By the way, the rebuild will also pull the new dependencies implied by the new 
use flags settings.

HTH.

--
Xavier Parizet
YaGB: http://gentooist.com



Re: [gentoo-user] Can I (partially) rebuild a package with emerge?

2009-12-16 Thread Neil Bothwick
On Wed, 16 Dec 2009 20:44:29 +, Alan Mackenzie wrote:

 I've just emerged xorg-x11, and noticed that I had a wrong setting for
 VIDEO_CARDS in /etc/make.conf.  Does emerge have a facility to rebuild
 only those portions of xorg-x11 dependent on that setting, or do I have
 to start again from scratch?  I've perused the emerge man page, but not
 found this situation addressed.

VIDEO_CARDS sets USE flags, so emerge -uavDN world.


-- 
Neil Bothwick

Angular Momentum Makes The World Go 'Round


signature.asc
Description: PGP signature


Re: [gentoo-user] Can I (partially) rebuild a package with emerge?

2009-12-16 Thread Alan McKinnon
On Wednesday 16 December 2009 23:06:00 Xavier Parizet wrote:
 Le mercredi 16 décembre 2009 21:44:29, Alan Mackenzie a écrit :
  Hi, gentoo,
 
  I've just emerged xorg-x11, and noticed that I had a wrong setting for
  VIDEO_CARDS in /etc/make.conf.  Does emerge have a facility to rebuild
  only those portions of xorg-x11 dependent on that setting, or do I have
  to start again from scratch?  I've perused the emerge man page, but not
  found this situation addressed.
 
  Thanks for the help!
 
 Actually it's not possible because when a package is merged with success,
  the build tree is deleted from /var/tmp/portage.
 The only choice you have is to rebuild the whole package using emerge --
 oneshot package.
 By the way, the rebuild will also pull the new dependencies implied by the
  new use flags settings.


OT for the original question, but there is a way to lessen the amount of work 
done if a package may need to be merged (or attempted to be merged) 
repeatedly. You have to do it manually though:

- ensure all needed deps are already installed
- ebuild package command

where command is on of fetch, unpack, compile, install, etc as detailed in 
the ebuild man page. You can't restart a failed compile from where it left off 
[you can do that if you are running make manually, but ebuild abstracts that 
away] but at least some work can be omitted.

If course, this in no way answers the original question, but it's occasionally 
useful to know

-- 
alan dot mckinnon at gmail dot com



Re: [gentoo-user] Can I (partially) rebuild a package with emerge?

2009-12-16 Thread Jesús Guerrero
On Wed, 16 Dec 2009 20:44:29 +, Alan Mackenzie a...@muc.de wrote:
 Hi, gentoo,
 
 I've just emerged xorg-x11, and noticed that I had a wrong setting for
 VIDEO_CARDS in /etc/make.conf.  Does emerge have a facility to rebuild
 only those portions of xorg-x11 dependent on that setting, or do I have
 to start again from scratch?  I've perused the emerge man page, but not
 found this situation addressed.

What you failed to see if that VIDEO_CARDS flags are just an special type
of USE flags. Using -auDvN world will fix everything. Truly speaking,
xorg-server wouldn't even need to be recompiled (though that's what portage
will do). As far as I know, all these special USE flags for xorg-server
just push one of another xf86-video-* package(s) as dependencies, which in
turn install the required driver(s).

The rest of Xorg components do not relate to this, you shouldn't need to
recompile anything else unless it also depends on VIDEO_CARDS (only several
packages do, like DirectFB if I remember right).

-- 
Jesús Guerrero



Re: [gentoo-user] Can I (partially) rebuild a package with emerge?

2009-12-16 Thread Joshua Murphy
2009/12/16 Jesús Guerrero i92gu...@terra.es:
 On Wed, 16 Dec 2009 20:44:29 +, Alan Mackenzie a...@muc.de wrote:
 Hi, gentoo,

 I've just emerged xorg-x11, and noticed that I had a wrong setting for
 VIDEO_CARDS in /etc/make.conf.  Does emerge have a facility to rebuild
 only those portions of xorg-x11 dependent on that setting, or do I have
 to start again from scratch?  I've perused the emerge man page, but not
 found this situation addressed.

 What you failed to see if that VIDEO_CARDS flags are just an special type
 of USE flags. Using -auDvN world will fix everything. Truly speaking,
 xorg-server wouldn't even need to be recompiled (though that's what portage
 will do). As far as I know, all these special USE flags for xorg-server
 just push one of another xf86-video-* package(s) as dependencies, which in
 turn install the required driver(s).

 The rest of Xorg components do not relate to this, you shouldn't need to
 recompile anything else unless it also depends on VIDEO_CARDS (only several
 packages do, like DirectFB if I remember right).

 --
 Jesús Guerrero

Actually, as I ran across on my ~x86 systems, x11-base/xorg-drivers is
now a separate ebuild from
 xorg-server, keeping the latter from trying to be rebuilt every time
you change what drivers you want to have built... and looking at
gentoo-portage.com, xorg-drivers-1.6 is stable on both amd64 and x86.
It really is a much more sensible approach, and appears to work rather
well.

-- 
Poison [BLX]
Joshua M. Murphy