PKGBUILD 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131
  1. # Maintainer (arch): Andreas Radke <andyrtr@archlinux.org>
  2. # Contributor: Art Gramlich <art@gramlich-net.com>
  3. # Contributor: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
  4. # Contributor: Eli Schwartz <eschwartz@archlinux.org>
  5. # Contributor: bill-auger <bill-auger@programmer.net>
  6. # Maintainer: Parabola Hackers <dev@lists.parabola.nu>
  7. # parabola changes and rationale:
  8. #
  9. # Several Parabola packages depends on ICU, and the ICU soname changes often.
  10. # This means that if we don't rebuild all the Parabola packages which depend
  11. # on ICU, as soon as the new ArchLinux, ArchLinux32, and ArchLinuxARM ICU
  12. # packages are synchronized into the Parabola repositories, we have a problem.
  13. # The repo server synchronizes with the upstream repos un-attended; so this
  14. # is a wonderful surprise each time; and we hustle frantucally to get the
  15. # system sane again. We could watch the testing and staging repos of each
  16. # upstream, and start re-building everything in a Parabola staging repo;
  17. # but that could result in discarded work, if those exact versions are not the
  18. # ones which are eventually released into [core].
  19. #
  20. # At first nothing was done to fix or workaround that issue. In practice,
  21. # once a new ICU was synchronized, many users were upgrading before the
  22. # Parabola packages had the time to be rebuilt. For such users, it
  23. # broke all the installed Parabola packages that were depending on the old ICU.
  24. # This means that users had to find a way to downgrade packages manually or wait
  25. # until developers would finally have rebuilt all the packages that were broken.
  26. #
  27. # Then such packages were modified to make them depend on the exact version of
  28. # the ICU packages they were built against. This way, once the new ICU package
  29. # was synchronized, users could not upgrade if they had packages that were not
  30. # rebuilt yet against the new ICU package. However this workaround also prevents
  31. # installing packages that depends on the new ICU.
  32. #
  33. # The correct fix would probably be to automatically build all the Packages
  34. # instead of relying on Arch Linux Packages. Still, a staging repo would be
  35. # required to hold the new packages, until they all can be released together sanely.
  36. # However we don't have the code, configuration and/or infrastructure to run
  37. # an automatic builder for all packages yet even if there is work in this
  38. # direction.
  39. #
  40. # In the meantime, this version of ICU exists for Parabola packages to link against
  41. # at runtime. In this way, Parabola packages can depend only on the "sodeps" exposed
  42. # by ICU, which is usually provided by the upstream distribution's ICU; but may be
  43. # this ICU, if the Parabola package has yet to be rebuilt agianst the upgraded ICU.
  44. #
  45. # It is inspired by the admittedly awkward hack of versioned library
  46. # dependencies more commonly seen (e.g. in the AUR as 'icu65') on which
  47. # proprietary binaries built against Debian's ICU will depend. It is awkward,
  48. # in the eyes of the beholder and this elegantly scales to Parabola's needs,
  49. # without consuming increasing resources, which is the best definition of "not
  50. # awkward".
  51. #
  52. # To use it, simply add the following dependency to any package which parabola
  53. # has built or rebuilt:
  54. #
  55. # depends=('libicui18n.so')
  56. #
  57. # or whichever shared library is reported by readelf -d /path/to/compiled/ELF/file
  58. # and, every time the upstream distribution upgrades ICU, update this package
  59. # as well, to ensure it always stays exactly one version behind.
  60. #
  61. # This works well for ICU, even for packages which link to both the older and
  62. # newer versions of libicu*.so, since ICU uses versioned symbols as reported by
  63. #
  64. # nm -D --demangle --with-symbol-versions /path/to/library
  65. #
  66. # However, caution must be taken before implementing the same idea for other
  67. # libraries. So the idea is to only use it for libraries that often have this
  68. # issue.
  69. #
  70. # Changes:
  71. # - remove all files other than libicu*.so.*
  72. # - depend on icu; this is needed because if the package is installed on its
  73. # own, ldconfig will create untracked symlinks which were supposed to be
  74. # installed by the icu package.
  75. pkgname=icu-compat-68
  76. pkgver=68.2
  77. pkgrel=1
  78. pkgrel+=.parabola1
  79. pkgdesc="International Components for Unicode library"
  80. pkgdesc+=" (compatibility libraries for the previous release)"
  81. arch=(x86_64)
  82. arch+=(armv7h i686)
  83. url="https://icu.unicode.org"
  84. license=('custom:icu')
  85. depends=('gcc-libs' 'sh')
  86. depends+=("icu>${pkgver}")
  87. conflicts=("icu<=${pkgver}")
  88. makedepends=('python')
  89. provides=(libicu{data,i18n,io,test,tu,uc}.so)
  90. source=(https://github.com/unicode-org/icu/releases/download/release-${pkgver//./-}/icu4c-${pkgver//./_}-src.tgz{,.asc})
  91. # https://github.com/unicode-org/icu/releases/download/release-68-2/SHASUM512.txt
  92. sha512sums=('24f3b7981667b37df58118f56ae76a09b719358c1efa8d6f044d28ef8df1c722a894957acadfb3c37aee39ac845893924fc3370d6bbe09875aec8d937059f84b'
  93. 'SKIP')
  94. #validpgpkeys=('BA90283A60D67BA0DD910A893932080F4FB419E3') # "Steven R. Loomis (filfla-signing) <srloomis@us.ibm.com>"
  95. #validpgpkeys+=('9731166CD8E23A83BEE7C6D3ACA5DBE1FD8FABF1') # "Steven R. Loomis (ICU Project) <srl@icu-project.org>"
  96. #validpgpkeys+=('FFA9129A180D765B7A5BEA1C9B432B27D1BA20D7') # "Fredrik Roubert <fredrik@roubert.name>"
  97. #validpgpkeys+=('E4098B78AFC94394F3F49AA903996C7C83F12F11') # "keybase.io/srl295 <srl295@keybase.io>"
  98. #validpgpkeys+=('4569BBC09DA846FC91CBD21CE1BBA44593CF2AE0') # "Steven R. Loomis (codesign-qormi) <srloomis@us.ibm.com>"
  99. validpgpkeys=('0E51E7F06EF719FBD072782A5F56E5AFA63CCD33') #"Craig Cornelius (For use with ICU releases) <ccornelius@google.com>"
  100. build() {
  101. cd icu/source
  102. ./configure --prefix=/usr \
  103. --sysconfdir=/etc \
  104. --mandir=/usr/share/man \
  105. --sbindir=/usr/bin
  106. make
  107. }
  108. check() {
  109. cd icu/source
  110. make -k check
  111. }
  112. package() {
  113. cd icu/source
  114. make -j1 DESTDIR="${pkgdir}" install
  115. # Install license
  116. install -Dm644 "${srcdir}"/icu/LICENSE "${pkgdir}"/usr/share/licenses/"${pkgname}"/LICENSE
  117. # to avoid conflicts against the preferred 'icu' package, we remove all files
  118. # except the actual shared libraries
  119. rm -r "${pkgdir}"/usr/{bin,include,lib/{icu,pkgconfig},share}
  120. rm "${pkgdir}"/usr/lib/*.so
  121. }