blob: c50c2c839ac86c54b897f00a7c81c5878b32b11e (
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
|
# Contributor: V.Krishn <vkrishn4@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=libwebsockets
pkgver=2.4.0
pkgrel=1
pkgdesc="C library for lightweight websocket clients and servers"
url="http://libwebsockets.org"
arch="all"
license="LGPL2+"
makedepends="cmake zlib-dev libressl-dev"
subpackages="$pkgname-doc $pkgname-dev $pkgname-test:_test"
source="$pkgname-$pkgver.tar.gz::https://github.com/warmcat/$pkgname/archive/v$pkgver.tar.gz"
builddir="$srcdir/$pkgname-$pkgver"
build() {
mkdir -p "$builddir"/build
cd "$builddir"/build
cmake .. \
-DCMAKE_BUILD_TYPE=MinSizeRel \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_VERBOSE_MAKEFILE=TRUE
make
}
package() {
cd "$builddir"
install -Dm644 LICENSE \
"$pkgdir"/usr/share/licenses/$pkgname/LICENSE
make -C build DESTDIR="$pkgdir" install
}
_test() {
pkgdesc="$pkgdesc (test server)"
mkdir -p "$subpkgdir"/usr
mv "$pkgdir"/usr/share "$pkgdir"/usr/bin "$subpkgdir"/usr/
}
sha512sums="89ccc24b44e4f38f3b3918634dc5f2be78be1ea9fc1748064c8a54adae026c410bfc743caf9bbd304c312e34e624f5f8fb101d7b36052af9b94dbf309625ec0a libwebsockets-2.4.0.tar.gz"
|