Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 27 Apr 2006 11:44:38 +0900
From:      Tod McQuillin <devin@spamcop.net>
To:        FreeBSD-gnats-submit@FreeBSD.org
Cc:        obrien@FreeBSD.org
Subject:   ports/96389: [PATCH] sysutils/lsof: [Fix build on FreeBSD 4.x]
Message-ID:  <E1FYwUg-0006iH-09@mail.distalzou.net>
Resent-Message-ID: <200604270250.k3R2oDNr002177@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         96389
>Category:       ports
>Synopsis:       [PATCH] sysutils/lsof: [Fix build on FreeBSD 4.x]
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Thu Apr 27 02:50:12 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     Tod McQuillin
>Release:        FreeBSD 4.11-STABLE i386
>Organization:
>Environment:
System: FreeBSD plexi.pun-pun.prv 4.11-STABLE FreeBSD 4.11-STABLE #0: Thu Mar 23 21:52:12 JST 2006
>Description:
On FreeBSD 4.x, grep is GNU grep version 2.4d which does not know
about the -m option.  This causes the build to fail as follows:

/usr/ports/sysutils/lsof# make
===>  Extracting for lsof-4.77
=> MD5 Checksum OK for lsof_4.77.tar.bz2.
/usr/bin/grep: invalid option -- m
Usage: grep [OPTION]... PATTERN [FILE]...
Try `grep --help' for more information.
Expected and calculated MD5 signatures don't agree.
( != MD5 (lsof_4.77_src.tar) = 42d3927386adb1e1871b97a286fa00d2)
*** Error code 1

Stop in /usr/src/ports/sysutils/lsof.

This is fixed by replacing '-m 1' with '| head -1'.

Port maintainer (obrien@FreeBSD.org) is cc'd.

Generated with FreeBSD Port Tools 0.63
>How-To-Repeat:
Try to build on FreeBSD 4.x

>Fix:

--- lsof-4.77.patch begins here ---
Index: Makefile
===================================================================
RCS file: /usr/src/cvs-repo/ports/sysutils/lsof/Makefile,v
retrieving revision 1.147
diff -u -u -r1.147 Makefile
--- Makefile	26 Apr 2006 00:46:59 -0000	1.147
+++ Makefile	27 Apr 2006 02:38:35 -0000
@@ -51,7 +51,7 @@
 .if !defined(FIXUP_RELEASE)
 post-extract:
 	@( cd ${WRKDIR}/${DISTNAME} ; \
-	EXPMD5=`${GREP} -m 1 MD5 README.${DISTNAME} | ${SED} 's/[ 	]*//'` ; \
+	EXPMD5=`${GREP} MD5 README.${DISTNAME} | head -1 | ${SED} 's/[ 	]*//'` ; \
 	CALCMD5=`${MD5} ${SRCBALL_NAME}.tar` ; \
 	if [ "$${EXPMD5}"X != "$${CALCMD5}"X ]; then \
 		${ECHO} "Expected and calculated MD5 signatures don't agree." ; \
--- lsof-4.77.patch ends here ---

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E1FYwUg-0006iH-09>