!4 openEuler init

Merge pull request !4 from catastrowings/master
This commit is contained in:
openeuler-ci-bot 2020-01-20 16:40:58 +08:00 committed by Gitee
commit c19ba8de62
5 changed files with 70 additions and 111 deletions

View File

@ -1,39 +0,0 @@
# libkae
#### 介绍
{**以下是码云平台说明,您可以替换此简介**
码云是 OSCHINA 推出的基于 Git 的代码托管平台(同时支持 SVN。专为开发者提供稳定、高效、安全的云端软件开发协作平台
无论是个人、团队、或是企业,都能够用码云实现代码托管、项目管理、协作开发。企业项目请看 [https://gitee.com/enterprises](https://gitee.com/enterprises)}
#### 软件架构
软件架构说明
#### 安装教程
1. xxxx
2. xxxx
3. xxxx
#### 使用说明
1. xxxx
2. xxxx
3. xxxx
#### 参与贡献
1. Fork 本仓库
2. 新建 Feat_xxx 分支
3. 提交代码
4. 新建 Pull Request
#### 码云特技
1. 使用 Readme\_XXX.md 来支持不同的语言,例如 Readme\_en.md, Readme\_zh.md
2. 码云官方博客 [blog.gitee.com](https://blog.gitee.com)
3. 你可以 [https://gitee.com/explore](https://gitee.com/explore) 这个地址来了解码云上的优秀开源项目
4. [GVP](https://gitee.com/gvp) 全称是码云最有价值开源项目,是码云综合评定出的优秀开源项目
5. 码云官方提供的使用手册 [https://gitee.com/help](https://gitee.com/help)
6. 码云封面人物是一档用来展示码云会员风采的栏目 [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)

70
kae.spec Normal file
View File

@ -0,0 +1,70 @@
%global debug_package %{nil}
Name: libkae
Summary: Huawei Kunpeng Accelerator Engine
Version: 1.2.8
Release: 2
License: Apache-2.0
Source: %{name}-%{version}.tar.gz
Vendor: Huawei Corporation
ExclusiveOS: linux
URL: https://support.huawei.com
BuildRoot: %{_tmppath}/%{name}-%{version}-root
Prefix: /usr/local/lib/engines-1.1
Conflicts: %{name} < %{version}-%{release}
Provides: %{name} = %{version}-%{release}
BuildRequires: libwd >= %{version} openssl-devel
%description
This package contains the Huawei Kunpeng Accelerator Engine
%prep
%setup -c -n %{name}-%{version}
%build
cd KAE
chmod +x configure
./configure
make
%install
mkdir -p ${RPM_BUILD_ROOT}/usr/local/lib/engines-1.1
install -b -m -755 KAE/libkae.so.%{version} ${RPM_BUILD_ROOT}/usr/local/lib/engines-1.1
%clean
rm -rf ${RPM_BUILD_ROOT}
%files
%defattr(755,root,root)
/usr/local/lib/engines-1.1/libkae.so.%{version}
%pre
if [ "$1" = "2" ] ; then #2: update
rm -rf $RPM_INSTALL_PREFIX/kae.so > /dev/null 2>&1 || true
rm -rf $RPM_INSTALL_PREFIX/kae.so.0 > /dev/null 2>&1 || true
fi
%post
if [[ "$1" = "1" || "$1" = "2" ]] ; then #1: install 2: update
ln -sf $RPM_INSTALL_PREFIX/libkae.so.%{version} $RPM_INSTALL_PREFIX/kae.so
ln -sf $RPM_INSTALL_PREFIX/libkae.so.%{version} $RPM_INSTALL_PREFIX/kae.so.0
fi
/sbin/ldconfig
%preun
if [ "$1" = "0" ] ; then #0: uninstall
rm -rf $RPM_INSTALL_PREFIX/kae.so > /dev/null 2>&1 || true
rm -rf $RPM_INSTALL_PREFIX/kae.so.0 > /dev/null 2>&1 || true
rm -f /var/log/kae.log > /dev/null 2>&1 || true
rm -f /var/log/kae.log.old > /dev/null 2>&1 || true
fi
%postun
/sbin/ldconfig
%changelog
* Mon Jan 20 2020 catastrowings <jianghuhao1994@163.com> 1.2.7-2
- compatible with openEuler
* Tue Jan 07 2020 jinbinhua <jinbinhua@huawei.com> 1.2.7-1
- First Spec Version Include kunpeng_engine Code

Binary file not shown.

BIN
libkae-1.2.8.tar.gz Normal file

Binary file not shown.

View File

@ -1,72 +0,0 @@
Name: libkae
Summary: Huawei Kunpeng Accelerator Engine
Version: 1.1.10
Release: 1
Source: %{name}-%{version}.tar.gz
Vendor: Huawei Corporation
License: Apache-2.0
ExclusiveOS: linux
ExclusiveArch: aarch64
Group: System Environment/Kernel
Provides: %{name} = %{version}
URL:https://support.huawei.com
BuildRoot: %{_tmppath}/%{name}-%{version}-root
Requires: libwd >= %{version}
Autoreq: no
Autoprov: no
Prefix: /usr/local/lib/engines-1.1
Conflicts: %{name} < %{version}
BuildRequires: libwd >= %{version} openssl-devel
%description
This package contains the Huawei Kunpeng Accelerator Engine
%prep
%global debug_package %{nil}
%setup -c -n %{name}-%{version}
%build
cd kunpeng_engine
chmod +x configure
./configure
make
%install
mkdir -p ${RPM_BUILD_ROOT}/usr/local/lib/engines-1.1
install -p -m 0755 kunpeng_engine/libkae.so.%{version} ${RPM_BUILD_ROOT}/usr/local/lib/engines-1.1
%clean
rm -rf ${RPM_BUILD_ROOT}
%files
%defattr(755,root,root)
/usr/local/lib/engines-1.1/libkae.so.%{version}
%pre
if [ "$1" = "2" ] ; then #2: update
rm -rf $RPM_INSTALL_PREFIX/kae.so > /dev/null 2>&1 || true
rm -rf $RPM_INSTALL_PREFIX/kae.so.0 > /dev/null 2>&1 || true
fi
%post
if [[ "$1" = "1" || "$1" = "2" ]] ; then #1: install 2: update
ln -sf $RPM_INSTALL_PREFIX/libkae.so.%{version} $RPM_INSTALL_PREFIX/kae.so
ln -sf $RPM_INSTALL_PREFIX/libkae.so.%{version} $RPM_INSTALL_PREFIX/kae.so.0
fi
/sbin/ldconfig
%preun
if [ "$1" = "0" ] ; then #0: uninstall
rm -rf $RPM_INSTALL_PREFIX/kae.so
rm -rf $RPM_INSTALL_PREFIX/kae.so.0
if [ -e /var/log/kae.log ] ; then
rm -f /var/log/kae.log
fi
fi
%postun
/sbin/ldconfig
%changelog