Gentoo Archives: gentoo-user

From: Gregory Shearman <zekeyg@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] sudo in kernel config ?
Date: Sun, 12 Sep 2010 07:31:21
Message-Id: 20100912072949.GA17122@pacific.net.au
In linux.gentoo.user, you wrote:
> > Some people, such as myself, use kernel sources outside of portage (I > follow a git repo) and do so as a non-root user. In this case the > kernel tree is not owned by root and the config/compile is easily done > as a non-root user. > > If you are super-paranoid. You can make a non-root copy > of /usr/src/linux and compile it as a non-root user. > > But there really isn't any point in using sudo. It's effectively doing > the same thing that you are trying to avoid.
I agree there's no point in using sudo, but what's the problem? You don't need to edit the kernel sources merely to build a new kernel. You can build your kernel outside the tree using for example: make O=/home/user/kernel/tree/ menuconfig make O=/home/user/kernel/tree/ All files are put into the user's directory. All that's need is the KBUILD_OUTPUT environment variable set, so that drivers can find the kernel .config file etc. I've built my kernels like this for years now. All kernels are built by a specific user and then installed as root. No problem, no worries about permissions and no altering the portage installed kernel sources so that a purge (emerge -P gentoo-sources) will automatically remove the whole tree. -- Regards, Gregory.

Replies

Subject Author
Re: [gentoo-user] sudo in kernel config ? Bill Longman <bill.longman@×××××.com>