[petsc-dev] bug in BuildSystem check

Matthew Knepley knepley at gmail.com
Fri Apr 22 08:16:06 CDT 2011


On Fri, Apr 22, 2011 at 8:12 AM, Barry Smith <bsmith at mcs.anl.gov> wrote:

>
>  Matt,
>
>   In the test for isinf() the compile warns about lack of prototype.
> BuildSystem should stop at this point and NOT set HAVE_ISINF. Could you
> please fix this?
>

Are you sure? It linked just fine. If you still want to signal an error, we
can do it by looking for that string.

  Matt


>    Thanks
>
>     Barry
>
>
>
> sh: gcc -c -o conftest.o  -Wall -Wwrite-strings -Wno-strict-aliasing -g3
>  conftest.c
> Executing: gcc -c -o conftest.o  -Wall -Wwrite-strings -Wno-strict-aliasing
> -g3  conftest.c
> sh:
> Possible ERROR while running compiler: error message = {conftest.c: In
> function 'main':
> conftest.c:6: warning: implicit declaration of function 'isinf'
> conftest.c:6: warning: unused variable 'a'
> }
> Source:
> #include "confdefs.h"
> #include "conffix.h"
> #include <math.h>
>
> int main() {
> double b = 2.0; int a = isinf(b);
> ;
>  return 0;
> }
>                Pushing language C
>                Popping language C
> sh: gcc  -o conftest    -Wall -Wwrite-strings -Wno-strict-aliasing -g3
>  conftest.o -L/opt/local/lib/gcc/sparc-sun-solaris2.10/4.4.1
> -L/opt/local/lib/gcc -L/usr/ccs/lib -L/opt/local/lib -ldl -lgcc_eh -ldl
>  -lsocket -lnsl
> Executing: gcc  -o conftest    -Wall -Wwrite-strings -Wno-strict-aliasing
> -g3  conftest.o -L/opt/local/lib/gcc/sparc-sun-solaris2.10/4.4.1
> -L/opt/local/lib/gcc -L/usr/ccs/lib -L/opt/local/lib -ldl -lgcc_eh -ldl
>  -lsocket -lnsl
> sh:
>        Defined "HAVE_ISINF" to "1"
>
>


-- 
What most experimenters take for granted before they begin their experiments
is infinitely more interesting than any results to which their experiments
lead.
-- Norbert Wiener
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20110422/80fef445/attachment.html>


More information about the petsc-dev mailing list