[cups.development] Problem building 1.2.0 on Solaris 10/SPARC
Albert Chin
cups-dev at mlists.thewrittenword.com
Fri May 12 11:01:52 PDT 2006
I'm running into the following build error with cups-1.2.0 on Solaris
20/SPARC:
$ gtar jxf cups-1.2.0-source.tar.bz2
$ cd cups-1.2.0
$ ./configure
$ gmake
...
Compiling snmp.c...
"snmp.c", line 1379: improper member use: ifa_ifu
"snmp.c", line 1379: operands must have scalar type: op "&&"
"snmp.c", line 1380: improper member use: ifa_ifu
"snmp.c", line 1380: left operand of "->" must be pointer to struct/union
"snmp.c", line 1385: improper member use: ifa_ifu
"snmp.c", line 1386: argument #2 is incompatible with prototype:
prototype: pointer to const void : "/usr/include/iso/string_iso.h", line 60
argument : struct sockaddr {unsigned short sa_family, array[14] of char sa_data}
cc: acomp failed for snmp.c
gmake[1]: *** [snmp.o] Error 2
<net/if.h> has:
struct ifaddr {
struct sockaddr ifa_addr; /* address of interface */
union {
struct sockaddr ifu_broadaddr;
struct sockaddr ifu_dstaddr;
} ifa_ifu;
#define ifa_broadaddr ifa_ifu.ifu_broadaddr /* broadcast address */
#define ifa_dstaddr ifa_ifu.ifu_dstaddr /* other end of p-to-p link */
struct ifnet *ifa_ifp; /* back-pointer to interface */
struct ifaddr *ifa_next; /* next address for interface */
};
If a platform does not have getifaddrs(), a custom struct in
cups/http-private.h is used. However, this custom struct does not
define a ifa_broadaddr member.
Shouldn't the custom ifaddrs struct in cups/http-private.h have:
union {
struct sockaddr *ifu_broadaddr;
struct sockaddr *ifu_dstaddr;
} ifa_ifu;
--
albert chin (china at thewrittenword.com)
More information about the cups-devel
mailing list