[PATCH] Don't hardcode target dependencies

Dan Nicholson dbn.lists at gmail.com
Wed Mar 14 16:26:20 PDT 2007

On 3/14/07, M.Canales.es <macana at macana-es.com> wrote:
> El Miércoles, 14 de Marzo de 2007 01:07, Dan Nicholson escribió:
> > I should read the archives, but, why sudo?
> Actually the idea to implement such inner make invocations come from you ;-)
> http://linuxfromscratch.org/pipermail/alfs-discuss/2006-August/008649.html

Excuse me while I wipe this egg off my face :)

> Prior that, there was some request about not to have to run make as root, thus
> your idea allow us to can do the full jhalfs work as a normal user plus to
> reduce notably the Makefile size and the number of functions used.

A couple things to talk about here.

1. I'm not sure why people would be opposed to running make as root. It's a
   necessary part of LFS that you need to be root sometimes. The other thing
   is that if sudo is necessary, then it's just as easy to type "sudo
make". This
   was how I used to run jhalfs.

2. The use of functions and reduction of size are a different goal
than trying to
   figure out the best way to handle privileges.

Not trying to argue, but that's my opinion.

> The issue now is that, for testing purposses, in ocassions we may need to
> launch a partial build stopping on a dessired target, or do a build
> target-by-target. Thus, could that be implemented  again without reverting a
> lot of code to the 1.0 version?
> We should be able to find a solution...

Yes, I think it should be possible without a major altering of the
code. In my mind, the way to do it would be to require root privileges
then drop them with su $luser -c where necessary. There's the syntax
issue where the su argument has to be wrapped in "", but I think this
should workable with make functions.


More information about the alfs-discuss mailing list