bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [gettext-0.16.1] undefined ceil() reference when building msgl-fsear


From: Bruno Haible
Subject: Re: [gettext-0.16.1] undefined ceil() reference when building msgl-fsearch.c
Date: Fri, 6 Apr 2007 23:51:56 +0200
User-agent: KMail/1.5.4

Andreas Florath wrote:
> When compiling gettext-0.16.1 make stops with:
> msgl-fsearch.c:589: undefined reference to `ceil'
> collect2: ld returned 1 exit status
> 
> As stated in the other mail, the symbol MSGMERGE_LIBM is not set.  The  
> reason for this is, that the test is somewhat 'special': the program  
> that is used to look if -lm must be used or not is:
> 
> #include <math.h>
> int
> main ()
> {
> static double x; x = ceil(x); x = sqrt(x);
>    ;
>    return 0;
> }

Yes, and it occurs only with particular combinations of glibc and gcc
versions: glibc version < 2.3 with gcc version >= 4.0.

The workaround is to configure gettext with

    ./configure CPPFLAGS="-D__NO_MATH_INLINES"

You can also try the fix that has been put into the gettext CVS:
    
http://cvs.savannah.gnu.org/viewcvs/gettext/gettext-tools/configure.ac?root=gettext&r1=1.87&r2=1.88

Bruno





reply via email to

[Prev in Thread] Current Thread [Next in Thread]