__fswabXX symbol clash between uclibc and linux on CRIS

Andreas Eckstein andreas.eckstein at gmx.net
Thu Jan 18 02:07:28 UTC 2007


Hi all!
While trying to cross-build a CRIS system, I stumbled upon a symbol 
clash between uclibc and linux: __fswab16 and __fswab32, defined in 
<linux/byteorder/swab.h> and <bits/byteswap.h> (uclibc for CRIS 
architecture only), conflict when imported into the same file. This 
happens for example in the busybox module 
networking/libiproute/iptunnel.c'. For now I solved this by prefixing 
the uclibc functions, but I fear trouble will come of it as soon as some 
application wants either variant of these functions.
How would one go about solving this? Renaming? Just trying not to 
include both headers at once? Trying to include the in-kernel versions 
into byteswap.h? The functions look similar enough, but it is not as 
trivial as including swab.h in byteswap.h, and anyway it feels kind of 
wrong to use some kernel-header inline function in userland. I would 
value your opinions on this matter and I will try to write a decent 
patch when a solution comes up.

Greetings

Andreas Eckstein



More information about the uClibc mailing list