ports/120033: [PATCH] print/magicfilter: Use sysutils/file if it exists

Rong-En Fan rafan at FreeBSD.org
Sun Jan 27 10:40:02 UTC 2008


>Number:         120033
>Category:       ports
>Synopsis:       [PATCH] print/magicfilter: Use sysutils/file if it exists
>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:   Sun Jan 27 10:40:01 UTC 2008
>Closed-Date:
>Last-Modified:
>Originator:     Rong-En Fan
>Release:        FreeBSD 6.3-PRERELEASE amd64
>Organization:
NTU CSIE
>Environment:
>Description:
In ports/96495, I make this port depends on sysutils/file unconditionally
as at that time our libmagic in base is too old. However, the situation
changes now, our libmagic in 6.x to 8.x are new enough. And, with
unknown reason that with new X11BASE=LOCALBASE environment, magicfilter
can not correctly recognize file format when linking to sysutils/file.
So I think it's better to make magicfilter uses sysutils/file only if
it's installed.

Port maintainer (cjh at FreeBSD.org) is cc'd.

Generated with FreeBSD Port Tools 0.77
>How-To-Repeat:
>Fix:

--- magicfilter-2.3.h_2.patch begins here ---
Index: Makefile
===================================================================
RCS file: /home/ncvs/ports/print/magicfilter/Makefile,v
retrieving revision 1.18
diff -u -u -r1.18 Makefile
--- Makefile	24 Sep 2007 08:39:23 -0000	1.18
+++ Makefile	27 Jan 2008 10:06:04 -0000
@@ -7,17 +7,13 @@
 
 PORTNAME=	magicfilter
 PORTVERSION=	2.3.h
-PORTREVISION=	1
-PORREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	print
 MASTER_SITES=	http://www.pell.portland.or.us/~orc/Code/magicfilter/
 
 MAINTAINER=	cjh at FreeBSD.org
 COMMENT=	Customizable, extensible automatic printer filter
 
-BUILD_DEPENDS=	${LOCALBASE}/lib/libmagic.so:${PORTSDIR}/sysutils/file
-RUN_DEPENDS=	${BUILD_DEPENDS}
-
 USE_GHOSTSCRIPT=	yes
 
 GNU_CONFIGURE=	yes
@@ -30,4 +26,11 @@
 MAN5=		magicfilter.5
 MAN8=		magicfilter.8
 
-.include <bsd.port.mk>
+.include <bsd.port.pre.mk>
+
+.if exists(${LOCALBASE}/lib/libmagic.so)
+BUILD_DEPENDS+=	${LOCALBASE}/lib/libmagic.so:${PORTSDIR}/sysutils/file
+RUN_DEPENDS+=	${BUILD_DEPENDS}
+.endif
+
+.include <bsd.port.post.mk>
--- magicfilter-2.3.h_2.patch ends here ---

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



More information about the freebsd-ports-bugs mailing list