zstd-vl.spec 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192
  1. %bcond_without pzstd
  2. Name: zstd
  3. Summary: Zstd compression library
  4. Version: 1.4.5
  5. Release: 1%{?_dist_release}
  6. Vendor: Project Vine
  7. Distribution: Vine Linux
  8. License: BSD and GPLv2
  9. URL: https://github.com/facebook/zstd
  10. Source0: https://github.com/facebook/zstd/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
  11. BuildRequires: gcc gtest-devel
  12. %if %{with pzstd}
  13. BuildRequires: gcc-c++
  14. %endif
  15. %description
  16. Zstd, short for Zstandard, is a fast lossless compression algorithm,
  17. targeting real-time compression scenarios at zlib-level compression ratio.
  18. %package -n lib%{name}
  19. Summary: Zstd shared library
  20. %description -n lib%{name}
  21. Zstandard compression shared library.
  22. %package -n lib%{name}-devel
  23. Summary: Header files for Zstd library
  24. Requires: lib%{name}%{?_isa} = %{version}-%{release}
  25. %description -n lib%{name}-devel
  26. Header files for Zstd library.
  27. %prep
  28. %setup -q
  29. find -name .gitignore -delete
  30. %build
  31. export CFLAGS="$RPM_OPT_FLAGS"
  32. export LDFLAGS="$RPM_LD_FLAGS"
  33. for dir in lib programs; do
  34. %make_build -C "$dir"
  35. done
  36. %if %{with pzstd}
  37. export CXXFLAGS="$RPM_OPT_FLAGS -std=c++11"
  38. %make_build -C contrib/pzstd
  39. %endif
  40. %check
  41. export CFLAGS="$RPM_OPT_FLAGS"
  42. export LDFLAGS="$RPM_LD_FLAGS"
  43. make -C tests test-zstd
  44. %if %{with pzstd}
  45. export CXXFLAGS="$RPM_OPT_FLAGS -std=c++11"
  46. make -C contrib/pzstd test
  47. %endif
  48. %install
  49. %make_install PREFIX=%{_prefix} LIBDIR=%{_libdir}
  50. # Don't install the static lib
  51. rm %{buildroot}%{_libdir}/libzstd.a
  52. %if %{with pzstd}
  53. install -D -m755 contrib/pzstd/pzstd %{buildroot}%{_bindir}/pzstd
  54. install -D -m644 programs/%{name}.1 %{buildroot}%{_mandir}/man1/p%{name}.1
  55. %endif
  56. %files
  57. %doc CHANGELOG README.md
  58. %{_bindir}/%{name}
  59. %if %{with pzstd}
  60. %{_bindir}/p%{name}
  61. %{_mandir}/man1/p%{name}.1*
  62. %endif
  63. %{_bindir}/%{name}mt
  64. %{_bindir}/un%{name}
  65. %{_bindir}/%{name}cat
  66. %{_bindir}/%{name}grep
  67. %{_bindir}/%{name}less
  68. %{_mandir}/man1/%{name}.1*
  69. %{_mandir}/man1/un%{name}.1*
  70. %{_mandir}/man1/%{name}cat.1*
  71. %{_mandir}/man1/%{name}grep.1*
  72. %{_mandir}/man1/%{name}less.1*
  73. %license COPYING LICENSE
  74. %files -n lib%{name}
  75. %{_libdir}/libzstd.so.*
  76. %license COPYING LICENSE
  77. %files -n lib%{name}-devel
  78. %{_includedir}/zbuff.h
  79. %{_includedir}/zdict.h
  80. %{_includedir}/zstd.h
  81. %{_includedir}/zstd_errors.h
  82. %{_libdir}/pkgconfig/libzstd.pc
  83. %{_libdir}/libzstd.so
  84. %post -n lib%{name} -p /sbin/ldconfig
  85. %postun -n lib%{name} -p /sbin/ldconfig
  86. %changelog
  87. * Thu Jul 16 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 1.4.5-1
  88. - new upstream release.
  89. * Sun Mar 29 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 1.4.4-3
  90. - initial build for Vine Linux.
  91. * Fri Jan 31 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.4-2
  92. - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
  93. * Wed Jan 15 2020 Pádraig Brady <P@draigBrady.com> - 1.4.4-1
  94. - Latest upstream
  95. * Wed Jul 31 2019 Pádraig Brady <P@draigBrady.com> - 1.4.2-1
  96. - Latest upstream
  97. * Sat Jul 27 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.0-2
  98. - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
  99. * Mon Apr 29 2019 Pádraig Brady <P@draigBrady.com> - 1.4.0-1
  100. - Latest upstream
  101. * Sun Feb 03 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.3.8-2
  102. - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
  103. * Mon Dec 31 2018 Pádraig Brady <P@draigBrady.com> - 1.3.8-1
  104. - Latest upstream
  105. * Mon Oct 08 2018 Pádraig Brady <P@draigBrady.com> - 1.3.6-1
  106. - Latest upstream
  107. * Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.3.5-2
  108. - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
  109. * Mon Jul 02 2018 Pádraig Brady <P@draigBrady.com> - 1.3.5.1
  110. - Latest upstream
  111. * Wed Mar 28 2018 Pádraig Brady <P@draigBrady.com> - 1.3.4-1
  112. - Latest upstream
  113. * Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.3.3-3
  114. - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
  115. * Fri Feb 02 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 1.3.3-2
  116. - Switch to %%ldconfig_scriptlets
  117. * Thu Dec 21 2017 Pádraig Brady <P@draigBrady.com> - 1.3.3-1
  118. - Latest upstream
  119. * Fri Nov 10 2017 Pádraig Brady <P@draigBrady.com> - 1.3.2-1
  120. - Latest upstream
  121. * Mon Aug 21 2017 Pádraig Brady <P@draigBrady.com> - 1.3.1-1
  122. - Latest upstream
  123. * Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.3.0-3
  124. - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
  125. * Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.3.0-2
  126. - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
  127. * Sun Jul 16 2017 Pádraig Brady <P@draigBrady.com> - 1.3.0-1
  128. - Latest upstream
  129. * Mon May 08 2017 Pádraig Brady <P@draigBrady.com> - 1.2.0-1
  130. - Latest upstream
  131. * Mon Mar 06 2017 Pádraig Brady <P@draigBrady.com> - 1.1.3-1
  132. - Latest upstream
  133. * Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.1-2
  134. - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
  135. * Wed Nov 02 2016 Pádraig Brady <pbrady@redhat.com> - 1.1.1-1
  136. - Latest upstream
  137. * Thu Oct 6 2016 Pádraig Brady <pbrady@fb.com> 1.1.0-2
  138. - Add pzstd(1)
  139. * Thu Sep 29 2016 Pádraig Brady <pbrady@fb.com> 1.1.0-1
  140. - New upstream release
  141. - Remove examples and static lib
  142. * Mon Sep 12 2016 Pádraig Brady <pbrady@fb.com> 1.0.0-2
  143. - Adjust various upstream links
  144. - Parameterize various items in spec file
  145. * Mon Sep 5 2016 Pádraig Brady <pbrady@fb.com> 1.0.0-1
  146. - Initial release