blob: 8627b4bb202aa4a2d56a0c98698604e3841424f0 (
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
|
# Maintainer: Daniel Bermond <dbermond@archlinux.org>
pkgbase=lightway-core
pkgname=('lightway-core' 'lightway-core-doc')
pkgver=1.16.5
pkgrel=1
pkgdesc='A VPN protocol by ExpressVPN'
arch=('x86_64')
url='https://www.expressvpn.com/lightway/'
license=('GPL-2.0-or-later')
makedepends=('git' 'cmake' 'ruby-ceedling' 'doxygen' 'graphviz')
source=("https://github.com/expressvpn/lightway-core/archive/v${pkgver}/${pkgname}-${pkgver}.tar.gz"
'git+https://github.com/open-quantum-safe/liboqs.git'
'git+https://github.com/wolfSSL/wolfssl.git'
'010-lightway-core-disable-werror-on-wolfssl.patch')
sha256sums=('5fa4fd2ff4f27510efb8c1943345b45f8bb6c0c7c06564038097ca5289e98a3d'
'SKIP'
'SKIP'
'fd82affc9e605a7963e5b4908d8decc877980ac007f9ba5aabeccf9019cf5727')
prepare() {
local _liboqs_tag
local _wolfssl_tag
_liboqs_tag="$(awk '/HE_LIBOQS_TAG/ { print $3 }' "${pkgname}-${pkgver}/3rd_party_deps.yml")"
_wolfssl_tag="$(awk '/HE_WOLFSSL_TAG/ { print $3 }' "${pkgname}-${pkgver}/3rd_party_deps.yml")"
git -C liboqs config --local advice.detachedHead false
git -C liboqs checkout --quiet "$_liboqs_tag"
git -C wolfssl config --local advice.detachedHead false
git -C wolfssl checkout --quiet "$_wolfssl_tag"
patch -d wolfssl -Np1 -i "${srcdir}/010-lightway-core-disable-werror-on-wolfssl.patch"
mkdir -p "${pkgname}-${pkgver}/third_party"
cp -af liboqs wolfssl "${pkgname}-${pkgver}/third_party"
}
build() {
export CFLAGS+=' -ffat-lto-objects'
[ -z "$LC_ALL" ] && export LC_ALL='C'
cd "${pkgname}-${pkgver}"
ceedling release project:linux
doxygen
}
check() {
cd "${pkgname}-${pkgver}"
ceedling test project:linux
}
package_lightway-core() {
install -D -m644 "${pkgname}-${pkgver}/build/release"/*.a -t "${pkgdir}/usr/lib"
cp -dr --no-preserve='ownership' "${pkgname}-${pkgver}/public" "${pkgdir}/usr/include"
}
package_lightway-core-doc() {
pkgdesc+=' (documentation)'
arch=('any')
install -d -m755 "${pkgdir}/usr/share/doc"
cp -dr --no-preserve='ownership' "lightway-core-${pkgver}/html" "${pkgdir}/usr/share/doc/lightway-core"
}
|