summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 583fdc675fc2b5ec80a4cc455bbcb1722bfd1ab8 (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
# Maintainer: Stefan Auditor <stefan.auditor@erdfisch.de>
# Please report issues at https://github.com/sanduhrs/arch-aur-php-uploadprogress-git

_pkgname=uploadprogress
pkgname=php-${_pkgname}-git
pkgver=r126.e77cf26
pkgrel=1
pkgdesc="An extension to track progress of a file upload"
arch=('i686' 'x86_64')
url="http://pecl.php.net/package/uploadprogress"
license=('PHP')
depends=('php')
makedepends=('php' 'git' 'autoconf')
provides=("php-${_pkgname}")
conflicts=("php-${_pkgname}")
install=${_pkgname}.install
source=("${_pkgname}"::"git+https://github.com/php/pecl-php-uploadprogress.git")
sha512sums=('SKIP')

pkgver() {
  cd "${srcdir}/${_pkgname}"
  printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

build() {
  cd "${srcdir}/${_pkgname}"
  phpize
  ./configure
  make
}

package() {
  cd "${srcdir}/${_pkgname}"
  echo ";extension=${_pkgname}.so" > ${_pkgname}.ini
  install -Dm644 ${_pkgname}.ini "${pkgdir}/etc/php/conf.d/${_pkgname}.ini"
  make install INSTALL_ROOT="${pkgdir}/"
}