mozjpeg-vl.spec 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121
  1. %bcond_without shared
  2. Summary: Improved JPEG encoder
  3. Summary(ja): 改良されたJPEGエンコーダ
  4. Name: mozjpeg
  5. Version: 4.0.3
  6. Release: 1%{?_dist_release}
  7. Group: graphics
  8. Vendor: Project Vine
  9. Distribution: Vine Linux
  10. License: IJG and BSD
  11. URL: https://github.com/mozilla/mozjpeg
  12. Source0: https://github.com/mozilla/mozjpeg/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
  13. #Patch1000: CVE-2018-14498.patch
  14. #Patch1001: CVE-2020-13790.patch
  15. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  16. BuildRequires: cmake
  17. BuildRequires: libpng-devel
  18. BuildRequires: zlib-devel
  19. %ifarch %{ix86} x86_64
  20. BuildRequires: nasm
  21. %endif
  22. %description
  23. MozJPEG reduces file sizes of JPEG images while retaining quality and
  24. compatibility with the vast majority of the world's deployed decoders.
  25. %description -l ja
  26. MozJPEGは、品質と世界で利用されている大多数のデコーダとの互換性を維持
  27. しつつJPEG画像のファイルサイズを縮小します。
  28. %if %{with shared}
  29. %package libs
  30. Summary: drop-in libraries of mozjpeg
  31. Group: system
  32. %description libs
  33. This package contains drop-in libraries of mozjpeg.
  34. %package devel
  35. Summary: development files of mozjpeg
  36. Group: programming
  37. Requires: %{name}-libs
  38. %description devel
  39. This package contains development files of mozjpeg.
  40. %endif
  41. %debug_package
  42. %prep
  43. %setup -q
  44. %autopatch -p1
  45. %build
  46. %cmake \
  47. -DWITH_JPEG8=ON \
  48. %if %{with shared}
  49. -DENABLE_STATIC=OFF \
  50. -DENABLE_SHARED=ON \
  51. %else
  52. -DENABLE_STATIC=ON \
  53. -DENABLE_SHARED=OFF \
  54. %endif
  55. %{nil}
  56. %cmake_build
  57. %install
  58. %{__rm} -rf %{buildroot}
  59. %cmake_install
  60. rm -rf pkgdocs
  61. cp -rf %{buildroot}%{_docdir}/mozjpeg ./pkgdocs
  62. rm -rf %{buildroot}%{_docdir}/mozjpeg
  63. %if %{with shared}
  64. rm -f %{buildroot}%{_libdir}/*.{a,la}
  65. %else
  66. rm -rf %{buildroot}%{_includedir}/*
  67. rm -rf %{buildroot}%{_libdir}/*
  68. %endif
  69. %clean
  70. %{__rm} -rf %{buildroot}
  71. %files
  72. %defattr(-,root,root)
  73. %license LICENSE.md
  74. %doc README.*
  75. %{_bindir}/*
  76. %{_mandir}/man1/*
  77. %if %{with shared}
  78. %files libs
  79. %{_libdir}/*.so.*
  80. %files devel
  81. %doc pkgdocs/*
  82. %{_libdir}/*.so
  83. %{_libdir}/pkgconfig/*
  84. %{_includedir}/*
  85. %endif
  86. %changelog
  87. * Mon Jul 26 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.0.3-1
  88. - new upstream release.
  89. * Thu Jun 18 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.3.1-1
  90. - initial build for Vine Linux