1 Star 0 Fork 26

YoungJQ/clibcni_src

forked from src-openEuler/clibcni 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
clibcni.spec 2.58 KB
一键复制 编辑 原始数据 按行查看 历史
%global _version 2.0.2
%global _release 20200902.113625.git660192c5
Name: clibcni
Version: %{_version}
Release: %{_release}
Summary: CNI - the Container Network Interface
Group: System Environment/Libraries
License: Mulan PSL v2
URL: https://gitee.com/openeuler/clibcni
Source0: https://gitee.com/openeuler/clibcni/repository/archive/v%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}
BuildRequires: gcc
BuildRequires: cmake
BuildRequires: lcr-devel yajl-devel
Requires: lcr
%ifarch x86_64 aarch64
Provides: lib%{name}.so()(64bit)
%endif
%description
CNI (Container Network Interface), a Cloud Native Computing Foundation project,
consists of a specification and libraries for writing plugins to configure
network interfaces in Linux containers, along with a number of supported
plugins. CNI concerns itself only with network connectivity of containers and
removing allocated resources when the container is deleted. Because of this
focus, CNI has a wide range of support and the specification is simple to implement.
%package devel
Summary: Huawei CNI C Library
Group: Libraries
ExclusiveArch: x86_64 aarch64
Requires: %{name} = %{version}-%{release}
%description devel
the %{name}-libs package contains libraries for running %{name} applications.
%global debug_package %{nil}
%prep
%autosetup -n %{name} -Sgit -p1
%build
mkdir -p build
cd build
%cmake -DDEBUG=OFF -DLIB_INSTALL_DIR=%{_libdir} ../
%make_build
%install
rm -rf %{buildroot}
cd build
install -d $RPM_BUILD_ROOT/%{_libdir}
install -m 0644 ./src/libclibcni.so %{buildroot}/%{_libdir}/libclibcni.so
install -d $RPM_BUILD_ROOT/%{_libdir}/pkgconfig
install -m 0644 ./conf/clibcni.pc %{buildroot}/%{_libdir}/pkgconfig/clibcni.pc
install -d $RPM_BUILD_ROOT/%{_includedir}/clibcni
install -m 0644 ../src/api.h %{buildroot}/%{_includedir}/clibcni/api.h
install -m 0644 ../src/types/types.h %{buildroot}/%{_includedir}/clibcni/types.h
install -m 0644 ../src/version/version.h %{buildroot}/%{_includedir}/clibcni/version.h
find %{buildroot} -type f -name '*.la' -exec rm -f {} ';'
find %{buildroot} -name '*.a' -exec rm -f {} ';'
find %{buildroot} -name '*.cmake' -exec rm -f {} ';'
%clean
rm -rf %{buildroot}
%pre
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%defattr(-,root,root,-)
%{_libdir}/lib%{name}.so*
%files devel
%defattr(-,root,root,-)
%{_includedir}/%{name}/*.h
%{_libdir}/pkgconfig/%{name}.pc
%changelog
* Wed Sep 02 2020 YoungJQ <[email protected]> - 2.0.2-20200902.113625.git660192c5
- Type:enhancement
- ID:NA
- SUG:NA
- DESC: modify source0 address
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/yang_jiaqi11/clibcni_src.git
[email protected]:yang_jiaqi11/clibcni_src.git
yang_jiaqi11
clibcni_src
clibcni_src
master

搜索帮助