# make menuconfig broke?

## scooby4844

well, i am trying to re-compile my kernel and i am having some problems XD 

```
c@gentoo_netbook ~ $ cd /usr/src/linux

c@gentoo_netbook /usr/src/linux $ make menuconfig

make: *** No rule to make target `menuconfig'.  Stop.

c@gentoo_netbook /usr/src/linux $ 

```

i have emerged kernel sources and now i am unsure what to do

any help is appreciated, i really need 2 re-configure my kernel  (i hope it is just a little stupid thing so i could just move on)

----------

## cach0rr0

perhaps the symlink is broken? 

```

ls -l /usr/src/linux

```

if it is, you could simply (note the absence of the trailing forward slash in the first one)

```

rm /usr/src/linux

USE="symlink" emerge gentoo-sources
```

Obv if you use tuxonice-sources or hardened-sources, replace as needed.

----------

## scooby4844

ok, it ran nicely, and it finds the script.  i was running a different kernel before, but i guess i will just update it, the old kernel was probably the problem anyway 

```
c@gentoo_netbook ~ $ ls -l /usr/src/linux

lrwxrwxrwx 1 root root 22 Aug 23 22:37 /usr/src/linux -> linux-2.6.30-gentoo-r4

c@gentoo_netbook ~ $ cd /usr/src/linux

c@gentoo_netbook /usr/src/linux $ make menuconfig

  HOSTCC  scripts/basic/fixdep

scripts/basic/fixdep.c:399: fatal error: opening dependency file scripts/basic/.fixdep.d: Permission denied

compilation terminated.

make[1]: *** [scripts/basic/fixdep] Error 1

make: *** [scripts_basic] Error 2

c@gentoo_netbook /usr/src/linux $ 

```

i could probably fix this by running it at root, but i read somewhere to never compile a kernel at root.  any subjections or should i just run it @ root?

----------

## cach0rr0

heh

You're running this as a normal user, not root

was probably the problem with the old build too, looking back up at your post 

It ain't the kernel that's wrong. 

Change to root, and let's try with your old kernel sources

as root:

```

rm /usr/src/linux

ln -s /usr/src/whateveroldkernelsources /usr/src/linux

cd /usr/src/linux

make menuconfig

```

Someone had suggested kernel builds shouldn't be run as root, and though his claim likely has validity, 99.99999999% of us do so as root

----------

## scooby4844

i ran the old one in root and it wouldn't work as root wither, that's why i went to the forums here 

i will just run the new ones, i am pretty mutch rebuilding my kernel anyways 

another question i have had for a while.  whenever i re-compile my kernel i NEVER copy it right and am always forced to go into a live cd and search for it.  could you tell me where the compiled kernel goes? so maybe i could copy it right this time. 

anoteher question- when i go into menuconfig and set my choices, does it always compile the .config one or dies it compile the one that i just made (if i named it  something else)?

----------

## cach0rr0

 *scooby4844 wrote:*   

> i ran the old one in root and it wouldn't work as root wither, that's why i went to the forums here 
> 
> i will just run the new ones, i am pretty mutch rebuilding my kernel anyways 
> 
> 

 

If you're still getting the hang of building your own kernel, I highly highly recommend building from one of Pappy's seeds, or at the very least reading some of his quick tips on configuring a kernel. 

http://62.3.120.141/~pappy/

The short version - take one of his seed kernels appropriate for your sources version and processor, use the link in my sig (which is also mentioned on his site) to help identify what drivers you need, and ONLY build in the drivers you need - don't do guess work and say 'well, this one kinda looks like my hardware, but im not sure, so I'll include it anyway' - I did that for the longest time, and it never ended well. 

Pappy's seeds also take a lot of the guesswork out when you encounter something you *think* is safe to disable, but aren't sure because you're not entirely clear on what it does. 

 *Quote:*   

> 
> 
> another question i have had for a while.  whenever i re-compile my kernel i NEVER copy it right and am always forced to go into a live cd and search for it.  could you tell me where the compiled kernel goes? so maybe i could copy it right this time. 
> 
> 

 

If the build is successful, it should always be in arch/x86/boot/bzImage (no matter if youre running a 64bit kernel or 32bit - it will always be there)

I suggest rather than doing what the handbook says, and giving it some long funky name, you give it as simplistic a name as possible to avoid the potential pitfall of making a typo. 

For example, when I do a new config it's as follows:

```

mount /boot

cd /usr/src/linux

make menuconfig

make && make modules_install

cp arch/x86/boot/bzImage /boot/kernel-new

```

my grub.conf is then much simpler, and looks like so:

```

laptop02 linux # cat /boot/grub/grub.conf 

default 0

timeout 3

splashimage=(hd0,0)/boot/grub/splash.xpm.gz

title Gentoo Linux 2.6.30-r4 (no framebuffer)

root (hd0,0)

kernel /boot/kernel-new root=/dev/sda3

title Gentoo Linux 2.6.30-r4 (framebuffer)

root (hd0,0)

kernel /boot/kernel-fb root=/dev/sda3 vga=0x318 splash=silent,theme:natural_gentoo console=tty1 quiet

```

 *Quote:*   

> 
> 
> anoteher question- when i go into menuconfig and set my choices, does it always compile the .config one or dies it compile the one that i just made (if i named it  something else)?

 

Once you finish menuconfig, if you save your kernel config when prompted, it will move your old .config to .config.old, and save whatever you've just done in menuconfig to simply .config

the 'make' will *always* use .config (unless you throw a bunch of other commands at it, which you wont, as that's outside the scope of a basic kernel config)

menuconfig is for the purpose of generating a .config

menuconfig does NOT do any actual compilation

There are situations in which the above may not be true, but none of these are going to apply to you just yet

Hope that helps

----------

## scooby4844

awsome, ty 4 all the help

----------

