-
Notifications
You must be signed in to change notification settings - Fork 2.1k
/
template
47 lines (41 loc) · 1.33 KB
/
template
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
# Template file for 'fs-repo-migrations'
pkgname=fs-repo-migrations
version=2.0.2+13~14+v1.0.0
revision=1
_version=${version##*+}
_path="fs-repo-${version#*+}"
_path="${_path%+*}"
_path="${_path/"~"/-to-}"
build_style=go
# go_import_path="github.com/ipfs/fs-repo-migrations/fs-repo-migrations"
hostmakedepends="git"
short_desc="Tool to upgrade the IPFS filesystem repository"
maintainer="Orphaned <orphan@voidlinux.org>"
license="MIT"
homepage="https://github.com/ipfs/fs-repo-migrations"
distfiles="https://github.com/ipfs/fs-repo-migrations/archive/${_path}/${_version}.tar.gz>${_path}-${_version}.tar.gz"
checksum=17396914690c74527e365a4bfffcd1097aeef7772a7e3fa5d9b42af1a0f5c294
# fix: collect2: fatal error: cannot find 'ld'
export LDFLAGS="-fuse-ld=bfd"
# export GOTOOLCHAIN=go1.20
go_import_path="github.com/ipfs/fs-repo-migrations/fs-repo-0-to-1"
for _v in $(seq 2 "${_path##*-}"); do
go_import_path+=" github.com/ipfs/fs-repo-migrations/fs-repo-$((_v - 1))-to-${_v}"
done
unset _v
do_configure() {
GOSRCPATH="${GOPATH}/src/github.com/ipfs/fs-repo-migrations"
mkdir -p ${GOSRCPATH%/*}/
ln -rfs "$PWD" "${GOSRCPATH}"
}
pre_build() {
GOSRCPATH="${GOPATH}/src/github.com/ipfs/fs-repo-migrations"
}
pre_install() {
GOSRCPATH="${GOPATH}/src/github.com/ipfs/fs-repo-migrations"
}
post_install() {
vlicense LICENSE
vdoc README.md
vdoc run.md
}