Re: [dwm] improve config.mk

From: Ricardo Martins <meqif_AT_swearing-ape.net>
Date: Thu, 7 Sep 2006 12:57:21 +0100

On 13:11 Thu 07 Sep , Cedric Krier wrote:
> On 07/09/06 11:56 +0100, Ricardo Martins wrote:
> > On 12:11 Thu 07 Sep , Cedric Krier wrote:
> > >
> > > The way, I do when I update dwm with portage :
> > >
> > > I compile the new version which copy in /etc/portage/savedconfig the
> > > default config.h.
> > > I edit it to match my pref.
> > > I recompile dwm with portage.
> > >
> > > ( it looks like busybox's ebuild )
> > >
> > > I'm thinking about a way to have the config.h with compiling but the
> > > compilation is not very long.
> >
> > The way I see it, that is just a workaround, and only works very well
> > for a minimally to moderately customised config.h. What if your changes
> > to savedconfig are not trivial? Being lazy, I think it is easier to just
> > do a little change to one's old and proved custom config.h than changing
> > a new config.h to be adequated to what one had before. That's only my
> > opinion.
> >
> > One thing I don't understand clearly is in which conditions config.default.h
> > is copied to /etc/portage/savedconfig (I advise against this location,
> > /etc/dwm_config would be clearer). Is it copied whenever dwm is emerged
> > (probably not, since it would overwrite your changes), or only when
> > /etc/portage/savedconfig doesn't exist?
> > In the latter case, the issue I talked about arises, since a deprecated
> > config is being used, which results in a compile error.
> >
> As it is not a config file for the run but for compilation, it has not
> place in /etc. The config.h is saved like this ${PF}.config.h.
> But have a look to the ebuild and you will understand.
> And of course if your config.h is not valid, you will have a compile
> error.

Ok, point taken. But it isn't directly related to portage like
package.mask is, for example. It doesn't matter, anyway.

I had a look at it. It does check if there's already a custom config, so
as to not overwrite it, which is good. But the compile error is usually
not very clear. Perhaps if you added a warning like this if the compile
dies: "Check your savedconfig for errors, missing or changed parameters"
and then added a diff... That would probably help one to see quickly why
the emerge failed and correct it in a flash.

Regards,

-- 
 Ricardo Martins  ><><  www.swearing-ape.net  ><><  GPG key: 3B818E27
Received on Thu Sep 07 2006 - 13:57:51 UTC

This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 14:31:06 UTC