mirror of
https://gitdl.cn/https://github.com/chakralinux/desktop.git
synced 2025-01-24 10:32:13 +08:00
90 lines
3.1 KiB
Bash
90 lines
3.1 KiB
Bash
pkgname=bitcoin-core
|
|
pkgver=0.16.0
|
|
pkgrel=1
|
|
pkgdesc="Bitcoin is a peer-to-peer network based digital currency"
|
|
arch=('x86_64')
|
|
url="https://www.bitcoin.org/"
|
|
depends=('boost' 'boost-libs' 'zeromq' 'miniupnpc' 'libevent' 'qt5-base' 'qrencode' 'protobuf')
|
|
makedepends=('boost' 'qt5-tools')
|
|
license=('MIT')
|
|
conflicts=('bitcoin-daemon' 'bitcoin-cli' 'bitcoin-qt' 'bitcoin')
|
|
replaces=('bitcoin-daemon' 'bitcoin-cli' 'bitcoin-qt' 'bitcoin')
|
|
provides=('bitcoin-daemon' 'bitcoin-cli' 'bitcoin-qt' 'bitcoin')
|
|
source=("https://github.com/bitcoin/bitcoin/archive/v$pkgver.tar.gz"
|
|
"https://raw.github.com/bitcoin/bitcoin/v$pkgver/contrib/debian/bitcoin-qt.desktop"
|
|
"bitcoin128.svg"
|
|
"https://raw.github.com/bitcoin/bitcoin/v$pkgver/contrib/debian/examples/bitcoin.conf"
|
|
"bitcoin.service"
|
|
"bitcoin-reindex.service")
|
|
sha256sums=('8ade43e420b6aad00645d79239c21947e47f37d1f974b4948b0da0b6999c28d5'
|
|
'3d4eb0cfd0750adeadc7820e43159e5c6d622dbd8bb0177669c43c61d20958be'
|
|
'7ddc5b4f0e6a217663c4cc8bbf6dc237c8e16aff3159f0fe3e0de18810676f90'
|
|
'f5b34a5ff5f8bf4240a365dcca1f76eb1868054badf90117f2153f6254b96e10'
|
|
'5e45f2ceaeb7bfa60aeb66ca4167068191eb4358af03f95ac70fd96d9b006349'
|
|
'10ad0b8c356559886634eaf658992004045853ec26cddee143d16125cb75e8f1')
|
|
|
|
|
|
build() {
|
|
cd ${pkgname%-core}-$pkgver
|
|
|
|
msg2 'Building...'
|
|
./autogen.sh
|
|
./configure \
|
|
--prefix=/usr \
|
|
--sbindir=/usr/bin \
|
|
--libexecdir=/usr/lib/bitcoin \
|
|
--sysconfdir=/etc \
|
|
--sharedstatedir=/usr/share/bitcoin \
|
|
--localstatedir=/var/lib/bitcoin \
|
|
--with-incompatible-bdb \
|
|
--enable-hardening \
|
|
--with-gui=qt5
|
|
make
|
|
}
|
|
|
|
package() {
|
|
cd ${pkgname%-core}-$pkgver
|
|
|
|
msg2 'Installing bitcoin...'
|
|
make DESTDIR=$pkgdir install
|
|
|
|
msg "installing .desktop and icon"
|
|
install -Dm644 "$srcdir"/bitcoin-qt.desktop \
|
|
"$pkgdir"/usr/share/applications/bitcoin.desktop
|
|
install -Dm644 "$srcdir"/bitcoin128.svg \
|
|
"$pkgdir"/usr/share/pixmaps/bitcoin128.svg
|
|
|
|
msg "installing license"
|
|
install -Dm644 COPYING "$pkgdir/usr/share/licenses/$pkgname/COPYING"
|
|
|
|
msg2 'Installing man pages...'
|
|
install -Dm 644 doc/man/*.1 -t "$pkgdir/usr/share/man/man1"
|
|
|
|
msg2 'Installing documentation...'
|
|
install -dm 755 "$pkgdir/usr/share/doc/bitcoin"
|
|
for _doc in \
|
|
$(find doc -maxdepth 1 -type f -name "*.md" -printf '%f\n') \
|
|
release-notes; do
|
|
cp -dpr --no-preserve=ownership "doc/$_doc" \
|
|
"$pkgdir/usr/share/doc/bitcoin/$_doc"
|
|
done
|
|
|
|
|
|
msg2 'Installing bitcoin.conf...'
|
|
install -Dm 600 "$srcdir/bitcoin.conf" -t "$pkgdir/etc/bitcoin"
|
|
|
|
msg2 'Installing bitcoin.service...'
|
|
install -Dm 644 "$srcdir/bitcoin.service" -t "$pkgdir/usr/lib/systemd/system"
|
|
install -Dm 644 "$srcdir/bitcoin-reindex.service" \
|
|
-t "$pkgdir/usr/lib/systemd/system"
|
|
|
|
#msg2 'Installing bitcoin.logrotate...'
|
|
#install -Dm 644 "$srcdir/bitcoin.logrotate" "$pkgdir/etc/logrotate.d/bitcoin"
|
|
|
|
msg2 'Installing bash completion...'
|
|
for _compl in bitcoin-cli bitcoin-tx bitcoind; do
|
|
install -Dm 644 "contrib/${_compl}.bash-completion" \
|
|
"$pkgdir/usr/share/bash-completion/completions/$_compl"
|
|
done
|
|
}
|