* Header files conflicts
@ 1999-03-22 16:43 Thierry Lafage
1999-03-23 9:11 ` Thierry Lafage
1999-03-23 9:20 ` Jakub Jelinek
0 siblings, 2 replies; 3+ messages in thread
From: Thierry Lafage @ 1999-03-22 16:43 UTC (permalink / raw)
To: ultralinux
Hello,
The header files in /usr/include/linux seriously conflict with some
from glibc-devel-2.0.7-29 in my ultrasparc-I box running UP-1.1.9 and
kernel 2.2.4.
Here is a sample example (using <sys/types.h>):
[thierry@paranormale sparc]$ make agent.o
gcc -g -O3 -Wall -I. -I../../../misc-include -Wa,-Av9a -DLINUX -c agent.c -o agent.o
In file included from /usr/include/sys/types.h:30,
from md.h:10,
from agent.h:11,
from agent.c:16:
/usr/include/gnu/types.h:75: warning: `__NFDBITS' redefined
/usr/include/linux/posix_types.h:30: warning: this is the location of the previous definition
/usr/include/gnu/types.h:77: warning: `__FDMASK' redefined
/usr/include/linux/posix_types.h:42: warning: this is the location of the previous definition
[...]
/usr/include/sys/types.h:110: warning: redefinition of `u_int64_t'
/usr/include/linux/types.h:90: warning: `u_int64_t' previously declared here
In file included from /usr/include/sys/types.h:126,
from md.h:10,
from agent.h:11,
from agent.c:16:
/usr/include/sys/select.h:48: conflicting types for `fd_set'
/usr/include/linux/types.h:9: previous declaration of `fd_set'
make: *** [agent.o] Error 1
[thierry@paranormale sparc]$
I have seen similar conflicts when trying to compile amd from
am-utils-6.0a16-4.src.rpm.
What may have missed?
Thierry Lafage.
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: Header files conflicts
1999-03-22 16:43 Header files conflicts Thierry Lafage
@ 1999-03-23 9:11 ` Thierry Lafage
1999-03-23 9:20 ` Jakub Jelinek
1 sibling, 0 replies; 3+ messages in thread
From: Thierry Lafage @ 1999-03-23 9:11 UTC (permalink / raw)
To: ultralinux
>
> Hello,
>
> The header files in /usr/include/linux seriously conflict with some
> from glibc-devel-2.0.7-29 in my ultrasparc-I box running UP-1.1.9 and
> kernel 2.2.4.
>
> Here is a sample example (using <sys/types.h>):
[...]
> What may have missed?
>
> Thierry Lafage.
Here is another example (trying to include <linux/types.h>):
In file included from /usr/include/_G_config.h:9,
from /usr/include/libio.h:31,
from /usr/include/stdio.h:29,
from emul_error.h:6,
from traps-handle.h:30,
from traps-handle.c:7:
/usr/include/gnu/types.h:75: warning: `__NFDBITS' redefined
/usr/include/linux/posix_types.h:30: warning: this is the location of the previous definition
/usr/include/gnu/types.h:77: warning: `__FDMASK' redefined
/usr/include/linux/posix_types.h:42: warning: this is the location of the previous definition
In file included from /usr/include/stdlib.h:210,
from trace.h:12,
from traps-handle.h:32,
from traps-handle.c:7:
/usr/include/sys/types.h:117: warning: `__BIT_TYPES_DEFINED__' redefined
/usr/include/linux/types.h:73: warning: this is the location of the previous definition
In file included from /usr/include/stdlib.h:210,
from trace.h:12,
from traps-handle.h:32,
from traps-handle.c:7:
/usr/include/sys/types.h:33: warning: redefinition of `u_char'
/usr/include/linux/types.h:61: warning: `u_char' previously declared here
/usr/include/sys/types.h:34: warning: redefinition of `u_short'
/usr/include/linux/types.h:62: warning: `u_short' previously declared here
/usr/include/sys/types.h:35: warning: redefinition of `u_int'
[...]
Any idea?
Thierry Lafage.
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: Header files conflicts
1999-03-22 16:43 Header files conflicts Thierry Lafage
1999-03-23 9:11 ` Thierry Lafage
@ 1999-03-23 9:20 ` Jakub Jelinek
1 sibling, 0 replies; 3+ messages in thread
From: Jakub Jelinek @ 1999-03-23 9:20 UTC (permalink / raw)
To: ultralinux
>
> >
> > Hello,
> >
> > The header files in /usr/include/linux seriously conflict with some
> > from glibc-devel-2.0.7-29 in my ultrasparc-I box running UP-1.1.9 and
> > kernel 2.2.4.
> >
> > Here is a sample example (using <sys/types.h>):
> [...]
> > What may have missed?
> >
> > Thierry Lafage.
>
> Here is another example (trying to include <linux/types.h>):
That's what you get on i386 with glibc as well, simply linux/types.h is
incompatible with glibc headers, it has been like that for quite some time.
Generally, you should use glibc headers and if you ever need something from
linux/ headers which include linux/types.h or similar headers, just handle
it somehow. If you look into most low level packages which do this, you'll
see they either use their own copy of kernel headers, thus are independent
on the actual kernel version installed during build (which is a good thing),
or #define some define which will prevent those headers to be included.
Cheers,
Jakub
___________________________________________________________________
Jakub Jelinek | jj@sunsite.mff.cuni.cz | http://sunsite.mff.cuni.cz
Administrator of SunSITE Czech Republic, MFF, Charles University
___________________________________________________________________
UltraLinux | http://ultra.linux.cz/ | http://ultra.penguin.cz/
Linux version 2.2.3 on a sparc64 machine (3958.37 BogoMips)
___________________________________________________________________
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~1999-03-23 9:20 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1999-03-22 16:43 Header files conflicts Thierry Lafage
1999-03-23 9:11 ` Thierry Lafage
1999-03-23 9:20 ` Jakub Jelinek
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.