1 |
# $MidnightBSD$ |
2 |
|
3 |
PORTNAME= gnutls |
4 |
PORTVERSION= 2.12.23 |
5 |
PORTREVISION= 3 |
6 |
CATEGORIES= security net |
7 |
MASTER_SITES= \ |
8 |
ftp://ftp.gnutls.org/gcrypt/gnutls/v${PORTVERSION:C/.[0-9]+$//}/ \ |
9 |
http://www.ring.gr.jp/pub/net/gnupg/gnutls/v${PORTVERSION:C/.[0-9]+$//}/ |
10 |
|
11 |
MAINTAINER= novel@FreeBSD.org |
12 |
COMMENT= GNU Transport Layer Security library |
13 |
|
14 |
LICENSE= gpl3 |
15 |
|
16 |
LIB_DEPENDS= nettle:${PORTSDIR}/security/nettle \ |
17 |
gpg-error:${PORTSDIR}/security/libgpg-error \ |
18 |
p11-kit:${PORTSDIR}/security/p11-kit |
19 |
|
20 |
CONFLICTS= gnutls-devel-[0-9]* |
21 |
|
22 |
USES= pathfix pkgconfig iconv gmake shebangfix |
23 |
USE_PERL5_BUILD= yes |
24 |
USE_BZIP2= yes |
25 |
USE_GNOME= ltverhack |
26 |
GNU_CONFIGURE= yes |
27 |
USE_LDCONFIG= yes |
28 |
USE_AUTOTOOLS= libtool |
29 |
LIBTOOLFILES= configure lib/configure libextra/configure |
30 |
SHEBANG_FILES= doc/scripts/gdoc doc/scripts/sort2.pl |
31 |
CPPFLAGS+= -I${LOCALBASE}/include |
32 |
LDFLAGS+= -L${LOCALBASE}/lib |
33 |
CPPFLAGS+= -fPIC |
34 |
CONFIGURE_ARGS+= --disable-guile |
35 |
|
36 |
|
37 |
INFO= gnutls |
38 |
|
39 |
OPTIONS_DEFINE= LIBTASN1 CXX LZO NLS |
40 |
|
41 |
LIBTASN1_DESC= Use system libtasn1 instead of local one |
42 |
CXX_DESC= Install C++ library |
43 |
LZO_DESC= LZO compression |
44 |
|
45 |
OPTIONS_DEFAULT= LIBTASN1 CXX |
46 |
|
47 |
.include <bsd.mport.options.mk> |
48 |
|
49 |
.if ${PORT_OPTIONS:MLIBTASN1} |
50 |
LIB_DEPENDS+= tasn1:${PORTSDIR}/security/libtasn1 |
51 |
.else |
52 |
CONFIGURE_ARGS+= --with-included-libtasn1 |
53 |
.endif |
54 |
|
55 |
.if ${PORT_OPTIONS:MLZO} |
56 |
LIB_DEPENDS+= lzo2:${PORTSDIR}/archivers/lzo2 |
57 |
CONFIGURE_ARGS+= --with-lzo |
58 |
.else |
59 |
CONFIGURE_ARGS+= --with-lzo=no |
60 |
.endif |
61 |
|
62 |
.if ${PORT_OPTIONS:MCXX} |
63 |
PLIST_SUB+= CXX="" |
64 |
.else |
65 |
CONFIGURE_ARGS+= --disable-cxx |
66 |
PLIST_SUB+= CXX="@comment " |
67 |
.endif |
68 |
|
69 |
.if ${PORT_OPTIONS:MNLS} |
70 |
USES+= gettext |
71 |
PLIST_SUB+= NLS="" |
72 |
.else |
73 |
CONFIGURE_ARGS+= --disable-nls |
74 |
PLIST_SUB+= NLS="@comment " |
75 |
.endif |
76 |
|
77 |
PORTDOCS= AUTHORS NEWS README THANKS |
78 |
PORTEXAMPLES= *.c |
79 |
|
80 |
post-patch: |
81 |
@${FIND} ${WRKSRC} -name "Makefile.in" -type f |\ |
82 |
${XARGS} ${REINPLACE_CMD} -e 's|[$$][(]LTLIBPTHREAD[)]||g' |
83 |
@${REINPLACE_CMD} -e 's|/usr/bin/perl|${PREFIX}/bin/perl|g' \ |
84 |
${WRKSRC}/doc/doxygen/Doxyfile.in |
85 |
|
86 |
post-install: |
87 |
.if ${PORT_OPTIONS:MEXAMPLES} |
88 |
@${MKDIR} ${EXAMPLESDIR} |
89 |
cd ${WRKSRC} && ${INSTALL_DATA} ${PORTEXAMPLES:C,^,doc/examples/,} \ |
90 |
${EXAMPLESDIR} |
91 |
.endif |
92 |
.if ${PORT_OPTIONS:MDOCS} |
93 |
@${MKDIR} ${DOCSDIR} |
94 |
.for i in ${PORTDOCS} |
95 |
@${INSTALL_DATA} ${WRKSRC}/${i} ${DOCSDIR} |
96 |
.endfor |
97 |
.endif |
98 |
|
99 |
.include <bsd.port.mk> |