brotli-vl.spec 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191
  1. %bcond_with test
  2. Summary: Lossless compression algorithm
  3. Summary(ja): ロスレス圧縮アルゴリズム
  4. Name: brotli
  5. Version: 1.0.9
  6. Release: 1%{?_dist_release}
  7. Group: system
  8. Vendor: Project Vine
  9. Distribution: Vine Linux
  10. License: MIT
  11. URL: https://github.com/google/brotli
  12. Source0: https://github.com/google/brotli/archive/v%{version}.tar.gz
  13. BuildRequires: cmake
  14. BuildRequires: python3-devel python-rpm-macros python3-rpm-macros
  15. %description
  16. Brotli is a generic-purpose lossless compression algorithm that compresses
  17. data using a combination of a modern variant of the LZ77 algorithm, Huffman
  18. coding and 2nd order context modeling, with a compression ratio comparable
  19. to the best currently available general-purpose compression methods.
  20. It is similar in speed with deflate but offers more dense compression.
  21. %package -n python3-%{name}
  22. Summary: Lossless compression algorithm (python 3)
  23. Group: programming
  24. %{?python_provide:%python_provide python3-%{name}}
  25. Requires: python3
  26. %description -n python3-%{name}
  27. Brotli is a generic-purpose lossless compression algorithm that compresses
  28. data using a combination of a modern variant of the LZ77 algorithm, Huffman
  29. coding and 2nd order context modeling, with a compression ratio comparable
  30. to the best currently available general-purpose compression methods.
  31. It is similar in speed with deflate but offers more dense compression.
  32. This package installs a Python 3 module.
  33. %package -n %{name}-devel
  34. Summary: Lossless compression algorithm (development files)
  35. Group: programming
  36. Requires: %{name}%{?_isa} = %{version}-%{release}
  37. %description -n %{name}-devel
  38. Brotli is a generic-purpose lossless compression algorithm that compresses
  39. data using a combination of a modern variant of the LZ77 algorithm, Huffman
  40. coding and 2nd order context modeling, with a compression ratio comparable
  41. to the best currently available general-purpose compression methods.
  42. It is similar in speed with deflate but offers more dense compression.
  43. This package installs the development files
  44. %debug_package
  45. %prep
  46. %autosetup
  47. # fix permissions for -debuginfo
  48. # rpmlint will complain if I create an extra %%files section for
  49. # -debuginfo for this so we'll put it here instead
  50. %{__chmod} 644 c/enc/*.[ch]
  51. %{__chmod} 644 c/include/brotli/*.h
  52. %{__chmod} 644 c/tools/brotli.c
  53. %build
  54. mkdir -p build
  55. cd build
  56. %cmake .. -DCMAKE_INSTALL_PREFIX="%{_prefix}" \
  57. -DCMAKE_INSTALL_LIBDIR="%{_libdir}"
  58. %make_build
  59. cd ..
  60. %py3_build
  61. %install
  62. cd build
  63. %make_install
  64. # I couldn't find the option to not build the static libraries
  65. %__rm "%{buildroot}%{_libdir}/"*.a
  66. cd ..
  67. %py3_install
  68. %{__install} -dm755 "%{buildroot}%{_mandir}/man3"
  69. cd docs
  70. for i in *.3;do
  71. %{__install} -m644 "$i" "%{buildroot}%{_mandir}/man3/${i}brotli"
  72. done
  73. %if %{with test}
  74. %check
  75. cd build
  76. ctest -V
  77. cd ..
  78. %{__python3} setup.py test
  79. %endif
  80. %post -p /sbin/ldconfig
  81. %postun -p /sbin/ldconfig
  82. %files
  83. %license LICENSE
  84. %{_bindir}/brotli
  85. %{_libdir}/*.so.*
  86. # Note that there is no %%files section for the unversioned python module
  87. # if we are building for several python runtimes
  88. %files -n python3-%{name}
  89. %license LICENSE
  90. %{python3_sitearch}/*
  91. %files -n %{name}-devel
  92. %{_includedir}/*
  93. %{_libdir}/*.so
  94. %{_libdir}/pkgconfig/*
  95. %{_mandir}/man3/*
  96. %changelog
  97. * Tue Sep 22 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.0.9-1
  98. - nre upstream release.
  99. * Mon Aug 17 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.0.7-5
  100. - rebuilt with python-3.8.
  101. * Tue Aug 04 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 1.0.7-4
  102. - rebuilt with current environment.
  103. * Thu Jan 03 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 1.0.7-3
  104. - initial build for Vine Linux.
  105. * Sun Dec 09 2018 Miro Hrončok <mhroncok@redhat.com> - 1.0.7-2
  106. - Remove last python2 bits
  107. * Wed Nov 28 2018 Travis Kendrick pouar@pouar.net> - 1.0.7-1
  108. - Update to 1.0.7
  109. * Wed Nov 28 2018 Travis Kendrick pouar@pouar.net> - 1.0.5-2
  110. - remove Python 2 support https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal
  111. * Fri Jul 13 2018 Travis Kendrick pouar@pouar.net> - 1.0.5-1
  112. - update to 1.0.5
  113. * Thu Jul 12 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.4-4
  114. - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
  115. * Mon Jun 18 2018 Miro Hrončok <mhroncok@redhat.com> - 1.0.4-3
  116. - Rebuilt for Python 3.7
  117. * Wed Apr 18 2018 Travis Kendrick pouar@pouar.net> - 1.0.4-2
  118. - update to 1.0.4
  119. * Sat Mar 03 2018 Travis Kendrick <pouar@pouar.net> - 1.0.3-1
  120. - update to 1.0.3
  121. * Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.1-3
  122. - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
  123. * Sat Feb 03 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 1.0.1-2
  124. - Switch to %%ldconfig_scriptlets
  125. * Fri Sep 22 2017 Travis Kendrick <pouar@pouar.net> - 1.0.1-1
  126. - update to 1.0.1
  127. * Wed Aug 02 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.6.0-6
  128. - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
  129. * Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.6.0-5
  130. - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
  131. * Tue May 23 2017 Travis Kendrick <pouar@pouar.net> - 0.6.0-4
  132. - add man pages
  133. * Sun May 14 2017 Travis Kendrick <pouar@pouar.net> - 0.6.0-3
  134. - wrong directory for ctest
  135. - LICENSE not needed in -devel
  136. - fix "spurious-executable-perm"
  137. - rpmbuild does the cleaning for us, so 'rm -rf %%{buildroot}' isn't needed
  138. * Sat May 13 2017 Travis Kendrick <pouar@pouar.net> - 0.6.0-2
  139. - include libraries and development files
  140. * Sat May 06 2017 Travis Kendrick <pouar@pouar.net> - 0.6.0-1
  141. - Initial build