summaryrefslogtreecommitdiffstats
path: root/abs/extra/tidy/PKGBUILD
blob: 352e56fc6ff23b1c293955116c6ab0a4f33dd2d2 (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
# $Id: PKGBUILD 230776 2015-02-04 23:00:34Z bluewind $
# Maintainer:
# Contributor: eric <eric@archlinux.org>
# Contributor: Markus Meissner <markus@meissna.de>

pkgname=tidy
pkgver=5.2.0
pkgrel=1
pkgdesc="A tool to tidy down your HTML code to a clean style"
arch=(i686 x86_64)
url="http://www.html-tidy.org/"
license=(custom)
depends=(glibc)
makedepends=(cmake libxslt)
conflicts=(tidyhtml)
provides=(tidyhtml)
replaces=(tidyhtml)
source=("https://github.com/htacg/tidy-html5/archive/$pkgver.tar.gz")
md5sums=('ffbe6e8471eff90877b4d74bb714e22f')

prepare() {
  mkdir -p build
}

build() {
  cd build
  cmake ../tidy-html5-$pkgver \
    -DCMAKE_INSTALL_PREFIX=/usr \
    -DCMAKE_BUILD_TYPE=Release
  make
}

package() {
  cd build
  make DESTDIR="$pkgdir" install

# Compatibility symlinks until everything is ported
  ln -s tidybuffio.h "$pkgdir"/usr/include/buffio.h
  ln -s tidyplatform.h "$pkgdir"/usr/include/platform.h

  install -Dm644 "$srcdir"/$pkgname-html5-$pkgver/README/LICENSE.txt "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
}