init spec and get-version script
init for first version 0.1.1 Signed-off-by: snoweay <snoweay@163.com>
This commit is contained in:
parent
95bef6e2fa
commit
2d447e59d3
36
README.en.md
36
README.en.md
@ -1,36 +0,0 @@
|
||||
# syscare
|
||||
|
||||
#### Description
|
||||
System Hot Services. We take care of the operating system.
|
||||
|
||||
#### Software Architecture
|
||||
Software architecture description
|
||||
|
||||
#### Installation
|
||||
|
||||
1. xxxx
|
||||
2. xxxx
|
||||
3. xxxx
|
||||
|
||||
#### Instructions
|
||||
|
||||
1. xxxx
|
||||
2. xxxx
|
||||
3. xxxx
|
||||
|
||||
#### Contribution
|
||||
|
||||
1. Fork the repository
|
||||
2. Create Feat_xxx branch
|
||||
3. Commit your code
|
||||
4. Create Pull Request
|
||||
|
||||
|
||||
#### Gitee Feature
|
||||
|
||||
1. You can use Readme\_XXX.md to support different languages, such as Readme\_en.md, Readme\_zh.md
|
||||
2. Gitee blog [blog.gitee.com](https://blog.gitee.com)
|
||||
3. Explore open source project [https://gitee.com/explore](https://gitee.com/explore)
|
||||
4. The most valuable open source project [GVP](https://gitee.com/gvp)
|
||||
5. The manual of Gitee [https://gitee.com/help](https://gitee.com/help)
|
||||
6. The most popular members [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)
|
||||
37
README.md
37
README.md
@ -1,37 +0,0 @@
|
||||
# syscare
|
||||
|
||||
#### 介绍
|
||||
System Hot Services. We take care of the operating system.
|
||||
|
||||
#### 软件架构
|
||||
软件架构说明
|
||||
|
||||
|
||||
#### 安装教程
|
||||
|
||||
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. Gitee 官方博客 [blog.gitee.com](https://blog.gitee.com)
|
||||
3. 你可以 [https://gitee.com/explore](https://gitee.com/explore) 这个地址来了解 Gitee 上的优秀开源项目
|
||||
4. [GVP](https://gitee.com/gvp) 全称是 Gitee 最有价值开源项目,是综合评定出的优秀开源项目
|
||||
5. Gitee 官方提供的使用手册 [https://gitee.com/help](https://gitee.com/help)
|
||||
6. Gitee 封面人物是一档用来展示 Gitee 会员风采的栏目 [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)
|
||||
51
get-version.sh
Executable file
51
get-version.sh
Executable file
@ -0,0 +1,51 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
REPO=$1
|
||||
VERSION=$2
|
||||
|
||||
if [ -z "${REPO}" ]; then
|
||||
echo "Please assign a directory of syscare repo."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z "${VERSION}" ]; then
|
||||
VERSION=HEAD
|
||||
fi
|
||||
|
||||
cd ${REPO}
|
||||
REPO=$(pwd)
|
||||
REPO=${REPO##*/}
|
||||
cd -
|
||||
cp -r ${REPO} ${REPO}-${VERSION}
|
||||
cd ${REPO}-${VERSION}
|
||||
|
||||
git checkout ${VERSION}
|
||||
|
||||
for file in `find . -name Cargo.toml`
|
||||
do
|
||||
dir=${file%/Cargo.toml*}
|
||||
|
||||
if [ -n "${dir}" ]; then
|
||||
cd ${dir}
|
||||
cargo vendor
|
||||
mkdir -p .cargo
|
||||
|
||||
cat > .cargo/config << EOF
|
||||
[source.crates-io]
|
||||
replace-with = "local-registry"
|
||||
|
||||
[source.local-registry]
|
||||
directory = "vendor"
|
||||
EOF
|
||||
|
||||
cd -
|
||||
fi
|
||||
done
|
||||
|
||||
cd ..
|
||||
|
||||
rm -rf ${REPO}-${VERSION}/.git
|
||||
tar -zcf ${REPO}-${VERSION}.tar.gz ${REPO}-${VERSION}
|
||||
echo "Output: ${REPO}-${VERSION}.tar.gz"
|
||||
|
||||
BIN
syscare-0.1.1.tar.gz
Normal file
BIN
syscare-0.1.1.tar.gz
Normal file
Binary file not shown.
57
syscare.spec
Normal file
57
syscare.spec
Normal file
@ -0,0 +1,57 @@
|
||||
%global debug_package %{nil}
|
||||
|
||||
Name: syscare
|
||||
Version: 0.1.1
|
||||
Release: 1
|
||||
Summary: system hot-fix service
|
||||
|
||||
License: MulanPSL-2.0, GPLv2
|
||||
URL: https://gitee.com/openeuler/syscare
|
||||
Source0: %{name}-%{version}.tar.gz
|
||||
|
||||
ExclusiveArch: x86_64
|
||||
|
||||
BuildRequires: rust cargo gcc gcc-g++ cmake make
|
||||
BuildRequires: elfutils-libelf-devel
|
||||
|
||||
Requires: kpatch-runtime
|
||||
|
||||
%description
|
||||
SysCare is a system-level hot-fix software that provides single-machine-level and cluster-level security patches and system error hot-fixes for the operating system.
|
||||
The host can fix the system problem without rebooting.
|
||||
|
||||
%package build
|
||||
Summary: Tools for build syscare patch.
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
Requires: kpatch make gcc openssl-devel dwarves python3-devel bison flex
|
||||
Requires: rpm-build
|
||||
|
||||
%description build
|
||||
Syscare build tools.
|
||||
|
||||
%prep
|
||||
%autosetup -p1
|
||||
|
||||
%build
|
||||
cmake .
|
||||
make
|
||||
|
||||
%install
|
||||
%make_install
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
%dir /usr/libexec/%{name}
|
||||
%attr(750,root,root) /usr/bin/syscare
|
||||
|
||||
%files build
|
||||
%defattr(-,root,root,-)
|
||||
%dir /usr/libexec/%{name}
|
||||
%attr(750,root,root) /usr/libexec/%{name}/upatch-diff
|
||||
%attr(750,root,root) /usr/libexec/%{name}/upatch-build
|
||||
%attr(750,root,root) /usr/libexec/%{name}/upatch-tool
|
||||
%attr(750,root,root) /usr/libexec/%{name}/syscare-build
|
||||
|
||||
%changelog
|
||||
* Mon Nov 21 2022 snoweay<snoweay@163.com> - 0.1.1-1
|
||||
- init version for 0.1.1-1.
|
||||
Loading…
x
Reference in New Issue
Block a user