summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: a67d42e988866ccc62cdfff0c82c5f21037e4ca4 (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
# Maintainer: Markus Hubig <mhubig@gmail.com>

pkgname=sheepdog
pkgver=1.0_rc0
pkgrel=4
pkgdesc="This package provides a distributed storage system for QEMU. It provides highly available block level storage volumes to virtual machines. It supports advanced volume management features such as snapshot, cloning, and thin provisioning."
arch=("i686" "x86_64")
url="http://sheepdog.github.io/sheepdog/"
license=("GPL2")

depends=("fuse>=2.9.5"
         "corosync>=2.3.5")

optdepends=("qemu: needed on the client"
            "curl: for http request service"
            "fcgi: for http request service")

makedepends=("libqb>=0.17.2"
             "liburcu>=0.8.7"
             "qemu>=2.5.0"
             "yasm>=1.3.0")

backup=("etc/sheepdog/sheepdog.env")

source=("https://github.com/$pkgname/$pkgname/archive/v$pkgver.tar.gz"
        "sheepdog.service"
        "sheepdog.env")
sha512sums=("8d3fdb58ac4d62e814a11f191d83baa783a7e805f6400eb6807719760f10e49aaad28c68c7c1a95bc535bc1c15722d43458bf4f3342696d58624baab2af1436d"
            "ab399fbce466795596dac0130a15276897303261a29f38cf0e7f9983100ff6e7dbe11d806f47b866889a92aa0cf9f58b0091a863f01aa7746e9a29a405204d15"
            "f8ab393bcf5908d43129a79c7c1166361862a95c93f90581922ae3b805ae0eb8efdbbbdb6eb0b1eceb7190abcbbb80b1e7c5e2eb84f0c0431a8f6d2d7fc44da8")

build() {
    cd "$pkgname-$pkgver"
    ./autogen.sh
    ./configure --enable-sheepfs --prefix=/usr --exec-prefix=/usr --sysconfdir=/etc --sbindir=/usr/bin
    make
}

check() {
    cd "$pkgname-$pkgver"
    make -k check
}

package() {
    cd "$pkgname-$pkgver"
    make DESTDIR="$pkgdir/" install

    rm -rf $pkgdir/etc/init.d
    rm -rf $pkgdir/usr/lib/systemd/system/sheepdog.service

    install -D -m 644 \
      $srcdir/sheepdog.service \
      $pkgdir/usr/lib/systemd/system/sheepdog.service

    install -D -m 644 \
      $srcdir/sheepdog.env \
      $pkgdir/etc/sheepdog/sheepdog.env
}