PKGBUILD 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. # Maintainer (Arch) : Felix Yan <felixonmars@archlinux.org>
  2. # Contributor : Brian Bidulock <bidulock@openss7.org>
  3. # Maintainer : Sagar Acharya <sagar@hyperbola.info>
  4. pkgname=http-parser
  5. pkgver=2.9.4
  6. pkgrel=1
  7. pkgdesc="Parser for HTTP Request/Response written in C"
  8. arch=('x86_64')
  9. url="https://github.com/nodejs/http-parser"
  10. license=('Expat')
  11. depends=('glibc')
  12. makedepends=('quilt')
  13. source=($pkgname-$pkgver.tar.gz::"${url}/archive/v$pkgver.tar.gz"
  14. "series"
  15. "cherry-pick.v2.9.4-4-g805a0d1.fix-test-numbers.patch"
  16. "cherry-pick.v2.9.4-6-gd9275da.fix-wsign-compare-warning.patch"
  17. "cherry-pick.v2.9.4-7-g4b99e42.test-content-length-header-parsing.patch"
  18. "cherry-pick.v2.9.4-8-ge13b274.allow-content-length-and-transfer-encoding-chunked.patch"
  19. "cherry-pick.v2.9.4-9-g4f15b7d.fix-sizeof-http-parser-assert.patch")
  20. sha512sums=('b45df7b94d1c51079d44687d0a7f901f44faae51df4e84c7e3fe38f130c2d809d0e7c2a146c57b3723e60732aededc246bf44eadb10a95b710963d641f9fe7cd'
  21. 'a30538ea9add0cb95c5c1b776469b98e6807e41f860d03c58b76529129c7de4a178ce2187500c05ae85d83a7f777a131fd3188ce5a9eb52bdd264e7be3d5c43c'
  22. '6365c8d88a51d5bcac4d2c775cf3358bab0135a0a268e5f95bc2a3fb2233bdc1bd69cd667312221d63bc7da42efc930cec833151b6fd42545f493455d53bfb71'
  23. 'f3eb9c4addbca349e49de997a9618790b6a3f6bd4974bbcc45d587664de58c1e1248f3ae0d68fce5721e57c1435f94f5651ae3a9d8786f4025a8fb434b136639'
  24. '73ecafabebabb334f1e99eeb1cd65691ffbbb92c5dfbd5ac50da421574f9a071c79653392629e29724eb80c7029015cad8ff312b1d700d68dba958076357cc54'
  25. '35c78957489f7ece9580a333f659075e8d1ee3ec1d3a2e0718e308cf98454975540ada27a12c0dc41161a4fca49269365ba65c20107281779bce0afe1c26a1ea'
  26. 'ac6ffc375e7afaf786401ebf865079824249eb3b96ce180a0590f66bf8d537d62d7829e1d28007fe023b6cc72c50d82045c272b4012e127829fb65996d32817f')
  27. prepare() {
  28. cd $pkgname-$pkgver
  29. mkdir ./patches
  30. cp ${srcdir}/series ./patches
  31. cp ${srcdir}/*.patch ./patches
  32. export QUILT_PATCHES=patches
  33. export QUILT_REFRESH_ARGS='-p ab --no-timestamps --no-index'
  34. export QUILT_DIFF_ARGS='--no-timestamps'
  35. quilt push -av
  36. sed -i 's|-Werror||' Makefile
  37. }
  38. build() {
  39. cd $pkgname-$pkgver
  40. make library
  41. }
  42. check() {
  43. cd $pkgname-$pkgver
  44. make test
  45. }
  46. package() {
  47. cd $pkgname-$pkgver
  48. make PREFIX="$pkgdir/usr" install
  49. install -Dm644 LICENSE-MIT -t "$pkgdir"/usr/share/licenses/$pkgname/
  50. }