From owner-freebsd-ports Wed Mar 5 10:15:33 1997 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.5/8.8.5) id KAA02450 for ports-outgoing; Wed, 5 Mar 1997 10:15:33 -0800 (PST) Received: from alpha.xerox.com (alpha.Xerox.COM [13.1.64.93]) by freefall.freebsd.org (8.8.5/8.8.5) with SMTP id KAA02440 for ; Wed, 5 Mar 1997 10:15:26 -0800 (PST) Received: from fenestro.parc.xerox.com ([13.0.208.199]) by alpha.xerox.com with SMTP id <18655(6)>; Wed, 5 Mar 1997 10:14:28 PST Received: (from fenner@localhost) by fenestro.parc.xerox.com (8.8.4/8.8.4) id JAA15583; Wed, 5 Mar 1997 09:28:08 -0800 (PST) Date: Wed, 5 Mar 1997 09:28:08 PST From: Bill Fenner Message-Id: <199703051728.JAA15583@fenestro.parc.xerox.com> To: ports@freebsd.org Subject: Two Q's: "make depend" and repairing distfile? Cc: fenner@parc.xerox.com Sender: owner-ports@freebsd.org X-Loop: FreeBSD.org Precedence: bulk I'm trying to make a port of "tcptrace", a tcpdump log file analyzer. I'm having two problems: 1. The Makefile as distributed comes with dependencies for Solaris. My first attempt removed the dependencies using patches/patch-aa, but I decided that rebuilding the dependencies made more sense, so I did: DEPEND_TARGET= depend pre-build: @(cd ${WRKSRC}; ${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_FLAGS} ${MAKEFILE} ${DEPEND_TARGET}) Does it make sense to add DEPEND_TARGET to bsd.port.mk and make depend if DEPEND_TARGET is defined? 2. The distribution is from a broken HTTP server, which uncompresses the file before sending it even though it is a .tar.gz, resulting in getting an uncompressed file with the name foo.tar.gz, which bsd.port.mk doesn't like. I wrote the following to recompress it, but it's kind of hokey. Anyone have better ideas? # jarok.cs.ohiou.edu manages to uncompress the file before it transmits it, # even though it returns a content-type of file/gzip. Repair the damage. # # Using "if; then else" because of sh bug in 3.0-current . post-fetch: @(cd ${_DISTDIR}; \ if file ${DISTFILES} | grep -s gzip; then \ else \ echo "re-compressing ${DISTFILES}"; \ mv ${DISTFILES} `basename ${DISTFILES} .gz`; \ gzip `basename ${DISTFILES} .gz`; \ fi) Thanks, Bill