【linux】【rpm】 一般rpm 制作的过程

安装 rpmbulid 之后 

 

https://blog.csdn.net/weixin_44208042/article/details/89216844

yum install  rpmbuild 

mkdir -pv  /root/rpmbuild/{BUILD,RPMS,SOURCES,SPECS,SRPMS,BUILDROOT}

 

 

# 目录文件 创建情况
/root/rpmbuild/BUILDROOT/kingbasedump-sc-db-cluster1m-1.0-1.el7.x86_64/usr/bin/kingbasedump-sc-db-cluster1m.sh

# SPEC 文件信息
Name: kingbasedump-sc-db-cluster1m
Version: 1.0
Release: 1.el7
Summary: ceshi
License: GPL
Group: Applications/System
Vendor: crsc
Buildarch: noarch

%description
%prep
%build
%pre
%post
%preun
%postun
%files
/usr/bin/
========================================================
# 规律 ${NAME_PKG}'/usr/bin/'${NAME_FILE}
# 单个文件
/root/rpmbuild/BUILDROOT/kingbasedump-sc-db-cluster1m-1.1-1.el7.x86_64/usr/bin/kingbasedump-sc-db-cluster1m.sh
cd /root/rpmbuild/SPEC/
rpmbuild -bb kingbase_dump-1.1.spec

 

 

注意: 其实  ,这个版本号,可以说是作者虚构的,可以轻易的修改。一定程度能上,能够让安装rpm包的上边 识别成不同的程序。

 

posted @ 2021-06-10 18:10  allen514519  阅读(194)  评论(0)    收藏  举报