Subject: Re: Building pkgsrc ttcp on Mac OS X
To: None <maccult@pacbell.net>
From: Yuji Yamano <yyamano@kt.rim.or.jp>
List: tech-pkg
Date: 01/05/2003 23:01:46
Randy Beaudreault <maccult@pacbell.net> writes:

> In attempting to build pkgsrc ttcp on my OS X box, I ran into this issue:
> ===> Building for ttcp-1.12
> cc -pipe -g  -Werror  -no-cpp-precomp -c ttcp.c
> ttcp.c: In function `main':
> ttcp.c:155: `in_addr_t' undeclared (first use in this function)

Could you try the following patch? 

Index: Makefile
===================================================================
RCS file: /cvsroot/pkgsrc/benchmarks/ttcp/Makefile,v
retrieving revision 1.2
diff -u -u -r1.2 Makefile
--- Makefile	2001/04/19 13:01:59	1.2
+++ Makefile	2003/01/05 12:43:03
@@ -15,6 +15,10 @@
 MANCOMPRESSED_IF_MANZ=	YES
 WRKSRC=			${WRKDIR}
 
+.if (${OPSYS} == Darwin)
+MAKE_FLAGS=	CFLAGS="-Din_addr_t=\"unsigned long\""
+.endif
+
 .if (${OPSYS} == SunOS)
 do-build:
 	cd ${WRKSRC} && \

-- 
Yuji Yamano <yyamano@kt.rim.or.jp>
    Exterminate the sage, discard the wise, 
    and the people will benefit a hundredfold. --Lao Tzu