From e9087c8c193dc8a5c9f541920fe74861336fe186 Mon Sep 17 00:00:00 2001 From: "chenyuao.cya" Date: Fri, 7 Apr 2023 19:41:46 +0800 Subject: [PATCH] change spec file format --- libcbor.spec | 66 ++++++++++++++++++++++++++++++---------------------- 1 file changed, 38 insertions(+), 28 deletions(-) diff --git a/libcbor.spec b/libcbor.spec index 8386291..3d00a07 100644 --- a/libcbor.spec +++ b/libcbor.spec @@ -1,77 +1,87 @@ -%define anolis_release 2 +%define anolis_release 3 Name: libcbor Version: 0.10.2 Release: %{anolis_release}%{?dist} -Summary: A CBOR parsing library - +Summary: libcbor is a C library for parsing and generating CBOR License: MIT URL: http://libcbor.org Source0: https://github.com/PJK/%{name}/archive/v%{version}.tar.gz -BuildRequires: cmake -BuildRequires: gcc -BuildRequires: gcc-c++ -BuildRequires: python3-breathe -BuildRequires: python3-sphinx -BuildRequires: python3-sphinx_rtd_theme -BuildRequires: make +BuildRequires: cmake gcc gcc-c++ automake autoconf +BuildRequires: python3-breathe python3-sphinx python3-sphinx_rtd_theme + %description -libcbor is a C library for parsing and generating CBOR. +libcbor is a C library for parsing and generating CBOR, the general-purpose schema-less binary data format. +Main features: +Complete IETF RFC 8949 (STD 94) conformance +Robust platform-independent C99 implementation +Layered architecture offers both control and convenience +Flexible memory management +No shared global state - threading friendly +Proper handling of UTF-8 +Full support for streams & incremental processing +Extensive documentation and test suite +No runtime dependencies, small footprint %package doc -Summary: Documentation files for %{name} +Summary: Documentation files for libcbor Requires: %{name} = %{version}-%{release} BuildArch: noarch + %description doc -The %{name}-doc package contains documentation files for %{name}. +The libcbor-doc package contains documentation files for libcbor %package devel -Summary: Development files for %{name} +Summary: Development files for libcbor Requires: %{name} = %{version}-%{release} %description devel -The %{name}-devel contains libraries and header files for %{name}. +The libcbor-devel contains header files and libraries for libcbor + %prep -%autosetup -n %{name}-%{version} +%autosetup -n %{name}-%{version} -p1 sed -i 's|${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}/pkgconfig|${CMAKE_INSTALL_LIBDIR}/pkgconfig|' src/CMakeLists.txt + %build %cmake -B . -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFFIX="/usr" ./ %make_build -cd doc -make man +cd doc && make man %install %make_install mkdir -p %{buildroot}%{_mandir}/man3 -cp doc/build/man/* %{buildroot}%{_mandir}/man3 - +install -m 0644 -p doc/build/man/* %{buildroot}%{_mandir}/man3 %generate_compatibility_deps + %files %dir %{abidir} %license LICENSE.md -%{_libdir}/libcbor.so.0* -%{abidir}/libcbor.dump - -%files doc -%doc README.md - +%{_libdir}/libcbor.so.* +%{abidir}/*.dump %files devel +%{_libdir}/libcbor.so +%{_libdir}/pkgconfig/libcbor.pc %{_includedir}/cbor.h %{_includedir}/cbor/*.h %{_includedir}/cbor/internal/*.h -%{_libdir}/libcbor.so -%{_libdir}/pkgconfig/libcbor.pc %{_mandir}/man3/libcbor.3* +%files doc +%doc README.md + + %changelog +* Fri Apr 07 2023 chen_yu_ao - 0.10.2-3 +- change spec file format + * Tue Mar 07 2023 chen_yu_ao - 0.10.2-2 - remove redundant dependencies which was introduced for so compatibility -- Gitee