FedoraForum.org - Fedora Support Forums and Community
Results 1 to 11 of 11
  1. #1
    Join Date
    Jan 2006
    Posts
    25

    Kernel : no rule to make target main.o

    I need to recompile my kernel. for ibook 2001 12inch running fc4 ppc for ntfs.
    The currnent config doesnt' allow ntfs by module or built in.

    I'm currently using the 2.6.14...


    I issued


    make menuconfig then changed what I needed, then

    make.

    Got make[1] ***No rule to make target 'init/main.o' needed by 'init/built-in.o'. Stop
    make: *** [init] Error 2

    One of the other searches suggested running make with the original .config. luckily, I copied my .config to my own backup, so I copied it back, then make menuconfig and made sure that my change wasn't there, it wasn't.

    make clean
    make

    Same error.

    make allnoconfig
    Same error.

    SAME PROBLEM WITH OTHER KERNEL 2.6.11-...

    Any ideas?

    thanks,
    Jessop

  2. #2
    Join Date
    May 2005
    Location
    PH
    Posts
    696
    what kernel source do you have?
    what does

    uname -a

    says?

  3. #3
    Join Date
    Jan 2006
    Posts
    25
    OK, it seems I'm doing it wrong. According to another post, I'm supposed to do it in the usr/src/redhat/BUILD dir, not the location of headers in /usr/src/kernel...

  4. #4
    Join Date
    May 2005
    Location
    PH
    Posts
    696
    yes indeed.
    you need to go to that folder and make sure you have extracted the kernel tar file inside it before you
    make gconfig (X based) and compile.

    i am still curious, appreciate if you could post output of

    yum search *ntfs*

    with your PPC system.

  5. #5
    Join Date
    Jan 2006
    Posts
    25
    I doubt it would make any difference, since the make menuconfig doesn't even have ntfs enabled as a module.

    yum search *ntfs*

    No Matches found.

    -Thanks for the hint - I'm curious too why I can't find anything. Perhaps it's only finding things that I could use, and since ntfs modules are not enabled in the kernel, it doesn't report them.

    =Jessop

  6. #6
    Join Date
    Apr 2005
    Location
    Finland
    Posts
    5,072
    "yum search" has absolutely nothing to do with your kernel options. If it doesn't find something, it means that you haven't configured any yum repos containing the package you are looking for. Enable the Livna repo for kernel-module-ntfs packages.

  7. #7
    Join Date
    May 2005
    Location
    PH
    Posts
    696
    ntfs modules are not kernel-enabled by default due to patent restrictions, even if as a compile module.

    yum also depends on your yum repos, see your /etc/yum.repos.d/ files. yum searches only to enabled
    repos and defined repos under this folder.
    see www.fedorafaq.com for more yum repos and conf.

  8. #8
    Join Date
    Jan 2006
    Posts
    25
    yes, I had to add a repo for madwifi. I figured, though, that ntfs was a standard part. evidentally not.

    the ibook is happily 'make'ing away... ntfs being compiled right in. I'm using the thing for data recovery so chances are I'll be using it often.

    -Thanks, Jessop

  9. #9
    Join Date
    May 2005
    Location
    PH
    Posts
    696
    glad to help.

  10. #10
    Join Date
    Mar 2006
    Location
    South Bend, IN - USA
    Age
    46
    Posts
    34
    Quote Originally Posted by jessopb
    OK, it seems I'm doing it wrong. According to another post, I'm supposed to do it in the usr/src/redhat/BUILD dir, not the location of headers in /usr/src/kernel...
    Could I get the specifics on compiling my own kernel? I'm getting the same message and I can't find the other post.

  11. #11
    Join Date
    Mar 2007
    Posts
    2

    Angry SOLUTION to "No rule to make target 'init/main.o'"

    [QUOTE=jessopb]
    I'm currently using the 2.6.14...
    I issued
    make menuconfig then changed what I needed, then
    make.

    Got make[1] ***No rule to make target 'init/main.o' needed by 'init/built-in.o'. Stop
    make: *** [init] Error 2

    One of the other searches suggested running make with the original .config.
    make

    Same error.

    make allnoconfig
    Same error.

    SAME PROBLEM WITH OTHER KERNEL 2.6.11-.../QUOTE]

    The problem is that Red Hat Enterprise Linux 4 (RHEL 4), and therefore, Fedora, ships with a fake kernel source that's more than kernel header files, and less than a full kernel.
    You CAN make menuconfig
    You CAN make modules
    You CANNOT make
    You CANNOT make bzImage

    If you want to build a real kernel, you have to download the src.rpm for the kernel version you wish to rebuild, then install the src.rpm, then copy the kernel source from /usr/src/redhat/... to a sensible location like
    /usr/src/

    See documents like
    http://kbase.redhat.com/faq/FAQ_85_5109.shtm

    What Red Hat should do is CHANGE THEIR MAKEFILE
    to give a meaningful error when somebody types make
    or make bzImage

    Right now, it instead looks like a legitimate kernel misconfiguration problem. Are you listening Red Hat?

Similar Threads

  1. make: *** No rule to make target 'clean'. Stop.
    By JonnyBravo in forum Using Fedora
    Replies: 6
    Last Post: 18th October 2008, 10:38 AM
  2. Replies: 21
    Last Post: 7th March 2007, 12:08 AM
  3. Replies: 0
    Last Post: 13th April 2006, 10:50 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •