blob: 326ce6fd374d7ae3477d4978d8bf253586d035f6 (
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
|
# $FreeBSD$
PORTNAME= hyperscan
PORTVERSION= 4.1.0
DISTVERSIONPREFIX= v
CATEGORIES= devel textproc
MASTER_SITES= GH:hs SF/boost/boost/1.59.0:boost
DISTFILES= ${DISTNAME}${EXTRACT_SUFX}:hs boost_1_59_0.tar.gz:boost
MAINTAINER= vsevolod@FreeBSD.org
COMMENT= High-performance multiple regex matching library
LICENSE= BSD3CLAUSE
BUILD_DEPENDS= ragel:${PORTSDIR}/devel/ragel
USE_GITHUB= yes
GH_ACCOUNT= 01org
USES= compiler:c++11-lib cmake:outsource python:build pkgconfig
ONLY_FOR_ARCHS= amd64
ONLY_FOR_ARCHS_REASON= SSSE3 is required for work
OPTIONS_DEFINE= SHARED NATIVE
SHARED_DESC= Build shared library
NATIVE_DESC= Build with native CPU tunes
.ifndef DEBUG_FLAGS
CMAKE_BUILD_TYPE= MinSizeRel
.else
CMAKE_BUILD_TYPE= Debug
.endif
CMAKE_ARGS+= -DBOOST_ROOT=${WRKDIR}/boost_1_59_0
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MNATIVE}
CXXFLAGS+= -march=native -mtune=native
CFLAGS+= -march=native -mtune=native
.else
CXXFLAGS+= -march=core2
CFLAGS+= -march=core2
.endif
.if ${PORT_OPTIONS:MSHARED}
CMAKE_ARGS+= -DBUILD_STATIC_AND_SHARED=ON
PLIST_SUB+= SHARED="" \
SOVERSION=${PORTVERSION} \
SOSHORTVERSION=${PORTVERSION:C/\.[0-9]$//}
.else
PLIST_SUB+= SHARED="@comment "
.endif
post-stage:
${MV} ${STAGEDIR}/${PREFIX}/lib/pkgconfig/libhs.pc \
${STAGEDIR}/${PREFIX}/libdata/pkgconfig/
${RMDIR} ${STAGEDIR}/${PREFIX}/lib/pkgconfig/
.include <bsd.port.mk>
|