blob: f134c7b30c78a0f660d967c0fef0fdb4d6236dc7 (
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
|
# Maintainer: robertfoster
_pkgname=fabric
pkgname="hyperledger-${_pkgname}"
pkgver=2.5.0
pkgrel=1
pkgdesc="A platform for distributed ledger solutions, underpinned by a modular architecture delivering high degrees of confidentiality, resiliency, flexibility and scalability"
arch=(armv6h armv7h arm aarch64 i686 x86_64)
url="https://github.com/hyperledger/fabric"
license=('APACHE')
groups=('hyperledger')
depends=('go')
makedepends=('git' 'docker')
install="${pkgname}.install"
source=("${url}/archive/v$pkgver.tar.gz"
"${_pkgname}-peer.conf"
"${_pkgname}-peer.service"
hyperledger.sysusers
hyperledger.tmpfiles
)
prepare() {
cd "${srcdir}"
export GOPATH="${srcdir}/build"
mkdir -p "${GOPATH}/src/${url#*://}"
cp -r fabric-"$pkgver"/* \
"${GOPATH}/src/${url#*://}"
}
build() {
cd "${GOPATH}/src/${url#*://}"
make release
}
package() {
cd "${GOPATH}/src/${url#*://}"
install -Dm 644 -t "${pkgdir}/usr/share/licenses/${pkgname}" LICENSE
install -Dm 644 -t "${pkgdir}/usr/share/doc/${pkgname}" README.md
cp -r release/*/bin \
"${pkgdir}/usr"
install -dm 755 "${pkgdir}/etc/hyperledger/fabric/msp"
install -dm 755 "${pkgdir}/etc/hyperledger/fabric/tls"
cp -r sampleconfig/*.yaml \
"${pkgdir}/etc/hyperledger/fabric"
msg2 "Install systemd service"
install -Dm644 "${srcdir}/${_pkgname}-peer.service" \
"${pkgdir}/usr/lib/systemd/system/${_pkgname}-peer.service"
install -D -m644 "${srcdir}/hyperledger.sysusers" \
"${pkgdir}/usr/lib/sysusers.d/hyperledger.conf"
install -D -m644 "${srcdir}/hyperledger.tmpfiles" \
"${pkgdir}/usr/lib/tmpfiles.d/hyperledger.conf"
msg2 "Install conf file"
install -Dm644 "${srcdir}/${_pkgname}-peer.conf" \
"${pkgdir}/usr/lib/environment.d/${_pkgname}-peer.conf"
}
sha256sums=('abdb98622ac6b322286b3b879f793cc679e582d64c0775d7c8b030a0968f7f1b'
'bfdfb0f96bea3f6c2cafb17224fd5b21ec664352ef347841803e2448ca05426f'
'de85c5359019e44d5086d880cbcf6ab0b84e9bb456ed3e7302997f7e715eb908'
'9b29b63afd556563de227841060a2c7653d289cc70458992ef54d0339a53de94'
'729e4eba887b6b81d2d0bf40cb14db7163ada201657eef776017263d4a31dfdb')
|