diff options
| author | CoprDistGit <infra@openeuler.org> | 2026-09-23 14:10:11 +0000 |
|---|---|---|
| committer | CoprDistGit <infra@openeuler.org> | 2026-09-23 14:10:11 +0000 |
| commit | f25eb833b9b15567d8d5a0ed2088c5046d69a07a (patch) | |
| tree | c8a0174e0e3be124e49142a38c2e026cc936bf26 | |
| parent | 070a3844c10b33a49311b1b12b5bc6a6d787c0e6 (diff) | |
automatic import of libnanopb-dev
| -rw-r--r-- | .gitignore | 1 | ||||
| -rw-r--r-- | libnanopb-dev.spec | 73 | ||||
| -rw-r--r-- | sources | 1 |
3 files changed, 75 insertions, 0 deletions
@@ -0,0 +1 @@ +/libnanopb-dev-0.4.9.2.tar.gz diff --git a/libnanopb-dev.spec b/libnanopb-dev.spec new file mode 100644 index 0000000..77903d6 --- /dev/null +++ b/libnanopb-dev.spec @@ -0,0 +1,73 @@ +# topdir: libnanopb-dev-0.4.9.2 +# Self-provides cmake(Nanopb): the installed nanopb-config.cmake makes +# find_package(Nanopb) work for downstream consumers. find_package(Nanopb) +# seen by the dependency scanner only comes from examples/ and build-tests/ +# (consumer CMakeLists), never from the library's own build. + +%global debug_package %{nil} + +Name: libnanopb-dev +Version: 0.4.9.2 +Release: 1%{?dist} +Summary: Protocol Buffers for embedded systems - development files + +License: Zlib +URL: https://github.com/nanopb/nanopb +Source0: https://github.com/nanopb/nanopb/archive/0f6d088e777a33dd7b54297f137ef10d745c5da8.tar.gz#/libnanopb-dev-%{version}.tar.gz + +Group: Development/Libraries +Packager: openEuler Builder <builder@openeuler.org> + +BuildRequires: cmake +BuildRequires: gcc +BuildRequires: make +BuildRequires: protobuf-compiler +BuildRequires: python3-devel + +Requires: python3 +Requires: python3-protobuf +Requires: protobuf-compiler + +# This package installs nanopb-config.cmake, so it provides the cmake(Nanopb) +# capability that downstream find_package(Nanopb) consumers look for. +Provides: cmake(Nanopb) = %{version}-%{release} + +%description +Nanopb is a small code-size Protocol Buffers implementation in ANSI C. It is +especially suitable for use in microcontrollers, but fits any memory +restricted system. + +This package contains the C runtime headers, the static library +(libprotobuf-nanopb.a), the CMake integration files (nanopb-config.cmake) and +the nanopb code generator, which converts .proto definitions into .pb.c/.pb.h +source files. + +%prep +%autosetup -n %{name}-%{version} + +%build +%cmake \ + -DBUILD_SHARED_LIBS=OFF \ + -DBUILD_STATIC_LIBS=ON \ + -Dnanopb_BUILD_RUNTIME=ON \ + -Dnanopb_BUILD_GENERATOR=ON \ + -DPython_EXECUTABLE=%{_bindir}/python3 +%cmake_build + +%install +%cmake_install + +%files +%license LICENSE.txt +%doc README.md AUTHORS.txt CHANGELOG.txt +%{_includedir}/nanopb/ +%{_libdir}/libprotobuf-nanopb.a +%{_libdir}/cmake/nanopb/ +%{_bindir}/nanopb_generator +%{_bindir}/nanopb_generator.py +%{_bindir}/protoc-gen-nanopb +%{python3_sitelib}/nanopb/ + +%changelog +* Wed Sep 23 2026 openEuler Builder <builder@openeuler.org> - 0.4.9.2-1 +- Initial package for openEuler @@ -0,0 +1 @@ +1f510192222702be8cebe46555ec2427 libnanopb-dev-0.4.9.2.tar.gz |
