# Maintainer: Christian Rebischke # Maintainer: kpcyrd # Contributor: Timothy Redaelli # Contributor: shahid # Contributor: James Harvey # ALARM: Kevin Mihelich # - build aarch64 with crc+crypto pkgbase=bitcoin pkgname=('bitcoin-daemon' 'bitcoin-qt' 'bitcoin-tx') pkgver=25.1 pkgrel=1 arch=('x86_64') url="https://bitcoin.org/en/wallets/desktop/linux/bitcoincore/" makedepends=( boost db5.3 libevent libminiupnpc.so libsqlite3.so libzmq.so qrencode qt5-base qt5-tools ) license=('MIT') source=("$pkgbase-$pkgver.tar.gz::https://bitcoincore.org/bin/bitcoin-core-$pkgver/bitcoin-$pkgver.tar.gz" "$pkgbase-$pkgver.SHA256SUMS::https://bitcoincore.org/bin/bitcoin-core-$pkgver/SHA256SUMS" "$pkgbase-$pkgver.SHA256SUMS.asc::https://bitcoincore.org/bin/bitcoin-core-$pkgver/SHA256SUMS.asc" "bitcoin.sysusers" "bitcoin.tmpfiles" "bitcoin-qt.desktop" "bitcoin-qt.appdata.xml") sha256sums=('bec2a598d8dfa8c2365b77f13012a733ec84b8c30386343b7ac1996e901198c9' '9fa2d284701690cb3e922cdbb0e3edbdfb1fa6ba20b28fc99af5129b50867170' 'SKIP' '7a77112fb094b9b2e6dd873e24c9a6bacb1f1c453d811a024f271f4b78f2a704' 'ba83570b4671b18c230f23d8d93cd8faa73179a546655448c14d1644d9b49f35' 'a020897651c03690eae3411fe401100fd1a2ffaa799247165eb71124609b7959' '71b125555451e9bc60b54a6658d886bad63bd18c58b5d6e3bd8977b82a70da7a') b2sums=('e8e4ea99cb40db420033c4df75e985af93cbb64f9862376e2de1a0731b4aeafbf43a95b33770e882ad77b73e454d48dbd5744902c78ade2b965e3d2d4e4b4656' '87b33e75c2f8c229b42d0de24e09dbefb5053af37f3cbf40fd43fbd7aa378c157fb1428fd902b766b8f759e684a0dc721e6113805b6892c8f6496b7e60dda548' 'SKIP' '25166f5726b43c531b7ba5f58aaf1c0242d26b96d2057da156024a8f9fc53702ea9ef0c67290cf8d302b9fb473cb16435dc2fe4489ebc5d0eae516635fd81c0e' '45d4703b78476cb1c5748f62863914e5397858c835e43cee2f4895608dbabf383993b840bb3ec2d4d2c64ca02152881ad4b495b28f94451f706687b83e99d2af' 'f14315183b5ac6b6a9f3e4ff269be37eeb6a4529bb4c9d0cd3e1d54e3ec8052f87ba1e6591080a0d1c78daf7af40cb2ecbd11d9702e217b9c1e50d5011a8e048' '236a841446b905f4cf154184109451300b984694ace96bee3ec75872563313279f9c543daaceed2dd712bf56115deee538b862aa73f15dee5447d235299389c7') validpgpkeys=(71A3B16735405025D447E8F274810B012346C9A6 28E72909F1717FE9607754F8A7BEB2621678D37D 79D00BAC68B56D422F945A8F8E3A8F3247DBCBBF C388F6961FB972A95678E327F62711DBDCA8AE56) changelog=Changelog prepare() { sha256sum -c --ignore-missing "$pkgbase-$pkgver.SHA256SUMS" cd "$pkgbase-$pkgver" autoreconf -fi } build() { cd $pkgbase-$pkgver [[ $CARCH == "aarch64" ]] && CFLAGS=`echo $CFLAGS | sed -e 's/-march=armv8-a/-march=armv8-a+crc+crypto/'` && CXXFLAGS="$CFLAGS" #remove _FORTIFY_SOURCE from CXXFLAGS to prevent a duplicate definition warning as configure adds _FORTIFY_SOURCE itself CXXFLAGS=${CXXFLAGS/-Wp,-D_FORTIFY_SOURCE=?/} ./configure --prefix=/usr --with-gui=qt5 --with-incompatible-bdb BDB_LIBS="-ldb_cxx-5.3" BDB_CFLAGS="-I/usr/include/db5.3" make } package_bitcoin-qt() { pkgdesc="Bitcoin is a peer-to-peer network based digital currency - Qt" depends=( db5.3 hicolor-icon-theme libevent libminiupnpc.so libsqlite3.so libzmq.so qrencode qt5-base ) cd $pkgbase-$pkgver install -Dm755 src/qt/bitcoin-qt "$pkgdir"/usr/bin/bitcoin-qt install -Dm644 contrib/completions/fish/bitcoin-qt.fish \ -t "$pkgdir/usr/share/fish/vendor_completions.d/" install -Dm644 doc/man/bitcoin-qt.1 \ "$pkgdir"/usr/share/man/man1/bitcoin-qt.1 install -Dm644 ../bitcoin-qt.desktop \ "$pkgdir"/usr/share/applications/bitcoin-qt.desktop install -Dm644 ../bitcoin-qt.appdata.xml \ "$pkgdir"/usr/share/metainfo/bitcoin-qt.appdata.xml install -Dm644 src/qt/res/src/bitcoin.svg \ "$pkgdir"/usr/share/icons/hicolor/scalable/apps/bitcoin-qt.svg for i in 16 32 64 128 256; do install -Dm644 share/pixmaps/bitcoin${i}.png \ "$pkgdir"/usr/share/icons/hicolor/${i}x${i}/apps/bitcoin-qt.png done install -Dm644 COPYING "$pkgdir/usr/share/licenses/$pkgname/COPYING" } package_bitcoin-daemon() { pkgdesc="Bitcoin is a peer-to-peer network based digital currency - daemon" depends=( db5.3 libevent libminiupnpc.so libsqlite3.so libzmq.so ) backup=('etc/bitcoin/bitcoin.conf') provides=('bitcoin-cli') replaces=('bitcoin-cli') cd $pkgbase-$pkgver install -Dm755 -t "$pkgdir/usr/bin" \ src/bitcoind \ src/bitcoin-cli install -Dm644 contrib/completions/bash/bitcoind.bash-completion \ "$pkgdir/usr/share/bash-completion/completions/bitcoind" install -Dm644 contrib/completions/bash/bitcoin-cli.bash-completion \ "$pkgdir/usr/share/bash-completion/completions/bitcoin-cli" install -Dm644 -t "$pkgdir/usr/share/fish/vendor_completions.d/" \ contrib/completions/fish/bitcoind.fish \ contrib/completions/fish/bitcoin-cli.fish install -Dm644 -t "$pkgdir"/usr/share/man/man1/ \ doc/man/bitcoind.1 \ doc/man/bitcoin-cli.1 install -Dm644 contrib/init/bitcoind.service \ "$pkgdir/usr/lib/systemd/system/bitcoind.service" install -Dm644 "$srcdir/bitcoin.sysusers" \ "$pkgdir/usr/lib/sysusers.d/bitcoin.conf" install -Dm644 "$srcdir/bitcoin.tmpfiles" \ "$pkgdir/usr/lib/tmpfiles.d/bitcoin.conf" install -Dm644 share/examples/bitcoin.conf \ "$pkgdir/etc/bitcoin/bitcoin.conf" install -Dm644 COPYING "$pkgdir/usr/share/licenses/$pkgname/COPYING" } package_bitcoin-tx() { pkgdesc="Bitcoin is a peer-to-peer network based digital currency - commandline tools" depends=( db5.3 libsqlite3.so ) cd $pkgbase-$pkgver for tool in bitcoin-tx bitcoin-util bitcoin-wallet; do install -Dm755 "src/$tool" -t "$pkgdir/usr/bin" if [ -f "contrib/completions/bash/$tool.bash-completion" ]; then install -Dm644 "contrib/completions/bash/$tool.bash-completion" \ "$pkgdir/usr/share/bash-completion/completions/$tool" fi install -Dm644 contrib/completions/fish/$tool.fish \ -t "$pkgdir/usr/share/fish/vendor_completions.d/" install -Dm644 "doc/man/$tool.1" \ "$pkgdir/usr/share/man/man1/$tool.1" done install -Dm644 COPYING "$pkgdir/usr/share/licenses/$pkgname/COPYING" } # vim:set ts=2 sw=2 et: