[Gdal-dev] problem compiling png in daily build

Sophia Parafina sophia.parafina at ionicenterprise.com
Wed Sep 12 13:51:05 EDT 2007


Hi,

I'm trying to compile the gdal-svn-trunk-2007.09.12.tar.gz and I get 
these errors while compiling:

gcc -c -DPNG_NO_GLOBAL_ARRAYS -Ilibpng -I../zlib 
-I/home/sparafina/gdal-scripts/unix/build/gdal-svn-trunk-2007.09.12/port 
-I/home/sparafina/gdal-scripts/unix/build/gdal-svn-trunk-2007.09.12/gcore 
-I/home/sparafina/gdal-scripts/unix/build/gdal-svn-trunk-2007.09.12/alg 
-I/home/sparafina/gdal-scripts/unix/build/gdal-svn-trunk-2007.09.12/ogr 
-I/home/sparafina/gdal-scripts/unix/build/gdal-svn-trunk-2007.09.12/ogr/ogrsf_frmts 
-I/home/sparafina/gdal-scripts/unix/install/include 
-I/home/sparafina/gdal-scripts/unix/build/gdal-svn-trunk-2007.09.12/port  
-Wall -Wdeclaration-after-statement -fPIC -O2   libpng/pnggccrd.c -o 
../o/pnggccrd.o
/tmp/ccNcUQGx.s: Assembler messages:
/tmp/ccNcUQGx.s:113: Error: suffix or operands invalid for `push'
/tmp/ccNcUQGx.s:114: Error: suffix or operands invalid for `push'
/tmp/ccNcUQGx.s:115: Error: suffix or operands invalid for `push'
/tmp/ccNcUQGx.s:116: Error: suffix or operands invalid for `pushf'
/tmp/ccNcUQGx.s:117: Error: suffix or operands invalid for `pop'
/tmp/ccNcUQGx.s:120: Error: suffix or operands invalid for `push'
/tmp/ccNcUQGx.s:121: Error: suffix or operands invalid for `popf'
/tmp/ccNcUQGx.s:122: Error: suffix or operands invalid for `pushf'
/tmp/ccNcUQGx.s:123: Error: suffix or operands invalid for `pop'
/tmp/ccNcUQGx.s:124: Error: suffix or operands invalid for `push'
/tmp/ccNcUQGx.s:125: Error: suffix or operands invalid for `popf'
/tmp/ccNcUQGx.s:143: Error: suffix or operands invalid for `pop'
/tmp/ccNcUQGx.s:144: Error: suffix or operands invalid for `pop'
/tmp/ccNcUQGx.s:145: Error: suffix or operands invalid for `pop'
make[3]: *** [../o/pnggccrd.o] Error 1

This seems to be a problem with 64bit gcc on AMD64.  Here is my compiler 
info:

Reading specs from /usr/lib/gcc/x86_64-redhat-linux/3.4.6/specs
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man 
--infodir=/usr/share/info --enable-shared --enable-threads=posix 
--disable-checking --with-system-zlib --enable-__cxa_atexit 
--disable-libunwind-exceptions --enable-java-awt=gtk 
--host=x86_64-redhat-linux
Thread model: posix
gcc version 3.4.6 20060404 (Red Hat 3.4.6-3)

I tried to get around the problem by adding -DPNG_NO_ASSEMBER_CODE to 
the CPPFLAGS in the png make file, but I get this error:

        
-L/home/sparafina/gdal-scripts/unix/build/gdal-svn-trunk-2007.09.12 
-lgdal -I/home/sparafina/gdal-scripts/unix/install/include      -lz  -lm 
-lrt -ldl  -L/home/sparafina/gdal-scripts/unix/install/lib  -L/usr/lib64 
-lcurl -L/usr/kerberos/lib -L/usr/kerberos/lib64 -lssl -lcrypto 
-lgssapi_krb5 -lkrb5 -lcom_err -lk5crypto -lresolv -ldl -lz 
-lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lresolv -L/usr/kerberos/lib 
-L/usr/kerberos/lib64 -lidn -lssl -lcrypto -lssl -lcrypto -lgssapi_krb5 
-lkrb5 -lcom_err -lk5crypto -lresolv -ldl -lz -lz  -o gdalinfo
/home/sparafina/gdal-scripts/unix/build/gdal-svn-trunk-2007.09.12/libgdal.so: 
undefined reference to `DGN2IEEEDouble(void*)'
/home/sparafina/gdal-scripts/unix/build/gdal-svn-trunk-2007.09.12/libgdal.so: 
undefined reference to `AVCBinReadClose'
/home/sparafina/gdal-scripts/unix/build/gdal-svn-trunk-2007.09.12/libgdal.so: 
undefined reference to `AVCBinReadOpen'
/home/sparafina/gdal-scripts/unix/build/gdal-svn-trunk-2007.09.12/libgdal.so: 
undefined reference to `AVCBinReadNextTableRec'
/home/sparafina/gdal-scripts/unix/build/gdal-svn-trunk-2007.09.12/libgdal.so: 
undefined reference to `png_mmx_support'
collect2: ld returned 1 exit status
make[2]: *** [gdalinfo] Error 1


I've compiled 1.4.2 without problems on the same box, so is there 
something different in the daily build?

ophia



More information about the Gdal-dev mailing list