git: cb4b4bccc6cc - main - devel/openocd: Fix libusb for libjaylink

From: Joel Bodenmann <jbo_at_FreeBSD.org>
Date: Mon, 08 Apr 2024 12:35:50 UTC
The branch main has been updated by jbo:

URL: https://cgit.FreeBSD.org/ports/commit/?id=cb4b4bccc6cc654a846356e8854f615b364f37d7

commit cb4b4bccc6cc654a846356e8854f615b364f37d7
Author:     Joel Bodenmann <jbo@FreeBSD.org>
AuthorDate: 2024-04-08 12:32:41 +0000
Commit:     Joel Bodenmann <jbo@FreeBSD.org>
CommitDate: 2024-04-08 12:35:18 +0000

    devel/openocd: Fix libusb for libjaylink
    
    We're using OpenOCD's internal redistribution of libjaylink which
    requires libusb >= 1.0.16.
    
    PR:             277688
    Approved by:    tcberner (mentor, implicit)
---
 devel/openocd/Makefile | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/devel/openocd/Makefile b/devel/openocd/Makefile
index cc2e2184e4ce..76b3874dbf24 100644
--- a/devel/openocd/Makefile
+++ b/devel/openocd/Makefile
@@ -1,6 +1,6 @@
 PORTNAME=	openocd
 DISTVERSION=	0.12.0
-PORTREVISION=	2
+PORTREVISION=	3
 CATEGORIES=	devel
 MASTER_SITES=	SF
 
@@ -20,6 +20,9 @@ USES=		gmake libtool makeinfo pkgconfig tar:bzip2
 GNU_CONFIGURE=	yes
 GNU_CONFIGURE_MANPREFIX=	${PREFIX}/share
 
+# Required to make OpenOCD's internal libjaylink work
+CONFIGURE_ENV+=	libusb_CFLAGS=" " libusb_LIBS="-lusb"
+
 CFLAGS+=	-Wno-error=strict-prototypes \
 		-Wno-error=unused-but-set-parameter \
 		-Wno-error=unused-but-set-variable \