summaryrefslogtreecommitdiff
path: root/pcr/fair-coin/PKGBUILD
blob: 0b54510784658c2841cff4da076835e10b1f06aa (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
61
62
63
64
65
66
67
68
# $Id$
# Maintainer: Timothy Redaelli <timothy.redaelli@gmail.com>
# Contributor: shahid <helllamer@gmail.com>

pkgbase=fair-coin
pkgname=('faircoin-daemon' 'faircoin-qt')
pkgver=1.5.2
pkgrel=1
arch=('i686' 'x86_64')
url="http://fair-coin.org/"
makedepends=('boost<1.60' 'automoc4' 'qrencode' 'miniupnpc' 'protobuf')
license=('custom:MIT')
source=(https://github.com/FairCoinTeam/fair-coin/archive/v${pkgver}.tar.gz
        https://raw.githubusercontent.com/FairCoinTeam/fair-coin/v1.2.0/contrib/debian/examples/novacoin.conf
        https://raw.githubusercontent.com/FairCoinTeam/fair-coin/v1.2.0/contrib/debian/manpages/novacoin.conf.5
        https://raw.githubusercontent.com/FairCoinTeam/fair-coin/v1.2.0/contrib/debian/manpages/novacoind.1
        https://raw.githubusercontent.com/FairCoinTeam/fair-coin/v1.2.0/contrib/debian/novacoin-qt.desktop)

prepare() {
  cd "${srcdir}"
  sed -e "s/Nova/Fair/g" -e "s/nova/fair/g" \
      -e "s/bitcoin/faircoin/g" \
      -i novacoin-qt.desktop novacoin.conf \
         novacoind.1 novacoin.conf.5

  cd "$srcdir/$pkgbase-$pkgver"
  ./autogen.sh
}

build() {
  cd "$srcdir/$pkgbase-$pkgver"
  ./configure --prefix=/usr --disable-maintainer-mode --disable-tests --with-incompatible-bdb --with-gui=qt4

  # fix error with missing DSO by adding -lrt
  # https://github.com/bitcoin/bitcoin/issues/879
  sed -i -e "s/^LIBS = .*$/& -lrt/" src/Makefile
  make
}

package_faircoin-qt() {
  pkgdesc="faircoin is a peer-to-peer network based digital currency - Qt"
  depends=("boost-libs<1.60" qt4 miniupnpc qrencode protobuf)
  install=faircoin-qt.install

  cd "$srcdir/$pkgbase-$pkgver"
  install -Dm755 src/qt/FairCoin-qt "$pkgdir"/usr/bin/faircoin-qt
  install -Dm644 "${srcdir}/novacoin-qt.desktop" "${pkgdir}"/usr/share/applications/faircoin-qt.desktop
  install -Dm644 share/pixmaps/faircoin80.xpm "${pkgdir}"/usr/share/pixmaps/faircoin80.xpm
  install -Dm644 share/pixmaps/faircoin32.xpm "${pkgdir}"/usr/share/pixmaps/faircoin32.xpm
  install -Dm644 COPYING "$pkgdir/usr/share/licenses/$pkgname/COPYING"
}

package_faircoin-daemon() {
  pkgdesc="faircoin is a peer-to-peer network based digital currency - daemon"
  depends=("boost-libs<1.60" miniupnpc openssl)

  cd "$srcdir/$pkgbase-$pkgver"
  install -Dm755 src/FairCoind "$pkgdir"/usr/bin/faircoind
  install -Dm644 "${srcdir}"/novacoin.conf "${pkgdir}"/etc/faircoin.conf
  install -Dm644 "${srcdir}"/novacoin.conf.5 "${pkgdir}"/usr/share/man/man5/faircoin.conf.5
  install -Dm644 "${srcdir}"/novacoind.1 "${pkgdir}"/usr/share/man/man1/faircoind.1
  install -Dm644 COPYING "$pkgdir/usr/share/licenses/$pkgname/COPYING"
}
sha512sums=('b19f73b40f5b491c73c0670679dc7461e1eef8f05d4af86570743f45d26e1e1b8e17b43ad604531741a6a1febf1fd526c05fcd31bc08d0d779137911bdf737cd'
            '8e148d602106e1b403b07fe23269aa7210139274f58ddd42bd6ca18e3b3998ea45ce3e82eeb2aa4968449b072cd3b2d338f10b97e7e07e810b7488ac46d6442c'
            '35c5f5f34f134b44f41b0d169232ee00b7edaabc3c00f3a3200f6ec8f3d80ed312c43784d290c137995906d56777e842f10fb3dad7d66aa81279dbd725fe3abc'
            '24f46919cbc84b2c204850b64d2d0737b7fb9d0c727da974c930ae4be182e104d72c780d7f534fb25541a1a94dff670067a7c57e7b35979657d088c4903102b0'
            'b6348a030f122d2807e9b73a482ca0e551f3b191525c00954f941fe1e9d8988537f52da14e1361c82862929207f4cc8922d2143ceca175e9e6b741115f7eae02')