summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: ec69324e72f88f56c16901177c84c4a0c854b9a3 (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
# Maintainer: Darshit Shah <darnir [at] gnu [dot] org>
# Contributor: Levente Polyak <anthraxx[at]archlinux[dot]org>

_pkgname=libpsl
pkgname=$_pkgname-git
pkgver=libpsl.0.21.0.r41.g72365d3
pkgrel=1
pkgdesc='Public Suffix List library'
url='https://github.com/rockdaboot/libpsl'
arch=('x86_64')
license=('MIT')
depends=('libidn2' 'libunistring')
makedepends=('libxslt' 'python' 'publicsuffix-list' 'gtk-doc' 'git')
provides=('libpsl')
conflicts=('libpsl')
source=(git+https://github.com/rockdaboot/${_pkgname}.git)
sha512sums=('SKIP')

pkgver() {
  cd ${_pkgname}
  git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
}

prepare() {
  cd ${_pkgname}
  ./autogen.sh
}

build() {
  cd ${_pkgname}
  ./configure \
    --prefix=/usr \
    --disable-static \
    --disable-dependency-tracking \
    --enable-man \
    --enable-gtk-doc \
    --enable-{builtin,runtime}=libidn2 \
    --with-psl-file=/usr/share/publicsuffix/effective_tld_names.dat \
    --with-psl-testfile=/usr/share/publicsuffix/test_psl.txt
  LC_CTYPE=en_US.UTF-8 make
}

check() {
  cd ${_pkgname}
  make check
}

package() {
  cd ${_pkgname}
  make DESTDIR="${pkgdir}" install
  install -Dm 644 COPYING -t "${pkgdir}/usr/share/licenses/${pkgname}"
}

# vim: ts=2 sw=2 et: