From owner-freebsd-ports-bugs@FreeBSD.ORG Mon Apr 24 18:20:29 2006 Return-Path: X-Original-To: freebsd-ports-bugs@hub.freebsd.org Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 89D8516A404 for ; Mon, 24 Apr 2006 18:20:29 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 82D6343D8F for ; Mon, 24 Apr 2006 18:20:19 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.4/8.13.4) with ESMTP id k3OIKJr7068052 for ; Mon, 24 Apr 2006 18:20:19 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.4/8.13.4/Submit) id k3OIKIsx068051; Mon, 24 Apr 2006 18:20:18 GMT (envelope-from gnats) Resent-Date: Mon, 24 Apr 2006 18:20:18 GMT Resent-Message-Id: <200604241820.k3OIKIsx068051@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Wesley Shields Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 698AF16A40D for ; Mon, 24 Apr 2006 18:17:49 +0000 (UTC) (envelope-from wxs@syn.csh.rit.edu) Received: from syn.csh.rit.edu (syn.csh.rit.edu [129.21.60.158]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4E57743D81 for ; Mon, 24 Apr 2006 18:17:41 +0000 (GMT) (envelope-from wxs@syn.csh.rit.edu) Received: from syn.csh.rit.edu (localhost [127.0.0.1]) by syn.csh.rit.edu (8.13.4/8.13.4) with ESMTP id k3OJLZPB033695 for ; Mon, 24 Apr 2006 14:21:35 -0500 (EST) (envelope-from wxs@syn.csh.rit.edu) Received: (from wxs@localhost) by syn.csh.rit.edu (8.13.4/8.13.4/Submit) id k3OJLZod033687; Mon, 24 Apr 2006 14:21:35 -0500 (EST) (envelope-from wxs) Message-Id: <200604241921.k3OJLZod033687@syn.csh.rit.edu> Date: Mon, 24 Apr 2006 14:21:35 -0500 (EST) From: Wesley Shields To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: Subject: ports/96273: [MAINTAINER]: Unbreak net/bittwist on 5.x. X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Wesley Shields List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 24 Apr 2006 18:20:29 -0000 >Number: 96273 >Category: ports >Synopsis: [MAINTAINER]: Unbreak net/bittwist on 5.x. >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: maintainer-update >Submitter-Id: current-users >Arrival-Date: Mon Apr 24 18:20:18 GMT 2006 >Closed-Date: >Last-Modified: >Originator: Wesley Shields >Release: FreeBSD 6.0-RELEASE-p2 i386 >Organization: >Environment: System: FreeBSD syn 6.0-RELEASE-p2 FreeBSD 6.0-RELEASE-p2 #1: Wed Jan 11 11:57:33 EST 2006 root@syn:/usr/obj/usr/src/sys/GENERIC i386 >Description: net/bittwist uses round() which is only available in 5.3 and higher. It also depends upon a relatively recent version of libpcap which only exists in the base of 6.0 and up[1]. The attached patch marks it as broken on 5.2 and lower, and depends on net/libpcap for 5.3 up to 6.0. While I'm here it also incorporates a patch to fix up the hardcoding of CFLAGS and CC in the port's Makefile[2]. I guess this will teach me to keep a 5.x VM handy. :( [1]: Pointed out to me by Kris Kennaway via pointyhat. [2]: Pointed out to me by Kris Kennaway. >How-To-Repeat: N/A >Fix: diff -ruN net/bittwist.orig/Makefile net/bittwist/Makefile --- net/bittwist.orig/Makefile Mon Apr 24 14:05:44 2006 +++ net/bittwist/Makefile Mon Apr 24 13:37:54 2006 @@ -21,8 +21,15 @@ .include -.if ${OSVERSION} < 500000 -IGNORE= does not build under 4.x +# 5.3 is the first version to have round(). +.if ${OSVERSION} < 503001 +IGNORE= does not build under 5.2 and older (no round()) +.endif + +# 5.3 and up do not have a new enough libpcap but does have round(). +# 6.0 and up have both a new enough libpcap and round(). +.if ${OSVERSION} >= 503001 && ${OSVERSION} < 600100 +BUILD_DEPENDS= ${LOCALBASE}/lib/libpcap.a:${PORTSDIR}/net/libpcap .endif .include diff -ruN net/bittwist.orig/files/patch-Makefile net/bittwist/files/patch-Makefile --- net/bittwist.orig/files/patch-Makefile Thu Jan 1 00:00:00 1970 +++ net/bittwist/files/patch-Makefile Mon Apr 24 11:43:19 2006 @@ -0,0 +1,16 @@ +--- Makefile.orig Mon Apr 24 11:41:57 2006 ++++ Makefile Mon Apr 24 11:42:54 2006 +@@ -5,10 +5,11 @@ + bindir = ${exec_prefix}/bin + mandir = ${prefix}/man/man1 + +-CC = gcc ++CC ?= gcc + DEBUG = -g + #CFLAGS = -O2 -Wall $(DEBUG) +-CFLAGS = -O2 $(DEBUG) ++CFLAGS ?= -O2 ++CFLAGS += ${DEBUG} + SRC = src + DOC = doc + >Release-Note: >Audit-Trail: >Unformatted: