aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authoryuri <yuri@FreeBSD.org>2018-11-08 16:54:36 +0800
committeryuri <yuri@FreeBSD.org>2018-11-08 16:54:36 +0800
commitf1616df970e5264a9fb0aa64b5502c05d896a996 (patch)
tree3feef5f7ef0900a9a673bc8282f6fb3637030299 /net
parentf75103cf0bf593449b82c94e0ed8fcca5964cc9e (diff)
downloadfreebsd-ports-gnome-f1616df970e5264a9fb0aa64b5502c05d896a996.tar.gz
freebsd-ports-gnome-f1616df970e5264a9fb0aa64b5502c05d896a996.tar.zst
freebsd-ports-gnome-f1616df970e5264a9fb0aa64b5502c05d896a996.zip
net/libfabric: Add port options for individual providers; Enclose the VERBS option in .if/.else
Requested by: mat (VERBS option .if/.else enclosure)
Diffstat (limited to 'net')
-rw-r--r--net/libfabric/Makefile23
-rw-r--r--net/libfabric/pkg-plist7
2 files changed, 17 insertions, 13 deletions
diff --git a/net/libfabric/Makefile b/net/libfabric/Makefile
index b38adf524014..6f2e92ded33d 100644
--- a/net/libfabric/Makefile
+++ b/net/libfabric/Makefile
@@ -3,6 +3,7 @@
PORTNAME= libfabric
DISTVERSIONPREFIX= v
DISTVERSION= 1.6.2
+PORTREVISION= 1
CATEGORIES= net
MAINTAINER= yuri@FreeBSD.org
@@ -21,20 +22,24 @@ CONFIGURE_ARGS= --disable-static
USE_LDCONFIG= yes
CFLAGS+= -I${LOCALBASE}/include/libepoll-shim
-LDFLAGS+= ${LOCALBASE}/lib/libepoll-shim.so -pthread
+LDFLAGS+= ${LOCALBASE}/lib/libepoll-shim.so
-OPTIONS_DEFINE= VERBS
-OPTIONS_SUB= yes
-
-VERBS_DESC= Build 'verbs' provider
-VERBS_CONFIGURE_ENABLE= verbs
+OPTIONS_MULTI= PROVIDERS
+OPTIONS_MULTI_PROVIDERS= RXD RXM SOCKETS TCP UDP
+OPTIONS_DEFAULT= ${OPTIONS_MULTI_PROVIDERS}
+OPTIONS_SUB= yes
+PROVIDERS_DESC= Providers to build:
.if exists(/usr/include/infiniband/verbs.h) # some earlier FreeBSD 11 systems don't have it
-OPTIONS_DEFAULT+= VERBS
-.else
-VERBS_BROKEN= infiniband/verbs.h not available on your system
+OPTIONS_MULTI_PROVIDERS+= VERBS
+VERBS_PLIST_FILES= man/man7/fi_verbs.7.gz
.endif
+.for p in ${OPTIONS_MULTI_PROVIDERS}
+${p}_DESC= '${p:tl}' provider
+${p}_CONFIGURE_ENABLE= ${p:tl}
+.endfor
+
post-patch:
@${FIND} ${WRKSRC} -name "*.[ch]" -and -exec ${GREP} -q '<asm/types\.h>' {} \; -print | ${XARGS} ${REINPLACE_CMD} 's|<asm/types\.h>|<sys/types.h>|'
@${FIND} ${WRKSRC} -name "*.[ch]" -and -exec ${GREP} -q '<malloc\.h>' {} \; -print | ${XARGS} ${REINPLACE_CMD} 's|<malloc\.h>|<stdlib.h>|'
diff --git a/net/libfabric/pkg-plist b/net/libfabric/pkg-plist
index 006d1c0e3631..63eb4dd3afc9 100644
--- a/net/libfabric/pkg-plist
+++ b/net/libfabric/pkg-plist
@@ -149,7 +149,6 @@ man/man3/fi_writev.3.gz
man/man7/fabric.7.gz
man/man7/fi_direct.7.gz
man/man7/fi_provider.7.gz
-man/man7/fi_rxm.7.gz
-man/man7/fi_sockets.7.gz
-man/man7/fi_udp.7.gz
-%%VERBS%%man/man7/fi_verbs.7.gz
+%%RXM%%man/man7/fi_rxm.7.gz
+%%SOCKETS%%man/man7/fi_sockets.7.gz
+%%UDP%%man/man7/fi_udp.7.gz