json-c-vl.spec 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162
  1. %define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}
  2. %define pkg_date 20220414
  3. Summary: A JSON implementation in C
  4. Name: json-c
  5. Version: 0.16
  6. Release: 1%{?_dist_release}
  7. Group: system
  8. Vendor: Project Vine
  9. Distribution: Vine Linux
  10. License: MIT
  11. URL: http://json-c.github.io/json-c/
  12. Source0: https://github.com/json-c/json-c/archive/json-c-%{version}-%{pkg_date}.tar.gz
  13. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  14. BuildRequires: cmake ninja
  15. %description
  16. JSON-C implements a reference counting object model that allows you to easily
  17. construct JSON objects in C, output them as JSON formatted strings and parse
  18. JSON formatted strings back into the C representation of JSON objects.
  19. %package devel
  20. Summary: Development files for json-c
  21. Group: programming
  22. Requires: %{name} = %{version}-%{release}
  23. Requires: pkgconfig
  24. %description devel
  25. This package contains the libraries and header files that are needed
  26. for writing applications that are using json-c.
  27. %package doc
  28. Summary: Documentation for json-c
  29. Group: documentation
  30. Requires: %{name} = %{version}-%{release}
  31. BuildArch: noarch
  32. %description doc
  33. This package contains documentation for json-c.
  34. %package -n compat32-%{name}
  35. Summary: A JSON implementation in C
  36. Group: system,legacy
  37. Requires: %{name} = %{version}-%{release}
  38. %description -n compat32-%{name}
  39. JSON-C implements a reference counting object model that allows you to easily
  40. construct JSON objects in C, output them as JSON formatted strings and parse
  41. JSON formatted strings back into the C representation of JSON objects.
  42. %package -n compat32-%{name}-devel
  43. Summary: Development files for json-c
  44. Group: programming,legacy
  45. Requires: compat32-%{name} = %{version}-%{release}
  46. Requires: pkgconfig
  47. %description -n compat32-%{name}-devel
  48. This package contains the libraries and header files that are needed
  49. for writing applications that are using json-c.
  50. %debug_package
  51. %prep
  52. %setup -q -n json-c-json-c-%{version}-%{pkg_date}
  53. %build
  54. %cmake \
  55. -DBUILD_SHARED_LIBS:BOOL=ON \
  56. -DBUILD_STATIC_LIBS:BOOL=OFF \
  57. -DCMAKE_BUILD_TYPE:STRING=RELEASE \
  58. -DCMAKE_C_FLAGS_RELEASE:STRING="" \
  59. -DDISABLE_BSYMBOLIC:BOOL=OFF \
  60. -DDISABLE_WERROR:BOOL=ON \
  61. -DENABLE_RDRAND:BOOL=ON \
  62. -DENABLE_THREADING:BOOL=ON \
  63. -G Ninja
  64. %cmake_build
  65. %install
  66. %{__rm} -rf $RPM_BUILD_ROOT
  67. %cmake_install
  68. %{__rm} -f $RPM_BUILD_ROOT%{_libdir}/*.la
  69. %check
  70. %ctest
  71. %clean
  72. %{__rm} -rf $RPM_BUILD_ROOT
  73. %files
  74. %defattr(-,root,root,-)
  75. %license COPYING
  76. %doc AUTHORS ChangeLog NEWS README*
  77. %{_libdir}/libjson-c.so.*
  78. %files devel
  79. %defattr(-,root,root,-)
  80. %dir %{_includedir}/json-c
  81. %{_includedir}/json-c/*
  82. %{_libdir}/libjson-c.so
  83. %{_libdir}/pkgconfig/json-c.pc
  84. %dir %{_libdir}/cmake/json-c
  85. %{_libdir}/cmake/json-c/*.cmake
  86. %files doc
  87. %defattr(-,root,root,-)
  88. %doc doc/html/*
  89. %if %{build_compat32}
  90. %files -n compat32-%{name}
  91. %defattr(-,root,root,-)
  92. %{_libdir}/libjson-c.so.*
  93. %files -n compat32-%{name}-devel
  94. %defattr(-,root,root,-)
  95. %{_libdir}/libjson-c.so
  96. %endif
  97. %changelog
  98. * Wed Oct 26 2022 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.16-1
  99. - new upstream release.
  100. * Fri Sep 03 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.15-1
  101. - new upstream release.
  102. - dropped Patch1000: fixed in upstream.
  103. * Sat May 16 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.14-1
  104. - updated to 0.14.
  105. - added Patch1000 to fix CVE-2020-12762.
  106. * Tue Jan 01 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.13.1-1
  107. - updated to 0.13.1.
  108. * Sat Jan 17 2015 Daisuke SUZUKI <daisuke@vinelinux.org> 0.11-1
  109. - update to 0.11
  110. * Wed Nov 28 2012 Daisuke SUZUKI <daisuke@linux.or.jp> 0.10-1
  111. - update to 0.10
  112. - update URL
  113. * Sat Oct 08 2011 Yoji TOYODA <bsyamato@sea.plala.or.jp> 0.9-2
  114. - create compat32 sub packages
  115. * Fri Oct 07 2011 Yoji TOYODA <bsyamato@sea.plala.or.jp> 0.9-1
  116. - initial build for Vine Linux