Boston Linux & Unix (BLU) Home | Calendar | Mail Lists | List Archives | Desktop SIG | Hardware Hacking SIG
Wiki | Flickr | PicasaWeb | Video | Maps & Directions | Installfests | Keysignings
Linux Cafe | Meeting Notes | Blog | Linux Links | Bling | About BLU

BLU Discuss list archive


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

zImage, zlilo, zdisk bomb out



make[2]: Entering directory `/usr/src/linux/arch/i386/boot/compressed'
gcc -I/usr/src/linux/include -O2 -DSTDC_HEADERS -o xtract xtract.c
xtract.c:22: sizeof applied to an incomplete type
xtract.c: In function `main':
xtract.c:53: dereferencing pointer to incomplete type
xtract.c:53: `ZMAGIC' undeclared (first use this function)
xtract.c:53: (Each undeclared identifier is reported only once
xtract.c:53: for each function it appears in.)
xtract.c:56: dereferencing pointer to incomplete type
xtract.c:56: `QMAGIC' undeclared (first use this function)
xtract.c:59: dereferencing pointer to incomplete type
make[2]: *** [xtract] Error 1
-------------------------------------

I have some suggestions -- I don't know if they're any good or not.
Just a couple ideas to help you get started.

Whenever stuff like that happens to me I start looking for places where
the undeclared things ARE declared (or #defined).

Do a recursive search of all .c, .h and makefiles in all your source
and include directorys.  Look for a file containing the string ZMAGIN
and/or QMAGIC, where ZMAGIC or QMAGIC are defined or declared.

If that fails, then they could be in link libraries.  Check your
.a and other link file types for the symbols ZMAGIC, QMAGIC, or
symbols that they may have been #defined using (as per the prev.
step).

One interesting file is ./linux-1.2.13/include/linux/a.out.h, which contains
the following lines:

	#define ZMAGIC 0413 

	#define QMAGIC 0314

One or both are referred to in fs/sysv/binfmt_elf.c,
arch/i386/ibcs/binfmt_elf.c, and in arch/i386/boot/compressed/xtract.c,
but you already knew that), and arch/i386/boot/tools/build.c. 

You might try seeing why those other files compiled and xtract didn't.
Should a.out.h be in the #includes?  Check the makefile -- is there
an a.out.o that should be getting linked in when you compile xtract?

Sorry I don't really know the answer -- but I hope this puts you on
the path.

        -r

	rmela at shore.net
	http://www.shore.net/~rmela





BLU is a member of BostonUserGroups
BLU is a member of BostonUserGroups
We also thank MIT for the use of their facilities.

Valid HTML 4.01! Valid CSS!



Boston Linux & Unix / webmaster@blu.org