A problem with ptrdiff_t

William Gropp gropp at mcs.anl.gov
Wed Dec 13 08:24:13 CST 2006


That helped with that problem but introduced another one:


cd lib && make
/Users/gropp/tmp/mpi2-inst/bin/mpicc -c -g -O2 -I.    mpinetcdf.c
mpinetcdf.c:7802: warning: no previous prototype for 'ncmpii_postwrite'
mpinetcdf.c:7819: warning: no previous prototype for 'ncmpii_postread'
mpinetcdf.c:7860: warning: no previous prototype for 'ncmpii_postmwrite'
mpinetcdf.c:7877: warning: no previous prototype for 'ncmpii_postmread'
mpinetcdf.c:7901: warning: no previous prototype for  
'ncmpii_postprocess'
mpinetcdf.c: In function 'ncmpi_iput_var1':
mpinetcdf.c:8210: warning: unused variable 'mpistatus'
/Users/gropp/tmp/mpi2-inst/bin/mpicc -c -g -O2 -I.    header.c
/Users/gropp/tmp/mpi2-inst/bin/mpicc -c -g -O2 -I.    mpincio.c
In file included from nc.h:13,
                  from mpincio.c:27:
/usr/lib/gcc/i686-apple-darwin8/4.0.1/include/stddef.h:152: error:  
two or more data types in declaration specifiers
mpincio.c: In function 'ncmpiio_free':
mpincio.c:60: warning: implicit declaration of function 'free'
mpincio.c: In function 'ncmpiio_new':
mpincio.c:70: warning: implicit declaration of function 'malloc'
mpincio.c:70: warning: incompatible implicit declaration of built-in  
function 'malloc'
mpincio.c: In function 'ncmpiio_move':
mpincio.c:270: warning: incompatible implicit declaration of built-in  
function 'malloc'
make[3]: *** [mpincio.o] Error 1
make[2]: *** [all] Error 2
make[1]: *** [subdir_target] Error 1
make: *** [src/lib/all] Error 2
groppmac:~/projects/software/parallel-netcdf gropp$

Bill

On Dec 13, 2006, at 12:38 AM, Robert Latham wrote:

>
>> The offending line in stddef is a typedef for ptrdiff_t ; there must
>> be conflicting definitions in the ncconfig.h file .
>
> There sure is.  You found and diagnosed this earlier this year :>
> http://www.mcs.anl.gov/web-mail-archive/lists/parallel-netcdf/ 
> 2006/06/msg00010.html
>
> Unfortunately, two-argument AC_CHECK_TYPE is deprecated:
> http://www.gnu.org/software/autoconf/manual/html_node/Obsolete- 
> Macros.html
> and while Autoconf 2.59 has been out for quite some time, I'm still
> nervous about adding AC_CHECK_TYPES and the corresponding
> AC_PREREQ(2.59) to our configure.in
>
> In any case, I think I fixed this by taking the easy way out and
> including <stddef.h> before ncconfig.h. I don't have asccess to an os
> x box right now. Please try CVS now and see if it fixed the problem.
>
> ==rob
>
> -- 
> Rob Latham
> Mathematics and Computer Science Division    A215 0178 EA2D B059 8CDF
> Argonne National Lab, IL USA                 B29D F333 664A 4280 315B
>




More information about the parallel-netcdf mailing list