aboutsummaryrefslogtreecommitdiffstats
path: root/devel/grpc/Makefile
blob: 6b4d838c19fa2ef8c92b19d67e73161fcde7abad (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# Created by: vanilla@
# $FreeBSD$

PORTNAME=   grpc
PORTVERSION=    1.4.2
DISTVERSIONPREFIX=  v
CATEGORIES= devel

MAINTAINER= vanilla@FreeBSD.org
COMMENT=    HTTP/2-based RPC framework

LICENSE=    BSD3CLAUSE
LICENSE_FILE=   ${WRKSRC}/LICENSE

BUILD_DEPENDS=  go:lang/go
LIB_DEPENDS=    libgflags.so:devel/gflags \
        libprotobuf.so:devel/protobuf \
        libcares.so:dns/c-ares

USE_GITHUB= yes
GH_TUPLE=   grpc:grpc:v${PORTVERSION} \
        google:boringssl:a93bc11:boringssl/third_party/boringssl \
        google:benchmark:v1.1.0:benchmark/third_party/benchmark

USES=       cmake perl5 pkgconfig
USE_LDCONFIG=   yes
USE_PERL5=  build
PLIST_SUB+= SOVERSION=${PORTVERSION}
CFLAGS+=    -I${LOCALBASE}/include
LDFLAGS+=   -L${LOCALBASE}/lib -lpthread -lcares -lm
CMAKE_ARGS= -DgRPC_ZLIB_PROVIDER:STRING="package" \
        -DgRPC_PROTOBUF_PROVIDER:STRING="package" \
        -DgRPC_GFLAGS_PROVIDER:STRING="package" \
        -DgRPC_SSL_PROVIDER:STRING="module" \
        -DgRPC_CARES_PROVIDER:STRING="package" \
        -DgRPC_BENCHMARK_PROVIDER:STRING="module" \
        -DBENCHMARK_USE_LIBCXX=ON \
        -DBUILD_SHARED_LIBS=ON

.include <bsd.port.mk>