blob: 5318e8bb329eb3125cd07ba10c03066967cebf2c (
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
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
|
# Maintainer: Leonardo Arena <rnalrd@alpinelinux.org>
pkgname=ovn
pkgver=22.03.0
ovs_pkgver=2.17.1
pkgrel=1
pkgdesc="Open Virtual Network"
url="https://www.ovn.org"
arch="all"
license="Apache-2.0"
makedepends="automake
autoconf
libtool
libcap-ng-dev
linux-headers
openssl-dev
python3
unbound-dev
"
subpackages="$pkgname-dev $pkgname-doc"
giturl="https://github.com/openvswitch/ovs.git"
_gitrev="498cedc"
options="!check" # a couple of tests fail, disabling for now
source="$pkgname-$pkgver.tar.gz::https://github.com/ovn-org/ovn/archive/refs/tags/v$pkgver.tar.gz
https://dev.alpinelinux.org/archive/ovn/openvswitch-$ovs_pkgver-$_gitrev.tar.gz"
snapshot() {
mkdir -p "$srcdir"
cd "$srcdir"
if ! [ -d ovs ]; then git clone $giturl; fi
cd ovs
git archive --prefix=openvswitch-$ovs_pkgver/ -o "$srcdir"/openvswitch-$ovs_pkgver-$_gitrev.tar.gz $_gitrev
scp "$srcdir"/openvswitch-$ovs_pkgver-$_gitrev.tar.gz dev.alpinelinux.org:/archive/$pkgname/
}
prepare() {
default_prepare
./boot.sh
}
build() {
export CFLAGS="$CFLAGS -fPIC"
# First OpenVSwitch must be built
# Taking the same configure options from openvswitch APKBUILD
cd "$srcdir"/openvswitch-$ovs_pkgver
./boot.sh
./configure --prefix=/usr \
--sysconfdir=/etc \
--mandir=/usr/share/man \
--infodir=/usr/share/info \
--localstatedir=/var \
--enable-ndebug \
--enable-libcap-ng \
PYTHON=/usr/bin/python3
make
# now building OVN
cd "$builddir"
./configure --prefix=/usr \
--sysconfdir=/etc \
--localstatedir=/var \
--mandir=/usr/share/man \
--infodir=/usr/share/info \
--enable-shared \
--with-ovs-source=../openvswitch-$ovs_pkgver \
--with-ovs-build=../openvswitch-$ovs_pkgver
make
}
package() {
# parallel install issue
make -j1 DESTDIR="$pkgdir" install
}
check() {
make check
}
sha512sums="
b47ad17ada4bbaadd4a7baf194512f327c9838aa779a811c4ba1859e6ebcf380e56cb3bf4786d32ef1cdef4fe285351996dccf740b74982f195c6b19feb75ccb ovn-22.03.0.tar.gz
5d1fb0fb5eb070c8712759131f4c86915ab7b9075a1f5d136bea7b66efdcf55fd9aef79768f6431582aba9baddec4514200e2998abc3a37e01e5f0e186170b86 openvswitch-2.17.1-498cedc.tar.gz
"
|