template.py 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. pkgname = "pcre"
  2. pkgver = "8.45"
  3. pkgrel = 0
  4. build_style = "gnu_configure"
  5. configure_args = [
  6. "--with-pic",
  7. "--enable-utf8",
  8. "--enable-unicode-properties",
  9. "--enable-pcretest-libedit",
  10. "--enable-pcregrep-libz",
  11. "--enable-pcregrep-libbz2",
  12. "--enable-newline-is-anycrlf",
  13. "--enable-jit",
  14. "--enable-static",
  15. "--disable-stack-for-recursion",
  16. ]
  17. hostmakedepends = ["pkgconf"]
  18. makedepends = ["zlib-devel", "libbz2-devel", "libedit-devel"]
  19. pkgdesc = "Perl Compatible Regular Expressions"
  20. maintainer = "q66 <q66@chimera-linux.org>"
  21. license = "BSD-3-Clause"
  22. url = "http://www.pcre.org"
  23. source = f"$(SOURCEFORGE_SITE)/{pkgname}/{pkgname}/{pkgver}/{pkgname}-{pkgver}.tar.bz2"
  24. sha256 = "4dae6fdcd2bb0bb6c37b5f97c33c2be954da743985369cddac3546e3218bffb8"
  25. options = ["!cross"]
  26. match self.profile().arch:
  27. case "riscv64":
  28. configure_args += ["--disable-jit"]
  29. def post_install(self):
  30. self.install_license("LICENCE")
  31. @subpackage("libpcrecpp")
  32. def _libpcrecpp(self):
  33. self.pkgdesc = f"{pkgdesc} (C++ shared libraries)"
  34. return ["usr/lib/libpcrecpp.so.*"]
  35. @subpackage("libpcre")
  36. def _libpcre(self):
  37. self.pkgdesc = f"{pkgdesc} (shared libraries)"
  38. return self.default_libs()
  39. @subpackage("pcre-devel")
  40. def _devel(self):
  41. self.depends += ["zlib-devel", "libbz2-devel"]
  42. return self.default_devel(extra = ["usr/share/doc"])