aboutsummaryrefslogtreecommitdiff
path: root/security
diff options
context:
space:
mode:
authorMichael Nottebrock <lofi@FreeBSD.org>2004-12-12 17:55:54 +0000
committerMichael Nottebrock <lofi@FreeBSD.org>2004-12-12 17:55:54 +0000
commit5663f401056fc0b7e1a9f10f870756c17d16a8f7 (patch)
tree6d3c6f3657745b600d033e5cf3729d2f0c439f6c /security
parentc0b7f1d89c456208454a11a34aff43612c8c7bcd (diff)
downloadports-5663f401056fc0b7e1a9f10f870756c17d16a8f7.tar.gz
ports-5663f401056fc0b7e1a9f10f870756c17d16a8f7.zip
Notes
Diffstat (limited to 'security')
-rw-r--r--security/gpgme/Makefile23
-rw-r--r--security/gpgme/pkg-plist6
2 files changed, 20 insertions, 9 deletions
diff --git a/security/gpgme/Makefile b/security/gpgme/Makefile
index 39b5f73f299e..562316f48f72 100644
--- a/security/gpgme/Makefile
+++ b/security/gpgme/Makefile
@@ -7,7 +7,7 @@
PORTNAME= gpgme
PORTVERSION= 1.0.1
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= security
MASTER_SITES= ${MASTER_SITE_GNUPG}
MASTER_SITE_SUBDIR= gpgme
@@ -17,9 +17,7 @@ COMMENT= A library to make access to GnuPG easier
BUILD_DEPENDS= gpg:${PORTSDIR}/security/gnupg \
gpgsm:${PORTSDIR}/security/gnupg-devel
-
-LIB_DEPENDS= gpg-error:${PORTSDIR}/security/libgpg-error \
- pth:${PORTSDIR}/devel/pth
+LIB_DEPENDS= gpg-error:${PORTSDIR}/security/libgpg-error
USE_LIBTOOL_VER=15
USE_GMAKE= yes
@@ -28,18 +26,31 @@ USE_REINPLACE= yes
CONFIGURE_TARGET=--build=${MACHINE_ARCH}-portbld-freebsd${OSREL}
CONFIGURE_ARGS= --with-gpg=${LOCALBASE}/bin/gpg \
--with-gpgsm=${LOCALBASE}/bin/gpgsm
-
-INFO= gpgme
+
+INFO= gpgme
+
+OPTIONS= PTH "Enable alternative libgpgme using GNU portable threads" off
.include <bsd.port.pre.mk>
+
+.if defined(WITH_PTH)
+LIB_DEPENDS+= pth:${PORTSDIR}/devel/pth
+PLIST_SUB+= WITH_PTH=''
+.elseif defined(WITHOUT_PTH)
+CONFIGURE_ARGS+=--without-pth --without-pth-test
+PLIST_SUB+= WITH_PTH='@comment '
+.endif
+
post-patch:
@${REINPLACE_CMD} -e 's|-lpthread|${PTHREAD_LIBS}|g' \
${WRKSRC}/${CONFIGURE_SCRIPT} \
${WRKSRC}/gpgme/Makefile.in \
${WRKSRC}/gpgme/gpgme-config.in
+.if defined(WITH_PTH)
.if ${OSVERSION} < 503100 || defined(PTHREAD_LIBS) && ${PTHREAD_LIBS} != "-pthread"
@${REINPLACE_CMD} -e 's|t_thread1_LDADD = ../../gpgme/libgpgme-pthread.la|t_thread1_LDADD = ../../gpgme/libgpgme-pthread.la -lpthread|g' \
${WRKSRC}/tests/gpg/Makefile.in
.endif
+.endif
.include <bsd.port.post.mk>
diff --git a/security/gpgme/pkg-plist b/security/gpgme/pkg-plist
index 62c58f70a1de..1e7801bb367f 100644
--- a/security/gpgme/pkg-plist
+++ b/security/gpgme/pkg-plist
@@ -1,8 +1,8 @@
bin/gpgme-config
include/gpgme.h
-lib/libgpgme-pth.a
-lib/libgpgme-pth.so
-lib/libgpgme-pth.so.14
+%%WITH_PTH%%lib/libgpgme-pth.a
+%%WITH_PTH%%lib/libgpgme-pth.so
+%%WITH_PTH%%lib/libgpgme-pth.so.14
lib/libgpgme-pthread.a
lib/libgpgme-pthread.so
lib/libgpgme-pthread.so.14