Skip to contentSkip to conversation

Change in compiler.h causes compile errors in many applications

DISCUSSION Helmut Auer 2 participants 2 messages Feb 25, 2004

lore
Share & tools
lore
#0 lore raw

Hello,
With kernel 2.6.3 a
#ifdef __KERNEL__
was added at the beginning of linux/compiler.h
That causes compile errors in severel applications, because the following includes were no longer done. Was that caused by accident ?

Signature · 1 line
Helmut Auer, [email protected] 
#1 lore raw
Quoted 10 lines · Helmut Auer

Hello,
With kernel 2.6.3 a
#ifdef __KERNEL__
was added at the beginning of linux/compiler.h
That causes compile errors in severel applications, because the following includes were no longer done.
Was that caused by accident ?

--
Helmut Auer, [email protected]

The kernel headers are to be used for compiling the kernel only! Older distributions may have a sim-link (two) for /usr/include/linux and /usr/include/asm. These should point to the headers used to compile the 'C' runtime library, not the current kernel headers.

A fix is to remove these symlinks and create directories that contain your last working headers.

Cheers,
Dick Johnson
Penguin : Linux version 2.4.24 on an i686 machine (797.90 BogoMips).
Note 96.31% of all statistics are fiction.