blob: bd3159c8f6d69d74db9c14c17a8e9d7a1ac0211f (
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
|
# Contributor: V.Krishn <vkrishn4@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=libwebsockets
pkgver=1.4
_tag=libwebsockets-$pkgver-chrome43-firefox-36
pkgrel=0
pkgdesc="C library for lightweight websocket clients and servers"
url="http://libwebsockets.org"
arch="all"
license="LGPL2.1"
depends=
depends_dev=""
makedepends="$depends_dev cmake zlib-dev openssl-dev"
subpackages="$pkgname-doc $pkgname-dev $pkgname-test:_test"
source="http://git.libwebsockets.org/cgi-bin/cgit/libwebsockets/snapshot/$_tag.tar.gz
0001-Avoid-use-of-internal-glibc-sys-cdefs.h-header.patch
"
_srcdir="${srcdir}"/${_tag}
_builddir="${srcdir}/build"
prepare() {
cd "$_srcdir"
for i in $source; do
case $i in
*.patch)
msg "Applying $i"
patch -p1 -i "$srcdir"/$i || return 1
;;
esac
done
}
build() {
mkdir "$_builddir"
cd "$_builddir"
cmake -DCMAKE_INSTALL_PREFIX=/usr \
"$_srcdir" || return 1
make
}
package() {
cd "$_srcdir"
install -Dm644 LICENSE "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE || return 1
cd "$_builddir"
make DESTDIR="$pkgdir" install || return 1
rm -f "$pkgdir"/usr/lib/*.a
}
_test() {
pkgname="$pkgdesc - test server"
mkdir -p "$subpkgdir"/usr
mv "$pkgdir"/usr/share "$pkgdir"/usr/bin "$subpkgdir"/usr/
}
md5sums="0452c278a5cd4349135df2a693f35c28 libwebsockets-1.4-chrome43-firefox-36.tar.gz
b8d335dbe62cc38b58e593a3d2cd6eaf 0001-Avoid-use-of-internal-glibc-sys-cdefs.h-header.patch"
sha256sums="e11492477e582ef0b1a6ea2f18d81a9619b449170a3a5c43f32a9468461a9798 libwebsockets-1.4-chrome43-firefox-36.tar.gz
7dc31117023e27bc3cd6fb15135dd866c7c7e0d80627c78ee57598d103929f51 0001-Avoid-use-of-internal-glibc-sys-cdefs.h-header.patch"
sha512sums="46dd538193e001a54a1fc78f238c6ff94252b79239b110c0e57bd354082cc6adc12578cd7c7afddd8c9de6319e31ab511189ee5decf101075402874a9f6932cb libwebsockets-1.4-chrome43-firefox-36.tar.gz
b56ef2a08cdc0d08d8b229d6675379eff46fb54ee5a3a12538e80ce6d88dd0a2959565eea7622a6bd8aabf92a26d0b0f4a53425b567e600b5be097537db4c22f 0001-Avoid-use-of-internal-glibc-sys-cdefs.h-header.patch"
|