summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: e3162b5dde0d72c8b9a778142d03115c3c0f9ef1 (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
55
56
57
58
59
60
# Maintainer: Chocobo1 <chocobo1 AT archlinux DOT net>

pkgname=nanopolish-git
pkgver=0.14.0.r10.g21c75db
pkgrel=1
pkgdesc="Provide signal-level analysis of Oxford Nanopore sequencing data"
arch=('i686' 'x86_64')
url="https://github.com/jts/nanopolish"
license=('MIT')
depends=('glibc' 'hdf5' 'htslib' 'zlib')
makedepends=('git' 'eigen' 'wget')
provides=("nanopolish=$pkgver")
conflicts=('nanopolish')
source=("git+https://github.com/jts/nanopolish.git")
sha256sums=('SKIP')


prepare() {
  cd "nanopolish"

  git submodule update --init --recursive
}

pkgver() {
  cd "nanopolish"

  git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}

build() {
  cd "nanopolish"

  make \
    EIGEN=noinstall \
    HDF5=noinstall \
    HTS=noinstall \
    EIGEN_INCLUDE="-I/usr/include/eigen3" \
    H5_INCLUDE="-I/usr/include" \
    HTS_INCLUDE="-I/usr/include/htslib"
}

check() {
  cd "nanopolish"

  make \
    EIGEN=noinstall \
    HDF5=noinstall \
    HTS=noinstall \
    EIGEN_INCLUDE="-I/usr/include/eigen3" \
    H5_INCLUDE="-I/usr/include" \
    HTS_INCLUDE="-I/usr/include/htslib" \
    test
}

package() {
  cd "nanopolish"

  install -Dm755 "nanopolish" -t "$pkgdir/usr/bin"
  install -Dm644 "LICENSE" -t "$pkgdir/usr/share/licenses/nanopolish"
}