~cypheon/pkgsrc-wip

pkgsrc-wip/exabgp4/Makefile -rw-r--r-- 3.4 KiB
5f1bf4f5 — Johann Rudloff Subst PLIST paths for platform specific files for other architectures 6 months ago
                                                                                
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
# $NetBSD$

VERSION=		4.2.11
DISTNAME=		${VERSION}
PKGNAME=		exabgp4-${VERSION}
PKGREVISION=		2
EGG_NAME=		exabgp-${VERSION}
CATEGORIES=		net
MASTER_SITES=		${MASTER_SITE_GITHUB:=Exa-Networks/exabgp/archive/}
DIST_SUBDIR=		exabgp

MAINTAINER=		jorn.dejong@uninett.no
HOMEPAGE=		https://github.com/Exa-Networks/exabgp/
COMMENT=		Userspace BGP daemon written in python
LICENSE=		modified-bsd
CONFLICTS=		exabgp-[0-9]* # the exabgp3 package is simply called exabgp

WRKSRC=			${WRKDIR}/exabgp-${VERSION}

# Unclear if this is needed;
# perl is used in two example scripts,
# which need their shebang fixed,
# but is not needed to build or to run the software
#USE_TOOLS+=		perl:run

#PYTHON_VERSIONED_DEPENDENCIES+=	setuptools
BUILD_DEPENDS+=		${PYPKGPREFIX}-setuptools-[0-9]*:../../devel/py-setuptools

REPLACE_PERL+=		etc/exabgp/examples/dynamic-1.pl
REPLACE_PERL+=		etc/exabgp/examples/watchdog-1.pl

REPLACE_PYTHON+=	etc/exabgp/examples/api-add-remove.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-announce.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-announcement.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-api.nothing.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-api.receive.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-attributes-vpn.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-attributes.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-broken-flow.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-check.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-eor.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-fast.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-flow.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-manual-eor.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-multi-neighbor.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-multisession.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-nexthop-self.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-nexthop.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-no-respawn-1.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-no-respawn-2.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-notification.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-open.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-reload.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-teardown.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-vpls.run
REPLACE_PYTHON+=	etc/exabgp/examples/api-vpnv4.run
REPLACE_PYTHON+=	etc/exabgp/examples/stderr-1.py
REPLACE_PYTHON+=	etc/exabgp/examples/syslog-1.py
REPLACE_PYTHON+=	etc/exabgp/examples/watchdog.run

PYTHON_VERSIONS_ACCEPTED=	39 38 37 36

USE_LANGUAGES=		# none

RCD_SCRIPTS+=		exabgp

PKG_SYSCONFSUBDIR=	exabgp
CONF_FILES+=		${PREFIX}/share/examples/exabgp/exabgp.env ${PREFIX}/etc/exabgp/exabgp.env

INSTALLATION_DIRS+=	share/exabgp share/examples/exabgp bin
INSTALLATION_DIRS+=	${PKGMANDIR}/man1 ${PKGMANDIR}/man5

FILES_SUBST+=		PYTHONBIN=${PYTHONBIN}

post-patch:
	${SED} -e s,/etc/,${PREFIX}/etc/, ${WRKSRC}/doc/man/exabgp.1 > ${WRKSRC}/doc/man/exabgp.1.sed
	${CP} ${WRKSRC}/doc/man/exabgp.1.sed ${WRKSRC}/doc/man/exabgp.1

post-install:
	${INSTALL_MAN} ${WRKSRC}/doc/man/exabgp.1 \
		${DESTDIR}${PREFIX}/${PKGMANDIR}/man1
	${INSTALL_MAN} ${WRKSRC}/doc/man/exabgp.conf.5 \
		${DESTDIR}${PREFIX}/${PKGMANDIR}/man5
	${INSTALL_DATA} ${FILESDIR}/exabgp.env ${DESTDIR}${PREFIX}/share/examples/exabgp/

.include "../../lang/python/distutils.mk"
.include "../../lang/python/application.mk"
.include "../../lang/python/pyversion.mk"
.include "../../lang/python/versioned_dependencies.mk"
.include "../../mk/bsd.pkg.mk"