summaryrefslogtreecommitdiff
path: root/net/savvycan/Makefile
blob: 636139e274c23125ca3377bdee5fd7aa3de761ee (plain)
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

PORTNAME=	savvycan
PORTVERSION=	1.0.173
PORTEPOCH=	1
#DISTVERSIONPREFIX=	V
CATEGORIES=	net

MAINTAINER=	leres@FreeBSD.org
COMMENT=	CAN bus reverse engineering and capture tool

LICENSE=	MIT

BUILD_DEPENDS=	${PYTHON_PKGNAMEPREFIX}sphinx>=0,1:textproc/py-sphinx@${PY_FLAVOR}

USES=		compiler:c++11-lang gmake python:build,3.6+ qmake qt:5
USE_QT=		buildtools_build core gui help printsupport serialbus \
		serialport websockets-qml widgets

USE_GITHUB=	yes
GH_TUPLE=	collin80:SavvyCAN:${DISTVERSIONPREFIX}${PORTVERSION}
NO_MTREE=	yes
PLIST_FILES=	bin/savvycan \
		man/man1/savvycan.1.gz

PORTSCOUT=	skipv:continuous

OPTIONS_DEFINE+=	DOCS EXAMPLES

PORTDOCS=	*
PORTEXAMPLES=	*

.include <bsd.port.options.mk>

post-build:
	cd ${WRKSRC}/docs && ${GMAKE} man
.if ${PORT_OPTIONS:MDOCS}
	cd ${WRKSRC}/docs && ${GMAKE} html
.endif

do-install:
	${MKDIR} ${STAGEDIR}${PREFIX}/bin
	${INSTALL_PROGRAM} ${WRKSRC}/SavvyCAN ${STAGEDIR}${PREFIX}/bin/savvycan
	${MKDIR} ${STAGEDIR}${MANPREFIX}/man/man1
	${INSTALL_MAN} ${WRKSRC}/docs/build/man/savvycan.1 \
	    ${STAGEDIR}${MANPREFIX}/man/man1
.if ${PORT_OPTIONS:MDOCS}
	${MKDIR} ${STAGEDIR}${DOCSDIR}
	cd ${WRKSRC}/docs/build && ${COPYTREE_SHARE} html ${STAGEDIR}${DOCSDIR}
.endif
.if ${PORT_OPTIONS:MEXAMPLES}
	${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
	cd ${WRKSRC}/examples && ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR}
.endif

.include <bsd.port.mk>