summaryrefslogtreecommitdiff
path: root/community/openvswitch/PKGBUILD
blob: 90839dbb78ec3cccad36ea75ea085ab5c4255567 (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
# $Id: PKGBUILD 113226 2014-06-16 11:06:53Z spupykin $
# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Contributor: Pedro Martinez-Julia (pedromj@um.es)
# Contributor: Matt Monaco <net 0x01b dgbaley27>

pkgname=openvswitch
pkgver=2.1.2
pkgrel=3
pkgdesc="Production Quality, Multilayer Open Virtual Switch"
url="http://openvswitch.org"
license=('APACHE')
arch=(x86_64 i686)
install=openvswitch.install
source=("http://openvswitch.org/releases/openvswitch-$pkgver.tar.gz"
	openvswitch.tmpfiles
	ovsdb-server.service
	ovs-vswitchd.service)
depends=('openssl')
makedepends=('python2')
optdepends=('python2')
md5sums=('430ff6d1e1fc81e9c5ebc2e641cfc953'
         '0534c19ed27d2ff8c6b32d87c07bc76f'
         '3a1b706c1adfb1166b58bc9d65ea396f'
         '4ec9c05448d6910c5fd581e964518ef7')

build() {
	cd "$srcdir/$pkgname-$pkgver"
	./boot.sh
	./configure \
		--prefix=/usr \
		--sysconfdir=/etc \
		--localstatedir=/var \
		--with-rundir=/run/openvswitch \
		--sbindir=/usr/bin \
		PYTHON=/usr/bin/python2
	make
}

package() {
	cd "$srcdir/$pkgname-$pkgver"
	make DESTDIR="$pkgdir" install
	install -Dm0644 $srcdir/openvswitch.tmpfiles "$pkgdir/usr/lib/tmpfiles.d/openvswitch.conf"
	install -Dm0644 $srcdir/ovsdb-server.service "$pkgdir/usr/lib/systemd/system/ovsdb-server.service"
	install -Dm0644 $srcdir/ovs-vswitchd.service "$pkgdir/usr/lib/systemd/system/ovs-vswitchd.service"
	install -dm0755 "$pkgdir/etc/openvswitch"
	rm -rf $pkgdir/run
}