PKGBUILD 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. # Maintainer: txtsd <aur.archlinux@ihavea.quest>
  2. pkgname=flaresolverr
  3. _pkgname=flaresolverr
  4. __pkgname=FlareSolverr
  5. pkgver=3.1.0
  6. pkgrel=1
  7. pkgdesc='A proxy server to bypass Cloudflare protection'
  8. arch=('any')
  9. url='https://github.com/FlareSolverr/FlareSolverr'
  10. license=('MIT')
  11. depends=('chromium' 'python-bottle' 'python-waitress' 'python-selenium' 'python-func-timeout'
  12. 'python-pefile' 'python-requests' 'python-websockets' 'python-xvfbwrapper')
  13. makedepends=('git')
  14. # checkdepends=('python-webtest')
  15. conflicts=('flaresolverr-bin' 'flaresolverr-git')
  16. install='flaresolverr.install'
  17. source=("git+https://github.com/FlareSolverr/FlareSolverr.git#tag=v$pkgver"
  18. "flaresolverr.service"
  19. "flaresolverr.sysusers"
  20. "flaresolverr.tmpfiles"
  21. "flaresolverr.install")
  22. sha256sums=('SKIP'
  23. 'c147d51e7fd78e5e2b4648db5d1052a36b151559bfa08aa7776bd34aa0897bd0'
  24. '62f114d4e559cf9dae22bfd90759eff697e42da5f700a52988e70e78f3048ae2'
  25. '4a61a6d9db1a9f4ec0812d86ef524a7f575a45f272404f0ebfc79376628feeb2'
  26. 'f3585f385fe8dd2d619144b8e666f1883d3501ce05d81e7c3ed4a57f0d093e85')
  27. # check() {
  28. # cd "${srcdir}/${__pkgname}/src"
  29. #
  30. # python tests.py
  31. # python tests_sites.py
  32. # }
  33. package() {
  34. cd "${pkgdir}"
  35. install -dm755 "opt/${_pkgname}"
  36. install -Dm644 "${srcdir}/${__pkgname}/LICENSE" "${pkgdir}/usr/share/licenses/${_pkgname}/LICENSE"
  37. rm "${srcdir}/${__pkgname}/LICENSE"
  38. install -Dm644 "${srcdir}/flaresolverr.service" "${pkgdir}/usr/lib/systemd/system/${_pkgname}.service"
  39. # Checks one directory above src/
  40. # We don't want that
  41. sed -i "s/os.pardir, //" "${srcdir}/${__pkgname}/src/utils.py"
  42. cp -a "${srcdir}/${__pkgname}/src/"* "${pkgdir}/opt/${_pkgname}"
  43. cp "${srcdir}/${__pkgname}/package.json" "${pkgdir}/opt/${_pkgname}"
  44. install -Dm644 "${srcdir}/flaresolverr.sysusers" "${pkgdir}/usr/lib/sysusers.d/${_pkgname}.conf"
  45. install -Dm644 "${srcdir}/flaresolverr.tmpfiles" "${pkgdir}/usr/lib/tmpfiles.d/${_pkgname}.conf"
  46. }