Apache CloudStack for Arch Linux
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

43 lines
962 B

  1. # Maintainer: Pekka Helenius <pekka.helenius@fjordtek.com>
  2. pkgname=cloudmonkey-git
  3. _pkgname=cloudmonkey
  4. pkgver=6.1.0.r22.g773fc17
  5. pkgrel=1
  6. pkgdesc='Command line interface for Apache CloudStack management'
  7. arch=('any')
  8. url='https://github.com/apache/cloudstack-cloudmonkey'
  9. license=('Apache2')
  10. depends=()
  11. provides=('cloudmonkey')
  12. makedepends=('git' 'go' 'make')
  13. source=(
  14. "${pkgname}::git+https://github.com/apache/cloudstack-cloudmonkey.git"
  15. )
  16. sha256sums=('SKIP')
  17. pkgver() {
  18. cd $pkgname
  19. git describe --long | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
  20. }
  21. build() {
  22. cd $pkgname
  23. GOPATH="$srcdir" go build \
  24. -trimpath \
  25. -buildmode=pie \
  26. -mod=readonly \
  27. -modcacherw \
  28. -ldflags "-s -w" \
  29. -o ${_pkgname} .
  30. }
  31. package() {
  32. cd $pkgname
  33. install -Dm 755 ${_pkgname} "$pkgdir/usr/bin/${_pkgname}"
  34. install -Dm 644 -t "$pkgdir/usr/share/doc/${_pkgname}/" README.md
  35. install -Dm 644 LICENSE "$pkgdir/usr/share/licenses/${_pkgname}/LICENSE"
  36. }