blob: 5076190cf0243205195451d2ff0b44fd55df8d33 (
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
|
# Maintainer: Benjamin Lopez <contact@scotow.com>
pkgname=mego
pkgver=1.3.0
pkgrel=2
pkgdesc="A simple megadl wrapper with auto-retry and download list"
arch=('x86_64')
url="https://github.com/scotow/${pkgname}"
license=('MIT')
depends=('megatools')
makedepends=('go' 'git')
source=("${pkgname}-${pkgver}.tar.gz::https://github.com/scotow/${pkgname}/archive/${pkgver}.tar.gz")
sha256sums=('e06df26dd1a0cfc78793f35c925da69225b8fcb3b061d4c65816616e2e861595')
prepare(){
mkdir -p src/github.com/scotow
ln -rTsf "${pkgname}-${pkgver}" "src/github.com/scotow/${pkgname}"
}
build(){
export GOPATH="${srcdir}"
cd "src/github.com/scotow/${pkgname}"
go get -v ./...
go install \
-gcflags "all=-trimpath=${GOPATH}/src" \
-asmflags "all=-trimpath=${GOPATH}/src" \
-ldflags "-extldflags ${LDFLAGS}" \
./...
}
package(){
install -Dm755 "bin/${pkgname}" "${pkgdir}/usr/bin/${pkgname}"
cd "${pkgname}-${pkgver}"
install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
|