db-move: moved gnome-calendar from [testing] to [extra] (x86_64)
[arch-packages.git] / libwebp / trunk / PKGBUILD
blob0ba89afe35563a96efa63e9c06507d9e3a97e58d
1 # Maintainer: Jan Alexander Steffens (heftig) <heftig@archlinux.org>
2 # Contributor: Alexander Rødseth <rodseth@gmail.com>
3 # Contributor: Jon Nordby <jononor@gmail.com>
5 pkgname=libwebp
6 pkgver=1.3.0
7 pkgrel=2
8 pkgdesc="WebP library and conversion tools"
9 url="https://developers.google.com/speed/webp/"
10 arch=(x86_64)
11 license=(BSD)
12 depends=(libpng libjpeg libtiff giflib)
13 makedepends=(cmake ninja)
14 provides=(libwebp{,decoder,demux,mux}.so libsharpyuv.so)
15 source=(https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-$pkgver.tar.gz{,.asc})
16 sha256sums=('64ac4614db292ae8c5aa26de0295bf1623dbb3985054cb656c55e67431def17c'
17             'SKIP')
18 validpgpkeys=('6B0E6B70976DE303EDF2F601F9C3D6BDB8232B5D') # WebP release signing key
20 build() {
21   local cmake_options=(
22     -DCMAKE_INSTALL_PREFIX=/usr
23     -DCMAKE_BUILD_TYPE=None
24     -DCMAKE_SKIP_INSTALL_RPATH=ON
25     -DBUILD_SHARED_LIBS=ON
26     -DWEBP_BUILD_VWEBP=OFF
27     -DWEBP_BUILD_EXTRAS=OFF
28   )
30   # Mimic autotools build without --enable-asserts
31   CFLAGS+=" -DNDEBUG"
32   CXXFLAGS+=" -DNDEBUG"
34   cmake -S libwebp-$pkgver -B build -G Ninja "${cmake_options[@]}"
35   cmake --build build
38 check() {
39   cd build
40   ctest --output-on-failure --stop-on-failure -j$(nproc)
43 package() {
44   DESTDIR="$pkgdir" cmake --install build
46   install -Dt "$pkgdir/usr/share/licenses/$pkgname" -m644 \
47     libwebp-$pkgver/COPYING
50 # vim:set sw=2 sts=-1 et: