libcbor/libcbor.spec
2024-02-27 06:25:54 +00:00

50 lines
1.1 KiB
RPMSpec

Name: libcbor
Version: 0.10.2
Release: 1
Summary: A CBOR parsing library
License: MIT
URL: http://libcbor.org
Source0: https://github.com/PJK/%{name}/archive/v%{version}.tar.gz
BuildRequires: cmake gcc-c++ make libcmocka-devel
%description
libcbor is a C library for parsing and generating CBOR.
%package devel
Summary: Development files for %{name}
Requires: %{name} = %{version}-%{release}
%description devel
The %{name}-devel contains libraries and header files for %{name}.
%prep
%autosetup -n %{name}-%{version}
sed -i 's|${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}/pkgconfig|${CMAKE_INSTALL_LIBDIR}/pkgconfig|' src/CMakeLists.txt
%build
%cmake . -DCMAKE_BUILD_TYPE=Release -DWITH_TESTS=ON
%make_build
%install
%make_install
%files
%license LICENSE.md
%doc README.md
%{_libdir}/libcbor.so.0*
%files devel
%{_includedir}/cbor.h
%{_includedir}/cbor/*.h
%{_includedir}/cbor/internal/*.h
%{_libdir}/libcbor.so
%{_libdir}/pkgconfig/libcbor.pc
%changelog
* Tue Feb 27 2024 wangshuo <wangshuo@kylinos.cn> - 0.10.2-1
- Update version to 0.10.2
* Wed May 11 2022 yangchenguang <yangchenguang@uniontech.com> - 0.9.0-1
- Package Init