bind-9.11.0-P1 "db.c", line 771: error: syntax error before or at: )

Dennis Clarke dclarke at blastwave.org
Fri Nov 4 05:43:44 UTC 2016


During a compile in the same way as I have always done I was surprised 
to see :

.
.
.
/opt/developerstudio12.5/bin/cc -mt 
-I/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001 -I../../../.. 
-I/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/lib/dns/include 
-I../../../../lib/dns/include 
-I/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/lib/isc/include 
-I../../../../lib/isc -I../../../../lib/isc/include 
-I../../../../lib/isc/unix/include 
-I../../../../lib/isc/pthreads/include 
-I../../../../lib/isc/noatomic/include  -D_REENTRANT -D_LARGEFILE_SOURCE 
-D_FILE_OFFSET_BITS=64  -D_TS_ERRNO -D_POSIX_PTHREAD_SEMANTICS 
-D_LARGEFILE64_SOURCE -DDIG_SIGCHASE=1 -D_XPG4_2 -D__EXTENSIONS__ -m64 
-errfmt=error -erroff=%none -errshort=full -xstrconst -xildoff 
-xmemalign=8s -xnolibmil -Xc -xcode=pic32 -xregs=no%appl -xlibmieee -mc 
-g -xs -ftrap=%none -Qy -xbuiltin=%none -xdebugformat=dwarf -xunroll=1 
-I/usr/local/include -xtarget=ultraT2 -xcache=8/16/4:4096/64/16 
-I/usr/local/ssl/include -I/usr/local/ssl -D_TS_ERRNO 
-D_POSIX_PTHREAD_SEMANTICS -D_LARGEFILE64_SOURCE 
-I/usr/local/include/libxml2 -I/usr/local/include -I /usr/local/include 
-KPIC -KPIC    -c driver.c
"/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/lib/dns/include/dns/rrl.h", 
line 90: warning: nonportable bit-field type
"/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/lib/dns/include/dns/rrl.h", 
line 91: warning: nonportable bit-field type
"/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/lib/dns/include/dns/rrl.h", 
line 115: warning: nonportable bit-field type
"/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/lib/dns/include/dns/rrl.h", 
line 118: warning: nonportable bit-field type
ld -G -z text -o driver.so driver.o
gmake[4]: Leaving directory 
`/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/bin/tests/system/dlzexternal'
making all in 
/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/bin/tests/system/dyndb
gmake[4]: Entering directory 
`/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/bin/tests/system/dyndb'
making all in 
/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/bin/tests/system/dyndb/driver
gmake[5]: Entering directory 
`/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/bin/tests/system/dyndb/driver'
/opt/developerstudio12.5/bin/cc -mt 
-I/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001 -I../../../../.. 
-I/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/lib/dns/include 
-I../../../../../lib/dns/include 
-I/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/lib/isc/include 
-I../../../../../lib/isc -I../../../../../lib/isc/include 
-I../../../../../lib/isc/unix/include 
-I../../../../../lib/isc/pthreads/include 
-I../../../../../lib/isc/noatomic/include  -D_REENTRANT 
-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64  -D_TS_ERRNO 
-D_POSIX_PTHREAD_SEMANTICS -D_LARGEFILE64_SOURCE -DDIG_SIGCHASE=1 
-D_XPG4_2 -D__EXTENSIONS__ -m64 -errfmt=error -erroff=%none 
-errshort=full -xstrconst -xildoff -xmemalign=8s -xnolibmil -Xc 
-xcode=pic32 -xregs=no%appl -xlibmieee -mc -g -xs -ftrap=%none -Qy 
-xbuiltin=%none -xdebugformat=dwarf -xunroll=1 -I/usr/local/include 
-xtarget=ultraT2 -xcache=8/16/4:4096/64/16 -I/usr/local/ssl/include 
-I/usr/local/ssl -D_TS_ERRNO -D_POSIX_PTHREAD_SEMANTICS 
-D_LARGEFILE64_SOURCE -I/usr/local/include/libxml2 -I/usr/local/include 
-I /usr/local/include -KPIC -KPIC    -c db.c
"db.c", line 110: warning: statement not reached
"db.c", line 126: warning: statement not reached
"db.c", line 151: warning: statement not reached
"db.c", line 771: warning: argument mismatch
"db.c", line 771: error: syntax error before or at: )
cc: acomp failed for db.c
gmake[5]: *** [db.o] Error 2
gmake[5]: Leaving directory 
`/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/bin/tests/system/dyndb/driver'
gmake[4]: *** [subdirs] Error 1
gmake[4]: Leaving directory 
`/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/bin/tests/system/dyndb'
gmake[3]: *** [subdirs] Error 1
gmake[3]: Leaving directory 
`/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/bin/tests/system'
gmake[2]: *** [subdirs] Error 1
gmake[2]: Leaving directory 
`/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/bin/tests'
gmake[1]: *** [subdirs] Error 1
gmake[1]: Leaving directory 
`/usr/local/build/bind-9.11.0-P1_SunOS5.10_sparcv9.001/bin'
gmake: *** [subdirs] Error 1


This is a run of the mill compile with the latest bind release on
Solaris 10 with the Oracle Studio 12.5 compilers.

Taking a glance at the trouble :

$ cat -n ./bin/tests/system/dyndb/driver/db.c | head -780 | tail -20
    761          REQUIRE(rdclass == dns_rdataclass_in);
    762          REQUIRE(argc == 0);
    763          REQUIRE(argv != NULL);
    764          REQUIRE(driverarg != NULL); /* pointer to driver 
instance */
    765          REQUIRE(dbp != NULL && *dbp == NULL);
    766
    767          UNUSED(driverarg); /* no driver-specific configuration */
    768
    769          a_addr.s_addr = 0x0100007fU;
    770
    771          CHECKED_MEM_GET_PTR(mctx, sampledb);
    772          ZERO_PTR(sampledb);
    773
    774          isc_mem_attach(mctx, &sampledb->common.mctx);
    775          dns_name_init(&sampledb->common.origin, NULL);
    776          isc_ondestroy_init(&sampledb->common.ondest);
    777
    778          sampledb->common.magic = DNS_DB_MAGIC;
    779          sampledb->common.impmagic = SAMPLEDB_MAGIC;
    780


So nothing obvious however perhaps the argument mismatch is the issue.

The CFLAGS above are set for strict C99 compliance :

$ echo $CFLAGS
-m64 -errfmt=error -erroff=%none -errshort=full -xstrconst -xildoff 
-xmemalign=8s -xnolibmil -Xc -xcode=pic32 -xregs=no%appl -xlibmieee -mc 
-g -xs -ftrap=%none -Qy -xbuiltin=%none -xdebugformat=dwarf -xunroll=1 
-I/usr/local/include -I/usr/local/ssl/include -I/usr/local/ssl 
-D_TS_ERRNO -D_POSIX_PTHREAD_SEMANTICS -D_LARGEFILE64_SOURCE


Perhaps strict C99 compliance is the issue ?

Dennis


More information about the bind-users mailing list