[Gdal-dev] swig/perl CVS compile issue

Ethan Alpert ealpert at digitalglobe.com
Tue Oct 31 11:06:20 EST 2006

Ari, et al,

I downloaded the CVS version of gdal yesterday and got a compile error
in the swig perl directory. The problem is with gdalconst_wrap.c . Since
it's a .c and not a .cpp it is compiled with gcc (I'm using version gcc
3.2.3 and perl 5.8.0). When I manually compile with g++ I get no errors.

Below is the error:

gcc -c  -I../../gcore -I../../alg -I../../ogr -I../../port -fpic -O2 -g
-pipe -march=i386 -mcpu=i686   -DVERSION=\"\" -DXS_VERSION=\"\" -fPIC
"-I/usr/lib/perl5/5.8.0/i386-linux-thread-multi/CORE"   gdalconst_wrap.c
In file included from
                 from gdalconst_wrap.c:705:
/usr/lib/perl5/5.8.0/i386-linux-thread-multi/CORE/reentr.h:602: field
`_crypt_struct' has incomplete type
/usr/lib/perl5/5.8.0/i386-linux-thread-multi/CORE/reentr.h:747: confused
by earlier errors, bailing out
make[1]: *** [gdalconst_wrap.o] Error 1
make[1]: Leaving directory
make: *** [build] Error 2

Compiling with g++ creates the .o successfully:

-bash-2.05b$ g++ -c  -I../../gcore -I../../alg -I../../ogr -I../../port
-fpic -O2 -g -pipe -march=i386 -mcpu=i686   -DVERSION=\"\"
"-I/usr/lib/perl5/5.8.0/i386-linux-thread-multi/CORE"   gdalconst_wrap.c

More information about the Gdal-dev mailing list