41 lines
975 B
Text
41 lines
975 B
Text
# Contributor: Michał Polański <michal@polanski.me>
|
|
# Maintainer: Michał Polański <michal@polanski.me>
|
|
pkgname=llhttp
|
|
pkgver=6.0.10
|
|
pkgrel=0
|
|
pkgdesc="Port of http_parser to llparse"
|
|
url="https://llhttp.org/"
|
|
license="MIT"
|
|
arch="all"
|
|
makedepends="cmake clang npm"
|
|
subpackages="$pkgname-dev $pkgname-doc"
|
|
source="https://github.com/nodejs/llhttp/archive/v$pkgver/llhttp-$pkgver.tar.gz"
|
|
|
|
prepare() {
|
|
default_prepare
|
|
|
|
sed -i "s/_TAG_/$pkgver/" CMakeLists.txt
|
|
npm ci
|
|
}
|
|
|
|
build() {
|
|
make release
|
|
cmake -S release -B releasebuild \
|
|
-DCMAKE_BUILD_TYPE=MinSizeRel \
|
|
-DCMAKE_INSTALL_PREFIX=/usr \
|
|
-DBUILD_SHARED_LIBS=ON
|
|
cmake --build releasebuild
|
|
}
|
|
|
|
check() {
|
|
npm test
|
|
}
|
|
|
|
package() {
|
|
DESTDIR="$pkgdir" cmake --install releasebuild
|
|
install -Dm644 LICENSE-MIT "$pkgdir"/usr/share/doc/$pkgname/LICENSE
|
|
}
|
|
|
|
sha512sums="
|
|
b417fe97467404426c673a6e0303a92b8c3420c6c2bc44bbea6398112879b860ab439119f9d07cfa782a329e42cb9a6d566bf02f147cdfce007527a580acad28 llhttp-6.0.10.tar.gz
|
|
"
|