1 # Maintainer: Sven-Hendrik Haase <svenstaro@archlinux.org>
2 # Contributor: Frederik Schwan <frederik dot schwan at linux dot com>
3 # Contributor: Daniel Maslowski <info@orangecms.org>
8 _pkgver="${pkgver//./-}${_timever//:/-}"
10 pkgdesc='Object storage server compatible with Amazon S3'
12 url='https://minio.io'
15 makedepends=('go' 'git')
17 source=(git+https://github.com/minio/minio.git#tag=RELEASE.${_pkgver}
21 backup=('etc/minio/minio.conf')
23 '9fb09d19af9d7a00e4680cd92d208ddd44ce52328f6efee68d7ee47f591cbe77ee88ce139a677bcf8836de0643de18c6c7c4005d50b0056f9b861c3d595e5233'
24 'f4df8e50618712b6e5f62e2674eca4430ef17ef003426bd83ea6b427da4e0fb519589cc14547b08db4b4a0de114488920071295a680b0c1cb5fd508d31576190'
25 '7e4617aed266cf48a2ff9b0e80e31641d998537c78d2c56ce97b828cfc77d96dbf64728d4235dac7382d6e5b201388bef6722959302de5e2298d93f4ec1e0e63')
28 export CGO_LDFLAGS="${LDFLAGS}"
29 export CGO_CFLAGS="${CFLAGS}"
30 export CGO_CPPFLAGS="${CPPFLAGS}"
31 export CGO_CXXFLAGS="${CXXFLAGS}"
32 export GOFLAGS="-buildmode=pie -trimpath -ldflags=-linkmode=external -mod=readonly -modcacherw"
36 sed -i "s/Version.*/Version = \"${pkgver//./-}${_timever}\"/g" cmd/build-constants.go
37 sed -i "s/ReleaseTag.*/ReleaseTag = \"RELEASE.${_pkgver}\"/g" cmd/build-constants.go
38 sed -i "s/CommitID.*/CommitID = \"$(git rev-parse HEAD)\"/g" cmd/build-constants.go
44 install -dm750 -o 103 -g 103 "${pkgdir}/srv/minio"
45 install -dm750 -o 103 -g 103 "${pkgdir}/var/lib/minio"
47 install -Dm755 minio/minio "${pkgdir}/usr/bin/minio"
48 install -Dm600 "${srcdir}/minio.conf" "${pkgdir}/etc/minio/minio.conf"
49 install -Dm644 "${srcdir}/minio.service" "${pkgdir}/usr/lib/systemd/system/minio.service"
50 install -Dm644 "${srcdir}/minio.sysusers" "${pkgdir}/usr/lib/sysusers.d/minio.conf"