blob: b06334eb581bccc9879e0d8d34b7ce0a4b3c3700 (
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
|
# Maintainer: sum01 <sum01@protonmail.com>
pkgname=cpp-httplib-compiled
_pkgname='cpp-httplib'
pkgver=0.20.0
pkgrel=1
pkgdesc='A C++ HTTP/HTTPS server and client library (compiled version)'
arch=('x86_64' 'i686')
url='https://github.com/yhirose/cpp-httplib'
license=('MIT')
provides=("cpp-httplib=$pkgver" 'libcpp-httplib.so')
conflicts=('cpp-httplib')
depends=('openssl>=3' 'zlib' 'brotli' 'zstd')
makedepends=('cmake>=3.14' 'python>=3')
source=("$pkgname-$pkgver.tar.gz::https://github.com/yhirose/cpp-httplib/archive/v$pkgver.tar.gz")
sha512sums=('a20d306bfc7b3749f67c3f213f410cf61e1d3896cb7b02582299af7a396731594d514680d8af54a48e1462223a30354446c7970dc38f68fb2f647c9d2e018581')
build() {
mkdir -p "$srcdir/$_pkgname-$pkgver/build"
cd "$srcdir/$_pkgname-$pkgver/build"
cmake -DCMAKE_BUILD_TYPE=None \
-DBUILD_SHARED_LIBS=ON \
-DHTTPLIB_COMPILE=ON \
-DHTTPLIB_REQUIRE_OPENSSL=ON \
-DHTTPLIB_REQUIRE_ZLIB=ON \
-DHTTPLIB_REQUIRE_BROTLI=ON \
-DHTTPLIB_REQUIRE_ZSTD=ON \
-DCMAKE_INSTALL_PREFIX=/usr ..
cmake --build .
}
package() {
cd "$srcdir/$_pkgname-$pkgver/build"
DESTDIR="$pkgdir" cmake --build . --target install
}
|