[CentOS] Kernel 92.1.10 build issue

Thu Aug 7 09:24:11 UTC 2008
Akemi Yagi <amyagi at gmail.com>

On Wed, Aug 6, 2008 at 11:23 PM, Mark Hull-Richter <mhullrich at gmail.com> wrote:
> I pulled down the 2.6.18-92.1.10 source, installed it, built the package,
> copied the straight x86_64 config file from SOURCES into the build
> directory, redid make menuconfig to enable NTFS support, added the # x86_64
> back into the .config file, copied .config back to the SOURCES directory and
> ran rpmbuild -ba --target=x86_64 <spec file> (same as I always do with new
> kernels), but this time I'm getting this error in the build:
>
> Patch #99990 (linux-2.6-rhel-version-h.patch):
> + patch -p1 -s
> + perl -p -i -e 's/^SUBLEVEL.*/SUBLEVEL = 18/' Makefile
(snip)
> + cat .config
> + for i in '*.config'
> + mv kernel-2.6.18-x86_64.config .config
> ++ head -1 .config
> ++ cut -b 3-
> + Arch=x86_64
> + make ARCH=x86_64 nonint_oldconfig
> CONFIG_MAX_RAW_DEVS
> make[1]: *** [nonint_oldconfig] Error 1
> make: *** [nonint_oldconfig] Error 2
> error: Bad exit status from /var/tmp/rpm-tmp.53835 (%prep)
>
> RPM build errors:
>     Bad exit status from /var/tmp/rpm-tmp.53835 (%prep)
>
> Was there something I needed to tweak in the spec file, other than the build
> id and a few of the build switches I usually turn off (xen, debug, kdump)?

I suggest you take a look at the Wiki article:

http://wiki.centos.org/HowTos/Custom_Kernel

It has been updated recently (Alan did most of the work) to
accommodate recent changes in the spec file.  You will find many lines
that were changed or added newly.  Among other things, it now suggests
that you copy the .config file from the config/ directory (or from
your /boot) instead of the SOURCES directory.  Because your build is
failing at the step of:

  make ARCH=$Arch nonint_oldconfig > /dev/null

I suspect using the config file from configs/ might fix the error you got.

Akemi