In general, how to find solution to error of make bzImage

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I tried to build 2.4.18-3 kernel for kgdb 1.5 setup using instructions below. And #make bzImage failed. I wonder someone who had built kernel for kgdb before could tell what I went wrong. Here is what I did compare with instructions:

>On developement machine:
>1. Extract a kernel source
>$ cd /mnt/work/build/old-pc
>$ bunzip2 -c ~/linux-2.4.6.tar.bz2 | tar xvf -
>$ mv linux linux-2.4.6-kgdb

I did:
Becuase kernel-source package is in /usr/src/linux-2.4.18-3, I simply
#cp -R linux-2.4.18-3 linux-2.4.18-3-kgdb
I don't know why need to rename the source directory as instructions suggested.

>2. Apply kgdb patch
>$ cd linux-2.4.6-kgdb
>$ patch -p1 < ~/linux-2.4.6-kgdb.patch

I did:
#cd linux-2.4.18-3-kgdb
#patch -p1 < ~/download/kgdb/linux-2.4.18-kgdb-1.5.patch

at this stage, it went smoothly.

>3. Configure the kernel
>$ make xconfig or make menuconfig
>$ make dep

I did:
#make menuconfig
#make dep
these two steps went through smoothly

#make bzImage

building kernel error:
cc -D__KERNEL__ -I/usr/src/linux-2.4.18-3-kgdb/include -Wall -Wstrict-prototypes -Wno-
trigraphs -O2 -fno-strict-aliasing -fno-common -Wno-unused -g -pipe -mpreferred-stack-b
oundary=2 -march=i686 -DKBUILD_BASENAME=sys_i386 -c -o sys_i386.o sys_i386.c
cc -D__KERNEL__ -I/usr/src/linux-2.4.18-3-kgdb/include -Wall -Wstrict-prototypes -Wno-
trigraphs -O2 -fno-strict-aliasing -fno-common -Wno-unused -g -pipe -mpreferred-stack-b
oundary=2 -march=i686 -DKBUILD_BASENAME=pci_dma -c -o pci-dma.o pci-dma.c
cc -D__KERNEL__ -I/usr/src/linux-2.4.18-3-kgdb/include -Wall -Wstrict-prototypes -Wno-
trigraphs -O2 -fno-strict-aliasing -fno-common -Wno-unused -g -pipe -mpreferred-stack-b
oundary=2 -march=i686 -DKBUILD_BASENAME=i386_ksyms -DEXPORT_SYMTAB -c i386_ksyms.c
i386_ksyms.c:178: `do_BUG' undeclared here (not in a function)
i386_ksyms.c:178: initializer element is not constant
i386_ksyms.c:178: (near initialization for `__ksymtab_do_BUG.value')
make[1]: *** [i386_ksyms.o] Error 1
make[1]: Leaving directory `/usr/src/linux-2.4.18-3-kgdb/arch/i386/kernel'
make: *** [_dir_arch/i386/kernel] Error 2
[root@Cheetah linux-2.4.18-3-kgdb]#


Your help will be appreciated,
-Hong


--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive: http://mail.nl.linux.org/kernelnewbies/
FAQ: http://kernelnewbies.org/faq/



[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux