I'm very, very sorry. But it seems that #define __darwin_size_t size_t
did not fix the problem. In my attempts, I tried to inline the macros,
but it seems that what actually enabled it to compile was commenting
out that line, without restoring it to the original state. Please
forgive me.
The output of: g++ -E src/ipc/TypedMsgHdr.h
struct CtrlBuffer {
# 107 "src/ipc/TypedMsgHdr.h"
char raw[CMSG_SPACE(sizeof(int))];
} ctrl;
If I add this line:
#include <netinet/in.h>
the output is:
struct CtrlBuffer {
# 107 "src/ipc/TypedMsgHdr.h"
char raw[(((__darwin_size_t)((char *)(sizeof(struct cmsghdr)) +
(sizeof(__darwin_size_t) - 1)) &~ (sizeof(__darwin_size_t) - 1)) +
((__darwin_size_t)((char *)(sizeof(int)) + (sizeof(__darwin_size_t) -
1)) &~ (sizeof(__darwin_size_t) - 1)))];
} ctrl;
and the result of make is:
Making all in ipc
/bin/sh ../../libtool --tag=CXX --mode=compile g++ -DHAVE_CONFIG_H
-DDEFAULT_STATEDIR=\"/usr/local/squid/var/run/squid\" -I../..
-I../../include -I../../lib -I../../src -I../../include
-I../../libltdl -Wall -Wpointer-arith -Wwrite-strings -Wcomments
-Werror -pipe -D_REENTRANT -g -O2 -MT StrandCoord.lo -MD -MP -MF
.deps/StrandCoord.Tpo -c -o StrandCoord.lo StrandCoord.cc
libtool: compile: g++ -DHAVE_CONFIG_H
-DDEFAULT_STATEDIR=\"/usr/local/squid/var/run/squid\" -I../..
-I../../include -I../../lib -I../../src -I../../include
-I../../libltdl -Wall -Wpointer-arith -Wwrite-strings -Wcomments
-Werror -pipe -D_REENTRANT -g -O2 -MT StrandCoord.lo -MD -MP -MF
.deps/StrandCoord.Tpo -c StrandCoord.cc -fno-common -DPIC -o
.libs/StrandCoord.o
../../src/ipc/TypedMsgHdr.h:108: error: array bound is not an integer constant
make[3]: *** [StrandCoord.lo] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all] Error 2
make: *** [all-recursive] Error 1
Received on Tue Apr 03 2012 - 22:53:22 MDT
This archive was generated by hypermail 2.2.0 : Wed Apr 04 2012 - 12:00:04 MDT