ports/118070: [PATCH] comms/gnokii: Fix detection of devel/libusb

Mario Sergio Fujikawa Ferreira lioux at FreeBSD.org
Thu Nov 15 12:40:02 UTC 2007


>Number:         118070
>Category:       ports
>Synopsis:       [PATCH] comms/gnokii: Fix detection of devel/libusb
>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 Nov 15 12:40:00 UTC 2007
>Closed-Date:
>Last-Modified:
>Originator:     Mario Sergio Fujikawa Ferreira
>Release:        FreeBSD 7.0-BETA2 i386
>Organization:
>Environment:
System: FreeBSD nexxus.fedaykin.here 7.0-BETA2 FreeBSD 7.0-BETA2 #5: Thu Nov  8 23:44:48 BRST
>Description:
Port maintainer (mad at madpilot.net) is cc'd.

The attached patch fixes the port configure script so that it
correctly detects libusb. Furthermore, a WITH_LIBUSB knob has been
added.

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

--- gnokii-0.6.18,1.patch begins here ---
diff -ruN --exclude=CVS /usr/ports/comms/gnokii/Makefile gnokii/Makefile
--- /usr/ports/comms/gnokii/Makefile	2007-07-27 07:49:20.000000000 -0300
+++ gnokii/Makefile	2007-11-14 17:50:27.000000000 -0200
@@ -46,10 +46,22 @@
 WITH_ICAL=	yes
 .endif
 
+.if exists(${LOCALBASE}/lib/libusb.so)
+WITH_LIBUSB=	yes
+.endif
+
 .if defined(WITH_ICAL)
 LIB_DEPENDS+=	ical.0:${PORTSDIR}/devel/libical
 .endif
 
+.if defined(WITH_LIBUSB)
+LIB_DEPENDS+=	usb:${PORTSDIR}/devel/libusb
+
+CONFIGURE_ARGS+=	--enable-libusb
+.else
+CONFIGURE_ARGS+=	--disable-libusb
+.endif
+
 # If smsd is enabled check if MySQL or PostgreSQL are installed and
 # build the modules, no switches to make this port build those, if
 # you want them, just install them before this port. The port will
@@ -133,6 +145,10 @@
 .if defined(SMSD_WITH_GLIB1)
 	@cd ${WRKSRC} && ${PATCH} -s <${PATCHDIR}/smsd-Makefile-WITH_GLIB.diff
 .endif
+# fix test conditions on configure
+	@${REINPLACE_CMD} -E \
+		-e 's|([[:space:]]+test[[:space:]]+.+)==([[:space:]]+"yes")|\1=\2|' \
+		${WRKSRC}/${CONFIGURE_SCRIPT}
 
 post-build:
 .if defined(WITH_SMSD)
--- gnokii-0.6.18,1.patch ends here ---

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



More information about the freebsd-ports-bugs mailing list