<URL: http://bugs.freeciv.org/Ticket/Display.html?id=39849 >
On 27/11/2007, Jason Short <[EMAIL PROTECTED]> wrote: > > > [EMAIL PROTECTED] - Tue Nov 27 17:48:50 2007]: > > > > On 27/11/2007, Marko Lindqvist wrote: > > > Now I got this same error in Ubuntu system. > > > > > > It seems that user has to define "_GNU_SOURCE" for "__USE_GNU" to > > be defined. > > > > > > No idea how it always gets set at configure time. > > > > Patch to define it both configure and compile time. > > This *can't* be the right fix. AC_GNU_SOURCE is what autoconf manual tells one to use. It's not fix to the actual bug (wherever that is) but gets around it. > First of all, why is configure finding the function when it can't be > found by gcc later? This seems like autoconf bug. It should not find it when AC_GNU_SOURCE is not used. > Secondly, _GNU_SOURCE? Is this a real define or just something internal > to glibc? Why would strcasestr not be presented to the user by default > as the manual indicated? _GNU_SOURCE is documented as user (from glibc point of view) settable macro: http://www.gnu.org/software/libc/manual/html_node/Feature-Test-Macros.html Glibc manual mentions that "strcasecmp is derived from BSD." Maybe one is expected to read that as "strcasecmp is available only when _BSD_SOURCE or _GNU_SOURCE is defined." > Honestly this looks like a glibc bug. ...or gcc. There has been ongoing discussion for years if they should define _GNU_SOURCE by default or not. I saw some comment saying that currently g++ defines it, but gcc not! - ML _______________________________________________ Freeciv-dev mailing list Freeciv-dev@gna.org https://mail.gna.org/listinfo/freeciv-dev