zttranscode.c:37:30: linux/page-flags.h: No such file or directory

chris (2007-03-19 21:03:14)
1374 views
0 replies

Compiling Zaptel on a 2.4 kernel is getting harder, as development seems to focus now more on the 2.6 kernel releases. Compiling the newest Zaptel sources on linux 2.4.33.3 today gave the following errors:
root@baikal:/usr/src/zaptel# make
make[1]: Entering directory `/usr/src/zaptel'
gcc -I/lib/modules/2.4.33.3/build/include -O6 -DMODULE -D__KERNEL__ -DEXPORT_SYMTAB -I/lib/modules/2.4.33.3/build/drivers/net -Wall -I. -Wstrict-prototypes -fomit-frame-pointer -I/lib/modules/2.4.33.3/build/drivers/net/wan -I/lib/modules/2.4.33.3/build/include/net -DMODVERSIONS -include /lib/modules/2.4.33.3/build/include/linux/modversions.h  -DSTANDALONE_ZAPATA -o zttranscode.o -c zttranscode.c
In file included from /lib/modules/2.4.33.3/build/include/linux/spinlock.h:6,
                 from /lib/modules/2.4.33.3/build/include/linux/module.h:12,
                 from zttranscode.c:28:
/lib/modules/2.4.33.3/build/include/asm/system.h: In function `__set_64bit_var':
/lib/modules/2.4.33.3/build/include/asm/system.h:190: warning: dereferencing type-punned pointer will break strict-aliasing rules
/lib/modules/2.4.33.3/build/include/asm/system.h:190: warning: dereferencing type-punned pointer will break strict-aliasing rules
zttranscode.c:37:30: linux/page-flags.h: No such file or directory
make[1]: *** [zttranscode.o] Error 1
make[1]: Leaving directory `/usr/src/zaptel'
make: *** [all] Error 2

I immediately ran 'updatedb && locate page-flags.h' and the file didn't exist anywhere on the system. I suspected this might be due to the builder expecting a 2.6 kernel to be present, so I just went for broke and tried the following:

1) Download latest 2.6 kernel sources
2) Extract
3) updatedb && locate page-flags.h # this returned a file in the new source tree
4) copy the file into the place where zaptel's build process is expecting it:

$ cp /usr/src/linux-2.6.20.3/include/linux/page-flags.h /lib/modules/2.4.33.3/build/include/linux/.

So I tried the above, re-ran make, and the compilation ran through to the end without error. hurrah!

hth

christo
Digg it! Submit to Slashdot Add to Blinklist Del.icio.us Add to Newsvine Add to Technorati Add it to Google Bookmarks
comment